Find an open source small network database lazarus / 16-Databases ---------------------------------------------------------------------- lazpas · 2021-08-04 08:18 Where is the open source small network database? I want to learn the principle. Thanks. ---------------------------------------------------------------------- mangakissa · 2021-08-04 09:06 I don't understand your question. Firebird and SQLite is an open source small network database. ---------------------------------------------------------------------- valdir.marcos · 2021-08-04 09:10 Quote from: lazpas on August 04, 2021, 10:18:39 amWhere is the open source small network database? I want to learn the principle. Thanks.Firebird would be your best option: http://firebirdsql.org/en/firebird-rdbms/ ---------------------------------------------------------------------- lazpas · 2021-08-04 09:29 Quote from: mangakissa on August 04, 2021, 11:06:36 amI don't understand your question. Firebird and SQLite is an open source small network database. Thanks. sqlite is not a network database. Firebird is very large. I am a newbie. ---------------------------------------------------------------------- marcov · 2021-08-04 09:33 Quote from: lazpas on August 04, 2021, 11:29:34 amsqlite is not a network database. Firebird is very large. I am a newbie. Please qualify what large is acceptable and what not. This is all too vague. Most open source database systems run fine on an original raspberry pi. ---------------------------------------------------------------------- lazpas · 2021-08-04 09:37 Quote from: valdir.marcos on August 04, 2021, 11:10:29 amQuote from: lazpas on August 04, 2021, 10:18:39 amWhere is the open source small network database? I want to learn the principle. Thanks.Firebird would be your best option: http://firebirdsql.org/en/firebird-rdbms/ Thank you. Firebird is very good.But it is large,and I don't know how to C++.I am a newbie. ---------------------------------------------------------------------- lazpas · 2021-08-04 09:42 Is there a pascal language? ---------------------------------------------------------------------- lazpas · 2021-08-04 09:50 Quote from: marcov on August 04, 2021, 11:33:29 amQuote from: lazpas on August 04, 2021, 11:29:34 amsqlite is not a network database. Firebird is very large. I am a newbie. Please qualify what large is acceptable and what not. This is all too vague. Most open source database systems run fine on an original raspberry pi. Thanks for reply. I think, as little code as possible, a framework, including network, file io, thread, and possibly functions. basic skills. ---------------------------------------------------------------------- valdir.marcos · 2021-08-04 17:46 Quote from: lazpas on August 04, 2021, 11:29:34 amQuote from: mangakissa on August 04, 2021, 11:06:36 amI don't understand your question. Firebird and SQLite is an open source small network database.Thanks. sqlite is not a network database. Firebird is very large. I am a newbie. Quote from: lazpas on August 04, 2021, 11:37:28 amQuote from: valdir.marcos on August 04, 2021, 11:10:29 amQuote from: lazpas on August 04, 2021, 10:18:39 amWhere is the open source small network database? I want to learn the principle. Thanks.Firebird would be your best option: http://firebirdsql.org/en/firebird-rdbms/Thank you. Firebird is very good.But it is large,and I don't know how to C++.I am a newbie. Quote from: lazpas on August 04, 2021, 11:42:27 amIs there a pascal language? Quote from: lazpas on August 04, 2021, 11:50:37 amQuote from: marcov on August 04, 2021, 11:33:29 amQuote from: lazpas on August 04, 2021, 11:29:34 amsqlite is not a network database. Firebird is very large. I am a newbie. Please qualify what large is acceptable and what not. This is all too vague. Most open source database systems run fine on an original raspberry pi.Thanks for reply. I think, as little code as possible, a framework, including network, file io, thread, and possibly functions. basic skills.Lighter than Firebird, only if you would use an old xBase solution, such as DBase or Paradox. And they have Pascal source code: https://wiki.freepascal.org/Lazarus_Tdbf_Tutorial https://wiki.freepascal.org/TParadoxDataSet ---------------------------------------------------------------------- lazpas · 2021-08-04 23:30 Quote from: valdir.marcos on August 04, 2021, 07:46:42 pmLighter than Firebird, only if you would use an old xBase solution, such as DBase or Paradox. And they have Pascal source code: https://wiki.freepascal.org/Lazarus_Tdbf_Tutorial https://wiki.freepascal.org/TParadoxDataSet Thanks for help. ---------------------------------------------------------------------- mangakissa · 2021-08-06 09:31 Thank you. Firebird is very good.But it is large,and I don't know how to C++.I am a newbie. [/quote] You're very vague. You don't need C++ to use Firebird. Also Firebird can also use embedded. That's not large. But yes, you can build a large database with it. ---------------------------------------------------------------------- lazpas · 2021-08-08 06:24 Quote from: mangakissa on August 06, 2021, 11:31:17 am Thank you. Firebird is very good.But it is large,and I don't know how to C++.I am a newbie. You're very vague. You don't need C++ to use Firebird. Also Firebird can also use embedded. That's not large. But yes, you can build a large database with it. [/quote] Hi,mangakissa My English is bad,sorry.I use online translation. I mean to learn client-server database principles.How to make a client-server database. ---------------------------------------------------------------------- lazpas · 2021-08-08 06:29 I have found these https://github.com/ggaughan/ThinkSQL https://sourceforge.net/projects/tpflashfiler/ ---------------------------------------------------------------------- MarkMLl · 2021-08-08 09:18 Quote from: lazpas on August 08, 2021, 08:29:49 amI have found these https://github.com/ggaughan/ThinkSQL https://sourceforge.net/projects/tpflashfiler/ Have you actually read the description that goes with ThinkSQL? QuoteThe source code is linear per se, but while writing it, it was an organic thing, generating great interwoven trees in the computer memory and in my head that were many-layered and that were modified and traversed, and impacted on a dynamic multi-versioned data store alongside many other threads, causing and needing deep psychological flow. The code comments are released as-is, and are often streams-of- consciousness. A number of other people have given you some good suggestions and to those I'd add that you might find it worthwhile looking for an early version of PostgreSQL, i.e. v6 or older, which basically started off as a teaching/research exercise so at least in those days was well documented. Look, I'm sorry to be brutal but software is /complex/, and the more man-years have gone into a project the more complex it's likely to be. Alternatively, if a project was left on a hillside at birth it's likely to be valueless, and a waste of time in terms of both utility and didactic potential. If you think that, as somebody with admittedly-limited experience, your chances of getting to grips with a project are dominated by your familiarity with the language it's written in then you're fooling nobody but yourself: these days you /need/ at least limited familiarity with C/C++ (and, regrettably, with Python and Javascript) even if you have no intention of writing anything in them. MarkMLl ---------------------------------------------------------------------- PierceNg · 2021-08-08 11:12 Quote from: lazpas on August 08, 2021, 08:24:51 amI mean to learn client-server database principles.How to make a client-server database. Learn the various bits. For a networked SQL database, some key pieces: how to organize data on disk using B-trees etchow to parse SQLhow to execute the parsed SQL to work with the stored databackup and restoreauthentication and authorizationnetwork programmingdata encryption over the wiredata encryption at restSDK for database client programming Anything important missing from my list I'm sure others will add. ---------------------------------------------------------------------- lazpas · 2021-08-10 08:01 Quote from: MarkMLl on August 08, 2021, 11:18:47 amQuote from: lazpas on August 08, 2021, 08:29:49 amI have found these https://github.com/ggaughan/ThinkSQL https://sourceforge.net/projects/tpflashfiler/ Have you actually read the description that goes with ThinkSQL? QuoteThe source code is linear per se, but while writing it, it was an organic thing, generating great interwoven trees in the computer memory and in my head that were many-layered and that were modified and traversed, and impacted on a dynamic multi-versioned data store alongside many other threads, causing and needing deep psychological flow. The code comments are released as-is, and are often streams-of- consciousness. A number of other people have given you some good suggestions and to those I'd add that you might find it worthwhile looking for an early version of PostgreSQL, i.e. v6 or older, which basically started off as a teaching/research exercise so at least in those days was well documented. Look, I'm sorry to be brutal but software is /complex/, and the more man-years have gone into a project the more complex it's likely to be. Alternatively, if a project was left on a hillside at birth it's likely to be valueless, and a waste of time in terms of both utility and didactic potential. If you think that, as somebody with admittedly-limited experience, your chances of getting to grips with a project are dominated by your familiarity with the language it's written in then you're fooling nobody but yourself: these days you /need/ at least limited familiarity with C/C++ (and, regrettably, with Python and Javascript) even if you have no intention of writing anything in them. MarkMLl Thank you,MarkMLI.I understand your idea。 ---------------------------------------------------------------------- lazpas · 2021-08-10 08:04 Quote from: PierceNg on August 08, 2021, 01:12:30 pmQuote from: lazpas on August 08, 2021, 08:24:51 amI mean to learn client-server database principles.How to make a client-server database. Learn the various bits. For a networked SQL database, some key pieces: how to organize data on disk using B-trees etchow to parse SQLhow to execute the parsed SQL to work with the stored databackup and restoreauthentication and authorizationnetwork programmingdata encryption over the wiredata encryption at restSDK for database client programming Anything important missing from my list I'm sure others will add. Thanks,PierceNg I want to record these in my notebook. ---------------------------------------------------------------------- PierceNg · 2021-08-19 04:44 Quote from: lazpas on August 10, 2021, 10:04:10 amQuote from: PierceNg on August 08, 2021, 01:12:30 pmhow to organize data on disk using B-trees etc See https://benjamincongdon.me/blog/2021/08/17/B-Trees-More-Than-I- Thought-Id-Want-to-Know/ I dunno if there are "standalone" open source B-tree implementations in Pascal. It'll be nice to have one. ---------------------------------------------------------------------- lucamar · 2021-08-19 06:28 Quote from: PierceNg on August 19, 2021, 06:44:19 amI dunno if there are "standalone" open source B-tree implementations in Pascal. It'll be nice to have one. There are several, probably, but one that comes to mind at the moment is TurboPower B-Tree Filer. Though it's kind of oldish and I don't remember if it's fully compatible with Free Pascal; probably needs to be compiled in mode TP or Delphi and thoroughly tested before using it in production code. ---------------------------------------------------------------------- MarkMLl · 2021-08-19 10:21 Quote from: lucamar on August 19, 2021, 08:28:17 amThough it's kind of oldish and I don't remember if it's fully compatible with Free Pascal; probably needs to be compiled in mode TP or Delphi and thoroughly tested before using it in production code. Also while it provides an OKish API for file access, it's very much not suitable for running on a network where multiple people might attempt (WILL EVENTUALLY ATTEMPT) simultaneous access, and omits the higher-level operations that people with some degree of SQL exposure expect. I'm not necessarily criticising it for not supporting SQL since the OP didn't make clear whether this was one of his requirements, but these days things like transactions/rollback are pretty much de rigeur. MarkMLl ---------------------------------------------------------------------- marcov · 2021-08-19 12:56 TDBF is also still built in. ---------------------------------------------------------------------- PierceNg · 2021-08-22 06:58 Quote from: lucamar on August 19, 2021, 08:28:17 amQuote from: PierceNg on August 19, 2021, 06:44:19 amI dunno if there are "standalone" open source B-tree implementations in Pascal. It'll be nice to have one. There are several, probably, but one that comes to mind at the moment is TurboPower B-Tree Filer. Though it's kind of oldish and I don't remember if it's fully compatible with Free Pascal; probably needs to be compiled in mode TP or Delphi and thoroughly tested before using it in production code. So I booted into Windows and opened the project using Delphi CE 10.3. Worked through incompatibility between PAnsiChar and PWideChar, and some function signature changes. After that got compilation error like "Cannot access element 0. use SetLength." Gave up at that point. Don't feel up to attempting to port this to Free Pascal. Like the OP who started this thread, I'm more looking at this for learning. If I'm building an app with local database I will just use SQLite. ---------------------------------------------------------------------- PierceNg · 2021-08-22 07:00 Quote from: marcov on August 19, 2021, 02:56:50 pmTDBF is also still built in. Thanks. And dBase file format is well documented so that helps while reading the code. ---------------------------------------------------------------------- MarkMLl · 2021-08-22 07:31 Quote from: PierceNg on August 22, 2021, 08:58:30 amAfter that got compilation error like "Cannot access element 0. use SetLength." Gave up at that point. Don't feel up to attempting to port this to Free Pascal. That's a very easy one to fix: the compiler's telling you that the code's trying to do something like a[0] := Length(b) which is only valid for shortstrings, replace it with SetLength(a, Length(b)). MarkMLl ---------------------------------------------------------------------- jwharton · 2021-08-24 17:56 Quote from: lazpas on August 04, 2021, 11:37:28 amQuote from: valdir.marcos on August 04, 2021, 11:10:29 amQuote from: lazpas on August 04, 2021, 10:18:39 amWhere is the open source small network database? I want to learn the principle. Thanks.Firebird would be your best option: http://firebirdsql.org/en/firebird-rdbms/ Thank you. Firebird is very good.But it is large,and I don't know how to C++.I am a newbie. Firebird SQL is not at all a large footprint.  It installs very quickly and requires very little, if any, configuration.  It is also a zero admin required system, except for backups and restores.  There are also native pathways to access it using Lazarus.  I am the author of one of them.  You can use IB Objects (www.ibobjects.com) to work with it directly.  If anyone wants to give IBO a try, reach out to me directly and I can set you up with a read-only tap on my SVN repository for development. I would also like to put in a plug for people to support the Firebird Foundation. https://www.firebirdsql.org/en/firebird-foundation/ Thanks, Jason Wharton Firebird Foundation President