Subject Re: [firebird-support] 'Unavailable database'
Author Helen Borrie
At 17:45 1/09/2008, you wrote:
>Hello
>
>When I call *_isc_attach_database* from *fbembed.dll* 2.1.1 I get this error
>saying 'Unavailable database'.
>
>I can open the same database with *isql.exe* with the same user name and
>password and I can show tables and SELECT data from them. Still I would
>like to access the database with fbemebd.dll from my application.
>
>The interesting thing is *isql* uses the same client library as my
>application
>(the same .dll) so I guess there is something I could do to get it work,
>some settings or open mode for example.
>
>Do you know what could be wrong and what could I do ?
>
>I use Delphi 10, FBLib 0.85 and embedded Firebird 2.1 on Windows.

Embedded is a deployment model. Both the server and the client are running in (the same) application space. When one application has a database open within this space, other applications are blocked from access to that database.

Don't use embedded as your backend when developing in Delphi. It won't work: if the IDE is connected to the database through the embedded client then you won't be able to run your app - hence the 'unavailable database' message. Use Classic or Superserver for development. Pre-deployment, set up a test installation on a stand-alone machine to check that you have done everything the right way.

./heLen