SP_Transaction Notification Query for Transaction Category field

Dear Experts,
I want to make Transaction Category field mandatory under Tax Tab on Sales Order document and being tried SP_Transaction Notification.
Please send me right query or any other solution.....
Thanks.....

Hi!
Try this
IF (@object_type = '17')
BEGIN
if (@transaction_type in ('A','U'))
BEGIN
if exists ( Select R0.Docentry from ORDR R0, RDR12 R12  where R0.Docentry=@list_of_cols_val_tab_del and
R0.Docentry=R12.Docentry and (R12.Transcat is Null or R12.Transcat=''))
BEGIN
  set @error = 0
END
ELSE
BEGIN
    set @error_message='Enter the Transaction Code in Tax Tab'
    set @error=1  
END
END END
Regards,
[Thanga Raj K|Q3 Wrap-Up: What happened in the third quarter of 2009 in the SAP Business One Community]

Similar Messages

  • Notification Query for Item Group

    Dear Experts,
    Please Guide me for a Notification Query for this Scenario :
    I want to put a Notification Query for a  Group i.e. when any user do transactions in any form or any Particular form using items
    of this Group than if the Item Quantity is in Decimal then he can not do that Transaction and Get Error Message.
    Thanks in Advance.
    Atul Chakraborty

    Hi Atul,
    to achieve this you have to write SPTN at the back end
    under databases node select your live database.
    Select programability
    select stored procedure
    select db.sbo.SP_Transactionnotification
    and paste your code into
    ADD YOUR CODE AREA
    If (@object_type = '17') and (@transaction_type in ('A', 'U'))
    BEGIN
         Declare @ItmGrpCode as int
         Declare @Qty as int
         set @ItmGrpcode = (select oitm.itmsgrpcod from oitm inner join rdr1 on oitm.itemcode = rdr1.itemcode inner join ordr on   
            rdr1.docentry = ordr.docentry where  ordr.docentry=@list_of_cols_val_tab_del)
            set @Qty = (select quantity from rdr1 inner join ordr on ordr.docentry = rdr1.docentry where ordr.docentry =
            @list_of_cols_val_tab_del)
         BEGIN
                        if @ItmGrpcode = 10 and @qty = 0
                        Begin
                             set @error = -1
                             set @error_message = 'Invalid Input'
                       End
           End
    END
    Like wise by capturing object type and dml mode you have to write code for every document that you want to check.
    For example I've given code for Sales Order.
    hope this will help you
    Thanking you
    Malhaar'

  • In a query, for the selection field 'KNB1-ZWELS' a match-code isn't availab

    Hi All,
    Creating a query, for the selection field 'KNB1-ZWELS' a match-code isn't available.
    Could anyone tell me the reason?
    Thanks
    Gandalf

    Hi,
    Match Code Object is not available for the field ZWELS. If required, You need to contact a Developer for creating one .

  • NOTIFICATION QUERY FOR UDF COLUMN

    Dear experts,
    I want notification query for delivery should not be add without fill up the information in  machine number column (UDF Column- U_MCnumber)
    Please do needful.
    Thanks & Regards,
    Akshata

    Dear all,
    I have got query ...........
    If @object_type = '15'and @transaction_type= ('A')
    BEGIN
    If Exists (Select T0.DocEntry from ODLN T0 Inner Join DLN1 T1
    On T0.DocEntry=T1.DocEntry INNER JOIN OITM T3 ON T3.ItemCode = T1.ItemCode
    Where (T1.U_MCnumber Is Null and T3.ITMsgrpcod='119')
    And T0.DocEntry = @list_of_cols_val_tab_del  )
    BEGIN
    Select @error = -1,
    @error_message = 'Please fill up machine number!!!'
    End
    End
    Thanks & Regards,
    Akshata

  • Applying functions to database fields when querying for a form field

    Hi,
    how is it possible to apply trim() or another method to the content of a database field when a query is initiated?
    The actual problem is that there are entries in the database which are entailed by a blank and, because the user is not aware of this fact, he cannot be forced to add a blank or % to the form field he is querying.
    Does anyone have an idea how to solve this issue?
    Thank you very much in advance.
    Message was edited by:
    user492074
    null

    The where clause is built that way:
    WHERE (ETN.trim(ETN_PLZ)=:1)
    The error message:
    ORA-00904: "ETN"."TRIM": invalid identifier
    Actually, I guess that the trim statements should surround ETN.ETN_PLZ but that is obviously not the case.
    Apart from that I did not enter 1 as the value to query for.
    Nevertheless, thank you for your help. Forms version is 10.1.2 by the way.

  • Reg Query For Multiple Text Fields

    Hi all
    I am New to this forum..
    I am developing an application for generating reports.
    In my application i have multiple text fields.
    The user might enter any of the textfields or even enter all the fields.
    In those cases how to use the query when some fields are empty??

    Welcome to the forum.
    It always helps to post a small, simplified example of what it is you're trying to achieve.
    (When posting examples, put the {noformat}{noformat} tag before and after the example, so it will get posted formatted on this forum.)
    In those cases how to use the query when some fields are empty??If your textfields serve as parameters/bind variables for you query, then you could use NVL.
    Something like:select ...
    from some_table
    where col1 = nvl(p_col1, col1)
    and col2 = nvl(p_col2, col2)
    And how about wildcards (the '%' or '_' sign), by the way? Are they allowed as well?
    You also might want to read about this approach:
    http://www.oracle.com/technology/oramag/oracle/09-jul/o49asktom.html                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

  • Creating an SQL Query for Project Custom Fields Values

    Hello:
    I'm currently trying to create an SQL Query to show all of the server's Project Custom Fields Values, along with the modification date.
    So far, I've managed to display correctly all of the data for all of the Projects' text value Custom Fields (those not based on a LookUp Table) with this query:
    SELECT
    MSP_PROJECTS.PROJ_NAME,
    MSP_CUSTOM_FIELDS.MD_PROP_NAME,
    MSP_PROJ_CUSTOM_FIELD_VALUES.CODE_VALUE,
    MSP_PROJ_CUSTOM_FIELD_VALUES.TEXT_VALUE,
    MSP_PROJ_CUSTOM_FIELD_VALUES.MOD_DATE
    FROM
    MSP_PROJ_CUSTOM_FIELD_VALUES
    INNER JOIN
    MSP_CUSTOM_FIELDS
    ON MSP_CUSTOM_FIELDS.MD_PROP_UID = MSP_PROJ_CUSTOM_FIELD_VALUES.MD_PROP_UID
    INNER JOIN
    MSP_PROJECTS
    ON MSP_PROJECTS.PROJ_UID = MSP_PROJ_CUSTOM_FIELD_VALUES.PROJ_UID
    WHERE
    MSP_PROJ_CUSTOM_FIELD_VALUES.CODE_VALUE IS NULL
    ORDER BY
    MSP_PROJ_CUSTOM_FIELD_VALUES.PROJ_UID,
    MSP_PROJ_CUSTOM_FIELD_VALUES.MD_PROP_UID
    However, when I try a new Query to obtain the actual values for the Projects Custom Fields that do use a LookUp Table, I can't seem to find what table in the model I'm supposed to link to the MSP_PROJ_CUSTOM_FIELD_VALUES.CODE_VALUE field (the TEXT_VALUE
    field has NULL value when CODE_VALUE field isn't NULL)
    Any suggestions on how to obtain the actual Projects' custom fields values instead of the Code Value, for Metadata that do use a LookUp Table?
    Also, I'm able to run this query only in the Published Database, since the MSP_CUSTOM_FIELDS table is empy in the Draft Database. Why is that?
    Awaiting your kind reply,
    Sebastián Armas PMO Project Manager

    Hi Sebastián, rather than directly accessing the database it would be better to use the PSI to get this data.  Take a look at the ProjTool sample in the SDK whcih gets this data.
    Best regards,
    Brian.
    Blog |
    Facebook | Twitter | Posting is provided "AS IS" with no warranties, and confers no rights.
    Project Server TechCenter |
    Project Developer Center |
    Project Server Help | Project Product Page

  • Need BAPI/RFC for Updating Category field of CRM_DNO_MONITOR  from SAP R/3.

    Hi SAP GURUS!!
    I need to have a new field category in "Create support message"  of the HELP menu in SAP server. This field values needs tobe updated with that of Category in Solution Manager ( CRM_DNO_MONITOR) .We have found a BADI (SBCOS001 ) where we designed the screen for having the new field. FOr updating the value of this field to sol man, is there any bapi or rfc ..
    Thanks in Advance,
    gopa.

    Hi
    Please check the following points.
    1. Please check the settings that you maintained in the table CRMSUBTAB in ECC. You need to have an entry as follows:
    User: CRM
    Object: VENDOR_MAIN
    U/D : DOWNLOAD
    Object Class: VEND ( & not BUPA for this entry)
    Function Module: PI_BP_VENDOR_MAIN_EXTRACT
    The other entry (for upload) has similar but different values. (Refer to the OSS note 883162.)
    2. Check if you have applied any filter settings in CRM for the adapter object VENDOR_MAIN.
    Regards,
    Srini.

  • Display Title in BEX query for Master Data Field

    Hi All,
    Appreciate if someone can assist me in this.
    When we display query result, we will have results of master data field for as master data and Text, e.g Customer and customer text.
    BEX display:
    Header Line : Customer
    Display Line : 90002011   Mary Kay
                          90002023   John Smith
    For the header Line, we have title 'customer', can we have the title for 'Customer Description' instead of having it as a blank field.
    Appreciate if someone can assist me in this, I cant find this issue posted by anyone.
    Thank you.

    Hi,
    For one object you can not have seperate description for key and text.
    Either you need to have seperate object. Check if your Customer object is having some name attribute then display cutomer key with name attribute so that there will be two object and you may change the description in report display.
    If this is not possible then you may not have dirctly in reporting. You need to stage one more object in staging area with same cutomer field then one you may use as text the other one as key.
    I hope it will help.
    Thanks,
    S

  • Query for Transaction number in Create Accounting = Draft Mode

    Hi al!!
    I run the Create Accounting program concurrent in my R12 instance in DRAFT MODE, and when the concurrent program finish i want to obtain the TRANSACTION number of the transactions in the XLA_AE_LINES table, how can i do that ???... it's for AP_INVOICES, AP_PAYMENTS, RECEIPT and CE Tables...
    Thanks in advance..
    Pablo.-

    1 row in ap_invoice_distributions_all ------> 1 row in xla_ae_lines.xla_ae_lines will have more than one row. dr and cr has to be there for each journal entry.
    I want to do a query that get lines from XLA_AE_LINES and then obtain the transaction number (AP_INVOICES_ALL.INVOICE_NUM) that was generated this line in the table.Check the link http://www.orafaq.com/node/2242
    I know that this is possible to do using the XLA_ENTITY_TRANSACTIONS table... but when the concurrent is run in DRAFT mode no line are created in this table.The rows in xla_transaction_entities table will get created when the invoice is created. NOT after running accounting, which is much earlier.
    Check the link http://www.orafaq.com/node/2243
    Also some more details on draft, final accounting are available at http://www.orafaq.com/node/2240
    By
    Vamsi

  • Query for yes/no field

    Hello,
    I have an access database with a Yes/No field. In access
    table it creates a checkbox which is checked if it is yes. Now, i
    want to query this field in my code. I am using CFMX7.
    <cfquery name="qcategoy" datasource="xyz">
    select *
    from tblgroup
    Where 1=1
    <cfif form.group1 EQ 'broilers'>AND broiler =
    true</cfif>
    </cfquery>
    I want this to be exported to an excel spreadsheet. If I take
    away the condition of "Broilers" then it works fine, but when I add
    this <cfif> code, I get an error
    "Internet Explorer was not able to open this file"
    BTW, this code is able to export the report to excel
    correctly in CF5, but in CFMX7 there is an error.
    Please help.

    start by looking at how the values come through the drivers.
    <cfquery name = "abc">
    select distinct true_false_field
    from yourtable
    <cfdump var="#abc#">
    What do you get in your dump?

  • Query for selecting the field of VBRK

    Hi All,
      I have fetched the Ztable into it_bauch.
    In the loop of It_bauch i have to fetch the records of vbrk in which the field of zuonr is wrongly stored in xblnr.
    while fetching VBRK the zuonr0(8) should be comapred with it_zbauch-xblnr2(8).
    select single * from vbrk where fkart = 'F2'
                                      and fktyp = 'L'
                                      and vbtyp = 'M'
                                      and rfbsk = 'C'
                                      and fksto = space.
                                 <b>  and ZUONR0(8)  = it_wabuch-xblnr2(8).</b>
    ZUONR0(8)  = it_wabuch-xblnr2(8).</b>
    the above line cannot be return so the below code is given whether it would work or not or any other solution kindly do respond
          data : begin of it_vbrk occurs 0.
                  include structure vbrk.
          data :  end of it_vbrk.
          data vbrk_flag type c.
    data : begin of wa_vbrk,
              zuonr(8) type c,
              end of wa_vbrk.
    loop at it_bauch.
    select single * from vbrk into  it_vbrk where fkart = 'F2'
                                      and fktyp = 'L'
                                      and vbtyp = 'M'
                                      and rfbsk = 'C'
                                      and fksto = space.
    loop at it_vbrk.
            wa_vbrk-zuonr  = it_vbrk-ZUONR+0(8).
            read table it_wabuch with key xblnr+2(8) = wa_vbrk-zuonr.
            if sy-subrc = 0.
              clear vbrk_flag.
              vbrk_flag = 'X'.
            endif.
            clear wa_vbrk-zuonr.
          endloop.
    if vbrl-zuonr  =  'X'.
    After lot of select querey are there based on above condition would trigger.
    endif.
    endloop.

    data : vxblnr(9).
    vxblnr = it_wabuch-xblnr+2(8).
    concatenate vxblnr '%' into vxblnr.
    select single * from vbrk where fkart = 'F2'
    and fktyp = 'L'
    and vbtyp = 'M'
    and rfbsk = 'C'
    and fksto = space.
    and ZUONR like vxblnr.
    regards
    shiba dutta

  • What is "Category" field for?

    In the iTunes List View, you can change or enter info for most columns for a song, for example the name column, by simply clicking in that column. The insertion point appears and you can type or change the name of an item. However, this doesn't happen for the Category field. If you click it, no insertion point appears. Plus, the Category field doesn't appear in the "Get Info" window.
    What is this Category field for?

    I believe Category is mainly used for Podcast tagging where the author of podcasts can categorize the type of podcast. For example, Cartoon, Music, Comedy, Spoken Word, or whatever categories you normally see for podcasts in the Apple Store.
    If you have podcasts, go to the podcasts and turn on the Category header to see what I mean.
    Patrick

  • Need to write a query for extractions

    How can I extract the following data from Oracle:
    1. Segment1 and description from mtl_system_items_b
    2. Onhand quantity that is orderable (Not under the WIP manufacturing or PO)
    3. Onhand quantity that not orderable (That is under WIP manufacturing or PO)
    4. Retail Price of these items.
    There is only one organization_id =21 needs to be considered. This extract needs to be a daily kind of an extract. If you can help me in writing the query for all the fields above with proper joins, I'll really appreciate.
    Thanks & Regards
    KM

    Hi,
    Primary_uom_code and Primary_transaction_quantity shows the items quantity on the basis of primary code
    whereas Secondary_uom_code and secondary_transction_quantity shows the items quantity on different code.
    e.g. suppose you have an item Pen opened on the primary code as Each. 1 Each = 1 Pen.
    You have a conversion set as 10 Each = 1 Pkt.
    At the time of transaction if you selects as 1 Pkt,
    The primary_transaction_quantity will show 10 Each where as the secondary_transaction_quantity will show 1Pkt.
    Now as the transaction has done as Pkt the column Transaction_quantity will display 10Pkt.
    If you have done this transaction on the primary code as 10 Each.
    The primary_transaction_quantity would show the same 10 Each but the Secondary_transaction_quantity will by
    null and the transaction_quantity will be 10 Each.
    Hope this will clarify the issue.
    2) why you want to join these tables
    How can I join the following tables: qp_list_lines and mtl_system_items_b? I want to find the price of each
    item. I tried using inventory_item_id but it does not work as inventory_item_id can be null in qp_list_lines table.i have not been able to find any thing in table qp_list_lines.

  • Select Query for smart form-invoice

    Hi Folks,
    I have to fetch the following fields as per the requirement for desiging a invoice smartform.I had copied lb_bill_invoice smartform into z format.
    Can anyone here please give me the select query for the same.
    fields to fetched are as follows:-
    1.vbrp-arktx,
    2.vbrp-fkimg,
    3.konv-kbetr with respect to vbrk-knumv
    4.konv-kwert.
    And also what all I have to give in format interface and global definitions of the smartform.
    please help  me in this regard.
    Points will be given.
    K.Kiran.

    Hi,
    declare the variables V_arktx(40) and v_Qty like vbrp-fkimp  and other varaibles for Kbetr, kwert, knumv on the global definitions.
    select  single arktx fkimg into (v_arktx, v_qty) from vbrp
    where vbeln = LBBIL_IT_REFPURORD-BIL_NUMBER.
    select single knumv into v_knumv from vbrk where where vbeln = LBBIL_IT_REFPURORD-BIL_NUMBER.
    this select has to fire in the item level and in the loop.
    so have to write in the correct place.
    select kbetr kwert into (v_kbetr, v_kwert) from konv
    where where knumv = v_knumv and kposn = LBBIL_IT_REFPURORD-ITM_NUMBER.
    regards,
    anji

Maybe you are looking for

  • How do i add a video in a PDF from an URL

    My dilemma: Creating an Interactive PDF using java and I would like to add various streaming video's throughout the pdf from url.  I would like them to run within the pdf.  I would like people to be able to play them, and then play them again if they

  • Can't save emailed images direct from mail to iPhoto anymore..

    Before the recent upgrade to mountain lion I was able to save pictures sent to me via email direct to iPhoto. This is not working anymore, but the dropdown box indicates that it can be done. Does anyone know of a fix for this? Or is this another side

  • Won't boot to desktop (picture anomally)- monitor goes and stays black

    Folks I've got a strange anomally here. I've got an aroginal G4 dual 500 running Tiger that won't provide any video por picture signal to the connected Apple 22" Cinema Display (the orginal with ADC). The machine boots and shows the grey screen with

  • Hibernatio​n turns on Function Keys

    On a G62-225DX notebook, when I hibernate my computer overnight and turn it on the next morning, the function keys enable themselves (they're previously disabled, i.e. press fn + F key to use the function).  However, when I restart and go into BIOS,

  • Structure for OM

    Hi , I want to know that like there is a common structure for an Employees Personnel Administration infotypes 'PRELP' wherein I can check that for each employee which Infotypes exist and I can update that likewise I want to know that is there also a