7 Replies Latest reply: Oct 26, 2010 7:31 PM by John Witherspoon RSS

    Reduce Vs Distribute

      What is the difference between reduce and distribute tabs on QV 9.0 enterprise management console? I have one reload task XYZ, upon successful completion I want that task to create two identical copies with field name in it. For eg.

      Reload task XYZ and reload document XYZ.qvw with a field date in it.

      Upon successful Reload of XYZ.qvw I want to Publisher to create to more copies of the same document with different name

      XYZ_date_1.qvw and XYZ_date_2.qvw. Both files should be identical copies of XYZ.qvw which just got reloaded.

        • Reduce Vs Distribute
          John Witherspoon

          I believe the Distribute tab "Loop Field in Document" choice is for when the field itself contains information about WHO to distribute to, like a user ID. So instead of manually specifying a list of users, you'd specify a list of users in the application itself. It would be one document distributed to all those users. I think. I haven't used it.

          The Reduce tab "Loop and Reduce" choice creates separate documents for each value of the field. I think. I haven't used it.

          Neither sounds like what you're asking for, assuming you want the CONTENTS of your two applications to be completely identical, that is, not reduced to ONLY that date. It sounds like you need some sort of loop but don't reduce.

          Well, maybe you can loop and reduce if the date field is completely separate from your main data. In that case, the reduce step would basically do nothing. Might work. Or maybe I'm just not understanding what you're after.

          • Reduce Vs Distribute
            Neil Miller

            Reduce will remove data from the document. Distribute sets it to be sent out to various users.

            You would do a reduce if there is data you don't want included or if the data you want to include will be different for each user. Example, User A gets USA, User B gets Canada. You would need to reduce on Field and then Distribute to each user.

            It doesn't sound like you need to use Reduce since the documents will be identical. I think you need to use Distribute. I don't think Manual can be used, because it doesn't seem to allow you multiple filenames. I would say Loop in Field on a dummy field with two values. I'm not sure what the file names would be in this case, but it should get you the two documents you need.

            EDIT: Or what John said. Big Smile

              • Reduce Vs Distribute

                Let me give you more information here. For example, I have Market_Analysis.qvw file which is run for reload every hour with different study name. Study_name is also a field in the file, which is unique for that particular hour.

                For first hour, Market_Analysis.qvw relaods (1 Mb size) for Study_name = Pen. As soon as the file reloads I want to have two more files as output

                Market_Analysis_Pen_1.qvw (1 Mb No reduction) & Market_Analysis_Pen_2.qvw (1 Mb No reduction)

                For second hour, Market_Analysis.qvw relaods (5 Mb size) for Study_name = Pencil. As soon as the file reloads I want to have two more files as output

                Market_Analysis_Pencil_1.qvw (5 Mb No reduction) & Market_Analysis_Pencil_2.qvw (5 Mb No reduction).

                I think I'll have to use distribute task, I am not sure how can I give this dynamic names on distribute tab on QEMC.

                  • Reduce Vs Distribute
                    John Witherspoon

                    OK, so when you reload the first hour, Market_Analysis.qvw will only contain a single Study_name, 'Pen'? After you reload the second hour, there will be no more 'Pen' data, and only a single Study_name, 'Pencil'? Probably this:

                    Create a Dummy_Field with values 1 and 2 not connected to your data, as already mentioned. Loop and distribute on Dummy_Field. Reduced Document Name = Market_Analysis_%DocumentField,Study_name%_%DocumentField,Dummy_Field%.

                      • Reduce Vs Distribute

                        I'll try and let you know if it works!

                        • Reduce Vs Distribute

                          John, Your idea works like a charm. However, I just got another requirement. As you know, we reload a document ABC.qvw and we distribute it with ABC_Pen_1.qvw and ABC_Pen_2.qvw at hour one. As of now we distribute them on same server. Is it possible to distribute ABC_Pen_2.qvw on some other server where it was not published ?

                          What I mean is ABC_Pen_1.qvw will remain on same server where it was published / reloaded, however, ABC_Pen_2.qvw will be forwarded to another server. I cannot have a batch job for this as document name changes every hour. For example, ABC_Pen_1.qvw for hour one will be ABC_Pencil_1.qvw next hour and so on...

                          Any suggestions ?

                            • Reduce Vs Distribute
                              John Witherspoon

                              I think you could still have a batch job do it, since you just want to forward whatever ABC_*_2.qvw was created in the past hour.

                              There probably IS a way to do it in Publisher, though, but I'm really not sure how you'd manage it. I wasn't involved in setting up our server environment and don't know how to control where a document is distributed. Specify a path in the document name, and break it into two tasks instead of one? I don't know if that would work, and there's probably a better way.

                              Hopefully someone else has an idea?