RTC report design: Looping in temporary table

mtlmonkmtlmonk Member Posts: 48
edited 2015-07-23 in NAV Three Tier
Hello,

I've got a report where I need to display Sales Invoice Lines and Sales Credit Memo Lines under Item Category grouping.

My solution was to build a temporary table of type Sales Invoice Line and put in the values of the credit memo lines in them but changing the Document type to Invoice....So far so good...

But when running the execution, it loops into the lines 2X for both Sales Invoice Lines and Sales CM Lines. Therefore, it unnecessary data.

How can you prevent the execution from adding the first loops of data but only looping in the Temp tables looping?

Dataitems as designed:

Sales Invoice Line
In there, it loops thru each and add them to a temporary Sales Invoice Line table
Sales CM Line
In there, it loops thru each and add them to the same temporary Sales Invoice Line table (obviously, changing the document type to Sales Invoice)
Integer
In there, it loops thru each record found in the temporary Sales Invoice Line table

In the About Page of the report, it shows data for each looping. I would like to have data only for the "Integer" dataitem loop.

Thanks in advance,

J-P

Comments

  • einsTeIn.NETeinsTeIn.NET Member Posts: 1,050
    First of all there's no Document Type in Sales Invoice Line. Is it possible that the data really exists twice in the Temp Table?

    Regarding your question, it depends on how your Report looks like in detail. The idea should be to set output variables only in the last Data Item of Integer. You could use Report 111 as an example.
    "Money is likewise the greatest chance and the greatest scourge of mankind."
Sign In or Register to comment.