Eddie Monster
14th June 2002, 23:42
We have a defined login of 'Batchjob' as a unix and baan user that we use to run jobs for Job Management.

One such 'batchjob' that runs under job managment runs all of our Work-In-Process reports for Finance's month end (the Job is called WIP).

This WIP job runs all inventory reports for all of our divisions (Pennsylvania and Arizona). These reports take several hours to run due to our heavy use of projects (not 'big' projects) and the number of transactions in our integrations table and will continue to take several hours until we archive.

Our Finance department would like to be able to have the batchjob print one full set of reports in Pennsylvania and have duplicates of the Arizona set print in Arizona. Since the reports that print are 'owned' by the 'batchjob' user, other users cannot re-print the job through Maintain Device Que.

Does anyone know of a way to get the reports to print without creating another batchjob user or Job Managment job?


Constraints:
We do not want anyone outside of our IT department to have rights to the 'batchjob' user for obvious reasons.

Due to the amount of time it takes for the reports to run we don't want to have to re-run the same reports. Additionally when the reports are run by 'batchjob' we have some coding that causes tables to be populated when we calculate an automatic WIP Accrual and an automatic reconciliation to our GL detail that will be double populated if 'batchjob' runs the job twice.

We don't want someone from IT to have to log into baan manually as batchjob to reprint these reports everymonth.

Any ideas?

jaymukh
15th June 2002, 00:10
Need to create a shell script to print the file to two different printer.
In the job mention a speacial device which calls this shell script. using lp command print the same tmp file to two different printer
Shell script may be like this...
lp -dprinter1 $1
lp -dprinter2 $1


call this in either queue field or as argument ASCII/twoprint.sh %s


Thanks

Jay

mark_h
17th June 2002, 15:17
Hi Eric!

Here is one I used for the Print Production Priority report. Our users wanted it run over night, because it took to long for them to run it when they get to work. At the same time I did not want to run this session 30 times for each work center - They need the reports when they walked in the door. I forgot to mention they wanted me to print their work center on their printer AND depending on which work center how many copies were printed. So what we did was put it in a batch job and had the report sent to disk. I then wrote a session that the user runs and prints only the piece they wanted. Now they logon, run my session print their work center(how ever many copies), and all in a matter of minutes. Their are actually 3 reports that they print from this session, they give the work center and yes/no to which reports they want printed.

Not sure if this applies, but thought I would mention it.

Good Luck!

Mark

Eddie Monster
18th June 2002, 17:20
Did you create a unix script to do that? What kind of file did you have the original reports 'print' to? I may be able to use this for my project listed above, but I can definately think of some other places where this would be mighty handy!

mark_h
18th June 2002, 21:03
The batch job runs and sends the report to an ASCIF file. We call this batch the "Daily Dispatch". Then the user runs the baan session which prints these files based on which report and which work center. The print program then reads these files and sends them to a report. The report is nothing but one detail with one field. The key is that your prints have to have the same page length as the ASCIF file, if not headings get kind of screwed up. Our page length is 55 for both our printers and the ASCIF device.

The only difficult thing about this is that I have to read the ascii file to find the beggining and ending pages based on a heading that contained the work center. Not really hard since I knew what the files looked like.

Mark