BIP Requirement - Sorting inside the for-each

Hi Gurus,
I need to sort the PlanDateOpened to capture the Test B Business Unit because this is the oldest date but this is inside the For-each of Contact.
Please help me how to code this in BIP.
Thanksa lot.
jP
Edited by: BIPnewbie on Sep 8, 2011 1:29 AM
Edited by: BIPnewbie on Sep 8, 2011 8:26 PM

thanks kavipriya..this is correct. :)
<?for-each: Opportunity[PlanDateOpened!=’’]?><?sort: PlanDateOpened ;'descending';data-type='text'?> <?if:position()=1?><? BusinessUnit ?>:<? PlanDateOpened?><?end if?><?end for-each?>
Thanks,
jP

Similar Messages

  • Reporting Services - How to open a second table inside report, for each number of client (each apears in first table)

    Reporting Services - How to open a second table inside report, for each number of client (each apears in first table)?
    Exemple:
    Table1
    Cliente name:
    John
    Client number:
    12345
    Survay number of negative answers:
    3
    Table2
    Questions and answers that were negative:
    Question: How much time where you waiting
    Avaluation: 3 (from 1 to 10)
    Answer: They only called me 1 mouth later
    Can you please help me?

    Hi,
    Based on the description, I understand that you want to add subreport in the main report. When previewing the main report, the subreport can be shown in detail. Please see the screenshots on my test:
    In Reporting Services, we can create parameters and pass them from main report to subreport in order to control the data dynamically.
    References:
    Subreports (Report Builder and SSRS)
    Add a Subreport and Parameters (Report Builder and SSRS)
    If I have any misunderstanding, please feel free to contact me.
    Regards,
    Heidi Duan
    Heidi Duan
    TechNet Community Support

  • Usage of for-each loop inside another for-each loop

    Hi All,
    I have tried using a for-each loop inside another for-each loop as given below.
    <?for-each:G_1?>
    <Customer Details>
    <?for-each:G_2?>
    <Address>
    <?end for-each?>
    <?end for-each?>
    Its not getting inside the second loop.I have referred this link
    Re: Loop Question but it didn't help me much.Please let me know if am going wrong somewhere.
    Regards,
    Sudeep.

    Sudeep,
    The syntax of the for-each statements looks oke. but you have omitted some question marks after the < and before the >.
    Furhermore, there cannot be spaces in XML element names. So, "Customer Details" won't work. Change it to something like: "Customer_Details". Also be reminded that the element names are case-sensitive.
    try this:
    <?for-each:G_1?>
    <?Customer_Details?>
    <?for-each:G_2?>
    <?Address?>
    <?end for-each?>
    <?end for-each?>
    Regards,
    Kevin

  • Use the for-each to group the element across in output

    I have the report in XMLP for which we need to design the template to generate the output in excel. we need to group the element across the report. by default the for-each group the element top-down, is there any option to group the elements across. example:
    consider the xml data as
    <?xml version="1.0"?>
    <XXFA_TAL_REP_XMLP>
    <LIST_G_DAY_WE_EXECUTED>
    <G_DAY_WE_EXECUTED>
    <DAY_WE_EXECUTED>18-NOV-09</DAY_WE_EXECUTED>
    </G_DAY_WE_EXECUTED>
    <G_DAY_WE_EXECUTED>
    <DAY_WE_EXECUTED>19-NOV-09</DAY_WE_EXECUTED>
    </G_DAY_WE_EXECUTED>
    </LIST_G_DAY_WE_EXECUTED>
    </XXFA_TAL_REP_XMLP>
    if we group by the above data with group G_DAY_WE_EXECUTED and try to print the data element - DAY_WE_EXECUTED we will get two fields as below
    18-NOV-09 - in excel cell A1
    19-NOV-09 - in excel cell A2
    but we need to have these fields in excel cells - A1 & B1
    Please help me to achieve this.
    ~ Ashish | 630 487 9486

    Can you try with
    for-each@column

  • How to speed up my code inside the for loops,

    how to speed up my code inside the for loops using c# WinForm.

    Hi  John,
    Please take a look at the reply from Wyck in the following thread.
    How to speed up for loop?
    His answer is very comprehensive.   Thanks.
    Best regards,
    kristin
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • For Each Loop: Enumerator Configuration In the For each loop Editor Help needed

    Hi All,
    I have a package that runs and updates a table with everytime someone adds a flat file in the source folder. One of the requirement is to upload files with the following
    ACA Flat files will have a naming convention of “ACA_ccyy_<julian date>”  : How can I add this?
    Under Files this is how I have setup the qualifies "ACA_*.*"
    Is there anyway to pass the entire naming convention in the file section? If so how can I ?
    Please help?
    FM

    As you have ACA_*.* set in Files Filter, it will return all the files from the folder which start with ACA_.
    You can have one dummy Sequence Container inside FE Loop Container. Connect it to your starting task and do right click on Precedence Constraint and write the expression the way you want by using SSIS functions. If the expression is evaluated to True only
    then it will go to the next task.
    In this way you can skip Non-ACA files.
    Please refer:
    SSIS Skip Certain Files in a For Each Loop
    - Vaibhav

  • BIP Requirement - Sorting

    Hi Gurus,
    I have this code that is working:
    <?for-each@inlines: HS1PrimaryAllocatedWorker?><?FamilyName?> <?FirstName?><?if@inlines:position()!=last()?>, <?end if?><?end for-each?>
    Output is: Ashfield Transferred To, Siebel Administrator, Basu Arka
    XML:
    - <HS1PrimaryAllocatedWorker>
    <FamilyName>Ashfield</FamilyName>
    <FirstName>Transferred To</FirstName>
    <Primary>N</Primary>
    </HS1PrimaryAllocatedWorker>
    - <HS1PrimaryAllocatedWorker>
    <FamilyName>Siebel</FamilyName>
    <FirstName>Administrator</FirstName>
    <Primary>Y</Primary>
    </HS1PrimaryAllocatedWorker>
    - <HS1PrimaryAllocatedWorker>
    <FamilyName>Basu</FamilyName>
    <FirstName>Arka</FirstName>
    <Primary>N</Primary>
    </HS1PrimaryAllocatedWorker>
    But I need to appear Siebel Administrator to come first because it is the Primary value.
    like this: Siebel Administrator, Ashfield Transferred To, Basu Arka
    Please help
    Thank you,
    jP

    Can you try this?
    <?for-each@inlines: HS1PrimaryAllocatedWorker?><?sort: Primary;'descending';data-type='text'?><?FamilyName?> <?FirstName?><?if@inlines:position()!=last()?>, <?end if?><?end for-each?>

  • Do we require a seperate server for each JWS app ?

    We have an app that runs on JWS and uses a fairly large MS SQL database. We currently host this on our server. We use ServletExec and Win2k and IIS. Most customers do not have MS SQL on their laptops. Each customer wants to login and use their own version of our application together with their own version of the database.
    Q: could we host several versions (one for each customer) of our app on a single server with one IP address, or do we need a different server with different IP for each?

    The question is : do you want your user to be able ti use their application offline ?
    If yes, then you may provide them a local database and use a JDBC type4 driver. (The application is fetch directly from the server when first connected and then is able to lauch the applicaiton off-line) Such a network listen is allowed by the JNLP security model without any application sign !
    If no, then why not having a single database and some user debedant table that store the user specific data (as usual), and using a login dialog-bon (or an auto-logon mechanism) to restric identify and access your database thru some business logic via RMI or any ligh-webservice technology.
    Anyway you have plenty of solutions ..... it only depends of what are the exact needs.
    Regards,
    Jean-Baptiste Bugeaud
    WWW.UP2GO.NET - The JNLP Applications Repository

  • 0o we require a seperate server for each JWS app

    We have an app that runs on JWS and uses a fairly large MS SQL database. We currently host this on our server. We use ServletExec and Win2k and IIS. Most customers do not have MS SQL on their laptops. Each customer wants to login and use their own version of our application together with their own version of the database.
    Q: could we host several versions (one for each customer) of our app on a single server with one IP address, or do we need a different server with different IP for each?

    I've used many UNIX databases, not SQL
    database, and I don't know how SQL database
    handles authentication, but with Oracle, for
    instance, it would be easy to run any number
    of apps and databases from a single directory
    on any web server.
    One way to differentiate DB instances would
    be by specifying a -D property in the JNLP
    launch commands.
    Any half-descent web server will permit you
    to control access to individual files by
    source address and/or passwords.

  • How can I make it so I'm not required to activate addons for each website?

    With the new firefox patch last week, every time I go to a website with a pdf I have to click to allow adobe acrobat unless I want to use firefox's crappy pdf reader. Same for other addons like silverlight, java, etc.
    Is there any way to avoid clicking this at every site I go to for every addon I want to use? Or is it time to uninstall firefox and just use Chrome?

    That's strange. Setting "Always Activate" on the Add-ons page definitely should bypass the message. While it is possible to override that on a site-by-site basis, the global setting should be sufficient.
    Could you check another way:
    (1) In a new tab, type or paste '''about:config''' in the address bar and press Enter. Click the button promising to be careful.
    (2) In the search box above the list, type or paste '''plugin.st''' and pause while the list is filtered
    Do you see any of these (indicating "Always Activate"):
    * '''plugin.state.java''' set to 2 (Java Platform SE plugin)
    * '''plugin.state.npctrl''' set to 2 (Silverlight plugin)
    * '''plugin.state.nppdf''' set to 2 (Adobe Acrobat plugin)

  • ?for-each-group? dosen't work with page break - rtf template???

    Hello all,
    When I give a page break inside the for-each-group the group doesn't iterate any code after the page break. I can't give <?split-by-pagebreak?> in this case because I want that loop to be iterated for every department, and should show the report in one column(ms word column), and the department description in two columns.....as this has to happen for every department I can't write separate code........everything should go into one file......
    Final file should look like:
    <for every department>
    <department_report-a table>--one column(ms word column)
    <department_description-a huge text>--two columns(ms word columns)
    <next department>
    how can I achieve this - please help, its urgent.
    Thanks for your time.
    DK

    bipuser thanks for your response
    i will have table data also so i cannot keep in the same line.
    its strange for the last 2-3 days below syntax gave me space at the beginning of each group now it is working i didnt do any change
    <?for-each:G_1?>
    ABCDEFDG
    <?split-by-page-break:?><?end for-each?>

  • B1if - #sender system in for each processing loop

    Hi all,
    I am creating a scenario where I use the for each processing loop.
    Everything works fine but when I want to use the #Sender system in various steps (call B1 atom eg), I get an error saying the #Sender system is empty.
    Do I need to do something to get it populated inside the for each loop?
    Kind regards,
    Joeri

    Hi Joeri,
    I have done a test and I have the same problem you are having the system is empty when I use the #Sender System in a B1 call inside a for each. If I use a fix system id then it works fine.
    <?xml version="1.0" encoding="utf-8" ?>
    <Msg xmlns="urn:com.sap.b1i.vplatform:entity">
      <Body>
        <Payload Role="C" id="atom3" system="empty">
          <B1CallResult status="failure" b1login="Technical User" method="Synchronous Retrieval" objectid="4" payload="" keyname="ItemCode" keyvalue="A00001" />
        </Payload>
      </Body>
    </Msg>
    Please open a message for support asking for it and share the information with us.
    Hope it helps
    Trinidad.
    Edited by: Maria Trinidad MARTINEZ GEA on Jan 6, 2012 11:00 AM
    My previous answer was not related to your question...

  • Custom sorting within "for-each-group:current-group"

    Hi, I need some help in doing a custom sort within a "for-each-group:current-group". My formatting is in a table format but I'm not sure how to post a table here so I'm just arranging the column details out as it would look in a table. I have a column on the left for the YEAR and a second column on the right for the DESCR. Under the DESCR column I've inserted a nested table with four columns: SUBJECT, CATALOG_NBR, DESCR250 and GRADE.
    COLUMN 1:
    <?for-each-group:row_table;./ YEAR?><?sort: YEAR;'ascending';data-type='text'?><?YEAR?>      
    COLUMN 2:
    <?for-each-group:current-group();./DESCR?><?DESCR?>
    NESTED TABLE (with 4 columns):
    +<?for-each:current-group()?><?SUBJECT?><?CATALOG_NBR?><?DESCR250?><?GRADE?><?end for-each?>+
    <?end for-each-group?> <?end for-each-group?>
    I'm able to sort by YEAR in the "for-each-group" on the left column. But I also want to do a custom sort on DESCR in the right column.
    I've seen this blog on custom sorting by Vetriselvan: http://winrichman.blogspot.com/2009/09/custom-dynamic-sort-in-bi-publisher.html and I tried inserting this sort below after <?for-each-group:current-group();./DESCR?> but I get an error message.
    <?sort:(number(DESCR='Status')*1)+(number(DESCR='First Semester')*2)+(number(DESCR='Second Semester')*3);'ascending';data-type='number'?>
    I've also seen this thread: Re: Sort within group and tried inserting <?for-each:DESCR?> before the sort (as below) - this time I can preview the results, but it is not sorting as required.
    <?for-each:DESCR?><?sort:(number(DESCR='Status')*1)+(number(DESCR='First Semester')*2)+(number(DESCR='Second Semester')*3);'ascending';data-type='number'?>
    Can anyone help me custom sort the DESCR column? I'm using Template Builder for Word version 5.6 build 45. Thanks in advance for any help!

    Hi Vetsrini,
    I tried adding <?sort: ./DESCR;'ascending';data-type='text'?> after <?for-each-group:current-group();./DESCR?> but I'm getting an error message.
    The DESCR values are below and I'm trying to sort them in the following order.
    STATUS
    SUMMER SEMESTER
    FIRST SEMESTER
    AUTUMN SEMESTER
    WINTER SEMESTER
    SECOND SEMESTER
    SPRING SEMESTER
    Because I need them in the above order, I can't use ascending or descending, and instead need to use a custom sort order. Do you know how I can go about creating a custom sort order?
    Thanks!

  • "for each" loop - under the hood question

    Question about the for each loop. Is it optomized? I think this is a poor use of memory management -
    for (int i = 0; i < stop; i++) {
    Object obj = new Object();
    doSomething(obj);
    }And this is the ideal, using the same object -
    Object obj = new Object();
    for (int i = 0; i < stop; i++) {
    doSomething(obj);
    }So underneath the hood, which is the for each loop comparable to? I love the syntax, it's very clean-looking in the code, but at the same time I don't want to hurt performance.

    Question about the for each loop. Is it optomized? I
    think this is a poor use of memory management -
    for (int i = 0; i < stop; i++) {
    Object obj = new Object();
    doSomething(obj);
    }And this is the ideal, using the same object -
    Object obj = new Object();
    for (int i = 0; i < stop; i++) {
    doSomething(obj);
    }So underneath the hood, which is the for each loop
    comparable to? I love the syntax, it's very
    clean-looking in the code, but at the same time I
    don't want to hurt performance.That depends on YOU. You CANNOT write a for-each loop for the code you provided. A for-each loop requires an Iterable. (I think that's what it requires--it at least requires something to iterate over, not just an index variable as you have.)
    Consider the following, however:
    Object o1 = new Object();
    for (Foo foo : fooList) {
        Object o2 = new Object();
         foo.doStuff(o1, o2);
    } It will be equivalent to this:Object o1 = new Object();
    for (Iterator iter = foo.iterator(); iter.hasNext();) {
        Foo foo = (Foo)iter.next();
        Object o2 = new Object();
        foo.doStuf(o1, o2);
    } How could it be any different? It has to keep the behvior of the "old fashioned" iteration.

  • Generate a seperate PDF for each copy of the recipients

    Hi
    We have a requirement to generate PDF for each copy of the recipients. Assume , if we have a transaction that has one insured , one broker and three mortgagee copies, we would need to generate 5 PDF's (one for insured , one for broker and three for mortgagee.
    The form has an address section which displays the mortgagee address details. Each of my mortgagee copies needs seperate PDF to be generated.
    Is there any Documaker Server or DAL Rule that we could use this to achieve the functionality. We are using Documaker 11.3 with Docupresentment 2.2 on AIX Platform
    Thanks in advance

    data :tab_otf_data TYPE ssfcrescl,
    cparam TYPE ssfctrlop.
    CALL FUNCTION GV_FMNAME
      EXPORTING
    IMPORTING
       EX_USER                    =
      DOCUMENT_OUTPUT_INFO       =
       JOB_OUTPUT_INFO            =  tab_otf_data
      JOB_OUTPUT_OPTIONS         =
      TABLES
        I_DESC                     =
    EXCEPTIONS
      FORMATTING_ERROR           = 1
      INTERNAL_ERROR             = 2
      SEND_ERROR                 = 3
      USER_CANCELED              = 4
      OTHERS                     = 5
    IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    check out for the field TDFORMS of tab_otf_format

Maybe you are looking for