If condition in a Package

Hi all,
I am new to ODI. I have got the following requirement.
I have got two interfaces. 1. Daily Sales 2. Monthly Sales.
My requirement is to execute the Daily Sales interface every day except the First Day of the Month. On the First Day of the month, Monthly Sales interface should be executed. And I have got two Global variables. 1. Present Day 2. First Day of the Month.
I am planning to create a Package and my idea is if variable1 = variable2 then execute the Monthly Sales interface if not execute the Daily Sales interface...but I don't know how to do this using ODI.
Can someone please help to me to achieve this? Thanks in advance.

Yes we needs to call the same Variable twice in Refresh and Evaluate Mode. The refresh will always refresh and pick the latest value and Evaluate check the condition . If we don't do refresh then evaluate will pick the last stored value and give us wrong results.
Now in order to handle the Yearly Sales , the method is similar to what i have suggested earlier.
Step 1. Create a Variable ( GET_YR_FRST_DY) and paste the following code
SELECT TO_CHAR(SYSDATE,'DDMM') FROM DUAL Step 2. Drag and Drop the Variable ( GET_YR_FRST_DY) in Refresh
Step 3 . Drag and Drop the Variable ( GET_YR_FRST_DY) in Evaluate
Operator = 0101
Step 4 . If true (OK) then Yearly Sales
Step 5. join Daily Sales and Monthly sales both to Step 2 (i.e GET_YR_FRST_DY) Refresh . This way you can handle all of them in one single package.
Please let me know if you have any question.

Similar Messages

  • Group By condition in result package

    Hi Experts,
    I have a requirement, where I need to write a logic to populate few key figures of a Cube.
    Logic is based on Group by condition on 3 fields of the result package. (Need to implement in end routine)
    Is there any way that I can do a select statement on the result package fields and then put a group by clause to get my aggregated data.
    I need to fill up the key figures in the cube itself (cant take it to BEx).
    Please let me know how to proceed for it.
    Thanks
    El.

    Githen, Thanks for the reply.
    I am thinking of another option of implementing it. Let me know your thoughts
    There is a DSO on the top of this Cube, If I use all the fields which I want to use in "Group By" condition as key fields of the DSO.
    Then would it automatically aggreagate the rows based on the conditions? Will it suffice the requirement?
    Thanks
    El.

  • Selection Conditions on Info Package

    Hi Experts
      Please advise me on how to proceed
    My requirment is to include selection condition in INFOPACKAGE as the total data that data source is extracting is nearly 200 million records to minimize the extraction of data to be loaded to DSo...my requirment is include selection conditions at infopackage level
    Condition 1: On Fiscal Year/Period
    To load data from  2005 to current....
    Condition 2: to exclude particula Cost Center
    and data source is delta capable
    Please update me how to include these selection conditions do i need to write any ABAP Code and
    Do i need to include selection conditions on INIT & DELTA info package as well
    I need to load data from FY 2005 to........
    Thanks in advance

    Hi Siegfried Szame
    Thanks for the update...apologies for multiple posts
    One question as you said Parallel Inits
    If i created about 9 different INIT info packages  ( My requirment is to initilize data from FY 2006)
    IP1: 001.2006 to 004.2006
    IP2: 005.2006 to 009.2006
    IP3: 010.2006 to 001.2007
    IP4: 002.2007 to 005.2007
    IP5: 006.2007 to 009.2007
    IP6: 010.2007 to 001.2008
    IP7: 002.2008 to 005.2008
    IP8: 006.2008 to 010.2008
    IP9: 011.2008 to 002.2009
    How about delta....what are the selection conditions i need to use
    and
    Can i execute the above packages one after another...that is after completion of IP1 then IP2..then IP3
    Please update
    Thanks in advance

  • Help with conditions AND installer Packages

    Hello everyone,
    I need help still learning.
    My shell is SHELL=/bin/sh based on env command
    I am trying to write a package with Iceberg to push Office 2004 to 250 Macs. I need a preflight script with a condition that will stop my script if /Applications/Microsoft Office 2004 exists OR if OFFICE 2004 exists. Don't know if searching on the folder name is the best or if there is better way
    If it doesn't exist I want it to continue with with placing Office 2004 in the /Applications folder.
    I don't know how to do conditions (If, then, end)
    PREFLIGHT SCRIPT
    IF /Applications/Microsoft Office 2004 folder exist = STOP
    IF /Applications/Microsoft Office 2004 folder doesn't exist continue with laying down files/folder in the package.
    LAYDOWN FILES
    LAY DOWN FILES IN ICEBERG FILE SECTION OF THE PACKAGE
    POSTFLIGHT SCRIPT
    #!/bin/sh
    #Change to root directory
    cd /
    # Move Microsoft Office X folder to Messages Received folder
    mv /Applications/Microsoft\ Office\ X /Messages\ Received
    #Open Office 2004 Installer
    open /Applications/Utilities/Installers/Office2004Installer
    G4 1.42   Mac OS X (10.3.5)  

    Hi Dmcrory,
       The answer to your question about ORing tests in a shell conditional statement could be something along the lines of:
    if [ -d /Applications/Microsoft\ Office\ 2004 -o -d "/Applications/OFFICE 2004" ]
    then
       exit 1
    fi
    I've included two different styles of quoting so you can choose which you prefer.
       That said, you appear to be asking us how to write shell scripts, starting from scratch. Time that you spend studying benefits you forever and sometimes benefits us, while time we spend doing your work is at best a trivial review for us. The above "-o" option, and many others, are documented at the compound comparison section of the Advanced Bash-Scripting Guide. Don't let the name fool you; the Guide actually assumes very little. The "Advanced" adjective refers to the completeness of work. In fact there are many good references.
       I used to have a long post of links to what I think are some of the better beginning UNIX tutorials and books. However, as others posted great links and I stole them, my post became too long so I put it in a web page. Bill Scott did the same thing so here is Bill's and here is mine.
       This is being written after reading your exchange with Roger. When you execute code that doesn't work, we certainly have no chance of knowing why without seeing the code. It generally helps a lot to see the output as well.
    Gary
    ~~~~
       University politics are vicious precisely because the
       stakes are so small.
             -- C. P. Snow

  • Packaging charge amount not appearing in miro

    Dear Friends,
    I am working on SAP 4.7, One material PO is made with a customized condition type Y004 (Packaging charge (%)) - 2% And freight 2%, and after GR it was found that separate line item is appearing for freight 2% as DCGR BUT same is not appearing for the case of packaging charge due to which at the time of MIRO packaging charge amount is showing as NIL in the line item whereas freight value appearing correctly. I have also checked whether the packaging charge is getting added in the total value or not and found it is nowhere added.
    Please let me know how to correct this problem

    Details maintained against condition Y004 (packaging charge)
    Cond. class   A Discount or surcharge     
    Plus/minus    A Positive
    Calculat.type A Percentage
    Cond.category B Delivery costs
    Manual entries C Manual entry has priority
    Header condition Tick yes
    Item condition   Tick yes
    Delete           Tick yes
    Amount/Percent   Tick Yes
    delete fr. DB    Do Not delete(set the deletion)
    Scale basis      C quantity scale
    Currency conv   Tick Yes
    Accruals        Tick yes
    I have checked in GR FI document also and found that all the other amount except packaging charges appearig correctly.
    Kindly help.

  • Info-package setting: Data selection tab

    Hi,
    I have to give selection conditions in info-package.
    The need is to restrict the values of a particular field to start with BP and BQ.
    i.e i need only values starting with BP and BQ.
    I gave from and to values in the selection screen of info-package as BP* and BQ*
    But the error says CP(Compare Pattern) is not allowed.
    How else can i make the info-package to select values starting only with BP and BQ
    Regards,
    Yeshwanth

    Hi Yeshwanth,
    If this is a character string, then check the length and start from BP0000, as per the length of the feild till the end which in our case would be BQ0000.
    Let me know, if this doesnt work.
    Naveen.A

  • Empties/returnable packaging pricing

    Is it possible to setup SD pricing conditions for empties or returnable packaging?  I have setup pricing conditions for these types of materials, but when I input the material on the sales order, no pricing condtions are found.  From what I've read so far, you cannot setup conditions for returnable packaging.  If so, how can I handle the following scenario-
    We want to charge the customer a deposit for the packaging ($250) at the time of the sale, then return the deposit once the packaging is picked up. 
    Thanks in advance,
    -Scott

    Hi
    Please go through the below link.
    returnable packaging scenario
    hope this will help u
    Regards,
    Krishna O

  • Packaging Material PRICE

    Hi All,
    i'm new in SD and i Have a little problem:
    I have to assign a price for my package material (box).
    The price is 3 Eur/PC.
    I have an order with 25 COMPUTERS in 5 BOXES.
    In pricing procedure can I assign a condition type to Package Material?
    I have tried to assign at it a condition record (PR00= 3Eur /PC) but in (Conditions TAB PAGE, in the order) i see only the price for the computers e not for the boxes.
    How can i make visible the price of the packaging?
    Thanks a lot
    Alba

    Dear Alba
    You have to maintain the packaging material code (let us assume it is PACK) as a sub component to your FERT item.  Go to CS01, input the header material which you are selling, plant and in BOM Usage maintain 5  and execute.
    There input the following:-
    ICat::::Component::::Component description::::Qty:::
    L:::::::::PACK:::::::::::::::Packing Carton:::::::::::::1
    Save the above data now try to create a sale order and see whether the packing material is also flowing.
    Also please note that item category for your header material should be TAQ and for packing material, it should be TAN
    thanks
    G. Lakshmipathi

  • Pricing of Packaging Material

    Hi All,
       I have a small query.
    How come I will give a price to the packaging material?
    During delivery packaging material is also going. So how i give price to the packaging material so that it will show in the pricing. How come a packaging material will be price relevant?
    Regards
    Ashis

    Dear Ashis
    I am sure, the cost of packaging material is based on per piece or per carton whatever you call.
    So create a condition type in V/06.  If you want, you can even copy PR00 and assign the same to your pricing procedure V/08.
    In V/08, while defining the conditions, you should do in such a way that both your unit price + condition type for packaging are taken into consideration for excise duty.
    Thanks
    G. Lakshmipathi

  • Getting "ORA-12703" error in forms 10.1.2.3.0 and database 11.1.0.6.0

    Hello All,
    I am using forms 10g (10.1.2.3.0) version with database 11g (11.1.0.6.0).
    I did some modification in a package. That package is getting called in the forms. After doing modification (just add one if condition) in the package procedure (Not added parameter) I connected to the application and calling the form. I am getting the error message "ORA-12703". After that if I am just compile all the forms, one form is working fine. But in some other form it is not working properly. Still I am getting the error message "ORA-12703". I just put some debug message in the package and form, I compiled both form and package. At this time both are working fine. But if I am putting some debug message in the package only then it is not working. Getting the same error message.
    Does it a forms or database issue or I need to do some thing? Any suggestion welcome.
    Thanks
    SUN

    ORA-12703 this character set conversion is not supported
    Cause: An attempt was made to use the CONVERT function to convert between two character sets, and the requested conversion is not possible due to unavailability of one or both character sets.
    Action: Use character sets available on the system in the CONVERT function.
    What character set do you have on the database and what charset on the client side? Maybe SQL*Net issues the convert function when you use different charsets for both?

  • For all the reflection gurus out there

    I need to be able to access protected classes/interfaces and protected methods from another package. I know this completely undermines the entire idea of java�s protection keywords, but I don�t have any other choice. I also understand that this will possibly lock me into a specific VM version and implementation that I can use for my application because it is not part of the java API spec. Having said that I still need it to work. My real goal here is to create my own modal window behavior because Sun�s is not robust enough for our needs.
    I need the following code to work:
    FILE1
    package protect;
    public class Helper {
        public static Object getEventDispatchThreadInstance() {
            return new EventDispatchThread();
    interface Conditional {
        public void evaluate();
    class EventDispatchThread extends Thread {
        void pumpEvents(Conditional condition) {
            condition.evaluate();
    }FILE2
    package my;
    import protect.Helper;
    import java.lang.reflect.*;
    public class MyClass {
        public MyClass() {
            try {
                Class evDispatchThread = Class.forName("protect.EventDispatchThread");
                Class conditional = Class.forName("protect.Conditional");
                Object[] conditionalInstance = {new Object() {
                    public boolean evaluate() {
                        System.out.println("Please work");
                        return false;
                Method method = evDispatchThread.getDeclaredMethod("pumpEvents", new Class[] { conditional });
                method.setAccessible(true);
                method.invoke(Helper.getEventDispatchThreadInstance(),
                    conditionalInstance);  // This throws an IllegalArgumentException :(    
            } catch (Exception ex) {System.out.println(ex);}
        public static void main(String[] args) {
            MyClass instance = new MyClass();
    }The method.invoke call doesn�t work. I think the problem is because the conditionalInstance is not an instance of protect.Conditional. If protect.Conditional was not protected I would be able to do a cast, but I can�t because the compiler complains about it. How can I create an interface that is protected by using reflection? I also need to have my implementation of the evaluate method be executed when it is called in the pumpEvents call of the EventDispatchThread object.
    If you want a better idea of what I am trying to do in my application you can check out these threads:
    Project Swing->Help with the event dispatch thread
    Project Swing->Modality..what is it good for (absolutely nooothing)
    Thanks
    Lance

    I didn�t say it was the smartest thing to do, but it is either this or rewrite swing or our application to use a different GUI interface. I would rather be able to get this to work. Hey if it isn�t possible it isn�t possible.
    By the way DrClap you might want to find a different language then. You can access several methods that are protected by using reflection. The problems with my code are that it seems like you can�t use reflection to make protected interfaces, you can�t extend protected classes/interfaces, and you can�t cast correctly with these protected objects. The method.setAccessible(true); actually works. Check out the java.lange.reflect.AccessibleObject in the api.
    Lance

  • Planning Layout Execution

    Dear all,
          I have a scenario would like to discuss and share. I have 2 planning folders, First planning folder has the correct volume, where as the 2nd planning folder the volume will get lesser, both also using the same planning version.
    when i Click the planning layout in the 2nd planning folder, i save the data in the cube( i dint do anything in the input layout,system seem got some records generated after opening the layout) thus i go back to that bw infopackage, volume got  some value has been minus out.
    Question:Why the sytem behave in this way?how come i dint execute any planning function there is records generated? can we stop that? if not my volume will vary from one folder to another.
    Feel free to give comment or solution,
    THanks

    Check if in your planing folder there is any function that start automaticlly on layout open or befor save.
    Also check if both layout has the same selection condition in planing package an level and if they have same logic (based on existent data or generate all possible combination).
    Hope it helps.
    Regards

  • Net Price item in RFQ same as that in Purchase order

    >The following is the client's requirement :-
    >The user maintains all the values like basic price, discount, excise duty, educational cess, higher secondary educational cess, freight, packaging and forwarding, insurance, octroi etc in the request for quotation. But only the net price, discount, excise duty, educational cess, higher secondary educational cess are getting calculated in the net price and are available for price comparision. The other conditions maintained are not getting calculated in the RFQ.
    >The user wants that the other conditions like freight, packaging and forwarding, insurance, octroi etc also should be calculated and added in the net price for price comparision when these conditions are maintained in RFQ through Tcode ME47.
    >All these conditions get calculated in the purchase order at item level. Hence the value of the item in Purchase order is greater than the value of the item in the RFQ and there is a difference between the RFQ value and the Purchase Order value at item level.
    >The user want that the price of the item in RFQ should exactly match with the price of the item in the Purchase Order.
    >Whether this requirement can be met in standard SAP.  If yes then what are the configuration settings to be done for the same.
    >Thanks in advance.
    >AJ

    The pricing procedure called in RFQ comes from the price condition.
    You can check the same in M/06. The procedure is maintained in the customization for condition type.
    for eg. if you enter price for PB00 then check the setting in M/06

  • ICR: how do assignments work in detail?

    Dear all,
    maybe somebody can help on how the setup of ICR assignment rules works in detail:
    1. question on customized rules:
    We have a couple of rules in place, but rules being more complicated than just one condition or a combination of "="-conditions of fields always populated sometimes produce unexpected results.
    E.g. it seems that condition "orgunit field X = partner field X" is false for empty fields as long as this is the only condition in a rule, but becomes true for empty fields as soon as there is a 2nd condition (since support package 60306, before implementing it this condition apparently was always false for empty records).
    And it seems that condition "orgunit field X = partner field Y" (with Y <> X and not being the only condition) is false when comparing records in different companies, but gets true when comparing records within the same company.
    Furthermore it seems that the behaviour of conditions with operator <> has also changed since support package 60306.
    Is there any documentation of the ICR assigment logic which is such detailed? The one in OSS note 1164059 is not.
    2. question on rules implemented in BAdi FB_RC_ASSIGNMENT:
    Can anyone provide an example implemetation assigning records?
    Thanks a lot in advance!
    Best regards,
    Claus

    Hello Claus,
    Re #1: I think it would be helpful if you could provide an example. Basically matches on initial values only are ignored (otherwise all documents where no reference number is posted will be assigned to each other - which would not make any sense). But if your rule has more than one condition and the other fields are not initial and are a match then the assignment is made.
    Re #2: If you want to create assignments you simply have to move the corresponding data records from CT_ORGUNIT_UNASSIGN and CT_PARTNER_UNASSIGN to CT_ASSIGN_DIFF or CT_ASSIGN_NODIFF. Also, you have to populate the field GRREF (hint: look at the call of FM NUMBER_GET_NEXT in LFBRC_CENTRAL_FUNCSF05).
    Best regards,
    Ralph

  • ABAP - If Else

    Hi Gurus
    I want to put a code in start routine like:
    If certain condition
       DO NOTHING
    Else
       Delete Package
    Endif.
    My Question is in ABAP - is there any statement that is similiar to DO NOTHING
    Currently I coded this like
    If certain condition
    Else
       Delete Package
    Endif
    Do u think its correct? Pls suggest

    Thanks Edan...
    I understand ur suggestion..but the problem is
    the condition is complex
    (3 fields with AND condition)OR
    (3 fields with AND condition)
    Now if I put NOT in front...readability may go down...
    Pls confirm if the code that I mentioned will work..
    Regards

Maybe you are looking for

  • If I install iCloud to my pc, will I be able to get access to the skype chat history stored on the iPad app?

    So my computer with itunes broke down 5 weeks ago. I haven't backed up my ipad or synced it with a computer  since. I want to download or get access to my skype history, stored on the iPad, from my pc and don't know how to. If I backup via iCloud, wi

  • Itunes locks up when I connect my ipod

    I have an 80GB classi.  it has worked fine until today.  Now when I connect my ipod to my WIn 7 computer iTunes locks up.  I can not get out of iTunes unless I reboot the computer as it will not even close when I try to end the process in task manage

  • No preferences avalable after clicking EDIT. Why?

    Hi all. This is what i am trying to do but can not: Firefox/ edit/ (ok so far), no preferences/ advanced + sign/ cache/ clear cache/ exit....Not sure why i can not get passed edit. Any help would be appreciated. frosty girl

  • Password not recognized after A&I

    I did an archive and install and after the reboot, my password is not being recognized. What can I do?

  • Networking: FRUSTRATING.... PLEASE HELP

    FileOutputStream inFile = new FileOutputStream(FileName); BufferedInputStream in2 = new BufferedInputStream(socket.getInputStream()); while( (len = in2.read(b,0,1024)) != -1 ) bytcount=bytcount+len; inFile.write(b,0,len); in2.close(); inFile.close();