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



Don't know if this will help you, but whenever I am using QSHELL "APIs" I
always create the outfile first with the CCSID I want before I stick content
in it.

For example, the following will create a file with a CCSID of 1252:

touch -C 1252 /home/aaron/myfile.txt

Note that is a capitol "C". A lowercase "c" means something else (I don't
immediately recall).

Or you could create it with the open() unix style API from RPG.

HTH,
Aaron Bartell
http://mowyourlawn.com

-----Original Message-----
From: midrange-l-bounces@xxxxxxxxxxxx
[mailto:midrange-l-bounces@xxxxxxxxxxxx] On Behalf Of Bob Schwartz
Sent: Thursday, January 10, 2008 7:24 AM
To: midrange-l@xxxxxxxxxxxx
Subject: qshell - grep removes CR from lines ?

I am running the qshell grep command on a csv file.
grep '\(^[0-9]\).*' ${INPUTFILE} > ${OUTPUTFILE}

The input csv file is ccsid 1252 with CRLF characters as end of each record.

The command selects all the correct records, but removes the CR.

Any seen this before, know why, how to correct?

Thanks, Bob S


As an Amazon Associate we earn from qualifying purchases.

This thread ...

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.