Firebird .NET provider and embedded server 3

Looking in the Provider code the default Client Library is fbembed (maybe for compatibility):

internal const string DefaultValueClientLibrary = "fbembed";

Now, passing the new value to the ConnectionString do the trick:

  var connectionString = new FbConnectionStringBuilder
  {
    Database = dbPath,
    ServerType = FbServerType.Embedded,
    UserID = "SYSDBA",
    Password = "masterkey",
    ClientLibrary = "fbclient.dll"
  }.ToString();

This took a while to figure out. But I got it to work....

For embedded client:
Run the NuGet command: Install-Package FirebirdSql.Data.FirebirdClient

For embedded server:
Key point: The dll's are NOT added to Visual Studio as a project reference. Instead, their location is defined in the connection string.

Download the full server zip from here. Then extract these three files to your project. Use a structure similar to below.

  • my_project\firebird_server\fbclient.dll
  • my_project\firebird_server\ib_util.dll
  • my_project\firebird_server\plugins\engine12.dll //Yes, need to have this in a "plugins" subdirectory otherwise firebird server will throw error.

Then setup connection string:

Database=c:\sample_firebird_database.FDB;
User=my_username;
Password=my_password;
ServerType=1; // 1 = embedded server
Charset=UTF8;
ClientLibrary=c:\my_project\firebird_server\fbclient.dll;