On 3 May 2014, at 2:35pm, Hayden Livingston <halivings...@gmail.com> wrote:
> That's clever. I'm thinking how I'll go about this .. essentially the > filename is devised by time splits. I could do what you're saying but then > I can't move the file. Basically, the good part is that our warehousing > department (which is what this is used for) can look at order inventories > every 5 minutes (that's the current split). This way I'll have to somehow > stop the writes for a few seconds, copy the file into a new file and then > start writing again. Continue with your current system that moves to writing a new text file every 5 minutes. Leave everything working the way it is, since that obviously works fine. Introduce a new program which is triggered when a new file is created, or perhaps just springs into action every 5 minutes. Its job is to read any text files /except the newest one, which is still being written/ into one big SQLite database. This makes your data available for query in a convenient form (one big SQLite database), but preserves everything you need for your old system, and doesn't interfere with the logging process you have already written and debugged. One disadvantage is that the SQLite database is always between 5 and 10 minutes out of date. But the ease of querying /all/ operations in one go might make up for that. Simon. _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users