× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



On 09-Aug-2014 06:05 -0500, rob@xxxxxxxxx wrote:
This is the first migration where we gave a rip about spool files. I
forgot to tell it to save the spool files. I do not want to redo the
whole save. Is there a way to just save spool files?


The API invocations following the imaginary command-string for the SAVOBJX request should, AFaIK, will create a backup of just spool files; I can not test. The *USRSPC [according to the remainder of the scripted CL command requests] then is saved, restored, modified, and finally used again for enabling restore of those same spooled files.

SAVOBJX LIB(*SPLF) /* more accurately: LIB(*SPLFDTA) */
SPLFDTA(*ALL) DEV(TAP01) UPDHST(*NO)
OUTPUT(*PRINT) INFTYPE(*MBR) /* include SPLF info */
/* remainder of parameters defaulted; prior 6 specified */
OBJ((*ALL *ALL)) VOL(*MOUNTED)
OMITLIB(*NONE) OMITOBJ(*ALL/*ALL *ALL)
ASPDEV(*) CLEAR(*NONE) DTACMP(*NO) DTACPR(*DEV)
ENDOPT(*REWIND) EXPDATE(*PERM) FILEMBR(*ALL *ALL)
LABEL(*LIB) MEDDFN(*N) PRECHK(*NO) OPTFILE('*')
PVTAUT(*NO) OUTFILE(*N) QDTA(*NONE) SAVFDTA(*NO)
SAVF(*N) ACCPTH(*SYSVAL)
SAVACT(*NO) SAVACTMSGQ(*NONE)
SAVACTWAIT(120 *LOCKWAIT *LOCKWAIT)
SEQNBR(*END) STG(*KEEP) SYNCID(*NONE)
TGTRLS(*CURRENT) USEOPTBLK(*NO)

call quscrtus ('SAVSPLFDTAQTEMP ' 'SAVSPLFDTA'
x'00000120' x'40' '*EXCLUDE '
/* See_Scale:*/'QSRSAVO input ')
/* Scale_line_:'....+....1....+....2....+....3....+....4....+....5' */


call quschgus ('SAVSPLFDTAQTEMP ' x'00000001' x'00000120'
/* reformat the following lines into one contiguous hex string */
x'00000006
0000001C000000020000000E000000015CE2D7D3C640404040404040
00000020000000030000000E00000001E3C1D7F0F14040404040404040404040
00000020000000230000000C000000020000000C000000E04040404040404040
000000200000001700000001F140404040404040404040404040404040404040
000000200000001A00000001F240404040404040404040404040404040404040
000000200000000500000001F040404040404040404040404040404040404040
4040404040404040404040404040404040404040404040404040404040404040
0000001400000000000000000000000100000100404040404040404040404040
000000185CC1D3D34040404040405CC1D3D34040404040404040404040404040'
'0')

call qsrsavo ('SAVSPLFDTAQTEMP ' x'0000000000000000')

crtsavf qtemp/savus

savobj savsplfdta qtemp *savf *usrspc savf(qtemp/savus) updhst(*no)

/* transfer save file.data to the target system; the example */
/* restore request presumes target in *LIBL of same name: */

rstobj savsplfdta qtemp *savf *usrspc savf(*libl/savus)

call quschgus ('SAVSPLFDTAQTEMP ' x'00000001' x'00000004'
x'00000005' /* five vlen rcds: vl01-vl05 */
'0') /* "remove" UpdHst as sixth vl record */

call qsrrsto ('SAVSPLFDTAQTEMP ' x'0000000000000000')

-+-+-+-+-+

Merely for reference [if for example there is an error in the above long hex string], the long hex string is broken down into what are effectively each parameter and parm-specification, each as a separate modification to the respective data within the user space [used as input (parameters) to both the Save API and the Restore API]; note that some offsets were hard-coded for simplicity, but obviously a coded solution would want to use procedures to add the vl-records and additional data:

call quschgus ('SAVSPLFDTAQTEMP ' x'00000001' x'00000004'
x'00000006' /* six vlen rcds: vl01-vl06 */
'0') /* Set nbr of VLen rcds to follow */

call quschgus ('SAVSPLFDTAQTEMP ' x'00000005' x'00000010'
x'0000001C000000020000000E00000001'
'0') /* vl01 LIB(): len(x1C) key(x02) dln(x0E) */
/* for pretty DMPOBJ output short vl */
/* add x04 for LIB key array element count */

call quschgus ('SAVSPLFDTAQTEMP ' x'00000015' x'0000000A'
'*SPLF '
'0') /* vl01 dta: LIB(*SPLF) */

call quschgus ('SAVSPLFDTAQTEMP ' x'00000021' x'00000010'
x'00000020000000030000000E00000001'
'0') /* vl02 DEV(): len(x20) key(x03) dln(x0E) */
/* add x04 for DEV key array element count*/

call quschgus ('SAVSPLFDTAQTEMP ' x'00000031' x'0000000A'
'TAP01 '
'0') /* vl02 dta: DEV(TAP01) */

call quschgus ('SAVSPLFDTAQTEMP ' x'00000041' x'0000000C'
x'00000020000000230000000C'
'0') /* vl03 SPLFDTA(): len(x20) key(x23) dln(x0C) */

call quschgus ('SAVSPLFDTAQTEMP ' x'0000004D' x'0000000C'
x'000000020000000C000000E0'
'0') /* vl03 dta: SPLFDTA(*SELECT) */
/* spool selection will be located at ofs(xE0) */

call quschgus ('SAVSPLFDTAQTEMP ' x'00000061' x'0000000C'
x'000000200000001700000001'
'0') /* vl04 OUTPUT(): len(x20) key(x17) dln(x01) */

call quschgus ('SAVSPLFDTAQTEMP ' x'0000006D' x'00000001'
'1'
'0') /* vl04 dta: OUTPUT(*PRINT) */

call quschgus ('SAVSPLFDTAQTEMP ' x'00000081' x'0000000C'
x'000000200000001A00000001'
'0') /* vl05 INFTYPE(): len(x20) key(x1A) dln(x01) */

call quschgus ('SAVSPLFDTAQTEMP ' x'0000008D' x'00000001'
'2'
'0') /* vl05 dta: INFTYPE(*MBR) */

call quschgus ('SAVSPLFDTAQTEMP ' x'000000A1' x'0000000C'
x'000000200000000500000001'
'0') /* vl06 UPDHST(): len(x20) key(x05) dln(x01) */

call quschgus ('SAVSPLFDTAQTEMP ' x'000000AD' x'00000001'
'0'
'0') /* vl06 dta: UPDHST(*NO) */

call quschgus ('SAVSPLFDTAQTEMP ' x'000000E1' x'00000014'
x'0000001400000000000000000000000100000100'
'0') /* xtra len(x14): SPLSLT(*SLTATR) */

call quschgus ('SAVSPLFDTAQTEMP ' x'00000101' x'00000004'
x'00000018'
'0') /* xtra len(x18): SLTATR() */

call quschgus ('SAVSPLFDTAQTEMP ' x'00000105' x'00000014'
'*ALL *ALL '
'0') /* xtra dta: SLTATR(*ALL/*ALL *ALL etc.) */



As an Amazon Associate we earn from qualifying purchases.

This thread ...


Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

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.