multi-user database (file based) - or no database at all? lazarus / 16-Databases ---------------------------------------------------------------------- ArminLinder · 2016-12-29 21:58 Hi all, this question has, in different forms, been asked alot, but I found no definitive answer, so I dare to ask again: - is there any component available to maintain records in a small database (<10.000 records, 1 data table, 2-3 indexes for fast searches), if there is absolutely no way to use anything else than plain old file system files stored on a NAS or any other network based file system? Design specs are as follows: - storage is any plain file system, absolutely no server service can be installed - multiple users, multiple computers, and multiple different users hosted on one computer (Terminal-services based) in any mixture - no specific installation of components required - may be commercial, but only if 1 developer license pays for unlimited installations of the final product - open source for ease of debugging/tracking - may be Windows only (XP ... W10) - very infrequent inserts/updates/queries of records (10 a day or so) - reasonable response times in LAN environments Any product/component anyone can suggest? Links to tutorials and sample code welcome so I try it out before settling on one. Alternative approach: Looking at the specs, especially at the low number of records and the very infrequent expected database accesses I am seriously thinking about not to use a database at all, but store each individual record in a file, and program some in-memory search tables into the clients to speed up searches. Any thoughts? Thx, Armin. ---------------------------------------------------------------------- JD · 2016-12-29 22:01 Firebird with SQLdb will fit the bill easily. It is very low maintainance & very fast on LAN. See http://wiki.freepascal.org/SQLdb_Tutorial0 and http://wiki.freepascal.org/SQLdb_Programming_Reference JD ---------------------------------------------------------------------- LacaK · 2016-12-30 08:27 With bit playing you can use also SQLite www.sqlite.org (one DLL and one database file which holds all tables) for multiuser environments. It depends how frequent are reads and updates ---------------------------------------------------------------------- Thaddy · 2016-12-30 09:30 Quote from: LacaK on December 30, 2016, 09:27:53 amWith bit playing you can use also SQLite www.sqlite.org (one DLL and one database file which holds all tables) Not even that. You can statically link sqlite, which, in this case, may be an optimal solution. The mormot guys showed us how to do that in a proper, but not the only, way. ---------------------------------------------------------------------- JD · 2016-12-30 10:44 Quote from: LacaK on December 30, 2016, 09:27:53 amWith bit playing you can use also SQLite www.sqlite.org (one DLL and one database file which holds all tables) for multiuser environments. It depends how frequent are reads and updates Multiuser SQLite https://stackoverflow.com/questions/1856313/simple-multi-user- database-solution https://stackoverflow.com/questions/5102027/can-sqlite-support- multiple-user