2 Replies Latest reply: Aug 26, 2014 1:48 PM by 1060618 RSS

    Sorting WIP Recorsd & WIPTransactions - Functionality | Documaker 12.2

    1060618

      Hello,

       

      Here is our situation.

       

      We store all the transactions which are triggered for "Batch Paper Print" into a database and assign the status code "B" to them. One of the column in the table is Agent #.  Also we have a Documaker Recipient - Agent, which has to print on its own stack. The catch is that the Paper Stack should be ordered by Agent # and each Agent's document set should be separated by a separator page.

       

      We are planning to develop a DAL script to add a Separator Page after each document set. However for this, we'll have to have the records in sorted order. We have two options here.

       

      1. Sort the BCH file that's generated after the GENDATA based on the Agent # offset. And then let the GENPRINT pick those sorted records.

      2. Have the records in the Database in the sorted order upfront. We are considering to add Agent # to be part of the (Clustered) Key so that these records will be sorted (that's my assumption).

       

      We are more inclined towards #2. However there is a question is since WIPTransactions retrieve records based on STATUSCODE - which is not part of the key, would this approach work?

       

      Appreciate suggestions on the above predicament.

       

      Also what goes behind the scenes for this rule WIPTransactions? Does it have a basic SQL query?  I am trying to understand how this Rule - WIPTransactions, works. From the manual the definition is as follows.

       

      "This rule processes WIP transactions and places them into batch files for GenPrint and GenArc processing. To specify which transactions, you use codes which you define in the Status_CD control group. If a WIP transaction has a status code that is not among the list of codes to be processed, the system deletes the transaction and WIP file."

      ___

       

      Thanks!    

        • 1. Re: Sorting WIP Recorsd & WIPTransactions - Functionality | Documaker 12.2
          user9976634

          The WIPTransaction rule defines a status code (or several) that you want to pick up during Gendata processing. Once loaded, then you may optionally have rules that make additional changes to the transaction before any batching rules kick in to route the recipients where you want them.

          Now, if you want your batch (BCH) files sorted before running GenPrint, you can accomplish this manually, between the GenData and GenPrint steps using your favorite sort utility. Or, depending upon your version, I believe there is a SortBatches rule that can be added to the top-level rules in the AFGJOB that will do simple sorts on the BCH files as a final step in the GenData process.

          • 2. Re: Sorting WIP Recorsd & WIPTransactions - Functionality | Documaker 12.2
            1060618

            Actually we did accomplish by going by the approach # 2 as I have listed in my original post.

             

            We had a Clustered Index declared on the Column. The records are retrieved in a sorted order.

             

            Thanks for your time.