× 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.




John, the redirection will be opened by the shell, which will
automatically do text conversion regardless of whether cat does so or not.
If you want to disable text conversion, you need to set
QSH_REDIRECTION_TEXTDATA=N. You can also set QIBM_CCSID to set which CCSID
the file will be tagged with and converted to.

Conceivably, you could do something like this:


QSH_REDIRECTION_TEXTDATA=N QIBM_CCSID=819 cat -c /pdfflr/pattycsv.csv
/pdfflr/pattycsv5.csv > /pdfflr/pattynew.csv

However, that will give errors: qsh: 001-0055 Error found creating file
/pdfflr/pattynew.csv The value specified for the argument is not correct.

Instead, you have to leave off the QIBM_CCSID or set it to 65535. In
either case, it seems to get tagged with the job ccsid (even for 65535).
You can fix it using setccsid:

setccsid 819 /pdfflr/pattynew.csv


[1]Documentation here (under "Variables used by qsh"):
http://www.ibm.com/support/knowledgecenter/ssw_i5_54/rzahz/variable.htm





----- Original message -----
From: John Yeung <gallium.arsenide@xxxxxxxxx>
Sent by: "MIDRANGE-L" <midrange-l-bounces@xxxxxxxxxxxx>
To: Midrange Systems Technical Discussion <midrange-l@xxxxxxxxxxxx>
Cc:
Subject: Re: merging 2 .csv files
Date: Thu, Dec 29, 2016 11:34 AM

On Thu, Dec 29, 2016 at 12:08 PM, Smith, Mike
<Mike_Smith@xxxxxxxxxxxxxxxx> wrote:
> Just to be clear this is how the data is showing up after the cat
command
>
"FNAME","LNAME""SASA","ACKAR""JAMES","ADAMS""AMY","ADKINS""ERNEST","ADKINS"
>
> This is how it should show up.
> "FNAME","LNAME"
> "MICHAEL","ALBERT"
> "FRANCES","ALDERSON"
> "JONATHAN","ALDRIDGE"

Actually, this is not the way to be clear. I mean, I can make an
educated guess, based on my experience and on your previous messages.
But your previous messages were clearer. The issue is, when you are
having problems with encoding, the clearest thing to do is give a hex
dump. Barring that, you need to at least say how you are looking at
the data (in other words, are you using Notepad, Excel, DSPF at a CL
prompt, cat command in QSH, etc.), because different methods will
render the data differently.

In one of your previous messages, you said your hex 0D0A line endings
became hex 0A. This is consistent with what I observed when using
methods which involve interpreting the data as text and then
potentially re-encoding it.

However, the -c option on the cat command should not be subject to
that, because it explicitly doesn't interpret the data. Please share
the EXACT command you are using. And be sure to use CHGATR to set the
CCSID of the output file to the same CCSID as the input files, after
the cat is complete. (The procedure isn't guaranteed to work if the
two CCSIDs on the input files are not the same as each other. It also
isn't guaranteed to work if the second file has a BOM; but if the only
CCSIDs you are seeing are 819 and 1208, and they are accurate, then
there shouldn't be any BOMs.)

John Y.
--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing
list
To post a message email: MIDRANGE-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: [2]http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at [3]http://archive.midrange.com/midrange-l.

Please contact support@xxxxxxxxxxxx for any subscription related
questions.

Help support midrange.com by shopping at amazon.com with our affiliate
link: [4]http://amzn.to/2dEadiD




References

Visible links
1. http://www.ibm.com/support/knowledgecenter/ssw_i5_54/rzahz/variable.htm
2. http://lists.midrange.com/mailman/listinfo/midrange-l
3. http://archive.midrange.com/midrange-l
4. http://amzn.to/2dEadiD

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

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.