Home > Delphi, Object Pascal > Firebird, daft or fab?

Firebird, daft or fab?

Programmers and their databases have always been a pickle. In many ways it’s like music where everyone has their favorite band and stick to them well beyond expiration date or technical excellence. I will be frank from the start and say that I have very little experience with firebird (or interbase for that matter), but what I have seen so far is quite impressive.

Let the flame-wars begin

Firebird, the tardis of database engines!

Firebird, the tardis of database engines!

The other day I posted a link to firebird on our Delphi Developer forum at Facebook. I didn’t think much of it as it was just a case of “support our native tools” type post. I made the huge mistake of using the word “enterprise” in the title – which spawned an avalanche of criticism. Apparently firebird is (in view of some) not an enterprise storage solution, at least not in the modern sense of the word. Or at least that was the impression I was left with.

Since I have little experience with firebird I was not really in a position to defend or accept what people told me. Many of the “facts” that were aired seemed reasonable – things like clustering and automated replication are indeed features we expect from an enterprise solution these days. Not to mention fallback safety for power-cuts (which I must admit I always leave to a dedicated UPS). That said, there are also other aspects of deploying database technology in large corporations which must be taken into account. It all depends on the need, pricing and demand for scaling i suppose.

But I must also say that I find firebird quite pleasant to work with. I know of at least two companies that use it large scale, both hosted on Amazon and through a dedicated in-house server; processing thousands of requests every hour. With Amazon EC2 you at least dont have to worry about power-cuts, and replication is .. well, we knocked out a dedicated backup system for firebird using Delphi in roughly 2 days. Wrapping the FireDac services in neat specialized classes for our purposes, adding zip compression and ftp all in one go.

IBExperts

Late in the debate the founder of IBExperts, which I guess all of us have heard about at one point or another, entered the debate. His company have specialized on Interbase and Firebird technology and the thread quickly turned from doom-and-gloom to a more optimistic view of firebird and what it could do when setup correctly. And that is the key concept: we expect firebird to act and behave as a small-time embedded database, but it actually has a much wider scope. The official firebird book is actually 3 massive bibles. Could perhaps be a case where people actually need to study a bit harder to use it properly. Just look at the books produced for MSSQL about tuning, indexing and clustering.

Other users likewise came into the debate in with their experiences, from handling terabytes of data to dealing with real-life problems such as (drumroll) clustering and replication. One user had operated a massive firebird database in the worst possible electrical environment for years without so much as a hitch. Power-out’s were almost a daily occurrence, yet firebird kept on going with no big issues. Naturally I cant defend if that is indeed true, but I see no reason why a well known Delphi developer should lie about a product which is essentially free, open and available to all.

Embedding

Embedded databases have become a market in themselves over the past 10 years. My personal favorite has always been Elevate Software’s ElevateDB, the successor to DBISAM which is probably one of the fastest and robust Delphi components ever written. I stuck with Elevate for many years and have only recently, around XE3, held on to renewing my subscription. Not because I dont like it any more, but because my work shifted from purely Win32/64 client-server development to JavaScript/RTL architecture during the development of Smart Mobile Studio.

Another factor is that more and more really good databases are available, database engines which are free. MySQL embedded is really cool – albeit something of a black art to work with directly (on C level). At the same time Embarcadero have brought Interbase back from the dead and are now shipping the embedded version with Delphi itself. And a database which works universally on Windows, OS X, Android and iOS makes a lot of sense. And last but not least there is MSSQL embedded which ships pre-installed on Windows 8 and Windows 10. But for me that is the last possible option.

Added: SQLite was mentioned in a comment, this is indeed true – but my initial text here is about mid-range to high-end databases. Postgres is another system, but I must admit I’m a complete agnostic about that engine. I’ve so far only worked with Oracle, MSSQL, MySQL and for mid-range work: ElevateDB, DBISAM and DBase (way back in the day).

Daft or fab? Not quite sure yet

It’s going to be interesting to get Firebird under my skin in the coming months. It does suffer the problems of all open-source projects in that it’s completely at the mercy of it’s contributors. Some of the tools are a bit rustic, like GBack which is the tool you use to create incremental or full backups. Using this from Delphi does require a bit of manual labour — but hey, it’s a free database engine! Last I checked MySQL didnt get good tools before someone decided to build it. The engine provider’s own tools are typically command-line oriented because the audience is DB administrators, not programmers, which script everything. Firebird is no different — which is a good thing!

I think we live in exciting times. Delphi is getting back on track, we see a growth of Delphi based products – especially client/server stuff which is what Delphi is really good at. At the same time technologies which stem from the Borland/Delphi miljø and sub-culture is getting more attention. There is a lot of cool stuff going on and it’s a great time to be a Delphi, Smart Mobile Studio or Freepascal developer!

Advertisements
  1. August 24, 2015 at 6:41 pm

    You did not even quote postgresql which is an amazing db, and sqlite which is the most deployed embedded db, with amazing speed and features!

    • Jon Lennart Aasenden
      August 24, 2015 at 6:49 pm

      Well the question is — should firebird be compared to SQLite? I would put these in two very different leagues. I updated the article and added these though. Well worth looking into Postgres

  2. August 25, 2015 at 6:49 am

    Herbie goes to Monte Carlo. That’s the database world and the good thing about databases.

    It’s about the fun driving and driving the fun.

    Software today is heading again strongly towards the view software as hardware – revision or version. That’s a very totalitarian view to software and software development.

  3. August 25, 2015 at 7:08 am

    Some people maybe wonder why for example the Oracle database did and still does offer a schema for every user. That’s about freedom. The original idea was to offer a data-store that allows users to store their data the way they want.

    An application is a result from files and the need to share information stored in files … The view is the definition of – What do I want to see and not What is a user allowed to see.

    The question left in case of NexusDB or PostgreSQL does it really matter to be in the position to extend the DBMS software. An application by definition is the most totalitarian way to restrict access to information provided.

  4. September 10, 2015 at 4:40 pm

    Without taking anything away from other databases – Definitely fab.

  1. No trackbacks yet.

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: