Re: replacing SAS for SMF reports?
- From: kirk@xxxxxxxxxxxx (Kirk Wolf)
- Date: 17 Jun 2008 15:54:23 -0700
o Java's float and double primitives are (ISO) binary floating point, but
has the java.math.BigDecimal class, which is a decimal floating point
representation ( n * 10**m, where n is arbitrary length integer, m is a 32
bit integer). The BigDecimal class can be used to represent any zoned or
packed data without loss of precision.
o Recent versions of the JZOS toolkit (on alphaWorks, SDK 6.0, or soon on
SDK 5) include type converter classes (com.ibm.jzos.fields package) that
convert Cobol datatypes to Java values. BTW: These classes are pure Java
code and don't rely on z/OS apis.
o The RecordClassGenerator class (available in the alphaWorks version of
JZOS) can be used to read the ADATA output from the High Level Assembler or
Enterprise Cobol Compiler and generate Java classes which use the above
converters to map DSECTS or Cobol copy books into Java classes. Samples are
included which show how SMF 83 DSECTS are automatically mapped into Java
classes.
For example, the following JCL generates a Java class which maps the base
part of the SMF 83 record:
//ASSEMBLE EXEC ASMAC,PARM='ADATA,LIST,NOTERM,NODECK,NOOBJECT'
//C.SYSIN DD *
IFASMFR 83
END
//C.SYSADATA DD DSN=&&ADATA,DISP=(NEW,PASS),
// SPACE=(CYL,(3,1))
//*
//JAVA EXEC PROC=EXJZOSVM,VERSION='50'
//MAINARGS DD *
com.ibm.jzos.recordgen.asm.RecordClassGenerator
section=SMFRCD83
bufoffset=false
package=com.ibm.jzos.sample.fields
class=Smf83BaseRecord
//SYSADATA DD DSN=&&ADATA,DISP=(OLD,DELETE)
//STDOUT DD PATH='/home/user/Smf83BaseRecord.java',
// PATHOPTS=(OWRONLY,OCREAT),
// PATHMODE=SIRWXU
//STDENV DD *
....
//
For the JZOS alphaWorks downloads, see:
http://www.alphaworks.ibm.com/tech/zosjavabatchtk
Kirk Wolf
Dovetailed Technologies
On Tue, Jun 17, 2008 at 1:07 PM, Tom Ross <tmross@xxxxxxxxxxxxxxxxxxxx>
wrote:
With reference modification available, the only things that are
awkward in COBOL are bit switches and the 1 byte binary fields. I
have written usage programs that parse the SMF 14/15, 30 and 64
records. If IBM would just implement the data types in the 2002
standard including the new floating point usages as IEEE, COBOL the
above caveats would go away and COBOL would play nicer with JAVA.
COMP-1 and COMP-2 could be retained for hex floating point so a single
COBOL program could have both types of floating point. YES there is a
SHARE requirement for this.
Java does not have Decimal Floating Point yet, and COBOL already plays
very nicely with automatic conversion from Java float to COBOL float
and back again with direct calls. In any case, it is off topic, there
is no Decimal Floating Point data in SMF records that I know of.
Cheers,
TomR >> COBOL is the Language of the Future! <<
----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to listserv@xxxxxxxxxxx with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html
----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to listserv@xxxxxxxxxxx with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html
.
- References:
- Re: replacing SAS for SMF reports?
- From: Tom Ross
- Re: replacing SAS for SMF reports?
- Prev by Date: Re: insane request: force load module to RMODE(24) AMODE(24)
- Next by Date: Re: Network Time Protocol (NTP) client support question
- Previous by thread: Re: replacing SAS for SMF reports?
- Next by thread: Re: replacing SAS for SMF reports?
- Index(es):
Relevant Pages
|