Quantcast
Channel: Raspberry Pi Forums
Viewing all articles
Browse latest Browse all 1251

Python • Re: 2 python scripts with SQLite3

$
0
0
If separate scripts need to modify the data then I would expect problems with sqlite.

Options are
- simple: migrate to another database like mariadb. Can work with multiple programs which read/update data.
- merge your different scripts into one. Threading could be used, asyncio is available.
- complicated: perhaps multiprocessing could be used, send the tasks to a Queue which is processed by one of these multi-processes in sequence.


My preference would be to use another database. You do not need to change the structure of your solution.

Statistics: Posted by ghp — Thu Jan 23, 2025 10:38 am



Viewing all articles
Browse latest Browse all 1251

Trending Articles