Board index » delphi » Connecting: what I'm doing wrong?

Connecting: what I'm doing wrong?

Hi

I hope one of you can help. In my Datamodul I have a TIBDatabase. To know
where the database is, I readout the Path from a ini-File:

procedure TDaten.DatenCreate(Sender: TObject);
var ini: TIniFile;
     LW: String;
begin
  ini := TIniFile.Create(ExtractFilePath(application.exename) +
'local.ini');
  LW :=
ini.ReadString('Optionen','Database',extractfilepath(application.exename));
  ini.free;
  IBDatabaseDaten.DatabaseName := LW + 'mydatabase.gdb';
  try
   IBDatabaseDaten.Connected := true;
  except
   ShowMessage('No database available!');
    Halt;
  end;
end;

Database is declared in the ini: Database=D:\pathx\

This will work well on different local-installations. On one Computer (WinNT
SP5) I can connect the database via IBConsole (localhost:d:\pathx\ or
d:\pathx\), but not with TIBDatabase.

IBDatabase-Settings: Parmas -->  user_name=SYSDBA
                                                    password=masterkey
                                                    lc_ctype=ISO08859_1
                                SQLDialect --> 3
IBX Version 4.52

IBDatabase isn't connected while compileing the exe.

Does anybody know, what I'm doing wrong?

Thanks for your help.

Dominik F?ssler

 

Re:Connecting: what I'm doing wrong?


Dont trap the error and give us the exact error string returned by IB.

--
Sergio Samayoa
Lgica Software
http://www.geocities.com/logicasw/

Re:Connecting: what I'm doing wrong?


Hello Dominik,

try to use 'lc_ctype=ISO8859_1' (without quotes) instead of
'lc_ctype=ISO08859_1'!!!

--
Best Regards
Thomas Steinmaurer
IB LogManager - The Logging Tool for Interbase/Firebird
http://www.iblogmanager.com
"Dominik F?ssler" <d.faess...@performa-software.ch> schrieb im Newsbeitrag
news:3b2f5dbc_1@dnews...

Quote
> Hi

> I hope one of you can help. In my Datamodul I have a TIBDatabase. To know
> where the database is, I readout the Path from a ini-File:

> procedure TDaten.DatenCreate(Sender: TObject);
> var ini: TIniFile;
>      LW: String;
> begin
>   ini := TIniFile.Create(ExtractFilePath(application.exename) +
> 'local.ini');
>   LW :=

ini.ReadString('Optionen','Database',extractfilepath(application.exename));
Quote
>   ini.free;
>   IBDatabaseDaten.DatabaseName := LW + 'mydatabase.gdb';
>   try
>    IBDatabaseDaten.Connected := true;
>   except
>    ShowMessage('No database available!');
>     Halt;
>   end;
> end;

> Database is declared in the ini: Database=D:\pathx\

> This will work well on different local-installations. On one Computer
(WinNT
> SP5) I can connect the database via IBConsole (localhost:d:\pathx\ or
> d:\pathx\), but not with TIBDatabase.

> IBDatabase-Settings: Parmas -->  user_name=SYSDBA
>                                                     password=masterkey
>                                                     lc_ctype=ISO08859_1
>                                 SQLDialect --> 3
> IBX Version 4.52

> IBDatabase isn't connected while compileing the exe.

> Does anybody know, what I'm doing wrong?

> Thanks for your help.

> Dominik F?ssler

Other Threads