Sequence in combination with function

Hi,
I have an issue with a sequence in combination with a function.
I want to generate some kind of an inventory material report that contains some kind of a material ID (a non-repeating, auto-incrementing number, gaps allowed). However I have to keep track of which material IDs I have used for which inventory material, for traceability reasons. Another important requirement is that whenever the report is run, that the returned material IDs are never repeating. So repeatedly runs for the same inventory material should always return new material ID.
So I was about to create a simple PL/SQL function where I pass my data from traceability as parameters. Then the function uses internally a sequence (nextval) to generate a new material ID, then stores the new material ID with the related values from the input parameters into a table (autonomous transaction) and returns the new ID.
This works pretty fine so far.
Now the tricky part: I want have a SQL statement where I want to return one and the same ID in different columns.
Let me give an example:
CREATE SEQUENCE XXX_TEST_SEQ
MINVALUE 1 MAXVALUE 999999999999999999999999999
INCREMENT BY 1 START WITH 1
NOCACHE NOORDER NOCYCLE;
CREATE PACKAGE XXX_TEST_PKG AUTHID CURRENT_USER AS
FUNCTION get_id(p_someparameter NUMBER) RETURN NUMBER;
END XXX_TEST_PKG;
CREATE PACKAGE BODY XXX_TEST_PKG AS
FUNCTION get_id(p_someparameter NUMBER) RETURN NUMBER IS
  l_new_id NUMBER;
BEGIN
  SELECT XXX_TEST_SEQ.NEXTVAL
    INTO l_new_id
    FROM DUAL;
    /* do some more logic, e.g. store the freshly generated ID
        together with the input parameter values in some tracing table */
  RETURN l_new_id;
END get_id;
END XXX_TEST_PKG;This is a simplified version of the function for demo.
Let's use it:
-- 1) this works as expected:
select xxx_test_pkg.get_id(1) from dual;
XXX_TEST_PKG.GET_ID(1)
1                       
-- 2) this returns two different numbers:
select xxx_test_pkg.get_id(1) as id_one
    ,  xxx_test_pkg.get_id(1) as id_two
from dual;
ID_ONE                 ID_TWO                
2                      3                     
-- 3) This is the problematic case: I want to return the same ID two times:
select my_id as id
     , my_id as same_id
from (select xxx_test_pkg.get_id(1) as my_id from dual);
ID                     SAME_ID               
4                      5                     
-- 4) CURVAL on these sequence does not work:
select my_id as id
     , xxx_test_seq.curval as same_id
from (select xxx_test_pkg.get_id(1) as my_id from dual);
SQL Error: ORA-00904: "XXX_TEST_SEQ"."CURVAL": invalid identifier
-- 5) This gives the output that I need, but why?
select my_id as id
     , xxx_test_seq.nextval as same_id
from (select xxx_test_pkg.get_id(1) as my_id from dual);
ID                     SAME_ID               
7                      7                      So query 3 is the one that gives me headaches. I need to return one and the same ID in different columns. But this returns just two different IDs. I know that the optimizer will merge the two select statements into one and therefore execute the function twice. Does anybody know how I could avoid this?
What is a bit strange to me is that query 5 really returns what I need, but at a first glance I would say it should not do so. I would say that using nextval would return me again another sequence number.
This is confusing... Can anybody explain this and advise how I could build a query were I can get the same ID two times per row?
I know I can totally get rid of the sequence in my function and use something different, but I was wondering if I can avoid changing my function.
Thanks,
David.

David Weber wrote:
thanks lot for all the great feedback. That's really helpful. I think I'll go for the NO_MERGE hint. A first test with this looks good.Keep in mind, only undocumented hint MATERIALIZE along with subquery factoring clause WITH (for which this hint was created) will work in real queries:
SQL> select my_id as id
  2       , my_id as same_id
  3  from (select /*+ NO_MERGE */ xxx_test_pkg.get_id(1) as my_id from dual),emp where rownum < 6;
        ID    SAME_ID
        20         20
        21         21
        21         21
        21         21
        21         21
SQL> select my_id as id
  2       , my_id as same_id
  3  from (select xxx_test_pkg.get_id(1) as my_id from dual where rownum=1),emp where rownum < 6;
        ID    SAME_ID
        22         22
        23         23
        23         23
        23         23
        23         23
SQL> select my_id as id
  2       , my_id as same_id
  3  from (select /*+ MATERIALIZE */ xxx_test_pkg.get_id(1) as my_id from dual),emp where rownum < 6;
        ID    SAME_ID
        24         25
        26         27
        28         29
        30         31
        32         33
SQL> with t as (select /*+ MATERIALIZE */ xxx_test_pkg.get_id(1) as my_id from dual)
  2  select my_id as id
  3       , my_id as same_id
  4  from t,emp where rownum < 6;
        ID    SAME_ID
        34         34
        34         34
        34         34
        34         34
        34         34
SQL> SY.

Similar Messages

  • Use of business partner functionality in combination with dual control

    Is there a generally agreed upon procedure to use the business partner functionality in combination with dual control? The problem is that when you block a business partner, the customer/ vendor master data aren't blocked automatically. You can then still use them in transactions, which leads to problems.
    So is there a way to make this work or a procedure to do this?
    Niels Vanwingh

    Thanks Masa,
    I did notice the 'Add external supplier from' in create supplier or bidder option. However there is a small catch and your experience may help.
    Let me explain the requirement and scenario here in SRM 7.
    We are implementing the Registration of Supplier scenario; both ROS and SRM are in same client. When a potential supplier registers themselves in the registration system, a BP number is created (an Internal number range is defined for this). After accepting the potential supplier in pre-select screen the purchaser has two options to transfer the potential supplier from the ROS system to SRM
    Option 1: He can select the accepted potential supplier from the supplier directory option and transfer the business partner to SRM. In this case the business partner number of the potential supplier is retained in SRM and a business partner with supplier and bidder tag is created. However the purchaser does not have any option to select which type of business partner he would like to create like supplier or bidder.
    Option 2: Purchase can go to create supplier or bidder option and choose the u2018Add external supplier formu2019 from the ROS system and create the business partner. The ROS business partner details are copied to the create supplier screen, but the purchaser have to provide an external business partner number for the supplier. This is because we have defined external number range for business partner for the vendors that are replicated from ERP to SRM.
    Objective is the ROS business partner should be retained in SRM with option to create as supplier and bidder and then manually create ERP supplier with same SRM BP number and map against SRM supplier.
    Is there any way we can achieve this?
    In SRM 5.5 with Manage business partner functionality we could achieve as system give us the option which business partner type we would like to create as well as retains the ROS BP number in SRM.
    Regards
    Sandeep

  • Satellite L650: Some combinations with the FN button do not work on W7x64

    Hello,
    System
    <h3>Satellite L650-1KU</h3>Part number
    <h3><span class="partNo">PSK1LE-01700MRU</h3>
    I have install Windows by myself - this laptop haven't any OS from factory.
    Installed Windows 7 x64, all drivers and utilites from Toshiba driver site for windows 7 x64 accessible for my laptop model.
    I have no any unknown devices in Windows Device manager, all drivers installed and all hardware components woks fine i.e. wifi or bluetooth or web camera.
    But I still can't use some of keyboard combinations with Fn button. Not all, just five combinations do not work: Fn+F2 power modes, Fn+F4 hibernate, Fn+1,2 zoom and Fn+F8 wirelles devices.
    From search I have found only mentions about Fn+1,2 zoom - this funtion provide some util named Toshiba Zoom but on download page no any Toshiba Zoom for my laptop model and W7.
    Looks like there must be installed some additional utils from vendor for handling this combinations but I cant find any additional info or soft on driver download page.
    May be there are some utils what shold be located in lists of drivers/soft for 32 bit windows and it will be fine for 64 bit one?
    All combinations which works fine like volume +- Fn+3 Fn+4 or mute Fn+ESC does not shows any popus at moment of pressing, just <span class="short_text"><span class="hps">perform <span class="hps">its <span class="hps">function <span class="hps">without any indication.
    Dear users and support, can you help me what I should install from additional utils to provide support for combinations Fn+F2 power modes, Fn+F4 hibernate Fn+1,2 zoom and Fn+F8 wirelles devices?
    Message was edited by: Gimli_r

    Have you installed the Toshiba Value Added Package?
    Have a look on the Toshiba support/downloads website. Ensure you install the Win7 64bit version of TVAP designed for the L650 series.
    Updating the BIOS may also help.

  • Bug? Mailto: in combination with Office 2013 Spell Checking.

    Dear community,
    For one of our sollutions we use the mailto protocol to send a hyperlink which users can use to automatically open a predefined new-email-window.
    This works fine with Office Professional Plus 2010 [EN-US] (32bit) in combinatione with Microsoft Office Language Pack 2010 - Dutch/Nederlands (32bit).
    However, Office Professional Plus 2013 [EN-US] (32bit), in combination with Microsoft Office Language Pack 2013 - Dutch/Nederlands (32bit), crashes whenever the spellingcheck is started.
    The mailto-command we use to reproduce this problem is (enter command in Internet Explorer, open with Outlook):
    mailto:[email protected]?subject=%20Actie%20vereist&body=%5b2103162%2f335159076094968874376260057075247208793%5d
    During analyses we concluded:
    - Office Configuration Analyzer Tool 1.2 (Full Scan) did not find any related issues.
    - Spellchecker crashes while checking the text within the body.
    - Uninstalling Microsoft Office Language Pack 2013 - Dutch/Nederlands solves the problem, but obviosly, we want to keep the Dutch spelling check functionality.
    - Standard Englsh (U.S.) spellchecking functions without problems.
    - This problem is reproducable on any computer running Office Professional Plus 2013 [EN-US] in combination with the Dutch (Nederlands) spelling check. Tried multiple hardware configurations (Intel based) and multiple OS's (Windows 7 Enterprise
    (64bit), Windows 8.1 Enterprise (64bit), Windows 8.1 Pro (64bit). All with the same result.
    Is there way to solve this issue, without loosing Outlook 2013 as client and Dutch Spelling Check capabilities?
    Kind regards,
    Leon Kandelaars.

    Hi Steve,
    Thanks for your reaction.
    Q - Do you mean Outlook crashes when we click the Spelling & Grammar button under Review tab?
    A - Yeah, if you try to edit the mail and have 'check spelling as you type' activated, it wil crash as well.
    Q - If we copy the email body and paste it to a new email message, will this issue continue?
    Does this   issue happen with other Office 2013 programs? Please try to use 'spell check' in word and check if the same issue occurs.
    A - If you copy the generated body to a new email or Word 2013, the spelling check will in both cases crash the application.
    Q - In addition, we can also have a look at the event log to see if we can find anything useful.
    A - The crash generates an "Application" "Hang error". I've generated 2 (1 with Outlook, 1 with Word):
    Generated mail, spellcheck crashes Outlook:
    Log Name:      Application
    Source:        Application Hang
    Date:          10-3-2015 9:52:31
    Event ID:      1002
    Task Category: (101)
    Level:         Error
    Keywords:      Classic
    User:          N/A
    Computer:      xxxx.xxxx.xxx.nl
    Description:
    The program OUTLOOK.EXE version 15.0.4693.1000 stopped interacting with Windows and was closed. To see if more information about the problem is available, check the problem history in the Action Center control panel.
    Process ID: 87c
    Start Time: 01d05b0effb4e6f8
    Termination Time: 0
    Application Path: C:\Program Files (x86)\Microsoft Office\Office15\OUTLOOK.EXE
    Report Id: bf3cde85-c702-11e4-a8c6-485ab6f00dbb
    Event Xml:
    <Event xmlns="http://schemas.microsoft.com/win/2004/08/events/event">
      <System>
        <Provider Name="Application Hang" />
        <EventID Qualifiers="0">1002</EventID>
        <Level>2</Level>
        <Task>101</Task>
        <Keywords>0x80000000000000</Keywords>
        <TimeCreated SystemTime="2015-03-10T08:52:31.000000000Z" />
        <EventRecordID>14242</EventRecordID>
        <Channel>Application</Channel>
        <Computer>xxxx.xxxx.xxx.nl</Computer>
        <Security />
      </System>
      <EventData>
        <Data>OUTLOOK.EXE</Data>
        <Data>15.0.4693.1000</Data>
        <Data>87c</Data>
        <Data>01d05b0effb4e6f8</Data>
        <Data>0</Data>
        <Data>C:\Program Files (x86)\Microsoft Office\Office15\OUTLOOK.EXE</Data>
        <Data>bf3cde85-c702-11e4-a8c6-485ab6f00dbb</Data>
        <Binary>55006E006B006E006F0077006E0000000000</Binary>
      </EventData>
    </Event>
    Copied body to Word, spellcheck crashes Word:
    Log Name:      Application
    Source:        Application Hang
    Date:          10-3-2015 9:57:15
    Event ID:      1002
    Task Category: (101)
    Level:         Error
    Keywords:      Classic
    User:          N/A
    Computer:      xxxx.xxxx.xxx.nl
    Description:
    The program WINWORD.EXE version 15.0.4693.1000 stopped interacting with Windows and was closed. To see if more information about the problem is available, check the problem history in the Action Center control panel.
    Process ID: 964
    Start Time: 01d05b0fe8e683af
    Termination Time: 0
    Application Path: C:\Program Files (x86)\Microsoft Office\Office15\WINWORD.EXE
    Report Id: 6a7dd15f-c703-11e4-a8c6-485ab6f00dbb
    Event Xml:
    <Event xmlns="http://schemas.microsoft.com/win/2004/08/events/event">
      <System>
        <Provider Name="Application Hang" />
        <EventID Qualifiers="0">1002</EventID>
        <Level>2</Level>
        <Task>101</Task>
        <Keywords>0x80000000000000</Keywords>
        <TimeCreated SystemTime="2015-03-10T08:57:15.000000000Z" />
        <EventRecordID>14247</EventRecordID>
        <Channel>Application</Channel>
        <Computer>xxxx.xxxx.xxx.nl</Computer>
        <Security />
      </System>
      <EventData>
        <Data>WINWORD.EXE</Data>
        <Data>15.0.4693.1000</Data>
        <Data>964</Data>
        <Data>01d05b0fe8e683af</Data>
        <Data>0</Data>
        <Data>C:\Program Files (x86)\Microsoft Office\Office15\WINWORD.EXE</Data>
        <Data>6a7dd15f-c703-11e4-a8c6-485ab6f00dbb</Data>
        <Binary>55006E006B006E006F0077006E0000000000</Binary>
      </EventData>
    </Event>

  • Advanced Antialias in combination with a lot of text does not show well

    I am using embedded fonts in combination with antiAliasType ADVANCED which gives good results for smaller fontsizes.
    But if the textField contains a lot of text (> 20000 characters) then part of the text is simply NOT shown. So the first couple of hundreds of lines are shown, then a couple of hundereds are not, then the next again are shown and so on. I have experimented with different values of the sharpness, but without results. Anyone any idea?
    Thanks!
    _textField.antiAliasType=AntiAliasType.ADVANCED
    _textField.sharpness=300

    I cannot reproduce this issue with neither dynamic nor authoring font embedding approach. All text displays fine.
    You may need to make sure that font you embed has all the characters first.
    The code I used:
    In Flash IDE (given Arial is embedded):
    init();
    function init():void
         var tf:TextField = new TextField();
         tf.multiline = tf.wordWrap = true;
         tf.width = 1200;
         tf.autoSize = "left";
         tf.embedFonts = true;
         tf.antiAliasType = AntiAliasType.ADVANCED;
         tf.sharpness = 300;
         tf.defaultTextFormat = new TextFormat("Arial", 9);
         tf.text = "";
         addChild(tf);
         while (tf.text.length < 20000) {
              tf.appendText(" " + String.fromCharCode(33 + Math.random() * 93));
    And as a document class with Embed metatag:
    package
         import flash.display.Sprite;
         import flash.text.AntiAliasType;
         import flash.text.Font;
         import flash.text.TextField;
         import flash.text.TextFormat;
         public class LargeText extends Sprite
              [Embed(systemFont="Arial",fontName="_arial",mimeType="application/x-font-truetype",embedAsCFF="false")]
              private var font:Class;
              public function LargeText()
                   init();
              private function init():void
                   var tf:TextField = new TextField();
                   tf.multiline = tf.wordWrap = true;
                   tf.width = 1200;
                   tf.autoSize = "left";
                   tf.embedFonts = true;
                   tf.antiAliasType = AntiAliasType.ADVANCED;
                   tf.sharpness = 300;
                   tf.defaultTextFormat = new TextFormat("_arial", 9);
                   tf.text = "";
                   addChild(tf);
                   while (tf.text.length < 20000)
                        tf.appendText(" " + String.fromCharCode(33 + Math.random() * 93));

  • Using own SQLite DB in combination with Data Management

    Hi,
    Currently on a huge project we're we are using LCDS 3.1 in combination with a AIR 2.5 client.
    I've been reading "Using Adobe LiveCycle Data Services ES2 version 3.1" and I have a question. In the chapter "Building an offline-enabled application" it says on the very first line:
    "You can use an offline adapter with an AIR SQLite database to perform offline fills when a desktop client is disconnected from the LiveCycle Data Services server. An offline adapter contains the SQL queries for AIR SQLite for retrieving cached items like an assembler on the server retrieves items from the data source."
    However, in my experience that AIR SQLite database is not just any DB but one that Datamanagment designs and generates itself, based on the Dto the DataManagement destination is managing. The offline adapter doesn't work like an assembler at all, because the documentation says you can only override the methods pertaining to constructing the WHERE, and ORDER BY parts of the queries, not the SELECT, CREATE, FROM,... parts.
    In our case, we have a database on the server, constructed according to a very specific ERD, and we have a SQLite database on the client, also constructed according to a very specific ERD. What we want to do is execute every fill, create, update, delete against the offline cache and only synchronize with the backend when we want it the synchronize (technically possible by playing with the autoMerge, autoSaveCache, autoConnect,... properties). So what part of datamanagement can we customize to use our DB instead of a generated one?
    Thx in advance!

    You are correct in noting that Data Management does not allow you to use your own database to store offline data.  This data is exclusively managed by the LCDS library for the developer.  The intent is that the local cache is a reflection of the server data, not an independent copy.
    If you have an existing database in AIR, then you will have much more direct control over the querying and updating of that data by using the SQLite APIs directly.
    That being said, you can in essence replicate the data stored on the server, managed by Data Management, in the offline cache.  In an upcoming release (winter 2011) we will have a few features ('briefcases' and a 'changes-only' fill) that will make this story even more compelling for your use cases.  But even with the 3.1 functionality, you can do something like the following:
    Perform a fill() to collect the data you want to have available on the client, save this in the offline cache
    Construct an Offline Adapter Actionscript class that implements the fills you want to perform on the local data
    Use the DataService.localFill() API to perform all of the client application fills, turn off autoCommit.
    When the client is online, call commit() to store client changes and call fill() to refresh the cached data.
    This should give you some ideas on how you could go about constructing your app to leverage the offline features of Data Services.
    Tom

  • Problem with function call from sql when using distinct

    I have the following problem.
    SELECT DISTINCT colA from tabA where my_function(colB) = 'TRUE'
    This statement will return a handfull of results from a table with 70k + records. The function takes about 0.5 secs to execute.
    How do i force the optimizer to do the select distinct first then execute the function on the results rather than execute the function for every single line first?
    Thanks in advance
    Keith

    Let's compare some of those methods:
    michaels>  CREATE OR REPLACE FUNCTION my_function (tr VARCHAR2)
       RETURN VARCHAR2
    AS
    BEGIN
       DBMS_APPLICATION_INFO.set_client_info (SYS_CONTEXT ('userenv','client_info') + 1);
       IF LOWER (tr) LIKE '%name%'
       THEN
          RETURN 'TRUE';
       ELSE
          RETURN 'FALSE';
       END IF;
    END my_function;
    Function created.
    michaels>  CREATE TABLE taba AS SELECT object_id cola ,object_name colb FROM all_arguments
    Table created.
    michaels>  SELECT COUNT(*) FROM taba
      COUNT(*)
         78786
    michaels>  EXEC dbms_application_info.set_client_info(0)
    michaels>  SELECT DISTINCT colA from tabA where my_function(colB) = 'TRUE'
    167 rows selected.
    michaels>  SELECT SYS_CONTEXT ('userenv','client_info') ci FROM dual
    CI   
    78786
    michaels>  EXEC dbms_application_info.set_client_info(0)
    michaels>  SELECT DISTINCT cola FROM (SELECT ROWNUM r, t.* FROM (SELECT DISTINCT cola, colb FROM taba) t)
              WHERE my_function (colb) = 'TRUE'
    167 rows selected.
    michaels>  SELECT SYS_CONTEXT ('userenv','client_info') ci FROM dual
    CI   
    14225
    michaels>  EXEC dbms_application_info.set_client_info(0)
    michaels>  SELECT DISTINCT cola FROM taba WHERE (SELECT my_function (colb) FROM DUAL) = 'TRUE'
    167 rows selected.
    michaels>  SELECT SYS_CONTEXT ('userenv','client_info') ci FROM dual
    CI   
    14281
    michaels>  EXEC dbms_application_info.set_client_info(0)
    michaels>  SELECT DISTINCT cola FROM taba WHERE EXISTS (SELECT ROWNUM FROM dual WHERE my_function (colb) = 'TRUE')
    167 rows selected.
    michaels>  SELECT SYS_CONTEXT ('userenv','client_info') ci FROM dual
    CI   
    13913
    michaels>  EXEC dbms_application_info.set_client_info(0)
    michaels>  WITH temp AS
      (SELECT DISTINCT colA, colB FROM tabA)
    SELECT DISTINCT colA FROM temp WHERE  my_function(colB) = 'TRUE'
    167 rows selected.
    michaels>  SELECT SYS_CONTEXT ('userenv','client_info') ci FROM dual
    CI   
    78786
    michaels>  EXEC dbms_application_info.set_client_info(0)
    michaels>  WITH temp AS
      (SELECT colB, my_function(colB) func FROM (SELECT DISTINCT colB FROM   tabA))
    SELECT DISTINCT colA FROM tabA a, temp t WHERE  a.colB = t.colB AND t.func = 'TRUE'
    michaels>  SELECT SYS_CONTEXT ('userenv','client_info') ci FROM dual
    CI   
    78786 The combination with exists, rownum and dual gives the least calls to the function.

  • Personal recruitment How to do new measure with function call Update IT4000

    Hi out there and happy new year to forum,
    i want to update to implement a recruitment measure (Transaction PB40). I did it already with batch input, but i guess it's much more comfortable to do with funtion module, bapi or calsses.
    After choosing the measure, the infogroup will be processed. So i guess, i just have to use the corresponding function modules to update the infotypes in a given sequence. is this suggestion right?
    What are these function modules? How to update f.e. IT4000? Does anyone has a coding snippet?
    Is it HR_INFOTYPE_OPERATION? 
    In our Infogroup there are also customer specific infotypes f.e. 9***. Can I use the sap standard function modules for "own implemented" infotypes?
    I also appreciate an abap oo pattern or any similar....
    Best regards,
    T

    Andy Goris wrote:
    But I don't think that it's possible to hire an application completly with function modules (there is no PERNR in the beginning so I would keep the BIM).
    The applicants already exists in system, i just want to implement a measure with exact one click!
    Otherwise there is a BAPI for applicant_create.
    I'm not very expierienced focussing the implementation in pa-recruiting. I'm really looking for a good documentation or anything like that f.e. sap press.
    Andy Goris wrote:
    ... but why would you use the old recruiting database? This is hardly used anymore.
    What are the alternatives to it. (I'm not looking forward to upgrade releases or using wd4a or webgui). we are on ecc 6.0 There is already a lot of z-coding in recruitment. We are also using an self implemented e-recruiting approach
    Edited by: Timo Ehl on Jan 3, 2012 2:30 PM

  • CK727 -Lot size cannot be passed on in combination with mixed costing

    I get below error.
    We have KMAT materials and scenario  is Non Valuated Sales Order Stock.
    in our PPC4 - we have below settings. (Both are SAP recommended)
    Qty Structure tab we have Pass on Lot size "1" with individual requirements (must of Non Valuated Sales) and
    Transfer Control "PC03" has "Current Std Cost" with "Transfer only with Collective requirements"
    I just created a mixed cost qty structure. In it I even added Costing type "01". Sales order costing type is "18".
    Mixed costing works as expected. However we are unable to create any Sales Orders.
    Lot size cannot be passed on in combination with mixed costing
    Message no. CK727
    Diagnosis
    For costing variant PPC4 and costing version 01, it was defined in Customizing that a mixed cost estimate should be created for quantity structure category M0001. At the same time, it was defined in the costing variant that the Pass_on_lot_size function should be active.
    System Response
    Mixed costing cannot be carried out simultaneously with Pass on lot size . Costing cannot be proceeded with.
    Any help is appreciated.

    Hi Kala,
    system's response is correct
    In the standard program the combination of mixed costing and
    simultaneously pass on lot size is not possible.
    Please review SAP Notes 402440, 584420 and 749128 .
    In particular the SAP Note 402440 describes the determination of the
    costing lot size at a mixed costing in detail.
    br, Guido

  • X-distr.chain status in combination with valid from date

    Hello I am using MM02 X-distr.chain status in combination with valid from date, to give materials a certain status in the sales order depending on the delivery date of the orderline.
    How can I enter multiple statuses with future validation dates?
    example following status with validation dates where entered in MM02 for a material
    - material should have status A valid from January
    - material should have status B valid form April
    - material should have status C valid from July
    - material should have status D valid from September
    When I enter a sales order with delivery date in January system replies with status C.
    When I enter a sales order with delivery date in April system replies with status C .
    When I enter a sales order with delivery date in July system replies with status C .
    When I enter a sales order with delivery date in September system replies with status D.
    So only the current  ( or previous status when current is not valid yet) is retained by the system.
    How could multiple statuses be used?
    Thanks in advance
    Joos

    Hello Jalo,
    Thanks for your reply,
    My customer sell season relevant materials so they want to control order entry and delivery creation based on predefined dates.
    Status A  = material is blocked for order entry and delivery creation
    Status B  = material is allowed for order entry, delivery creation is blocked
    Status C  = material is allowed for order entry and delivery creation.
    Status D  = material is blocked for order entry, delivery creation is allowed.
    I had hoped to use standard functionality with this status field, it meets most of my customers requirements but at this moment the only alternative is to create a new table where this data can defined and create some abap logic in the user exit to set the status base on the table information.
    Regards
    Joos

  • Sequence initialize problem with pre-mapping process

    Hi,
    I use a pre-mapping process in a mapping which executes a function which :
    a) drops a sequence
    b) re-creates the dropped sequence ( CREATE SEQUENCE xxxx START WITH 1)
    But OWB creates always the sequence beginning with 21 as value ?
    If I executes the procedure in SQL manually then it works fine and starts the sequence with 1.
    Is there an explanation for this action (bug ?) ?
    Thanks in advvance,
    Eric

    Hi,
    Its always better to create the sequence manually,import it into OWB and then use it.
    Regards
    Bharath

  • 'fn' key shows desktop (not in combination with f11). How to turn this off?

    iMac 21.5-inch, Late 2012
    OS X Yosemite 10.10.2
    Whenever I press the 'fn' key (standalone) key it shows my desktop, which it makes it difficult for me to use this key in combination with the f1-f12 keys. I had a similar issue on my Macbook Air, which was resolved by changing my keyboard to the correct input source and double checking that no shortcuts had been installed for the keyboard. When I realised that my iMac had the same problem I went through the same steps but nothing changed this time.
    I've restored all shortcuts to default and made sure that my keyboard input source is one that matches my wireless keyboard.
    Any ideas on how to stop the 'fn' standalone key from showing my desktop?

    Hi nbmm000,
    I see that you are experiencing an issue with the function key on your keyboard. While I am sure you have already seen this step, it has not been mentioned in your post, so I thought I would mention it as a troubleshooting step:
    How to change the behavior of function keys on your Mac - Apple Support
    http://support.apple.com/en-us/ht3399
    Thanks for coming to the Apple Support Communities!
    Cheers,
    Braden

  • Can Oracle be forced to use the spatial index for sdo_filter in combination with an or clause? Difference between Enterprise and SE?

    We’re seeing the following issue: sql - Can Oracle be forced to use the spatial index for sdo_filter in combination with an or clause? - Stack Overflow (posted by a colleague of mine) and are curious to know if this behaviour is due to a difference between standard and enterprise, or could we doing something else wrong in our DB config.?
    We have also reproduced the issue on the following stacks:
    Oracle SE One 11.2.0.3 (with Spatial enabled)
    Redhat Linux 2.6.32-358.6.2.el6.x86_64 #1 SMP Thu May 16 20:59:36 UTC 2013 x86_64 x86_64 x86_64 GNU/Linux
    11.2.0.3.0 Standard Edition and 11.2.0.4.0 Standard Edition (both with Spatial enabled)
    Microsoft Windows Server 2003R2 Standard x64 Edition
    However, the SQL works fine if we try it on Oracle 11.2.0.3.0 *Enterprise* Edition.
    Any help or advice would be much appreciated.
    Kindest Regards,
    Kevin

    In my experience sdo_filter ALWAYS uses the spatial index, so that's not the problem. Since you did not provide the explain plans, we can't say for sure but I think yhu is right: Standard Edition can't use the bitmap operations, and thus it'll take longer to combine the results of the two queries (because the optimizer will surely split this OR up in two parts, then combine them).
    BTW: when asking questions about queries here, it would be nice if you posted the queries here as well, so that we do not have to check another website in order to see what you are doing. Plus it will probably get you more answers, because not everyone can be bothered to click on that link. It would also have been nice if you had posted your own answer on the other post here as well, because my recommendation would have been to use union all - but since you already found that out for yourself my recommendation would have been a little late.

  • Some keys don't work in combination with Shift

    Okay  so I have the Pavilion Sleekbook  15-b011nr 
    Serial Number:   [Personal Information Removed]
    Product Number:   C6N92UA
    and today I noticed certain keys don't work in combination with the left Shift for example, Shift+S (both left and right), Shift+M, Shift+Z, Shift +X, Shift+C don't work, shift+F does work but gives me this FV. same with j it gives me JM instead. I installed an updated bios, ran a diagnostic test using F2 and under the compenant test for the keyboard it failed and gave me this
    keyboard test failed
    failure Id # U375BD-6m96P5-MFPX1F-G03B03 
    product id # C6N92Ua#aba
    now while trying to type all this I found other letters now working as well as me not being able to input the semicolon with either shift key. frustrating since I got this laptop in June so it's still under warranty. Has anyone else encountered this problem and if so how do i fix mine? I'm pretty tech savvy so feel free to let me know, or is my only option is a replacement from HP?
    Thanks!

    Hi hzapata, I know that it work fine, after Load preset, but why You lost the default configs?
    Is this my question to Smit.

  • Issue with language specific characters combined with AD-Logon to BO platform and client tools

    We are using SSO via Win AD to logon to BO-Launchpad. Generally this is working which means for Launch Pad no manual log on is needed. But  this is not working for users which have language specific letters in their AD name (e.g. öäüéèê...).
    What we have tried up to now:
    If the AD-User name is Test-BÖ the log on is working with the user name Test-BO with logon type AD
    If the logon Type "SAP" is used than it is possible to use the name Test-BÖ as the username
    Generally it is no problem in AD to use language specific letters (which means it is possible to e.g. log on to Windows with the user Test-BÖ)
    It is possible to read out the AD attributes from BO side and add them to the user. Which means in the user attributes the AD name Test-BÖ is shown via automatic import from AD. So it's not the problem that the character does not reach BO.
    I have opened a ticket concerning that. SAP 1th level support is telling me that this is not a BO problem. They say it is a problem of Tomcat. I don't believe that because the log on with authentification type SAP is working.
    I have set up the same combination (AD User Test-BÖ with SAP User Test-BÖ) as a single sign on authentification in SAP BW and there it is working without problems.
    Which leads me to the conlusion: It is not a problem of AD. It is something which is connected to the BO platform but only combined with logon type AD because SAP Logon is working with language specific characters.

    I have found this article with BO support:
    You cannot add a user name or an object name that only differs by a character with a diacritic mark
    Basically this means AD stores the country specific letters as a base letter internally. Which means that if you have created a user with a country specific letter in the name you can also logon with the Base letter to Windows.
    SAP-GUI and Windows are maybe replacing the country specific letters by the base letter. Due to that SSO is working. BO seems not to be able to do that. Up to now the supporter from BO is telling me that this is not a BO problem.
    Seems to be magic that the colleagues of SAP-GUI are able to to it.

Maybe you are looking for

  • How to configure Load balance

    Dear all,   Newly I installed dialog instance to my CI server, Now I can configure load balance to my CI server. Please send configuration doc for MSLG and what Settings I need to perform in SAPGUI Regards, satish

  • Is there a limit on how many times I can install my CS5?

    I own CS5 and have it installed on 2 computers. I need to upgrade my computers and am wondering if I am going to have any trouble installing CS5 onto new machines. Is there a limit on how many times I can install the program? Do I have to verify owne

  • Fields added using EEWB

    Hi All, i am trying to add new custom fields using EEWB to the Business Activity. i need to know to which tables are these fields added? Also, please advise if the fields can be directly added using screen painter. If yes, how to find the program nam

  • More of a HTML question

    Why is it that when clicking on a http://www...../example.ppt return a page of rubbish? In some sites, i see that it opens the powerpoint presentation nicely, but for mine, it opens a window of binary code. Any ideas?

  • HP Officejet Pro 8600 software issues

    After weeks for non-functioning NEW 8600 and finally reinstalling system software on my computer, I find that everything works until I install the HP software for the 8600.  Immediately the printer works and Internet Explorer longer works, unless I a