It happens in cases when the Job changes User profile as in the case of a JDBC connection. In my scenario the Java program was making a call to CL program using a stored procedure that will print a spool file and then convert it to a PDF and return it to the requesting party. When we called the stored procedure from STRSQL in AS400 it worked fine but when called from the Java program it failed to find the Spool file giving the following message.
Message ID . . . . . . : USR8431
Message type . . . . . : Diagnostic
Message . . . . : Spooled File S123456789 in job *// number *LAST not found
The solution is very simple. All you have to do is to change your OVRPRTF command with SPLFOWN(*JOB).
What is does?
- The spooled file is owned by the original user profile of the job. If the job has switched to a new user profile, the original user profile is still the owner of the spooled file.
No comments:
Post a Comment
NO JUNK, Please try to keep this clean and related to the topic at hand.
Comments are for users to ask questions, collaborate or improve on existing.