Archive jobs from Print Manager

 8 Replies
 3 Subscribed to this topic
 27 Subscribed to this forum
Sort:
Author
Messages
pops
Advanced Member
Posts: 46
Advanced Member

    I was wondering if this is possible...

     

    A user creates a job/report and submits it.  They then go into Print Manger to view the results.  The next time they run the job, the previous job results are overwritten with the new one.  We need to be able to archive the previous job (move it to a different directory) before it's overwritten.  Is there a way to do this?  There are many users so running some kind of job outside of Lawson might be a huge performance issue.

     

    Thank you!

    Allen

    Woozy
    Veteran Member
    Posts: 709
    Veteran Member
      I'm sure it is possible to "archive" them by having a script copy the $LAWDIR/print/{username}/{jobname} folder to an archive path with a datestamped name. However, I think you would have to access them without using the application, which may not be very helpful, depending on what you are trying to accomplish.
      Kelly Meade
      J. R. Simplot Company
      Boise, ID
      Woozy
      Veteran Member
      Posts: 709
      Veteran Member
        Actually, the more I think about this, the more challenging it appears to be. You could create a script as I mentioned above, but I'm not sure how you would trigger it. In Unix it could run very frequently under cron, but I don't know that there's a way to identify when the job is "done" so the files were all complete. Also, if you ran it less often, it would be possible to miss a job if someone ran it multiple times in quick succession.

        Are you needing to do this for all jobs, or for specific jobs for a certain user? If the latter, are they scheduled jobs or ad-hoc jobs? If there are specific jobs, and they are scheduled jobs, you could probably script a process to create a new job (date-stamp based) and then run the job. It would take some fiddling, but it should be possible.
        Kelly Meade
        J. R. Simplot Company
        Boise, ID
        Todd Mitchell
        Veteran Member
        Posts: 87
        Veteran Member

          There are couple options that I can think of:

          1. Copy the reports to an archive directory as Woozy mentioned -- but as he also mentioned, are not going to be accessible by Lawson
          2. Copy the reports to the current directory with a different name and do a loadrpts which will make them accessible via Lawson
          3. We utilize a 3rd party software called Cypress that we use as our report retention application.

           

          pbelsky
          Veteran Member
          Posts: 80
          Veteran Member
            What platform are you on? We are on windows and we push out adobe reader to our users. Those of our users who need to save reports as part of their business processes have their portal Default Report Type (under user options) set to pdf. This causes the report to open as a pdf. If they want to save that report, they just save the pdf to a specific folder of their choosing (e.g. a folder on a network drive that they have set up with specific permissions for their business area).
            pops
            Advanced Member
            Posts: 46
            Advanced Member
              This would be for all users. There doesn't seem to be some sort of trigger available in Lawson 10 to kick off some sort of script when the report has been completed. We can't have an external script always running in the background as I am sure we would miss files as users run jobs/reports at the same time.
              pops
              Advanced Member
              Posts: 46
              Advanced Member
                We are on Windows and we already set the report types to PDF. We don't want the users controlling this, IT needs to control the archiving.
                Todd Mitchell
                Veteran Member
                Posts: 87
                Veteran Member
                  As stated earlier, we have a 3rd party solution called Cypress that acts as a report retention application. Having something like this you can then set up the Report Distribution within the job itself to send the report to this retention application.
                  mikeP
                  Veteran Member
                  Posts: 151
                  Veteran Member
                    We've done it, but it's cumbersome, at least the way we do it, so we only do it on jobs that make it worthwhile.

                    Each job that needs report history saved must be set up as a multistep job. The first step saves the print files from the previous run, the second is the actual Lawson job, e.g. PR530.

                    The first step is a user token that runs a command file that in turn runs a VB script. The script creates a new folder to store the previous run's files, named the same as the original folder, but with a time stamp appended. The report files for the previous run are copied to the new folder. Finally, the loadrpts utility is run to load the new folders into the user's report list so they'll show up in their print manager.