Embedded Firebird Server in VB6

Asked By 10 points N/A Posted on -
qa-featured

Hello Techyv Guys,

I need to know, whether it's possible to use embedded Firebird Server in VB6, If so please help me the process of doing the same.

Thanks and Regards,

Young Hern

SHARE
Best Answer by RubyIslam3
Answered By 0 points N/A #189279

Embedded Firebird Server in VB6

qa-featured

Yes it is possible to use Embedded FireBird Server with Visual Basic 6 just like Super and Classic servers. The embedded server, consisting of dll and a client and server of Super server, is designated for embedded databases.

In order to access Firebird from Visual Basic, ActiveX Data Objects (ADO) library is used.

 

To create a new firebird database:

Start with this utility: C:Program FilesFirebirdFirebirdbinisql.exe

 

Follow this instruction:

Use Create Database to specify a database:

SQL> CREATE DATABASE 'localhost:d:temptest.fdb' user 'SYSDBA' password 'masterkey' DEFAULT CHARACTER SET WIN1251;

 

In order to test if the connection is running fine, use this query:

SQL> select MON$DATABASE_NAME from MON$DATABASE;

 

And a successful connection will return to the connected database:
D:TEMPTEST.FDB
 
 

 

Best Answer
Best Answer
Answered By 70 points N/A #189280

Embedded Firebird Server in VB6

qa-featured

Hi Young Hern,

To use embedded Firebird Server in VB6 at first you need to download the Embedded server kit from SourceForge. It's naturally called Firebird-n.n.n.xxxx_embed_win32.zip, with n.n.n.xxxx the Firebird version & build number.

After unzipping, you'll find the embedded server “fbembed.dll” in the origin directory of the package, along with some other files. As well, there are three subdirectories “doc”, “intl” and “udf”.

To create your application work with the embedded server follow these steps”

1. Copy “fbembed.dll” into your program directory. Rename it to “fbclient.dll” or “gds32.dll”, depending on what your program expects as a Firebird client file-name. Numerous applications still look for “gds32.dll”. Firebird command-line tools like “isql” and “gbak” – which you may also run against the embedded server – need “fbclient.dll”. You can also create copies with both names.

2. Also copy “firebird.msg” & “ib_util.dll” to your application directory. Copy “aliases.conf” if your program uses aliases to join. The configuration file “firebird.conf” is single required if you need to change the Firebird root directory.

3. For Firebird 2 or higher, copy the “icu*.dll” libraries too.

4. From the “intl” & “udf” directories, copy whatsoever your application or databases might need to same-named folders under your program directory.

5. Now if you run your program it will utilize the embedded server DLL to join to any local database you wish, provided that the Windows user who runs the application has enough access rights to the database file(s) in question! Any combination of worker name & password is accepted, as long as neither is an empty string (a space is “OK” however).

The most significant advantage of all this is that you can easily pack the Firebird Embedded files with your application & have them connected or unzipped at your users' PC’s without having to execute a separate Firebird install there. 

Login/Register to Answer

Related Questions