Report batch xml with header en details

Posted by Jorrit on 06-Jul-2016 09:39

Hi,

We have a template report via batch with header (from obj1) and details (from obj 2):

first we want to loop all the records of obj1, and when finished we want to loop all the records or related records of first loop.

E.G.

<SalesOrderDataSet>

{!#LOOP_BEGIN.all#120228}

<SalesOrder diffgr:id="SalesOrder1" msdata:rowOrder="0" diffgr:hasChanges="inserted">
  <SalesOrderID>{!ordern_ordernumber}</SalesOrderID>
  <CompanyName>Companyname</CompanyName>
  <CompanyAddress />
  <CompanyPostal>CompanyPostal</CompanyPostal>
  <CreateDate>CreateDate</CreateDate>
  <LastModifiedDate>LastModifiedDate</LastModifiedDate>
  <ShopName>ShopName</ShopName>
  <InvoiceNumber>InvoiceNumber</InvoiceNumber>
  <ApprovalNumber>ApprovalNumber</ApprovalNumber>
  <ReferenceNumber>ReferenceNumber</ReferenceNumber> 
  <Comments>Some Comments</Comments>
  <DateOfInvoice>DateOfInvoice</DateOfInvoice>
</SalesOrder>

{!#LOOP_END.all}


{!#LOOP_BEGIN.R295312#98006}

<SalesOrderLine diffgr:id="SalesOrderLine1" msdata:rowOrder="0" diffgr:hasChanges="inserted">
     <SalesOrderLineID>838051</SalesOrderLineID>
     <SalesOrderID>{!ordern_ordernumber}</SalesOrderID>
     <ArticleName>wisselen wiel aan voertuig</ArticleName>
     <Count>4.000</Count>
     <SalesPrice>11.0250</SalesPrice>
     <SalesAmount>44.1000</SalesAmount>
     <SalesDiscount>10.0000</SalesDiscount>
     <ArticleNumber>A4005</ArticleNumber>
</SalesOrderLine>

{!#LOOP_END.R295312}

</SalesOrderDataSet>

In my test the first loop works but the second loop is not executed.

Can anybody help me?

Regards Jorrit

All Replies

Posted by Karthikeyan Bhaskaran on 07-Jul-2016 01:02
Is this a Document Template report? Or is it HTML Template report?

If it is HTML Template report can you try pushing the second loop inside the first one?
This thread is closed