Hitachi Vantara Pentaho Community Forums
Results 1 to 2 of 2

Thread: SQL loop into single report

  1. #1
    Join Date
    Jun 2006
    Posts
    25

    Default SQL loop into single report

    Hi all gurus,

    I need to loop over a result set that returns data into a single report.

    The reason I can't use a single sql statement is that the sql must be parameterized before executing. The parameter is a Day name (part of a field name Stop_{DAY_NAME}.

    The way it is now, seems to only return the last iteration's data to the report not all of the data.

    Can anyone help. Please?

  2. #2
    Join Date
    Jun 2006
    Posts
    282

    Default Try a javascript

    It sounds like you need to iterate over one result-set to generate multiple result-sets and then aggregate those result-sets into one final result-set for your report. If that is the case I would try a javascript and insert each row per iteration. You would need to pass in the first result set into your javascript. I don't think you can use the loop component in this scenario unless it is a very small(one to two rows of data) report. Good Luck !!
    "If you want to increase your success rate, double your failure rate."
    Thomas Watson, Sr (former president of IBM)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Privacy Policy | Legal Notices | Safe Harbor Privacy Policy

Copyright © 2005 - 2019 Hitachi Vantara Corporation. All Rights Reserved.