VuurSnikkel
Programmer
Hi there ppl,
First things first: I'm becoming increasingly frustrated by the "handy" ways in which Delphi users are supposed to access their database. I'm currently writing a Win32 program that needs to store some information on a per project basis (each project consists of one or more files and I want some of these files to contain tables and records, hence, a database).
I've been doing quite a lot of web-based DB-related work using PHP and MySQL and I don't mind using something like MySQL server in such a case, but this application needs to be stand-alone, so I don't need some server running in the background when a user is working with the program.
(The file format for the files that store the database don't need to be fancy; plain text will do. Something like MySQL's structure and data dump for example or some XML file. These can be used to create the whole database on load.)
Let's illustrate what I have in mind by a few lines of pseudo-code:
...
OpenDatabaseFile('MyDatabase.Ext');
//Manipulate the database using SQL queries...
SaveDatabaseFile('MyDatabase.Ext');
...
There. That's it. Sounds pretty clear and logical to me, but I haven't got a clue about how to accomplish this, because whenever I try to find some examples of this using Google, different Dephi forums, Torry's Delphi pages etc., I end up with documents about ODBC, MSJet, Interbase, BDE, ADO and other client/server types of databases. <FRUSTRATION>I don't need all of that, I'm writing a single-user, single-machine application that needs some form of file-based database access. No servers. No middleware. No connections with programs running in the background. No overhead. Is this really so uncommon?</FRUSTRATION>.
I've come to the point that I thought about writing my own database engine for this application, but I simply can't believe that there isn't a viable alternative to using servers and/or writing the whole engine myself.
I'm really getting tired of all the overhead involved with accessing a database in Delphi and any help would be greatly appreciated. Thanks in advance.
GRTZ,
(Sn)Ik.
First things first: I'm becoming increasingly frustrated by the "handy" ways in which Delphi users are supposed to access their database. I'm currently writing a Win32 program that needs to store some information on a per project basis (each project consists of one or more files and I want some of these files to contain tables and records, hence, a database).
I've been doing quite a lot of web-based DB-related work using PHP and MySQL and I don't mind using something like MySQL server in such a case, but this application needs to be stand-alone, so I don't need some server running in the background when a user is working with the program.
(The file format for the files that store the database don't need to be fancy; plain text will do. Something like MySQL's structure and data dump for example or some XML file. These can be used to create the whole database on load.)
Let's illustrate what I have in mind by a few lines of pseudo-code:
...
OpenDatabaseFile('MyDatabase.Ext');
//Manipulate the database using SQL queries...
SaveDatabaseFile('MyDatabase.Ext');
...
There. That's it. Sounds pretty clear and logical to me, but I haven't got a clue about how to accomplish this, because whenever I try to find some examples of this using Google, different Dephi forums, Torry's Delphi pages etc., I end up with documents about ODBC, MSJet, Interbase, BDE, ADO and other client/server types of databases. <FRUSTRATION>I don't need all of that, I'm writing a single-user, single-machine application that needs some form of file-based database access. No servers. No middleware. No connections with programs running in the background. No overhead. Is this really so uncommon?</FRUSTRATION>.
I've come to the point that I thought about writing my own database engine for this application, but I simply can't believe that there isn't a viable alternative to using servers and/or writing the whole engine myself.
I'm really getting tired of all the overhead involved with accessing a database in Delphi and any help would be greatly appreciated. Thanks in advance.
GRTZ,
(Sn)Ik.