Cool. Learn something new everyday. Phil --- Scott Lindstrom <SLindstrom@Pactiv.com> wrote: > > You can perform an FTP to QSYSPRT. (yep - it really > works!) > > Scott Lindstrom > > > > > > > > > Hi Tom, > > Yes, I'm looking for the equivalent of > > CPYF filea QSYSPRT > > copying a physical file to a printer file to create > a spool file. > > Peter Dow > Dow Software Services, Inc. > 909 425-0194 voice > 909 425-0196 fax > > > ----- Original Message ----- > From: <email@example.com> > Sent: Monday, December 17, 2001 7:43 PM > Subject: Re: Printing from the IFS > > > 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. > > > > _______________________________________________ > This is the Midrange Systems Technical Discussion > (MIDRANGE-L) mailing list > To post a message email: MIDRANGE-L@midrange.com > To subscribe, unsubscribe, or change list options, > visit: > http://lists.midrange.com/cgi-bin/listinfo/midrange-l > or email: MIDRANGE-Lfirstname.lastname@example.org > Before posting, please take a moment to review the > archives > at http://archive.midrange.com/midrange-l. > __________________________________________________ Do You Yahoo!? Check out Yahoo! Shopping and Yahoo! Auctions for all of your unique holiday gifts! Buy at http://shopping.yahoo.com or bid at http://auctions.yahoo.com
As an Amazon Associate we earn from qualifying purchases.
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.