Author Topic: -j parameter usage with arsload utility  (Read 5812 times)

sandeepveldi

  • Guest
-j parameter usage with arsload utility
« on: July 11, 2011, 01:51:02 PM »
Hi All,
Is any one using the "-j" option available with arsload utility? If so, can you please provide some examples for the following cases listed in the documentation:
1) Appending a document name to an index value.                         
2) Populating an index value with something not seen within the data.   
3) Populating an index value with something that does not change

Basically, I'm trying to find if there's an option to add some metadata to the index file which is not part of the input load file before loading the file to CMOD.

Thanks in advance
Sandeep Veldi

wwwalton

  • Guest
Re: -j parameter usage with arsload utility
« Reply #1 on: July 12, 2011, 07:37:15 AM »
We do this alot actually.  One scenario we use is pulling syslogs from the mainframe in an ODMP (AIX) system.  I build a supplementary index file with JES Job Number and Return code, then issue an explicit ARSLOAD.  Another way we use this is where the the developer supplies an xml file with additional info.  We parse that and build the supplemental index, throw away the xml file and issue the load on a pdf or XLS file.  The down side is that one has to create a pre-processor of the object to do the construction of the supplemental index.  I use python for this.

-walt

sandeepveldi

  • Guest
Re: -j parameter usage with arsload utility
« Reply #2 on: July 13, 2011, 11:11:00 AM »
Walton,
Can you please explain more about the later case where you are pulling index data from the xml file and building the supplementary index file?
What's the format of param file that has to be used to add this additional index data etc?

Thanks
SV

wwwalton

  • Guest
Re: -j parameter usage with arsload utility
« Reply #3 on: July 13, 2011, 11:49:12 AM »
Basically, we have filters for different scenarios.  For the xml processng, the python code has a template:
IndxTblBeg = ['CODEPAGE:850',
   'GROUP_FIELD_NAME:OD_CIS_JOB_NM', 
   'GROUP_FIELD_VALUE:']   #this will be supplanted if db field is not null
IndxTblEnd = ['GROUP_OFFSET:0',
   'GROUP_LENGTH:0',
   'GROUP_FILENAME:']

Then the using the xml parsing class of python, it sifts through the tags for specific tags and builds the corresponding index in the usual form:  GROUP_FIELD_NAME  and GROUP_FIELD_VALUE

The values are derived from the tag elements, the tagnames are derived from a MySQL table we use to store indexing attributes.

It sounds complicated, but once the mechanics are in place, the components are re-usable.

Finally, it builds an arsload command with the -j supplementary index (or complete generic index) and executes the load.

-walt

sandeepveldi

  • Guest
Re: -j parameter usage with arsload utility
« Reply #4 on: July 13, 2011, 12:57:04 PM »
Walt,
Thanks for your response. Can you please tell me what's the format of the supplementary index file that has to be input when using the -j parameter.
Basically, I want to know how to use "-j" option in loading additional indexing data along with the one that's part of the input load file.

-------------
For example:
-------------
Application group "ABC" has 12 metadata fields defined in its settings. The application corresponding to "ABC" is using the ACIF indexer in its settings. The input load file has 8 metadata fields. There's an external file in which the additional 4 metadata fields related data is available. Using the arsload -j option is it possible to load the complete 12 metadata fields related data into the database? If so, what should be the format of the file in which these additional 4 metadata fields information is available?

Thanks
SV

wwwalton

  • Guest
Re: -j parameter usage with arsload utility
« Reply #5 on: July 13, 2011, 01:14:27 PM »
I pulled a recent load.  Here is the AF046FTP_JOB02444.ind file:
FIELD30='0000'
INDEX30='OD_CIS_JOB_COND_CD',FIELD30
FIELD31='AF046'
INDEX31='OD_CIS_JOB_NM',FIELD31
FIELD32='JOB02440'
INDEX32='OD_CIS_JOB_NO',FIELD32
OUTEXIT=/usr/local/bin/apkout

Here is the command executed to issue the load:
/usr/lpp/ars/bin/arsload -f -c /arsindx -A DATASET -j /arsdnld1/mfcm/AF046FTP/AF046FTP_JOB02444.ind  <ARD File to load>

I usually start at the high number end and work down for the INDEXnn, so INDEX32 is the first, and so on.

Here is a partial listing of the stdout:

0425-415 FILEFORMAT=STREAM,(NEWLINE=X'0A')
0425-415 TRIGGER1=*,2,X'2424245452494747455231',(TYPE=GROUP)
0425-415 FIELD1=0,2,1,(TRIGGER=1,BASE=0)
0425-415 INDEX1=X'4F445F545247525F315F56414C',FIELD1,(TYPE=GROUP,BREAK=YES)
0425-415 DCFPAGENAMES=NO
0425-415 UNIQUEBNGS=YES
0425-415 IMAGEOUT=ASIS
0425-415 INDEXOBJ=GROUP
0425-415 INDEXSTARTBY=1
0425-415 INSERTIMM=NO
0425-415 RESTYPE=NONE
0425-415 OUTEXIT=/usr/local/bin/apkout
0425-415 LINECNT=66
0425-415 FIELD30='0000'
0425-415 INDEX30='OD_CIS_JOB_COND_CD',FIELD30
0425-415 FIELD31='AF046FTP'
0425-415 INDEX31='OD_CIS_JOB_NM',FIELD31
0425-415 FIELD32='JOB02444'
0425-415 INDEX32='OD_CIS_JOB_NO',FIELD32
0425-415 OUTEXIT=/usr/local/bin/apkout
0425-415 inputdd=/arsdnld1/joblogs/AF046FTP.JES.01-JOBLOGS.01-JOBLOGS-T3.JOB02444.000.ARD
0425-415 outputdd=/arsindx/AF046FTP.JES.01-JOBLOGS.01-JOBLOGS-T3.JOB02444.000.ARD.out
0425-415 indexdd=/arsindx/AF046FTP.JES.01-JOBLOGS.01-JOBLOGS-T3.JOB02444.000.ARD.ind
0425-415 resobjdd=/dev/null
0425-440 ACIF AT PK04939 HAS COMPLETED NORMALLY WITH RETURN CODE 0.

sandeepveldi

  • Guest
Re: -j parameter usage with arsload utility
« Reply #6 on: August 02, 2011, 12:55:33 PM »
Walt,
Can you please clarify on the following:
a) Is there only one document in your load file (ARD) file?
b) Do you currently load only text format documents which use trigger based indexes using -j option? Or do you load any other type of data. For example: AFP

Regards
SV

wwwalton

  • Guest
Re: -j parameter usage with arsload utility
« Reply #7 on: August 03, 2011, 06:10:18 AM »
SV,
When using the -j for supplemental we:
a) Use for 1 ARD file, but also multiple ARD files where the index values in the supplemental file are the SAME across the ARD files; for example, JES Jobname, JES Job#, Job Return Code for a job producing multiple reports.
b) We are a Xerox shop and so store metacode (DJDE, LCDS, PCL). We also load XLS, PDF, TXT, XML, CSV; sometimes we pull index values only off reports, sometimes off the report AND using -j for supplemental, and sometimes just generic where we supply the index values external to report.

-walt