3 ms·
A disadvantage this has over awk/sed/cut is that those tools will start to process their input on a line-by-line basis. They don't need to wait for their inputs
by jolmg 7y ago
A disadvantage this has over awk/sed/cut is that those tools will start to process their input on a line-by-line basis. They don't need to wait for their inputs to complete to start outputting their results. cq/sqlite on the other hand needs to read the whole input file before starting to work. This is because sqlite, at the time it's importing the file into the in-memory database, doesn't know what kind of query you're going to ask of it. It might require processing the data in any order, and it's simplest to just slurp the whole file, rather than lazily loading it based on the query.