No you don't need to copy the file to USS, if you are running a Java batch job. JCL something like this, which executes the JVM procedure, in this case Java 1.8 64bit. The STDENV DD will need the environment variables, like LIBPATH, CLASSPATH, Java Options,etc.
//JAVA EXEC PROC=JVMPRC86, // REGSIZE='1024M', // JAVACLS='-jar "directory path"/"name of Java program compiled".jar' //* //MAINARGS DD DUMMY //STDENV DD * export PATH=/bin:"${JAVA_HOME}"/bin LIBPATH=/lib:/usr/lib:"${JAVA_HOME}"/bin LIBPATH="$LIBPATH":"${JAVA_HOME}"/lib/s390x LIBPATH="$LIBPATH":"${JAVA_HOME}"/lib/s390x/j9vm export LIBPATH="$LIBPATH": CLASSPATH=$CLASSPATH:${JAVA_HOME}"/lib:"${JAVA_HOME}"/lib/ext export CLASSPATH="$CLASSPATH": # Configure JVM options IJO="-Xms16m -Xmx128m" As far as encoding, you will need to in account for that in your Java program during the read. Hope that helps. Also, the OMVS segment is a RACF term for the security definitions when you access USS either via 3270 or something like SSH. Jerry -----Original Message----- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On Behalf Of Cameron Conacher Sent: Thursday, January 10, 2019 4:11 PM To: IBM-MAIN@LISTSERV.UA.EDU Subject: Do I need to copy a mainframe flat file to OMVS, before I access the data from a JAVA program? Hello Listers, If I have created a flat file in some mainframe batch JOB, and I want to pass it through a JAVA Utility, do I need to copy the file first to my OMVS segment, and the run my JAVA process? Or can I directly access the EBCDIC encoded flat file by my JAVA process? Just starting down this path. Not really sure where I am going with this yet, or what I will do when I get there. Thank ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN