[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Octave-bug-tracker] [bug #63655] [octave forge] (io) csv2cell line leng

From: Philip Nienhuis
Subject: [Octave-bug-tracker] [bug #63655] [octave forge] (io) csv2cell line length limit
Date: Fri, 13 Jan 2023 17:05:03 -0500 (EST)

Update of bug #63655 (project octave):

                  Status:                    None => Wont Fix               
             Open/Closed:                    Open => Closed                 
                 Release:                   7.3.0 => other                  
                 Summary: io -- csv2cell line length limit => [octave forge]
(io) csv2cell line length limit


Follow-up Comment #3:

It's not exactly a bug, no. Anyway I won't change csv2cell's max line length.

csv2cell's max line length is hard-coded to 32768 characters, so that is
already halfway your 72 K line length.
The reason for (this admittedly arbitrary) 32 K is to avoid excessive RAM
usage during processing of otherwise simple .csv files with just a few data
per line.
It's easy to change that limit and recompile csv2cell.cc using mkoctfile
(don't forget to first do a "clear -f" or "clear csv2cell" to wipe csv2cell
from Octave's function table in memory).
You can easily extract csv2cell.cc from a downloaded io package.

Reading your issue I wonder if it isn't better to simply use textscan or s/th
along the lines of:

fid = fopen (<filename.cc>, "r");
fgetline (fid); # Get rid of / read beyond first line.
                # Maybe repeat to skip other header lines
data = fscanf (fid, <parameters>);
fclose (fid);

(assuming fscanf can skip commas or other delimiters, I never tried)

Adapting title
Updating fields (forge package, not core Octave)
Closing report


Reply to this item at:


Message sent via Savannah

reply via email to

[Prev in Thread] Current Thread [Next in Thread]