Recent

Author Topic: What is the Best "Stand Alone" Database for lazarus  (Read 19731 times)

WTDdallas

  • Full Member
  • ***
  • Posts: 100
What is the Best "Stand Alone" Database for lazarus
« on: July 05, 2016, 10:45:34 pm »
What is the Best "Stand Alone" Database for lazarus?

Leledumbo

  • Hero Member
  • *****
  • Posts: 8836
  • Programming + Glam Metal + Tae Kwon Do = Me
Re: What is the Best "Stand Alone" Database for lazarus
« Reply #1 on: July 05, 2016, 11:24:30 pm »
Define "Best".
Define "Stand Alone" (MySQL can be regarded standalone as it doesn't have 3rd party dependency, so is PostgreSQL, SQL Server, Oracle, Firebird, SQLite and many more).

JD

  • Hero Member
  • *****
  • Posts: 1913
Re: What is the Best "Stand Alone" Database for lazarus
« Reply #2 on: July 06, 2016, 02:01:47 am »
I'll take a wild guess & say WTDallas probably means "embedded", no install database.  :D
Linux Mint - Lazarus 4.6/FPC 3.2.2,
Windows - Lazarus 4.6/FPC 3.2.2

mORMot 2, PostgreSQL & MariaDB.

WTDdallas

  • Full Member
  • ***
  • Posts: 100
Re: What is the Best "Stand Alone" Database for lazarus
« Reply #3 on: July 06, 2016, 04:28:09 am »
I'll take a wild guess & say WTDallas probably means "embedded", no install database.  :D

Yes Embedded.

No SQL Server or such.

markus_ja

  • New Member
  • *
  • Posts: 43
Re: What is the Best "Stand Alone" Database for lazarus
« Reply #4 on: July 06, 2016, 07:40:46 am »
I prefere firebird. Not sure if it is the best, but its free and it is available as embedded and as server. So you can easily switch, when you need server capabilities in the future.

http://firebirdsql.org/

Thaddy

  • Hero Member
  • *****
  • Posts: 19387
  • Glad to be alive.
Re: What is the Best "Stand Alone" Database for lazarus
« Reply #5 on: July 06, 2016, 07:45:33 am »
Frankly there are so many options right out-of-the-box that is really depends on your requirements.

There are applications where TBufDataSet simply suffices and is extremely lightweight but has no SQL query capabilities. It does have search, locate and sort, though...
Then you have Sqlite, which is pretty much the standard solution for single user or client-side databases and already present on most systems and it supports SQL.
Then you have slightly heavier solutions like FireBird which offers things that are not available in SQLite such as advanced locking etc.
Then there are the heavyweights like MySql and the super heavyweights like Oracle.

There are many more options in the standard distribution, like fpindexer...

[edit] So you are spoiled for choice compared to other languages. As Leledumbo asked the same as me: what are your requirements? That is what makes the choice.

And then there are solutions like tiOPF and mOrMot that abstract away the underlying database technology (mOrMot does sqlite, mainly)
« Last Edit: July 06, 2016, 09:20:32 am by Thaddy »
objects are fine constructs. You can even initialize them with constructors.

Leledumbo

  • Hero Member
  • *****
  • Posts: 8836
  • Programming + Glam Metal + Tae Kwon Do = Me
Re: What is the Best "Stand Alone" Database for lazarus
« Reply #6 on: July 06, 2016, 09:54:13 am »
Right, you still haven't defined "Best", so I still can't say which one, though the choice has been narrowed down to: Firebird, SQLite and MySQL.

WTDdallas

  • Full Member
  • ***
  • Posts: 100
Re: What is the Best "Stand Alone" Database for lazarus
« Reply #7 on: July 06, 2016, 01:34:47 pm »
Frankly there are so many options right out-of-the-box that is really depends on your requirements.


Looking for a Database that run inside the program and does not depend on a server or client software running.

Where the user, or my install program, does not have to have to install any other software, Mysql, Firebird, etc.

Light weight, few users or one user.

This is what I define as "Stand Alone".

I am coming back to Pascal after many years of being away from programming, so I am trying to get caught up, and find out what is in Lazarus?

« Last Edit: July 06, 2016, 01:44:03 pm by WTDdallas »

Thaddy

  • Hero Member
  • *****
  • Posts: 19387
  • Glad to be alive.
Re: What is the Best "Stand Alone" Database for lazarus
« Reply #8 on: July 06, 2016, 01:38:08 pm »
Well, then. Statically link the libs? e.g. sqlite. Problem solved.
objects are fine constructs. You can even initialize them with constructors.

WTDdallas

  • Full Member
  • ***
  • Posts: 100
Re: What is the Best "Stand Alone" Database for lazarus
« Reply #9 on: July 06, 2016, 02:09:44 pm »
Well, then. Statically link the libs? e.g. sqlite. Problem solved.

SQlite was not included in the default install? Easy to install.

Does it require another program running? client/server running?

Leledumbo

  • Hero Member
  • *****
  • Posts: 8836
  • Programming + Glam Metal + Tae Kwon Do = Me
Re: What is the Best "Stand Alone" Database for lazarus
« Reply #10 on: July 06, 2016, 03:13:15 pm »
Well, then. Statically link the libs? e.g. sqlite. Problem solved.

SQlite was not included in the default install? Easy to install.

Does it require another program running? client/server running?
SQLite bindings are. SQLite library is not, install that according to your platform. You better read what SQLite is first before asking further, their documentation is more than excellent to explain how they work.

Thaddy

  • Hero Member
  • *****
  • Posts: 19387
  • Glad to be alive.
Re: What is the Best "Stand Alone" Database for lazarus
« Reply #11 on: July 06, 2016, 03:58:53 pm »
Well, then. Statically link the libs? e.g. sqlite. Problem solved.

SQlite was not included in the default install? Easy to install.

Does it require another program running? client/server running?
SQLite bindings are. SQLite library is not, install that according to your platform. You better read what SQLite is first before asking further, their documentation is more than excellent to explain how they work.
On Debian and the likes it is installed by default, i think. On Windows it is definitely installed when you install e.g. Firefox or Thunderbird or many other industry standards.
objects are fine constructs. You can even initialize them with constructors.

Zath

  • Sr. Member
  • ****
  • Posts: 391
Re: What is the Best "Stand Alone" Database for lazarus
« Reply #12 on: July 07, 2016, 01:31:45 am »
Whatever you decide, avoid MS SQL with Lazarus (FPC).
Lazarus / FPC is the most user unfriendly option if you want to talk to MSSQL databases.
You need 3rd party libraries with conflicting info on their required locations and ....

I gave up.

talorigomat

  • Jr. Member
  • **
  • Posts: 96
Re: What is the Best "Stand Alone" Database for lazarus
« Reply #13 on: July 07, 2016, 08:26:03 am »
With Firebird embedded and sqlite all you would need to do is include the dll files in the same directory where your application is installed.
Lazarus 1.8.0Rc4, Windows 10

Thaddy

  • Hero Member
  • *****
  • Posts: 19387
  • Glad to be alive.
Re: What is the Best "Stand Alone" Database for lazarus
« Reply #14 on: July 07, 2016, 10:13:09 am »
With Firebird embedded and sqlite all you would need to do is include the dll files in the same directory where your application is installed.
  Well, not quite. That is Windows only advice. Furthermore the dll's may already exist where they belong, e.g. <drive>\windows\system32 or /usr/lib or /usr/local/lib.
If everybody starts putting commonly used dll's or so's  in the appication's directory you are polluting the system and missing the point of shared libraries / dll's.

The paths mentioned may include versioned subdirectories ofcourse like /usr/local/lib/fpc/3.1.1/units/arm-linux or something
« Last Edit: July 07, 2016, 10:27:49 am by Thaddy »
objects are fine constructs. You can even initialize them with constructors.

 

TinyPortal © 2005-2018