#1
  1. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    May 2004
    Posts
    2
    Rep Power
    0

    Red face fbembed.dll crashed Delphi


    Hi,

    when I change the property from Active:=True to Active:=False
    in the TSQLConnection ( dbExpress Component in Delphi 7 )
    Delphi crash.
    It's maybe a problem on unload the fbembed.dll by closing the (last/only) connection to the embedded Firebird-Db?!

    It happens at the following configuration:

    OS: NT4
    IDE: Delphi 7

    Form definition
    ===========

    object Form1: TForm1
    Left = 266
    Top = 122
    Width = 367
    Height = 252
    Caption = 'Form1'
    Color = clBtnFace
    Font.Charset = DEFAULT_CHARSET
    Font.Color = clWindowText
    Font.Height = -11
    Font.Name = 'MS Sans Serif'
    Font.Style = []
    OldCreateOrder = False
    PixelsPerInch = 96
    TextHeight = 13
    object SQLConnection1: TSQLConnection
    ConnectionName = 'IBConnection'
    DriverName = 'Interbase'
    GetDriverFunc = 'getSQLDriverINTERBASE'
    LibraryName = 'dbexpint.dll'
    LoginPrompt = False
    Params.Strings = (
    'DriverName=Interbase'
    'Database=D:\Sources\Delphi\ThdTest\data\default.fdb'
    'RoleName=RoleName'
    'User_Name=sysdba'
    'Password=masterkey'
    'ServerCharSet='
    'SQLDialect=3'
    'ErrorResourceFile='
    'LocaleCode=0000'
    'BlobSize=-1'
    'CommitRetain=False'
    'WaitOnLocks=True'
    'Interbase TransIsolation=ReadCommited'
    'Trim Char=False')
    VendorLib = 'fbembed.dll'
    Left = 40
    Top = 24
    end
    end
  2. #2
  3. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Dec 2003
    Posts
    249
    Rep Power
    14
    Hmmm... How about using the Firebird dbExpress driver at www.upscene.com ?
    Martijn Tonies
    Database Workbench: developer IDE for Firebird, MySQL, InterBase, MSSQL Server and Oracle
    Upscene Productions
    http://www.upscene.com
  4. #3
  5. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    May 2004
    Posts
    2
    Rep Power
    0
    Thanks a lot for your quick reply.
    The Firebird dbExpress driver from www.upscene.com do the job perfect!
    The only disadvantage ... it's not free ;o(

    For the moment I have found an other/dirthy solution ... for the runtime

    var
    hDLL: THandle;

    initialization

    //=========================================
    // Load the "fbembedi.dll" before "TSQLConnection" can
    // do it!
    //=========================================
    hDLL := LoadLibrary('fbembed.dll');

    finalization

    //=========================================
    // All "TSQLConnection"-Connections to an embedded
    // Firebird-DB should be disconnected at this point!
    //=========================================
    if hDLL <> INVALID_HANDLE_VALUE
    then FreeLibrary(hDLL);
    Last edited by huk; May 11th, 2004 at 08:46 AM.
  6. #4
  7. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Dec 2003
    Posts
    249
    Rep Power
    14
    Well, that's the problem. You're using Firebird, with an InterBase dbExpress driver (made by Borland). You cannot expect the InterBase driver to stay compatible with Firebird - they simply won't do that.

    If you like programming around problems and thinking of hacks every now and then instead of paying a few $$, then go ahead
    Martijn Tonies
    Database Workbench: developer IDE for Firebird, MySQL, InterBase, MSSQL Server and Oracle
    Upscene Productions
    http://www.upscene.com

IMN logo majestic logo threadwatch logo seochat tools logo