Its difficult to say why you are getting this exception. It seems that you are getting a conversion error when reading your input file, so I can't explain why it would have anything to do with how you launched Java.
On Fri, Jan 16, 2009 at 3:50 PM, John McKown <joa...@swbell.net> wrote: > On Fri, 16 Jan 2009 13:53:30 -0600, Kirk Wolf <k...@dovetail.com> wrote: > > >John, > > > >- If you change the code to use a BufferedReader/BufferedWriter with > >"readLine()" and then write()/newLine() , then it will handle any line end > >combo you give it. The output will use the lineend convention of the > >platform you are running on. > > I did the above. I also changed the code to use the JZOS FileFactory so > that > I can read and write both z/OS datasets and UNIX files. > > One curiousity is that when I invoke the program in a UNIX shell, all works > wonderfully. > > If I run a batch job using JZOS, then all the data is converted and > written, > but I get an RC=100 and the messages > > VMJZBL2004N Log level has been set to: I > VMJZBL1001N JZOS batch Launcher Version: 2.0.0 2006-09-28 > ... > JVMJZBL1012I Java Virtual Machine created. Version information follows: > java version "1.5.0" > Java(TM) 2 Runtime Environment, Standard Edition (build pmz64dev-20061002b > (SR3)) > IBM J9 VM (build 2.3, J2RE 1.5.0 IBM J9 2.3 z/OS s390x-64 > j9vmmz6423-20061002 (JIT enabled) > J9VM - 20060915_08260_BHdSMr > JIT - 20060908_1811_r8 > GC - 20060906_AA) > JVMJZBL1049W JZOS batch Launcher Version '2.0.0 2006-09-28' does not match > jzos.jar Version '2.0.0 2006-09-06' > ... > JVMJZBL2010E Exception occurred invoking comhealthmarketsutf16.Main.main() > JVMJZBL2007E Stack trace follows: > sun.io.MalformedInputException > at sun.io.ByteToCharUnicode.flush(ByteToCharUnicode.java:229) > at sun.nio.cs.StreamDecoder$ConverterSD.flushInto(StreamDecoder.java:333) > at sun.nio.cs.StreamDecoder$ConverterSD.implRead(StreamDecoder.java:357) > at sun.nio.cs.StreamDecoder.read(StreamDecoder.java:250) > at java.io.InputStreamReader.read(InputStreamReader.java:212) > at java.io.BufferedReader.fill(BufferedReader.java:157) > at java.io.BufferedReader.readLine(BufferedReader.java:320) > at java.io.BufferedReader.readLine(BufferedReader.java:383) > at comhealthmarketsutf16.Main.main(Main.java:45): > > > > > > >- On Windows, it will depend on which version of the Java JRE you are > using > >to get "IBM-1047". In older versions, you might try "Cp1047", which is > >equivalent. > > > >Kirk Wolf > >Dovetailed Technologies > > ---------------------------------------------------------------------- > For IBM-MAIN subscribe / signoff / archive access instructions, > send email to lists...@bama.ua.edu 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 lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html