Default Logic Optimization

Hello All,
I have built a BADI and I am using it in Default logic. I have included scoping statements in my default logic to get all the information for my BADI. If I look at my default log, the total execution of default logic is 3 mins, out of which 165 seconds is in the query read prior to execution of the BADI. BADI executes only for 10 seconds. How can I decrease this query time? I do have employee dimension with 20,000 members. I use
*XDIM_MEMBERSET EMPLOYEE=<ALL> to get everyone as I am calculating Labor costs at Employee level. Script I have in default logic is:
*XDIM_MEMBERSET TIME = %YEAR%.INP
*XDIM_MEMBERSET JOB = <ALL>
*XDIM_MEMBERSET P_ACCT = FTE,HR_RATE,MNTHLY_PREM_PAY,OT_RATE
*XDIM_MEMBERSET EMPLOYEE = <ALL>
*START_BADI LABOR
QUERY = ON
WRITE = ON
*END_BADI
Any ideas and help is appreciated.
Thanks!

Gersh,
I see drastic performance improvment when I set the QUERY=OFF and read the data in the BADI using UJQ_RUN_RSDRI_QUERY. Is this normal?
Also, I see that if I run my BADI using START_BADI it executes much faster in UJKT rather than in a BPC package. Any ideas why?
Also, why is there performance gain when I perform XDIM_MAXMEMBERS on the script scoping? For instance, one of dimension has 20,000 members. When I have the scoping statement for that dimension as *XDIM_MEMBERSET EMPLOYEE=<ALL> it runs for 20 seconds, but when I specify the same statement along with *XDIM_MAXMEMBERS EMPLOYEE=25,000, its down to 8 seconds.
Thanks.

Similar Messages

  • Finding "Default Logical System Name Model Instance" in DC Project

    Hi,
    While Creating an Adaptive RFCModel, one defines the
    Default Logical System Name for Model Instance & the
    Default Logical System Name for RFCMetadata.
    In which file can I find these settings at a later stage in the Project File Structure.
    Ofcourse, I can view them in the WedynproContentAdministrator under the Jco Destinations.
    But is there anyway to access them in the NWDS?
    Regards
    MK

    Hello MK,
    You'll find the Logical System Names of the JCo destinations in the file ".wdproperties" under the project structure.
    Bala

  • Default logical system names for application and metadata in models.

    hi,
    I have a dbt in web dynpro java. When we create a model, we give the logical system names. When our developement is over, do we have to change these names because in test system and subsequently production system, the backends will be oviously different than developement ?
    how do we change them and re import after changing? in abap we cant change our code in test and prod systems right  so how is it in web dynpro java ?
    thanks

    Hi Jeschael,
    thanks for the reponse.
    When I create the model, I give the default logical system names and on the next screen I give the
    ip address of the backend system, client , login, password etc
    Even though the logical system names wud be same in Dev, Test and Prod systems, the ip address, login password is different so how do I give it ?
    thanks
    B

  • Multiple script logics in default logic... can you control execution ?

    Hi Gurus,
    My default logic consists of two .LGF files both of which do two different Logics functions e.g. A and B
    For one input template when the user saves the data I would like Logic A be run and not Logic B.
    For the second input template I would like the Logic B to be executed and not Logic A.
    Is there a way to achieve this ?
    thanks

    Hi Daniel,
    The point is that his question not seems related to the data itself but to the screen, maybe a special operation for a screen?
    First scenario where the data itself have the reference of the operation. He might be then be able to distinguish even in a scriptlogic.
    Second scenario: The calculation is driven by the screen itself. Then he have several oportunities.
              1) Add extra information if possible in one unused dimension for the purpose of this calculation and use this information to distinguish the operation
              2) trigger the calculation on the default script logic of another application and bypass the calculation with a change of destination_app
              3) In a routing schema in a BADI you will still need to implement one of the two above points or as you know drive the operations through the dimension file ;).
    Best regards,
    Philippe
    Edited by: Martin, Philippe on Mar 30, 2010 3:45 PM

  • Multiple Script Logics in Default Logic.. order of execution... Commit

    Hi,
    I have a situation where I need to perform two activities...
    i) Perform a multiplication operation on the data input by the user - Script Logic A
    ii) Send the data at a summary level to another application. - Script Logic B
    Both Script logics are in the Default Logic
    User opens an input template and makes changes to a few Products (more than 1). I want the script logicA to execute completely (i.e. for all the models) and THEN Script Logic B to execute since Script Logic B summarises the data
    It seems like this is not how the system works.. Rather it goes thru Script Logic A and Script LogicB for the 1st Product, then the 2nd Product and so on...
    I tried using a commit after Script Logic A / before Script logic B and a few other options but to no avail... Any suggestions ???
    The other option is not to put Script Logic B in the Default Logic but to execute it separately... Worse case situation I'll use that option..
    thanks

    Hi,
    Have you defined the scope of the product for the two logics independently.
    Try that by including commit after the first logic. This should work.
    *XDIM_MEMBERSET PRODUCT=BAS(ALL)
    Script 1
    *COMMIT
    *XDIM_MEMBERSET PRODUCT=BAS(ALL)
    Script 2
    *COMMIT
    Hope this helps,
    Regards,
    G.Vijaya Kumar

  • Using %DIM_SET% in default logic

    I have the following logic:
    *SELECT(%TIMESTART%,"CURRENT_PERIOD","SCENARIO","ID='%SCENARIO_SET%'")
    *SELECT(%TIMEROLLING%,"ID","TIME","ID in(select top 6 ID from mbrtime where timeid>=(Select timeid from mbrTime where id='%TIMESTART%') order by timeid)")
    *XDIM_MEMBERSET TIME =%TIMEROLLING%
    *WHEN ACCOUNT_GP
    *IS FC_EOT1NN_P
    *REC(FACTOR=1,ACCOUNT_GP=FC_EOT1NN,TIME=%TIMEROLLING%)
    *ENDWHEN
    *COMMIT
    When I run this logic from datamanager using SSIS package it works fine.
    When I run this logic using default logic, nothing happens.
    How is it possible to use %SCENARIO_SET% (or any other dimension settings which should be dynamically selected) in default logic?
    Kind regards,
    Tim Vierhout
    Edited by: Tim Vierhout on Jan 5, 2010 12:52 PM

    Tim,
    Those SET variable is generated at Data Manager server DLL so if you run it as a default logic, those varibale will not be generated. That's why it doesn't work.
    Thank you
    Regards,
    James Lim

  • Changing Default logical system names of a model.

    Hi
        How could i change the
         Default logical system name for model instances:
         Default logical syatem name for RFC metadata:
        values for existing model? without recreating the model.
         Thanx

    Hi shah kond,
    you can change  rfc destinations of model in 2 differnet ways.
    firs one: right clcik on project
              from the context menu select propeties
              it will open a dialogbox from that select dynpro references then click on jco references tab
    by using add and remove buttons u can add and remove joc destnations
    2.expand ur model class double click output class.now seelct properties view.there u can change the jco destination
    hope this will use ful for u
    Regards
    Naidu

  • Changing the default logical system names for adaptive RFC models

    Hello,
    When I create an Adaptive RFC model the dialog that asks me to specify the model name, package, source folder, etc. has default values in the "Default logical system name for model instances" and "... RFC metadata".
    I know I can type in another name there but I'd like to change the default name to something that fits our naming conventions. Can I change that? If so, can someone tell me where?
    Thanks in advance!
    David.

    Suresh,
    Thank you for your response. However, that is not what I was looking for. Sorry if my post was not clear.
    I knew that I could change it AFTER the import. I also know that I can type in something else besides the default DURING the import.
    What I am asking is if there is a way to change some configuration setting so that the 'default' that comes up in the drop down DURING the import is something different than what comes 'out-of-the-box' with NWDS.
    Hope that clears up what I'm looking for.
    David.
    Message was edited by:
            David Z. Pantich

  • Error in Executing Default Logic

    Hi,
    I included a formula in default logic which is a simple multiplication of two account dimension members:
    *BEGIN
    [P_ACCT].[#CE0004220] = [P_ACCT].[CE0004210]*[P_ACCT].[CE0004230]
    *END
    Was able to successfully validate and save the logic. However, when I tried to send data, the system threw an error:
    "- Error Message -
    Error running default logic (Error checking work status)
              - Rejected record List -
    Error converting records: The root element is missing."
    Have checked the work status and nothing seems to be amiss. Also, I tried removing the formula from the default logic and then sending the data - this worked.
    So there must be some error with the default logic / work status. Could someone please help me out here?
    Thanks in advance
    Regards,
    Meiyalagan
    Edited by: Meiyalagan Kulandaivel on Nov 27, 2008 10:06 AM

    Hi Meiyalagan,
    Can you please indicate which BPC release you are using ?
    I would suggest that you first make the following 2 corrections on your formula:
    1. Add a "#" to the member on the left of the equal sign
    2. Put square brackets around the dimension and member names
    [P_ACCT].[#CE0004220] = [P_ACCT].[CE0004210]*[P_ACCT].[CE0004230]
    After that, you also may need to setup your workstatus. There are two places where you can defined workstatus.
    1. On the application set level, you define a list of the status (like unlocked, submitted, approved, locked, ...) and who is allowed to do what (like that only the manager is allowed to post journal for example)
    2. On the application, you indicate which dimension are used to set that workstatus (usually the combination category / entity / time is used to set and track these workstatus)
    In the Entity (or the dimension you have the OWNER property), you defined the owner of that entity (can also be a list of user or a team). Each owner of a parent is considered as a manager of that entity. If I for example own the entity France, the owner of the Entity Europe will be considered as my manager (as well as the owner of the Entity World). The settings Owner and Manager are used in the Work Status table on the application set, to define who can do which task and who is allowed to change the workstatus (promote it to the next status).
    Regards,
    Marcel

  • Dynamic re-scoping of default logic

    Hi all,
    I'm hoping someone can help on this logic problem -- BPC 5.1 SP5 on SQL 2005.
    My sales planning application has a dimension SKU with 20,000 members, in a very well structured hierarchy. Each SKU is at level 6, and the profit centers are at level 5.
    The default logic calculates sales & cogs amounts (unit * price for each SKU) as well as some discounts (which are planned at the profit center, not SKU level). There is a dummy base member for each profit center to store these discount rates.
    My problem in the default logic is to expand the SKU dim scope
    - when a profit-center driver changes, expand to include all SKUs in that profit center
    - when a SKU quantity or price changes, expand to include the profit-center dummy member
    - and of course, some times a user changes values for not just one, but many, profit centers & SKUs in a single data submission.
    A SKU.ProfitCenter property flags all the relevant members to pick up, but I can't figure out how to do this in default logic. (Batch logic with *SELECTs is not a problem.)
    Option 1. Use a *RUNLOGIC calling SecondLogic.LGF file, with a *SELECT inside -- this doesn't seem to work. The debug log shows that the SKU scope remains the same as the data submission, and it appears that the *SELECT is not being performed in SecondLogic.
    Option 2. Use a *RUNLOGIC calling SecondLogic.LGX, as follows:
    *RUNLOGIC
    *DIMENSION SKU=filter([SKU].members,[SKU].properties("ProfitCenter"=[SKU].CurrentMember.Properties("ProfitCenter")))
    *LOGIC=SecondLogic
    *ENDRUNLOGIC
    I was hoping that would work, but I get an error message after data submission:
    ExecuteBaseLogic::user has no write access to the selected members of dimension : SKU
    SKU dimension is secured R/W, but my user ID has write access to all members (confirmed in my ability to submit data, plus acsSKU table).
    I even simplified this to hard-code a particular profit center, but still the same error:
    *RUNLOGIC
    *DIMENSION SKU=filter([SKU].members,[SKU].properties("PROFITCENTER"="500143"))
    *LOGIC=SecondLogic
    *ENDRUNLOGIC
    I'd appreciate any tips on how to use this MDX filtering, or any other approach that gives this type of dynamic re-scoping in default logic.
    Thanks,
    Tim

    Hi Tim,
    You are missing  a bracket in your examples, after the name of the property (bracket should be closed)
    I used the following statement in an *XDIM_MEMBERSET and it is working fine. I have a also a .CurrentMember, not sure if this one makes any difference.
    Filter([Time].Members,[Time].CurrentMember.Properties("TIMEID")="20071200")
    Regards,
    Marcel

  • Default Logic for Intercompany Elimination (USELIM)

    Dear Friends,
    I am doing the Intercompany elimination for Management consolidation. I have configured the Entity and Intco and also maintained the "ELIMACC"  property in the account dimension. Also i have manintaied the ICELIM.LGF where the following code is been maintained
    *RUN_PROGRAM US_ELIM
    CATEGORY = %C_CATEGORY_SET%
    TID_RA = %TIME_SET%
    OTHER = ENTITY=%ENTITY_SET%
    *ENDRUN_PROGRAM
    do i need to maintain any thing else in the default logic of my application. I have not maintained any Business rules, is it mandatory to maintain the same?. Please suggest me. ( I have no currency convertion since input and reporting is in USD only.)
    I tried running the "IC Elimination" package with the sofar done setting am getting the Package  status as 'Cancelled'
    Thanks
    Prem

    Group dimension is mandatory to add.

  • Can we run 3 logics at a time through Default logic?

    Hi,
    I would like to run 3 script logics through Default logic at a time.  I mean
    all the 3 logics should run, when I import the data through DM.  Is it possible
    to run 3 logics at a time?
    Thanks in advance.
    Regards,
    B.S.RAGHU

    Hi,
    This is possible. You just have to use the INCLUDE statement in your default logic (INCLUDE FXtrans.lgl for example), and then save and validate both logic scripts.
    If you have to launch a logic in another application, by passing it some parameters for example, you can of course use RUNLOGIC statement, as said in the above thread. But the easiest way is to use INCLUDE.
    Hope this will help.
    Best Regards,
    Patrick

  • Script logic in default logic

    Hello
    How to include script logic in default logic?

    There are two ways:
    1. Direclty write the script in the default logic and the validate and save.
    2. Create a new script and write the scipt code in that and the add that script name in default logic . e.g: * include (your script name).lgf

  • Copy data between accounts on BPC 7.5 default logic

    Hi gurus,
    I have default logic code that does not work. I need to copy value from an account to another from real to budget data.
    I have this code:
    *XDIM_MEMBERSET PERIODO=%PERIODO_SET%
    *XDIM_MEMBERSET ESCENARIO=REAL,PPTO
    *XDIM_MEMBERSET SOCIEDAD=%SOCIEDAD_SET%
    *XDIM_MEMBERSET GROUPS=LC
    *XDIM_MEMBERSET FLOW=F_CIE
    *CALC_DUMMY_ORG CUENTA = PARENTH1
    *IGNORE_STATUS
    *WHEN ESCENARIO
    *IS PPTO
    *WHEN CUENTA
    *IS #BAI
    *WHEN SIGNEDDATA
    *IS <>0
    *REC(EXPRESSION=GET(ESCENARIO="REAL",CUENTA="630"),NOADD,ESCENARIO="PPTO",CUENTA="630")
    *ENDWHEN
    *ENDWHEN
    *ENDWHEN
    *COMMIT
    Where is my mistake???
    Thanks a lot for your help!!!!
    Have a nices day!

    Hi Jordi,
    Could you try to replace *IS #BAI with a single account (any one account that contains data) and see if that works.
    BR,
    Arnold

  • Defaulting logic in entity create method

    Hi
    As suggested by BC4J I use the create method of my entity object to insert defaulting logic for some attributes. The code looks like this:
    protected void create(AttributeList attributeList)
    super.create(attributeList);
    Number seqNumber = new Number();
    SequenceImpl s = new SequenceImpl("REV_SEQ", getDBTransaction());
    seqNumber = s.getSequenceNumber();
    setRevId(seqNumber);
    setCreationDate(SamUtils.getSystemDate());
    ApplicationModule am = getDBTransaction().getRootApplicationModule();
    if (am instanceof SecuredApplicationModule)
    setUsrId(((MyApplicationModule) am).getUsrId());
    But executing this code results in an Exception: "JBO-25014: Other User has changed the Row". If I remove the code between the lines above everything works ok.
    My questions are:
    - Is it ok to use set-Methods in the entity create method? Or should I set my default values to the "attributeList" instead?
    - do you think it is a problem to use the ApplicationModule as shown? I should mention that am.getUsrId() simply returns a previously stored variable and does not perform any queries or alike.
    Thanks for your help
    Frank Brandstetter

    It's definitely fine to setAttributes - I've done it myself (but not using "specific" setters).
    I haven't used the built-insequences before - this bit of your code looks a bit wasteful in terms of object creation, but that's obviously not your issue....
    It looks fine to use an application module in such a way; I coded a "current user id" function on mine too.
    I actually suspect the date-attribute, since I (me again!) had some "concurrent user" problems too. The issue was the fact that a Java date is accurate to the millisecond, and the database storage and retrieval wasn't. (I wasn't using Oracle so I'm not sure how it goes there....) A "concurrent user" exception gets thrown when bc4j goes to update an entity and finds that the date-value in the object doesn't match the "rounded" one it retrieves (as a check, just before it does the update - this is the optimistic locking) from the database. [So does the error occur only when you've saved the new entity once, then update it and try to save it again?]
    I got around it by setting the millisecond portion of any dates I used to zero (since the "storage" was accurate to a second) - so you might try that. (Did it generically in prepareForDML in my own Entity superclass, I think.)
    Otherwise, try setting the attribute, but not in the create method, and seeing if you get the same problem...
    HTH
    Mike.

Maybe you are looking for

  • User-Exit - MIGO How to get the Number of Material Document

    Hi everyone!! I'm looking for an user-exit after saving in MIGO transaction. I need the Number of Material Document (MKPF-MBLNR) to generate an IDOC. Does anybody knows an user-exit to get this number? Regards, Rubens Kumori Edited by: Rubens  Kumori

  • Email sharing with gmail

    When sharing a document with a collaborator, I place the pointer over their name at the bottom of the page, the tab pops up, and gives me the option of clicking on their email address to send them an email.  This is especially useful if I want to let

  • IPod CHARGE UP issue??

    the iPod doesn't charge up. Sometimes it does sometimes it doesn't... It's not a USB port issue I don't think... I've tried a high speed one and a slower one... I think it's in the iPod software... Can ANYONE help here? REALLY displeased with Apple.

  • Low battery window

    It started when I had Tiger installed, and after installing Leopard the problem remains. I used to get a window saying that I was running "On reserve power" when the battery level was too low, and since some time ago I don't see this window anymore,

  • Having trouble installing on ipad v1 installation hangs up

    I am having trouble downloading the e print app from the Apple app site. It seems to just hang up. Do you have recommendations? This question was solved. View Solution.