Sequence for order_number

Hi
Can any one tell me what is the sequence that generate the order_number in oe_order_headers_all table?
I've checked in ETRM too. But no info about the order_number sequence.
Can we change the series of the order_number from year to year? I mean for the year 2009-2010 I want the order number to be like 90XXXXX and for year 2010-2011 the order number has to be like 100XXXXX.
Where can we change the sequence?
Thank you.
Regards
Balu.

This can be done in XSL OR in procedure on the DB side. Performance wise better to do in procedure as mentioned by other use. You can choose to go with DB or XSL approach depending on number of orders you are expecting in a single message. If it is going to be 100s or few thousand messages then keeping it in XSL is not a problem. But if you are planning tens or hundreds of thousands of orders in the same request then better do it in stored procedure.
How do you do in XSL?
1. Put a for each on every unique order no. You can use xsl:Key or xslt:distinct-values() for this.
2. Within for each unique value of order no, use position() function to pass line/order no as 1,2,3... etc. As soon as the loop moves to second iteration for the next unique order no, count will automatically start again from 1,2,3... and so on.
Apart from slightly slower processing time, another drawback from this approach is that the data in the XML you send to DB procedure will be sorted by order numbers. All orders with same number will appear together.
Another problem with this approach is that this will work only within one request, i.e. if the next request contains an order with same no which was already sent in a previous request, for this order the count will again start from 1. So if you want to keep the sequencing maintained across multiple requests, the easiest way to do is in the DB procedure where you can lookup in the table before inserting a new row and insert with next sequence of that order no.

Similar Messages

  • Help with enabling TPM in Task Sequence for Dell Laptops

    Hi there,
    I would appreciate some advice on creating a task sequence for Win8.1 with TPM enabling for Dell laptops; I have BitLocker set up manually with a Group policy, but want to have TPM enabled in the task sequence. I have read older posts on sites such as windows
    noob, but can't see how to reference the CCTK and get TPM going for win8.1 in a SCCM2012 environment. 
    Obviously I haven't created this before so any help would be appreciated; I have noticed when I try to import my CCTK configurations into SCCM as it isn't a zip file I cannot do it.

    Luckily Dell wrote a whitepaper about that subject, see:
    http://en.community.dell.com/techcenter/extras/m/white_papers/20209083
    My Blog: http://www.petervanderwoude.nl/
    Follow me on twitter: pvanderwoude

  • How to create a sequence for an particular item in my apex form

    Hi friends,
    I created an database application, of a form with a report, and it is working fine...
    But in my form, i have a requirement....The below are the existing fields in my form
    issue no
    created by
    start date
    status
    priority
    due date
    Among these fields in my form i need to create a 'Sequence' for my field "issue no",
    So that whenever i opened the form the 'issue number' must generate automatically like 1 for the first time, 2 for the second time and so on..
    For that i created a sequence
    CREATE SEQUENCE "ORDERS_SEQ"
    MINVALUE 1
    MAXVALUE 999999999999999999999999999
    INCREMENT BY 1
    START WITH 1000
    NOCACHE
    NOCYCLE;
    But for validation where i need to write the sequence query for the particular item 'issue no'....i dont have any idea of where to write the validation query for the sequence..
    please tell where i need to write in step wise manner..please help me friends...
    As the below is my validated sequence query for item 'issue no'
    'select seq.issue_id.nextval into issue_no'
    This is my above validation query whether the query that i mentioned is right..if not let me know the validation query..
    And also i need where to apply this validation query in steps..
    Thanks in advance
    Regards,
    Harry...

    Harry,
    Rik is on the right track. Here is a sample insert trigger: Would need to substitute you sequence ORDERS_SEQ with my sequence las_log_seq, how you define or use timestamps is up to you.
    DROP TRIGGER LASDEV.BINS1_LAS_LOG_TBL;
    CREATE OR REPLACE TRIGGER LASDEV."BINS1_LAS_LOG_TBL"
       BEFORE INSERT
       ON las_log_tbl
       FOR EACH ROW
    BEGIN
       -- Description: Insert log_seq, creation_dt, creation_id,
       --              lst_updt_dt and lst_updt_id.
       -- Maintenance:
       -- Date        Actor          Action
       -- ====        =====          ======
       -- 07-Sep-2010 J. Wells       Create.
       :new.creation_id := nvl( v( 'app_user' ), user );
       :new.creation_dt := SYSDATE;
       :new.lst_updt_dt := :new.creation_dt;
       :new.lst_updt_id := :new.creation_id;
        SELECT las_log_seq.NEXTVAL
          INTO :new.las_log_seq
          FROM DUAL;
    END bins1_las_log_tbl;
    /Heff

  • Access sequence for stock transfer order

    Hi,
    My client is a paper industry. client is procuring raw materials from forest center. We are considering forest center as plant 1800 and paper mill as plant 1100. several depots has been created under forest center and considering them as storage location. goods receipt at forest center is happening through scheduling agreements. stock is transfered from forest center depots to mill through stock transport order.
    For each depots, freight value per MT is fixed for transporting goods from forest center to mill. Clients requirement is to maintain the rates for freight for each depots so that it will pick from condition records. No need to enter freight value in stock transport order.
    I have created an access sequence for combination of plant (1800) and forest center depots and maintained condition table. but it is not working as in stock transport order, there is no storage location option for supplying plant. In stock transport order supplying plant is forest center (1800) and receiving plant is mill (1100).
    Please guide me where to maintain the freight rate as this is mandatory for my client.
    Thanks
    Prasant

    Access seq with depot will not work becuse you don't have the storage location field in the header
    Rather create the diff pruchase group for each depot and assign them in STO based on your depot(storage location)
    and create the access sequence based on the palnt and purchase group than it will work.

  • How to create the Access sequence for the Vendor+material+plant combination

    Hi all
    Please let me know How to create the Access sequence for the Vendormaterialplant combination..
    Whats the use? What its effect in purhcase and taxe..
    brief me please

    Hi,
    you are asked to maintain the access sequence for the tax condition for which you are putting 7.5%.
    goto OBQ1 or img..financial accounting new...global settings.... taxes on sales and purchases ......basic settings.....
    find the tax condition type. see in it which access sequence is attached.
    if there is none then use JTAX used for taxes in India.
    or you can create the similar one for your.
    to create the same goto OBQ2.
    new entry or copy JTAX.
    and assign the access sequence to condition type.
    this will resolve your problem if you just need to assign the access sequence.
    regards,
    Adwait Bachuwar

  • One sequence for multiple lookup tables?

    I am sorry if this is off-topic, however can anybody advise what is better - use one sequence for all tables (lookup tables) or to create unique sequence for each table?
    Thanks
    DanielD

    Daniel,
    After you read this (http://asktom.oracle.com/pls/ask/f?p=4950:8:::NO::F4950_P8_DISPLAYID,F4950_P8_CRITERIA:2985886242221,), you may be sorry you asked.
    Scott

  • Is there a way to set up browse sequences for project with multiple TOCs and conditionalized modules

    I'm using RoboHelp 9 with WebHelp output.
    I've got five outputs, one of which contains Help for common functions, while the other four contain Help for licensed modules. When a user opens the Help for a licensed module, the user sees the core Help and the licensed Help. In addition, files are conditionalized so that searching for unlicensed content from a licensed Help module brings up nothing.
    I've been troubleshooting problems with the Previous Topic and Next Topic which, thanks to William, I learned are related to browse sequences. After trying assorted configurations, I've got a couple of questions:
    Does RH support only a single browse sequence in a project, even when the project has multiple outputs & TOCs?
    If RH supports only a single browse sequence, does that mean there is no way to create a unique browse sequence for each separate output?
    If RH supports multiple browse sequences, what is the workflow?
    I also maintain a 'master' TOC that contains all the modules, both common and unlicensed. What I've done for now is to autocreate a browse sequence based on the 'master TOC'. When I generate output for a licensed module, which is conditionalized, I only see the TOC for that module and, therefore, can only browse between books and subbooks in that module. I've also verified that topics that do not appear in the conditionalized module, such as for another licensed module, do not appear in the Search results list either.
    Carol

    Me again, Carol
    You also asked about the functional differences between WebHelp and WebHelp Pro, so let me elaborate.
    I'm aware of only two major differences (other than the extra benefits of feedback analytics reports and management of "Areas" with authentication in RoboHelp Server).
    The behavior of Browse Sequences as explained above
    The fact that Content Categories are not supported in WebHelp Pro for this latest version 9.
    As for the Browse Sequences you are trying to provide for different modules (licensed, etc.): Multiple Browse Sequences are included in a single .BRS file. The sequences are defined in the XML within the single file.
    As a workaround (for either WebHelp or WebHelp Pro) you could create a NGP Help.brs. which you have already created for one module; then backup and archive it. Then, create a modification for the different module before you generate again. The NGP Help.brs. will need to have the same name as your project so you will have to manage the desired .brs file into the project folder when you generate that version. All of your other choices (TOC, Index, Conditional Tags, etc.) would remain the same for the respective modules.
    Finally, I note that you are apparently generating WebHelp Pro right now even though you are not publishing it to the RH Server? This is really not the best practice. You should generate plain WebHelp for a web server that does not have RH Server on it (even though you may be getting away with it). As for your concern about "breaking" something; each output is placed in a different !SSL! folder automatically when you generate, so you should be able to generate WebHelp without interferring with the WebHelp Pro output. Then, you can re-publish to the RH Server using WebHelp Pro whenever the server is ready.
    John Daigle
    Adobe Certified RoboHelp and Captivate Instructor
    Evergreen, Colorado
    www.showmethedemo.com

  • BW error:  "invalid call sequence for interface when recording changes"

    I am getting the error "invalid call sequence for interface when recording changes" when I try to activate a datasource in BW.  Any ideas on how to resolve this error?
    Thanks.

    I already tried that.  This is what's happening..  When I get this error, if I try again it will activate and gets collected into a transport.  I moved this transport to our QA system.  As soon as I try to execute an infopackage under this datasource in QA, I get the error datasource   xxxxx must be activated.   Before the excecution of the infopackage, the datasource is in "Active version executable".   After I get the error message "datasource must be activated", the datasource in the QA system changes to "Active version not executable".   I am not sure all these issues are related back to the "invalid call sequence" error I am getting when I try to activate the data source.
    I also tried recollecting the transport from our Dev system to QA and it still gives the above errors.
    Any help?
    Thanks.

  • Create New Access Sequence for Free Goods

    Hi Guru,
    please help me, I need to do a new Access Sequence for Free Goods, different from standard SAP. (Vendor/Material/Purch. organization)
    The new sequence of access for "Vendor/Plant/Material", I have already created, but at the time that the use in condition, being created PO not shoot the discount goods. (despite having loaded a record condition with MBN1)
    Please help me, to create a condition of discount goods that shots for "Vendor/Plant/Material".
    Tank you
    Miki

    Thank you for your interest,
    but unfortunately I have already made this assignment Field.
    Please help me, there must be a way to run the discount goods.
    Tank you
    Miki

  • Access sequence for the partner is optional?

    Hello Experts,
    Is the access sequence for determining the partners is optional? What if no access sequence is mentioned in the partner determination procedure for any of the partner functions? Is there any other way of determining the partners exists other than access sequence?
    Could you please clarify?
    Thanks in advance!
    Regards,
    Swathi

    No, you must use access sequence. The only other way would be that you write your own function in which you prefill partners and trigger this function with event or if you write the same logic in on of the suitable badies.

  • Access Sequence for Plant/Tax code Combination  for JTAX

    Dear All
    i want to create a new access sequence for "Plant/Tax code" Combination.
    Please let me know the process for the same
    Regards
    Amey

    Hi,
    Goto- M/05.
    Create the condition table by selecting the fields Plant & Tax code.
    Assign this condition table in the Access sequence JTAX as per ur requirement.
    Create condition records (FV11) by choosing the requirec access sequence.
    Regards,
    Satpal

  • Creating sequences for all tables in the database at a time

    Hi ,
    I need to create sequences for all the tables in my database.
    i can create individually ,using toad and sqlplus.
    Can any one give me a code for creating the sequences dynamically at a time for all the tables.
    it is urgent ..
    Regards.

    I need to create sequences for majority of the tables that are having ID column
    which is sequences."The majority" is not the same as all. So you probably want to drive your generation script off the ALL_TAB_COLUMNS view...
    where column_name = 'ID'You need to think about this carefully. You might want different CACHE sizes or different INCREMENT BY clauses for certain tables. You might even (whisper it) want a sequence to be shared by more than one table.
    Code generation is a useful technique, but it is a rare application where one case fits all.
    Cheers, APC
    Blog : http://radiofreetooting.blogspot.com/

  • Urgent please .. condition found without access sequence for payment terms

    Dear All,
    I am seeing the pricing analysis. there is a condition type for which a value is found and it gave me certain payment terms. but when I tried to see the condition record, I am unable to find it.
    Message says ''The cash discount condition amount is not determined using condition technology, but directly from the terms of payment table"
    Please help in understading the meaning of these messge.
    When I looked at condition type, access sequence in not assigned.
    Thank You.
    Regards
    venkat
    Edited by: venkat Kumbham on Apr 28, 2008 3:09 PM

    Hi Venkat,
    We do not maintain an access sequence for cash discount. Its determined from the terms of payment defined by finance ( check Spro - Financial Accounting>Accounts Receivable and Accounts Payable>Business Transactions> Incoming invoice/Crdit Memos>Maintain Terms of Payment )
    Eg: 14 days 2%, 30 net
    You can select the relevent Terms of payment in the customer master.
    You will see the cash discount when you do the billing.
    Hope its clear...
    Rgds,
    sapdt

  • Formal error: Invalid calling sequence for function modules

    Hi All,
    I have developed a function module for FQEVENT 620 Payment: Transfer Line Items for Clearing.
    The clearing works fine.
    After clearing the open items i need to post an FI-CA Document(BAPI : BAPI_CTRACDOCUMENT_CREATE) for each open item(cleared item)
    I have used the bapi : BAPI_CTRACDOCUMENT_CREATE in the same function module that i have developed for FQEVENT 620 Payment: Transfer Line Items for Clearing.Here i am getting an error "Formal error: Invalid calling sequence for function modules".
    So please let me know where i can use this bapi to post fi-ca document.Is there a BAdi or Enhancement Spot where i can use this BAPI or tell me what should i do to overcome this error.
    Regards
    Venkat

    Venkat:
    While I am confused about your business process - creating an open item when clearing one seems strange.  Look into event 0020 which is called after documents are posted - it may present the opportunity to post process additional documents.
    regards,
    bill.

  • Need Sequence for this logic

    Hi,
    I need sequence for autogenerate of code
    Table 1
    id     code
    We need to autogenerate code for every new entity of id 
    ex:
    id          code
    sbi        sbi001
    hsb        hsb002 
    xyz        xyz003
    And
    ex:
    id          code
    sbi      s001
    hsb     h002
    xyz    x003

    You can use a Sequence and Trigger in combination like this
    create table t
      id   varchar2(10)
    , code varchar2(25)
    create sequence t_seq;
    create or replace trigger t_trig before insert on t for each row
    declare
      l_seq integer;
    begin
      select t_seq.nextval into l_seq from dual;
      :new.code := :new.id || to_char(l_seq, 'fm099');
    end;
    insert into t (id) values ('sbi');
    insert into t (id) values ('hsb');
    insert into t (id) values ('xyz');
    select * from t;

Maybe you are looking for

  • Muse site doesn't display properly

    Here's the deal.  I created a site in muse, then exported to html.  Muse created index.html inside of the folder where the muse doc is located.  That's exactly what I expect.  Now, when I ftp to my webserver, all I get is plain text.  I don't think t

  • Macbook pro had coffee spilled on it 2 weeks ago, all works fine except monitor display.

    Macbook pro had coffee spilled on it two weeks ago; all working fine now except for the monitor, display is dim and photos not appearing properly. Any suggestions? Apple said would cost too much to repair, anyone had any luck with outside repair faci

  • Quick email set up question

    Hi All, I just got a Curve 8900 Tmobile new from ebay.  Seller said it was unlocked, but it's not.  I need to use it overseas and on ATT when in the US.  Problem is this...during set up, there is no email set up icon, and from what I think I've read,

  • OLE MSWord VB Objects

    With ActiveDocument.Sections(1)     .Footers(wdHeaderFooterPrimary).PageNumbers.Add End With Does any one know how to call this above MSWord VB object from an ABAP program using OLE Automation? Thank you guys.

  • Sync photo problem.....!!!!

    i face a problem ....that about sync photo, once i done choose the folder and click the apply, it will come out a blank to ask me wanna remove all my application or not...does anyone tell me ? what happen to it???help me pls!!!