Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
Speed up CSV import by not querying the stream position
Avoid querying the position in the text stream using Qt's pos() function to update the progress dialog. Instead keep track of the stream position manually. This is possible here because we don't ever seek in the file. In result, this speeds up the CSV import dramatically.
- Loading branch information
ed9fda2
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
With this we're now more or less as fast as the sqlite3 CLI tool import :smile: I haven't done any thorough testing yet but: at least for the postcode file, and at least on my system, and at least for the one try I gave it, we were now about 5s faster than the CLI tool (while offering more config options and a progress bar) :wink: