Skip to content

fread should not create data.tables with more than 2^31 rows #7438

@ecoRoland2

Description

@ecoRoland2

I just imported a huge file with more than 2^31 rows using fread on a machine with 512 GB RAM. It worked great. Unfortunately, I couldn't do anything with the resulting data.table. Autoprinting or subsetting returned a "long vectors not supported yet" error, which isn't surprising.

I suggest to stop fread before the data.table gets too large. Maybe it could return (with a warning) as many rows as R supports.

The fread documentation mentions field width limits but I don't see a mention that R has a limit regarding the number of rows.

My solution was to use nrows and skip to import as two data.tables but that was after I wasted time with reading the whole file.

Metadata

Metadata

Assignees

No one assigned

    Labels

    longvecLong Vector support

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions