|
Peter: On Sun, 16 December 2001, "Peter Dow" wrote: > I'm looking for a way to copy an IFS stream file to an AS400 spool file, I'd guess this is the basic problem; that is, what you want to do isn't what your command is written to do. > something like: > > CPY OBJ('/home/test/textfile.txt') + > TOOBJ('/QSYS.LIB/QGPL.LIB/PRINTER.FILE') Though you want to copy to a "spool file", the command tries to copy to a printer file -- not the same thing at all, eh? (I'm assuming PRINTER.FILE is a PRTF kind of file.) Naturally, the PRTF exists; and hence, the CPY fails as it always will when TOOBJ() exists: > This fails with CPFA0A0 "Object already exists". I'm not sure if any 'standard' command will be useful for this; I'd like to know if any work. I'd start with QShell utilities for quick stuff, likely with pr. Then I'd create my own procedure in order not to require QShell. Note that a streamfile can be CPY'd directly to a new *usrspc object, i.e., with extension .USRSPC, if the *usrspc doesn't exist. Unfortunately, due to the way audit bits are handled, you'll probably need *AUDIT special authority. (The reverse doesn't seem to be true.) This might be useful for an intermediate solution if you don't have immediate time for a true solution. Tom Liotta -- Tom Liotta The PowerTech Group, Inc. 19426 68th Avenue South Kent, WA 98032 Phone 253-872-7788 Fax 253-872-7904 http://www.400Security.com ___________________________________________________ The ALL NEW CS2000 from CompuServe Better! Faster! More Powerful! 250 FREE hours! Sign-on Now! http://www.compuserve.com/trycsrv/cs2000/webmail/
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.