Future support of reading first columns along/instead of first rows? #2489
Labels
No Label
DBF
Dates
Defined Names
Features
Formula
HTML
Images
Infrastructure
Integration
International
ODS
Operations
Performance
PivotTables
Pro
Protection
Read Bug
SSF
SYLK
Style
Write Bug
good first issue
No Milestone
No Assignees
1 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: sheetjs/sheetjs#2489
Loading…
Reference in New Issue
No description provided.
Delete Branch "%!s(<nil>)"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Hello!
I currently extract first row and column of my worksheet by parsing through the cells, but I would like to limit the file reading so only needed data (first column and/or row) is extracted.
I already know about using
XLSX.read(myFile, { sheetRows: 1 });
, but I didn't find any issue discussing a column variantsheetColumns
. Is such a feature planned for later? Or not at all?Thanks for your time! :)
It's definitely interesting but lower priority. Some notes:
Most file formats store data in row-major order. For example, in the CSV format:
The file starts with the first row of data, followed by the second row, followed by the third row, etc. For
sheetRows: 1
, the parser can stop after the end of the first row.To extract the data from the first column, the parser would have to scan almost the entire file (stopping at cell B1000000 in the last row)
.
The dual
sheetCols
parameter is interesting because some formats are column-major order. The XLS file from issue #2432 is in column-major order. BIFF8 XLS also has optional special records that let you jump around the file. This approach would not work for XLSB or XLSX.If scanning the whole file is ok, just need to only store the first column and ignore the others, would that be easier to implement? I have no idea where to start looking in the code however 🤔
Dupe of #335
@reviewher related but not really duplicate, my issue is not with the format order of the json (row-major) but with limiting the parsed (or stored) data to the initial columns.
drop a comment in #475 that a column limit feature should also be supported