I have found out you have made a new version of CSVR4 that can handle UTF. Excellent.
But I have 2 questions.
1)
But when I'm looking in the source it looks like you haven't corrected an error that was reported in 2010:
Employee_ID,StateCode,FilingStatus
51,,
A1,TX,
B3,OK,S
The first 2 records will not return the correct number of fields, while the third one will.
Am I right?
2)
In 2009 you suggested a function to load a record from user-supplied string called CSV_loadbuffer().
The code was the following. But it seems you haven't implemented it in the new version.
Code: Select all
*+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
* CSV_loadrec(): Load a record from a delimited file into memory
*
* peHandle = (i/o) handle to file returned by CSV_open()
*
* Returns *ON if successful, *OFF upon failure or EOF
*+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
P CSV_loadrec B export
D CSV_loadrec PI 1N
D peHandle like(CSV_HANDLE) value
D CSV DS likeds(CSVFILE_t)
D based(peHandle)
D p_buf s *
D len s 10I 0
/free
%len(CSV.buf) = %size(CSV.buf) - VARPREF;
%len(CSV.buf) = len;
if (%subst(CSV.buf : len : 1) = LINEFEED );
len = len - 1;
%len(CSV.buf) = len;
endif;
if (%subst(CSV.buf : len : 1) = CARRTN );
len = len - 1;
%len(CSV.buf) = len;
endif;
csv_rewindrec(peHandle);
return *ON;
/end-free
P E
Peder
PS: I have pdf-files with the old entries from Systemi Networks Forum ( long gone ) but I'm not allowed to attach them.