Python Forum
millions rows and 40 columns
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
millions rows and 40 columns
#2
The best way is to load the data in a line at a time and save into a reliable database (Personally, I'd use PostgreSQL).
This may only work if it's not time critical.
In that case, you need to incrementally read the file line by line, and build
a hashed index (or SQL index) of:
hash code, key and file location (which you can get with filepointer.tell())
then to access a specific record, first look it up (using hash code) in the index, and seek the record from the file pointer.
Reply


Messages In This Thread
millions rows and 40 columns - by garikhgh0 - Mar-20-2018, 05:24 AM
RE: millions rows and 40 columns - by Larz60+ - Mar-20-2018, 11:05 AM
RE: millions rows and 40 columns - by Skaperen - Mar-21-2018, 06:17 AM
RE: millions rows and 40 columns - by Larz60+ - Mar-21-2018, 08:40 AM
RE: millions rows and 40 columns - by Skaperen - Mar-22-2018, 04:16 AM

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020