How to know about Description from the TransType...?

Hi All,
I have used SBO 2005 A PL 43 SP1 and have some queries below:
SELECT     TOP 100 PERCENT T0.DocDate, T0.TransType, CAST(T0.BASE_REF as char) AS BASE_REF, T0.Warehouse, T0.CardCode, T0.CardName, T0.xInQty, T0.xOutQty, T0.Price, T0.Currency , T1.ItemName, T1.SuppCatNum, CAST(T0.InvntAct as char) AS InvntAct, T2.AcctName, T0.StatusDescr
FROM         vwOINM_DEL0_02 T0 INNER JOIN OITM T1 ON T0.ItemCode = T1.ItemCode LEFT OUTER JOIN OACT T2 ON T0.InvntAct = T2.AcctCode
WHERE (T0.ItemCode = 'RO00 0465') AND (CAST(T0.TransType AS char(3)) + CAST(T0.CardCode AS char) IN ('13 ZZ0 Cash&Carry') OR (T0.TransType <> 13))
AND (T0.xDocDate BETWEEN CONVERT(DATETIME, '2008-01-01 00:00:00', 102) AND CONVERT(DATETIME, '2008-11-25 00:00:00',102)) ORDER BY T0.DocDate, T0.TransNum
TransType -
> is a field name on table "OINM"
How to know about Description from the TransType and where can we relate to the table?
example :
TransType     Description
====================
15          Delivery
13          AR Invoice
59          Goods Receipt
60          Goods Issue
Please anybody can help me...?
Regards,
Agung

You can use function on sql side which to proper transid returns desciption.
The function is as
create FUNCTION [dbo].[trans](@trans integer)
RETURNS varchar(100)
AS
BEGIN
DECLARE @ret varchar(100)
select @ret =
case @trans
when     1     then     'oChartOfAccounts'
when     2     then     'oBusinessPartners'
when     3     then     'oBanks'
when     4     then     'oItems'
when     5     then     'oVatGroups'
when     6     then     'oPriceLists'
when     7     then     'oSpecialPrices'
when     8     then     'oItemProperties'
when     12     then     'oUsers'
when     13     then     'oInvoices'
when     14     then     'oCreditNotes'
when     15     then     'oDeliveryNotes'
when     16     then     'oReturns'
when     17     then     'oOrders'
when     18     then     'oPurchaseInvoices'
when     19     then     'oPurchaseCreditNotes'
when     20     then     'oPurchaseDeliveryNotes'
when     21     then     'oPurchaseReturns'
when     22     then     'oPurchaseOrders'
when     23     then     'oQuotations'
when     24     then     'oIncomingPayments'
when     28     then     'oJournalVouchers'
when     30     then     'oJournalEntries'
when     31     then     'oStockTakings'
when     33     then     'oContacts'
when     36     then     'oCreditCards'
when     37     then     'oCurrencyCodes'
when     40     then     'oPaymentTermsTypes'
when     42     then     'oBankPages'
when     43     then     'oManufacturers'
when     46     then     'oVendorPayments'
when     48     then     'oLandedCostsCodes'
when     49     then     'oShippingTypes'
when     50     then     'oLengthMeasures'
when     51     then     'oWeightMeasures'
when     52     then     'oItemGroups'
when     53     then     'oSalesPersons'
when     56     then     'oCustomsGroups'
when     57     then     'oChecksforPayment'
when     59     then     'oInventoryGenEntry'
when     60     then     'oInventoryGenExit'
when     64     then     'oWarehouses'
when     65     then     'oCommissionGroups'
when     66     then     'oProductTrees'
when     67     then     'oStockTransfer'
when     68     then     'oWorkOrders'
when     70     then     'oCreditPaymentMethods'
when     71     then     'oCreditCardPayments'
when     73     then     'oAlternateCatNum'
when     77     then     'oBudget'
when     78     then     'oBudgetDistribution'
when     81     then     'oMessages'
when     91     then     'oBudgetScenarios'
when     97     then     'oSalesOpportunities'
when     93     then     'oUserDefaultGroups'
when     101     then     'oSalesStages'
when     103     then     'oActivityTypes'
when     104     then     'oActivityLocations'
when     112     then     'oDrafts'
when     116     then     'oDeductionTaxHierarchies'
when     117     then     'oDeductionTaxGroups'
when     125     then     'oAdditionalExpenses'
when     126     then     'oSalesTaxAuthorities'
when     127     then     'oSalesTaxAuthoritiesTypes'
when     128     then     'oSalesTaxCodes'
when     134     then     'oQueryCategories'
when     138     then     'oFactoringIndicators'
when     140     then     'oPaymentsDrafts'
when     142     then     'oAccountSegmentations'
when     143     then     'oAccountSegmentationCategories'
when     144     then     'oWarehouseLocations'
when     145     then     'oForms1099'
when     146     then     'oInventoryCycles'
when     147     then     'oWizardPaymentMethods'
when     150     then     'oBPPriorities'
when     151     then     'oDunningLetters'
when     152     then     'oUserFields'
when     153     then     'oUserTables'
when     156     then     'oPickLists'
when     158     then     'oPaymentRunExport'
when     160     then     'oUserQueries'
when     162     then     'oMaterialRevaluation'
when     163     then     'oCorrectionPurchaseInvoice'
when     164     then     'oCorrectionPurchaseInvoiceReversal'
when     165     then     'oCorrectionInvoice'
when     166     then     'oCorrectionInvoiceReversal'
when     170     then     'oContractTemplates'
when     171     then     'oEmployeesInfo'
when     176     then     'oCustomerEquipmentCards'
when     178     then     'oWithholdingTaxCodes'
when     182     then     'oBillOfExchangeTransactions'
when     189     then     'oKnowledgeBaseSolutions'
when     190     then     'oServiceContracts'
when     191     then     'oServiceCalls'
when     193     then     'oUserKeys'
when     194     then     'oQueue'
when     198     then     'oSalesForecast'
when     200     then     'oTerritories'
when     201     then     'oIndustries'
when     202     then     'oProductionOrders'
when     205     then     'oPackagesTypes'
when     206     then     'oUserObjectsMD'
when     211     then     'oTeams'
when     212     then     'oRelationships'
when     214     then     'oUserPermissionTree'
when     217     then     'oActivityStatus'
when     218     then     'oChooseFromList'
when     219     then     'oFormattedSearches'
when     221     then     'oAttachments2'
when     223     then     'oUserLanguages'
when     224     then     'oMultiLanguageTranslations'
when     229     then     'oDynamicSystemStrings'
when     231     then     'oHouseBankAccounts'
when     247     then     'oBusinessPlaces'
when     250     then     'oLocalEra'
when     280     then     'oSalesTaxInvoice'
when     281     then     'oPurchaseTaxInvoice'
when     300     then     'BoRecordset'
when     305     then     'BoBridge'
when     260     then     'oNotaFiscalUsage'
when     258     then     'oNotaFiscalCFOP'
when     259     then     'oNotaFiscalCST'
when     261     then     'oClosingDateProcedure'
when     10     then     'oBusinessPartnerGroups'
when     278     then     'oBPFiscalRegistryID'
else '?' end
return @ret
end
and call it as
SELECT TOP 100 PERCENT T0.DocDate, dbo.trans(T0.TransType), CAST(T0 ....

Similar Messages

  • I have upgraded my OX from mountain lion to mavericks . the installer is asking for previous product key. How to know about previous key as the trial version is installed and I have paid for upgrade cost?

    I have upgraded my OX from mountain lion to mavericks . the installer is asking for previous product key. How to know about previous key as the trial version is installed and I have paid for upgrade cost? I dont have the previous product key.

    virenkhare wrote:
    I have upgraded my OX from mountain lion to mavericks . the installer is asking for previous product key. How to know about previous key as the trial version is installed and I have paid for upgrade cost? I dont have the previous product key.
    There are no keys, there is no trial version of OSX (ML or Mavericks) and Mavericks is free
    What have you downloaded, and where did you get it

  • How to know about my iphone came from

    how to know about my iphone came from

    If you purchased it from a legitimate, authorized source, you wouldn't have to ask.
    Ask whoever you purchased it from.
    If you can activate it and look under Settings>General>About, check the model #. What does it say?

  • I cut and pasted a description from the Internet. It posted as a link in iPhoto. It seems to have made a global change--all my descriptions are now blue, underlined, and Times Roman 12 rather than Arial white. How can I get this back to the default?

    I cut and pasted a description from the Internet. It posted as a link in iPhoto. It seems to have made a global change--all my descriptions are now blue, underlined, and Times Roman 12 rather than Arial white. How can I get this back to the default?

    Greetings,
    I've never seen this issue, and I handle many iPads, of all versions. WiFi issues are generally local to the WiFi router - they are not all of the same quality, range, immunity to interference, etc. You have distance, building construction, and the biggie - interference.
    At home, I use Apple routers, and have no issues with any of my WiFi enabled devices, computers, mobile devices, etc - even the lowly PeeCees. I have locations where I have Juniper Networks, as well as Aruba, and a few Netgears - all of them work as they should.
    The cheaper routers, Linksys, D-Link, Seimens home units, and many other no name devices have caused issues of various kinds, and even connectivity.
    I have no idea what Starbucks uses, but I always have a good connection, and I go there nearly every morning and get some work done, as well as play.
    You could try changing channels, 2.4 to 5 Gigs, changing locations of the router. I have had to do all of these at one time or another over the many years that I have been a Network Engineer.
    Good Luck - Cheers,
    M.

  • HT2500 Does anyone know how to remove a group from the address panel in mail?

    Does anyone know how to remove a group from the address panel in mail?

    I haven't seen too many questions like this on this forum.  Did you also try the photoshop forums?

  • Do any one knows how to add those arrows from the right and left side of the screen in the youtube widget which allows you to navigate back and forth between video clips?

    do any one knows how to add those arrows from the right and left side of the screen in the youtube widget which allows you to navigate back and forth between video clips?

    do any one knows how to add those arrows from the right and left side of the screen in the youtube widget which allows you to navigate back and forth between video clips?

  • I am using the hp 3525 model printer , i like to know how to take photo print from the printer

    Hi,
    I am using the hp 3525 model printer , i like to know how to take photo print from the printer .
    Regards
    Mukesh.R

    Hi Mukesh,
    I'd like to help, but can you clarify the issue?  Are you asking how to print a photo from your printer?  Also, can you confirm that your printer is a HP Deskjet Ink Advantage 3525 e-All-in-One Printer?
    Thanks!
    Tara
    **Although I am an HP employee, I am speaking for myself and not for HP.

  • We lost access to are computers in the last two month and we want to know how to deauthorize two computers from the itunes account can you please help us?

    We lost access to are computers in the last two months and we want to know how to deauthorize two computers from the ituns account can you please help me please?

    If you don't have access to the computers to manually deauthorize them (they were sold, stolen, etc), then you have to log into your account, deauthorize all computers, and then re-authorize the machine(s) that you want to have access. This page explains how.

  • Restored my 4S. How to get pictures back from the cloud?

    Background: I had a 3GS and on launchday of the 4S I picked one up. A white 32GB on AT&T to be exact.
    I had been having some issues with the battery, so today I figured I'd try and start fresh. Well, I backed up everything on the cloud, and I also backed up everything onto the computer in iTunes when I did the restore.
    I've got my music back. Cool.
    I've got my apps back. Great.
    I can't seem to figure out how to get my photos from the camera roll back. Nor do I know how or if it is even possible to get the photos and my old text messages back on this new restore. Also, none of my mail is coming back either.
    I can see my most recent backup in the iphone settings under iCloud. And I can also see my most recent computer backup on the computer. But I'm not sure what I need to do.
    Any help would be great. Thanks.

    OK - understood.
    There are a couple of ways of going about this. First, my recommended method:
    Restore from a backup (so your photos, SMS etc are on the phone
    Connect to iTunes
    Set the phone to sync photos to a relevant app on your desktop (what app depends whether you're Windows or Mac) - this gets your pics onto the desktop and safe.
    If you want to save SMS, use PhoneView (Mac) or TouchCopy (Windows) or similar to copy them off the phone
    Restore the phone as a new device
    Get the photos back the way you got music etc back - via iTunes sync
    The second method entails using one of the utuilities around the place that can extract from the backup - I have no experience with them, so I don't know how well they work. That's why I go for the first method - simpler, more robust.
    By the way, I came across this other method for SMS:
    http://hints.macworld.com/article.php?story=20090624022758268
    Hope this helps

  • How do I remove apps from the cloud on iPad

    How do I remove apps from the cloud on my ipad

    Courcoul wrote:
    James Ward4 wrote:
    They cannot actually be removed from your AppleID, but they can be hidden.
    Heh, that can become a nuisance. Don't know how many you've accrued in your years of iGadget enjoyment, but I've managed to accumulate nearly 600, all free   So yeah, the list can get lengthy
    I'm afraid to count . I don't spend a lot time worry about it, but have on occassion gone in and hidden a few items. A handful of apps I know I never want to see again, plus some free music tracks that didn't pan out and some TV episodes that no longer have any value to me.

  • How do I download videos from the internet to my mac

    How do I download videos from the internet to my MAC?

    You can use SnapZ Pro X, which will screen record with sound any animation on the monitor into a QuickTime file, but it's expensive.
    If you look for Add-ons for Firefox, there are some that download Flash and YouTube videos to a file on your machine.
    https://www.mozilla.org/en-US/plugincheck/
    You Mac likely will come across sites and content that won't play in Quicktime, on your Mac or in your web browser unless you install additonal codecs
    You can get them here
    Perian
    http://perian.org/
    VLC
    http://www.videolan.org/vlc/download-macosx.html
    Flip4Mac $29
    http://www.telestream.net/flip4mac-wmv/overview.htm
    Bookmark and download Flash from here, DO NOT trust any website telling you to install anything or follow their links.
    Flash update
    http://get.adobe.com/flashplayer/
    Silverlight update
    http://www.microsoft.com/silverlight/get-started/install/default.aspx
    There is a FlashBack trojan making the rounds which tries to con people into installing it by looking like it's the real thing.
    Make sure your Flash (and Silverlight) is current by running these checks
    http://flashbuilder.eu/flash-player-version.html
    https://www.mozilla.org/en-US/plugincheck/
    How to install
    When you click a link, a download of the installer file occurs to your Downloads Folder usually located next to your Trash Can or in your Users Folder.
    Open the folder and double click (or File: Open) the download and icon can appear on your desktop which you open and inside is a installer package which you double click on to launch the installer.
    OS X will check the download to make sure you intended to start it and that it's not malware it knows about.
    Follow the installer instructions to install the software onto your computer and quit when finished.
    Some require the browsers to be closed first, others require the machine to be restarted to enable the software.
    Once the install is completed, remove any and all downloads from your Download folder, it's safer to keep this folder empty so you can keep track of what appears in there.
    Drive by downloads of malware can occur and reside in the Downloads folder, mixing in with files residing there and await your click to install.
    For backup, restore, performance and other tips I've got, read here
    https://discussions.apple.com/message/16276201#16276201

  • How to download a file from the internet using terminal

    how to download a file from the internet using terminal
    does any one know how to download afile from the internet using the Terminal application?

    Use curl. Something like this:
    curl -O http://www.example.com/filename.zip
    For more info, type +man curl+.

  • How do you remove recipients from the To list?

    Say you want to send an email to multiple recipients. You add a few recipients to the To list but then change your mind about including one of them. How do you remove one from the list? So far the only way I can see is go cancel the whole message and start again.

    Touch the persons name you wish to remove. It will highlight in blue. Then hit the destructive backspace (delete) key on the keyboard.

  • HOw Can I remove faces from the URL

    I know that it's in the web.xml file but as soon as i remove the faces part from the file nothing works. Someone please tell me how to properly remove "faces" from the url. Example http:.//localhost:8080/croot/Page1.jsp
    Thanks in advance

    I know that it's in the web.xml file but as soon as i remove the faces part from the file nothing works. Someone please tell me how to properly remove "faces" from the url. Example http:.//localhost:8080/croot/Page1.jsp
    Thanks in advance

  • How to export some data from the tables of an owner with integrity?

    Hi to all,
    How to export some data from the tables of an owner with integrity?
    I want to bring some data from all tables in a single owner of the production database for development environment.
    My initial requirements are: seeking information on company code (emp), contract status (status) and / or effective date of contract settlement (dt_liq_efetiva) - a small amount of data to developers.
    These three fields are present in the main system table (the table of contracts). Then I thought about ...
    - create a temporary table from the query results table to contract;
    - and then use this temporary table as a reference to fetch the data in other tables of the owner while maintaining integrity. But how? I have not found the answer, because: what to do when not there is the possibility of a join between the contract and any other table?
    I am considering the possibility of consulting the names of tables, foreign keys and columns above, and create dynamic SQL. Conceptually, something like:
    select r.constraint_name "FK name",
    r.table_name "FK table",
    r.column_name "FK column",
    up.constraint_name "Referencing name",
    up.table_name "Referencing table",
    up.column_name "Referencing column"
    from all_cons_columns up
    join all_cons_columns r
    using (owner, position), (select r.owner,
    r.constraint_name fk,
    r.table_name table_fk,
    r.r_constraint_name r,
    up.table_name table_r
    from all_constraints up, all_constraints r
    where r.r_owner = up.owner
    and r.r_constraint_name = up.constraint_name
    and up.constraint_type in ('P', 'U')
    and r.constraint_type = 'R'
    and r.owner = 'OWNERNAME') aux
    where r.constraint_name = aux.fk
    and r.table_name = aux.table_fk
    and up.constraint_name = aux.r
    and up.table_name = aux.table_r;
    -- + Dynamic SQL
    If anyone has any suggestions and / or reuse code to me thank you very much!
    After resolving this standoff intend to mount the inserts in utl_file by a table and create another program to read and play in the development environment.
    Thinking...
    Let's Share!
    My thanks in advance,
    Philips

    Thanks, Peter.
    Well, I am working with release 9.2.0.8.0. But the planning is migrate to 10g this year. So my questions are:
    With Data Pump can export data just from tables owned for me (SCHEMAS = MYOWNER) parameterizing the volume of data (SAMPLE) and filters to table (QUERY), right? But parameterizing a contract table QUERY = "WHERE status NOT IN (2,6) ORDER BY contract ":
    1º- the Data Pump automatically searches for related data in other tables in the owner? ex. parcel table has X records related (fk) with Y contracts not in (2,6): X * SAMPLE records will be randomly exported?
    2º- for the tables without relation (fk) and which are within the owner (MYOWNER) the data is exported only based on the parameter SAMPLE?
    Once again, thank you,
    Philips
    Reading Oracle Docs...

Maybe you are looking for

  • How do I transfer Airport Capsule to my new MacBook Pro?

    Just downloaded all from old MacBrook, how do I transfer to new MacBook?

  • Drag drop and dial up

    Has anyone tried using drag and drop with a dial up system? I am just curious if it works. My hunch is it will but a member of our project team had raised this question. :

  • Help! Starting up in terminal/Unix

    When I start up my G5, instead of starting the OSX GUI, it seems to be starting up in Unix - ie I get a black screen with BSD/Darwin, asking me to log on. When I do, I get 'Welcome to Darwin', but I don't know how to start up OSX! I have not chosen a

  • How to recover the administrator user and pass

    hello, I instaled ORACLEXE few days ago, and accord to the instructions I've been using HR user. but now I'd like to login as administrator because i'd like to create a new user. problem is I don't remember the administrato's user and pass. what shou

  • In sequence events - error?

    I am trying to make a sequence of events happen one after another. I have a background image that I want to fade in, blur, and then a panel slides in. Flash is giving me 2 errors when I test: Description: 1119: Access of possibly undefined property M