5 Replies Latest reply: Feb 15, 2011 9:51 AM by Brent Edwards RSS

    Loop and Load (not Reduce)?

      Hi, I'm very new to Qlikview and would appreciate any help that could be provided on the issue below...

      We have the need to segment our data into different QVWs in order to limit the amount of data in memory.

      I have written a QVW app to create QVDs for each data segment (ex. Data_North.qvd, Data_South.qvd, Data_East.qvd, Data_West.qvd). Now, I need to load each QVD into it's own QVW file (with other QVD content), so the end users can access it.

      This final QVW should:

      1. Load the data from a given QVD (North, South, East, West) based on a parameter.

      2. Save the QVW (ex. UserApp_North.qvw) off in an area for user access.

      The loop and reduce feature in Publisher does not seem to lend itself to this type of behavior...what am I missing?

      Thanks in advance!

        • Loop and Load (not Reduce)?
          s j

          can you post application with limited data ?.

            • Loop and Load (not Reduce)?

              Sorry, but I haven't built the application that would create the individual QVWs yet...was hoping to get some guidance before I started coding.

                • Loop and Load (not Reduce)?
                  John Witherspoon

                  I think you're right that loop and reduce won't do what you want. For loop and reduce to work, you'd have to create a QVW with all four QVDs in it first, then loop and reduce on that QVW to create your four separate QVWs. However, that would still require your server to be able to handle loading all the data at once during the reload process, so fails to limit the amount of data in memory. Well, it limits it some, as users would never see the full QVW. But it still needs it in memory during the load.

                  I'm not thinking of a solution, but that doesn't mean there isn't one. I'm not particularly great at the server and reload side of the house.

                    • Loop and Load (not Reduce)?
                      Johannes Sunden

                      I think the Script Parameter section under the Reload tab, using Publisher, lends itself well to this type of implementation. One way would be to create a field with North, South, East, West in the QVW and then use the script parameter to loop through this field and use the value to load the specific QVWs. Or, just use the parameter fields:

                       

                      Parameter Name

                      The variable created in the QlikView script that will be used in the script execution of the document.

                      Parameter Value

                      The values that will be assigned to the variable. This value or values will be used to create the document.
                      Enter a list of values separated by semicolons (;) or use dash (-) to enter a sequence of data. A separate
                      document will be created for each value.

                      The Script Parameters in v10 replaces the old repeat task from previous versions.



                        • Loop and Load (not Reduce)?

                          Yes, I agree this seems to be the route I need to take. The part I get stuck on is this...once I have passed the parameter in to the QVW to load a data segment (ex. South) and the script has loaded the data, how do I save that specific QVW (ex. UserApp_South.qvw)?

                          Is there a "save" command I can issue in the script to this? Or is there an option in Publisher to save off the file?

                          Thanks!