Limit of for each conditions in rtf templates

Hi Everyone,
I have a use case where i need to genereate a report by using values from two data sets. data sales, cost.
Data set sales have four columns product1, product 2, product 3, product 4
Cost has cost1,cost 2, cost 3, cost 4.
I need to display in below format
product 1| product 2| cost 1|cost 2| product 3| product 4| cost 3| cost 4|
To get above format i am using four for each condition groupings two for each data set
<?for-each:/data/sales?><?product1?>|<?product2?><?end for-each?>|<?for-each:/data/cost?><?cost1?>|<?cost2?><?end for-each?>|<?for_each:/data/sales?><?product3?>|<?product 4?><?end for-each?>|<?for-each:/data/cost?><?cost3?>|<?cost4?><?end for-each?>
If i use first two for each conditions i am able to see values in template but if i use four line is missing in the template.
I did not understand where lies the problem.
Please let me know if you need more info.
Regards
Sandeep

If you have product ID or key in the cost data set, then you can follow the method in this post to display data:
http://blogs.oracle.com/xmlpublisher/2009/09/formatting_concatenated_dataso.html

Similar Messages

  • How to print multiple footers for each page in RTF template xml report.

    Hi,
    How to print multiple footers for each page in RTF template xml report.
    i am able to print ( two sets ) ...
    up to last page ( one template ) and for last page ( another template).
    i want to change the footer information based on the group value printed in the report ( it might be 5 to 6) In every report run.. can you please check and let me know do we have any feasibility to achieve this.
    Thanks in advance.
    Regards,
    KAP.

    You can remove all other logic, like last page only contents (start@last-page:body), etc and section breaks if any you have inserted manually.
    Just have for-each@section logic.
    It would be difficult for me to guess what you have done without looking at your RTF or describing here.

  • Using OR condition in RTF Template

    Hi,
    How to use OR condition in RTF?
    say for example,consider the EMP table.
    I want to show the employees of department 10 and 20 in my XML Publisher report.
    How can i write --
    if deptno = 10 or deptno =20 in RTF template

    you can add the condition in RTF template
    <?if:XMLfield=30 or XMLfield=10 ?> to display <?end if?>

  • Unable to establish a for loop in custom rtf template for seeded xml file

    Hi Experts ,
    I am Unable to establish a for loop in custom rtf template for seeded xml file. i am using <?:for-each:G_BSALINE?> FORM FIELD .....<?:FOR-EACH?END> .AM i missing something?
    Please help.
    Thanks

    Hi,
    Need more information about your XML data structure; however based on the code you provided, the synax does not look right; you have some colon sign where it is not needed etc... You could use the following (although not quite sure if you want to use Form Filed to group by or just display), but look at the example provided below.
    <?for-each-group:G_BSALINE?> FORM FIELD .....<?end for-each-group?>
    Example code:
    <?for-each-group:G_INVOICE_NUM;./INV_TYPE?>
    xxxxxxxxxx
    <?end for-each-group?>
    Thanks!

  • How to Print Footer details conditionally in RTF template ( XML Bi report)

    Hi,
    I have a XML ( BI) report. in which i am printing carry frwd / running total/ sub group total values in the footer section.
    I have add one more condition to display the footer values based on the <xdofo:show-carry-forward ...> values.
    Please suggest and help me on this, how to handle this case.
    Regards,
    KAP.

    Hi,
    Thanks for the reply...
    Actually i am looking for the following scenarios :
    1. i want to Hide/ Don't show last 3-pages Footer information in the report.
    2. While i am displaying the Carry forward information in the report
    a. if the page/ running total is 0, i don't want to display the footer information.
    b. only case if the page/ running total is > 0, i want enable footer information dynamically for each page.
    i have done as follows :
    in the Template main body :
    *<?template:footer?>*
    **1000* *1000**
    *<?end template?>*
    and for behind 1000 currently :
    <xdofo:inline-total display-condition="exceptlast" name="RUNAMT"><xdofo:show-carry-forward name="RUNAMT" format="99G999G999D00"/></xdofo:inline-total>
    it was printing the " RUNAMT " calculated page total sucessfully. but here if the Total = 0 then i don't want to show the value in FOOTER...
    Thanks in Advance.
    Please let me know, if more information required to help..
    KAP..

  • "Or" condition in RTF Template

    Hello,
    In my RTF template, I try to test a statement for two values. I tried
    <?xdofx:if :A!='0' or B!= '0'?>
    <?if:A!='0' or B != '0'?>
    It doesn't work : there isn't any error but the result is wrong.
    Is there another syntax I've got to use ?
    Thanks
    Version : BI Publisher 10g
    Edited by: jbg on 4 oct. 2011 23:49

    Condition usage looks fine.
    Do these conditions individually work? Whats is your requirement?
    If possible paste a sample xml here

  • IF - ENDIF for NULL Values in .RTF Template

    Hi,
    I have a group which doesnt return anything, I dont want to display even the Labels in .RTF template, Can I do <?IF:P_APPT_NBR1 IS NULL?> ??
    Do we have anything for No Data Found ??
    <G_ASN>
    <P_APPT_NBR1 />
    <P_APPT_END_TS1 />
    - <LIST_G_ASN_DETAIL>
    - <G_ASN_DETAIL>
    <P_ASN_NBR1 />
    <PO_NBR1 />
    </G_ASN_DETAIL>
    - <G_ASN_DETAIL>
    <P_ASN_NBR1 />
    <PO_NBR1 />
    </G_ASN_DETAIL>
    </LIST_G_ASN_DETAIL>
    </G_ASN>
    Regards,
    Ashoka BL

    Achieved through <?if:not(P_APPT_NBR1)?>

  • SUM function with condition in RTF template

    Hi All,
    I have a problem in calculating the SUM in RTF template with condition,
    Here is the XML
    - <LIST_G_LINE_NOTES>
    - <G_LINE_NOTES>
    <LINE_TRX_ID>1567856</LINE_TRX_ID>
    <LINE_ID />
    - <LIST_G_TRX_LINE>
    - <G_TRX_LINE>
    <CF_ITEM_NO>SDCN1144B</CF_ITEM_NO>
    </G_TRX_LINE>
    </LIST_G_TRX_LINE>
    - <LIST_G_LINE_EQUIVALENT_UNIT_PRICE>
    - <G_LINE_EQUIVALENT_UNIT_PRICE>
    <LINE_EQUIVALENT_UNIT_PRICE>-15.99</LINE_EQUIVALENT_UNIT_PRICE>
    <LINE_EXCHANGE_EXTENDED_AMOUNT>-223.86</LINE_EXCHANGE_EXTENDED_AMOUNT>
    <CUSTOMER_TRX_LINE_ID>1567856</CUSTOMER_TRX_LINE_ID>
    </G_LINE_EQUIVALENT_UNIT_PRICE>
    </LIST_G_LINE_EQUIVALENT_UNIT_PRICE>
    - <LIST_G_TRX_LINE>
    - <G_TRX_LINE>
    <CF_ITEM_NO></CF_ITEM_NO>
    </G_TRX_LINE>
    </LIST_G_TRX_LINE>
    I need the summation of field LINE_EXCHANGE_EXTENDED_AMOUNT with the condition CF_ITEM_NO!=''
    can anybody help me with the solution.
    Thanks in Advance

    Kavipriya,
    Here is the XML
    <LIST_G_LINE_NOTES>
    <G_LINE_NOTES>
    <LINE_TRX_ID>1567856</LINE_TRX_ID>
    <LINE_ID />
    <LIST_G_TRX_LINE>
    <G_TRX_LINE>
    <LINE_DELIVERY_ID />
    <DISCOUNT>0</DISCOUNT>
    <CP_LN_TAX_AMT />
    <CF_ITEM_NO>SDCN1144B</CF_ITEM_NO>
    </G_TRX_LINE>
    </LIST_G_TRX_LINE>
    <LIST_G_LINE_EQUIVALENT_UNIT_PRICE>
    <G_LINE_EQUIVALENT_UNIT_PRICE>
    <LINE_EXCHANGE_EXTENDED_AMOUNT>-223.86</LINE_EXCHANGE_EXTENDED_AMOUNT>
    </G_LINE_EQUIVALENT_UNIT_PRICE>
    </LIST_G_LINE_EQUIVALENT_UNIT_PRICE>
    </G_LINE_NOTES>
    Edited by: user13012317 on Mar 10, 2011 11:00 PM

  • If like condition in rtf (template for oracle report)

    i'm begineer developer in oracle ebs i'm using report builder and rtf (xml) template to build report
    can anyone help my i want to make 2 layout in 1 template (1 rtf file) and give condition with if, lower and like (in sql i'm use like) but is error
    i give this query in my rft template:
    <?if: lower(WORK_ORDER_TYPE) like 'breakdown'?>
        <?start:body?>
            my_template
        <?end:body?>
    <?end if?>please help my for this problem
    thank you very much

    You can use choose too,
    note: the conditions are same
    <?choose:?>
    <?when: SHIP_COUNTRY_CODE=’IT’?>
    <?concat(‘Iscrizione Registro AEE n.’,WEEE_REG_NUM)?>
    <?end when?>
    <?when: SHIP_COUNTRY_CODE=’IT’?>
    <?concat(‘WEEE Registration No.’,WEEE_REG_NUM)?>
    <?end when?>
    <?end choose?>

  • Menu parameter and condition in rtf template

    Hello Guys,
    I have a problem with the .rtf xml condition for my
    menu parameter.
    <?sum(COUNT
    (../P_TIME_2 =2011)
    )?>
    the above does not work. I was wondering if a "IN" clause
    or something is needed but I dont know the syntax well.

    Hello AlexAnd,
    Thanks for your reply. Unfortunately I cant post the XML here (I dont even know how to see the xml).
    Let me explain what I did so far:
    I just added a field using the BI publisher Word Plugin (.rtf).
    BI Publisher Tab - > ab¦Field - > select fied and "sum" as caluclation method in window and that popped up- > double click on field and look
    at the code.
    Now this code says
    <?sum(mySalaryCount)?>
    I want to sum up mySalaryCount from the database but only when the column for a specific row
    has the right year value.
    lets say the one that has the value 2011. So I extend to code.
    <?sum(mySalaryCount)
    (../menuParamter_selected_year =2011)
    ?>
    the problem is, the above does not work. it works for "normal" parameters but does not seem to work for
    menu parameters (as set in the bi publisher data model)
    I guess the menuparameter is a list/array and hence the = is not the right operator.
    *in my case a menu parameter                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

  • Using Wild Card % in the IF condition of RTF templates

    Hi every one, we have a requirements to make bold whenever COL1 ends with Total. Below logic is not working. Can any body help?
    Thanks in advance.
    <?if@row:COL1like '%Total'?> <xsl:attribute name="font-weight" xdofo:ctx="incontext">bold</xsl:attribute><?end if?>
    -Phani Reddy
    ADP india,
    [email protected]

    You can do these
    <?if@row:contains(COL1,'Total')?> <?end if?>
    or
    <?if@row:ends-with(COL1,'Total')?> <?end if?>

  • RTF Template Condition

    Hi,
    Can anybody tell me how to add a condition in rtf template.
    Requirement: if sum =0
    Need to get data in one section
    if sum!=0
    Need to get data in another section
    Thanks!!!!

    >
    I would like not to hardcode the name of the Top XML node (Invoice) as it may change in the future.
    >
    IMHO name of this tag is needed
    <?if://ShipAddress?>cheking for existing tag ShipAddress on any level of xml
    it's true for ShipAddress for Invoice and for Invoice/Order
    <?if://Order/ShipAddress?>cheking for existing tag ShipAddress after tag Order
    so need point for start
    >
    n XSL/XPATH doc, they mention that we can use the dot (./ShipAddress)
    >
    yes but look at *.* more closly
    <?for-each:Invoice?>
    <?if:./ShipAddress?>
    or
    <?if:./Order/ShipAddress?>

  • Absolute/Relative Path for elements in xml to rtf template.

    Hi all,
    I have a small doubt, can anyone help me come out of this issue.
    I developed a BI Publisher Report using RTF Template and I am addressing XML elements which are out of the group in the XML file inside the for loop in the RTF template. I am able to get the body of the table but with all blank values on the output.
    I thought to give the full path ie., Absolute path instead only the element name, can anyone suggest me how to address an element outside the group in XML file from a for loop in the RTF template. Is it possible to address like that.?
    Thanks In advance.

    Hi Tim,
    I am using BIP 10.1.3.3.2. I am able to access system variable CURRENT_SERVER URL.
    Steps:
    <?param@begin:CURRENT_SERVER_URL?>
    <xsl:value-of select="$ CURRENT_SERVER_URL"/>
    CURRENT_SERVER_URL is getting printed in BI Publisher. Value displayed is http://xx4697.xxx.co.in:9704/xmlpserver.
    Now we are importing xsl into RTF template. File aaa.xsl is stored at [BIP_Installation_Directory\oc4j_bi\j2ee\home\default-web-app]
    We have hardcoded the path for XSL in RTF. The path is <?import: http://xx4697.xxx.co.in:9704/aaa.xsl?>
    As we want to set dynamic path we changed hardcoded xsl path to <?import: {$CURRENT_SERVER_URL}/../aaa.xsl?> but it is not working. Sometimes BIP is taking local path of MyDocuments folder and sometimes Desktop path. If I put that XSL file in MyDocuments folder or Desktop, it is working fine. But ideally it should refer [BIP_Installation_Directory\oc4j_bi\j2ee\home\default-web-app] path...
    Thanks,
    Amit D

  • How to have separate template for each role in OIM

    Hi,
    We have multiple roles on a multiple AS400 boxes. In OIM we need a separate template for each role that has to be popped up during provisioning. How do we achieve this in OIM?
    Pls help me with the solution.
    Edited by: user8963056 on May 23, 2010 7:47 PM
    Edited by: user8963056 on May 24, 2010 9:47 AM

    Thanks for the reply
    for the second question; we need on the basis of role these forrms will have different informations.
    the AS/400 guys wants the below steps to be done on OIM side
    They want to make sure below plan works with OIM plan.
    1.Per System, create templates per role.
    2.Update the AS400 User Request form to include a section for each system. Add templates for each role to each system’s section.
    3.Provide ITSA with a menu option to create profiles by selecting the template they wish to copy.
    4.Create backend programs to automate additional 400 tasks required per role.
    a.Create directory entry
    b.Add to Privilege Manager
    c.Add to Menu System
    d.Add to third party software
    e.Other as required.
    If we automate the above on the 400, in OIM , we would need to create the same templates.

  • PO RTF Template: Multiple attachments(long and shor text) displayed once

    Hi
    I have a RTF template for PO output communication program. These are the issues i am facing. could someone help.
    1) The template does not display multiple short text elements for each line number. It only displays the first attachment.
    <LINE_SHORT_TEXT>
    <LINE_SHORT_TEXT_ROW>
    <PO_LINE_ID>54015</PO_LINE_ID>
    <SHORT_TEXT>short text 1</SHORT_TEXT>
    </LINE_SHORT_TEXT_ROW>
    <LINE_SHORT_TEXT_ROW>
    <PO_LINE_ID>54015</PO_LINE_ID>
    <SHORT_TEXT>short text 2</SHORT_TEXT>
    </LINE_SHORT_TEXT_ROW>
    </LINE_SHORT_TEXT>
    In the template this
    <?for-each:LINES_ROW?><?sort:LINE_NUM;'ascending';data-type='number'?>
    <?LINE_NUM?> <?SHORT_TEXT?>
    <?end for-each?>
    2) The template does not display the multiple attachments(long text) for each line number. It only displays the first attachment.
    </DISTRIBUTIONS_ROW>
    </DISTRIBUTIONS>
    </LINE_LOCATIONS_ROW>
    </LINE_LOCATIONS>
    </LINES_ROW>
    </LINES>
    <LINE_ATTACHMENTS>
    <TEXT>long text attachment which is 2nd note.</TEXT>
    <ID>53995</ID>
    <TEXT>see this 5th long atta</TEXT>
    <ID>53995</ID>
    <TEXT>long text 1</TEXT>
    <ID>54015</ID>
    <TEXT>long text 2</TEXT>
    <ID>54015</ID>
    </LINE_ATTACHMENTS>
    In the template i am doing this
    <?if: PO_DATA/LINE_ATTACHMENTS/TEXT !=''?>
    <?for-each:LINES_ROW?><?sort:LINE_NUM;'ascending';data-type='number'?>
    <?if:LINE_NUM!=''?> <?concat('Line Number ',LINE_NUM)?> <?end if?>
    <?variable@incontext:PoLnID;'PO_LINE_ID'?>
    <?/PO_DATA/LINE_ATTACHMENTS/ID[child::text()=$PoLnID]/preceding-sibling::TEXT[1]?>
    <?end for-each?>
    3) Also I want the Total amount to be printed on the last page but the total amount header should still be there on every page and has "Continued" text when it has multiple pages.
    4) Also the Text File attached to PO is not seen in the PDF PO. is there anything for it do ?
    Please help
    Thanks
    Edited by: user525275 on May 1, 2009 2:14 PM

    Hi Tim,
    You are quite right... I'm trying to associate each of the text attachments with the proceeding ID.
    I've simplified it (sorry, I hadn't turned on the monitoring of the forums) in the following forum post:
    Basic RTF template question
    BTW, thanks for your blog. It's been very helpful.
    Cheers,
    Andrew

Maybe you are looking for