|
Johnson, In a message dated 11/30/01 6:19:19 PM US Eastern Standard Time, Johnson_Zhao@bba-nonwovens.com writes: <<snip>> > Anyone can give me a more detailed descriptions on how to create this kind of > CL program. If you can send me a sample CL program to do this kind of stuffs, > this will be very great. You can email your replies to me by > Johnson_zhao@bba-nonwovens.com CL programming is _NOT_ an appropriate question for this list. CL is the base language of the AS/400, and is available to all -- regardless of whether or not you have purchased application development tools or a compiler. I recently wrote a CL program to do what you ask. I created a file that contained the ten character query name and a batch/interactive flag as follows, although I do not presume to have correct syntax offline: PGM DCLF (MEQUERY) [containing "querynam" for the query name and "batchori" for batch or interactive] READ: RCVF MEQUERY MONMSG (CPF2103) GOTO CMDLBL(END) IF COND(&BATCHORI *EQ "I") THEN(RUNQRY(&QUERYNAM) RCDSLT(*YES) IF COND(&BATCHORI *EQ "B" THEN(SBMJOB CMD(RUNQRY &QUERYNAM) GOTO CMDLBL(READ) END: ENDPGM This program is written strictly from memory and is not necessarily correct (especially as regards CPF2103, which should be "end of file"). If you do not already _KNOW_ how to write CL, I doubt that this will help. I hope that it will help others... Regards, Dean Asmussen Enterprise Systems Consulting, Inc. Fuquay-Varina, NC USA E-mail: DAsmussen@aol.com "Children have more need of models than of critics." -- Carolyn Coats
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.