I have an older application (written in Delphi 6) that has to be ported to Delphi 2006 (update 2). The application used to connect to an Interbase 6.x database using DBExpress, but the new version needs to connect to a Firebird 2.x Superserver.
Porting went OK, no real problems. But now, when I try to connect to the new Firebird server from the ported app, I get the following error:
Database error
Database Server Error: no current record for fetch operation
Running the same application compiled with Delphi 6, talking to the same Firebird server runs fine. The changes needed to compile the app in Delphi 2006 weren't related to the database code - all local library stuff. The application uses TSQLDataset en datasetproviders and clientdatasets.
Anybody has any idea how or why? Any changes to DBExpress that might cause this behaviour?
Thanks.
I don't think Delphi 2006 supports Firebird natively. Think you need to install FIBPlus
Heres a list of what is supported in Delphi 2006:
Old driver New driver Database and Version
dbexpinf.dll dbxinf30.dll Interbase 7.5
dbexpora.dll dbxora30.dll Oracle 10g
dbexpdb2.dll dbxdb230.dll db2 UDB 8.x
dbexpmss.dll dbxmss30.dll MSSQL 2000
dbexpmys.dll dbxmys30.dll MySQL 4.0.24
dbexpasa.dll dbxasa30.dll Adaptive Sybase Anywhere 9
dbexpase.dll dbxase30.dll Sybase 12.5
dbexpinf.dll dbxinf30.dll Informix 9.x
Extracted from Here
Until Delphi 2010, the built in DBExpress drivers officially never supported FireBird.
In practice, a lot of combinations never worked at all.
Either:
go for a DBExpress driver officially supporting FireBird (search google),
or move to another database middle layer (FIBPlus that James suggests is really good).
--jeroen
First of all, retry the same steps from a new, 1-form app (put SQLConnection, SQLQuery etc etc), fill with the SQL you want and try to connect.
I believe there's some connection parameter that changed between versions, since I've used D2006 DBexpress to access Firebird 2.x with success. But the application were not ported, but new projects.
Related
I have made an application in Delphi with informix as a database. I am using BDE to connect with the database. It works fine on Win xp however this application doesn't run on Win7. As application is launched it stops. Can you plesae help. I tried this link but doesn't work:
http://www.willneumann.net/2008/09/configuring-bde-for-windows7/
The BDE is a very old product. It remains in delphi to be downwards compatible to old source.
On a new project I would never use the BDE.
On The BDE Alternatives Guide you find alternatives for the BDE.
May AnyDAC or SqlDirect is a good solution to connect to Informix.
I've used mOdbc package created by Konstantin Savelyev in the past to connect to Informix databases. It can be downloaded from here:
https://sites.google.com/site/robsosno/Home/downloads .
mOdbc is a set of components for Delphi 7 to work with Odbc with sources.
I don't know if it works with Windows 7. I think that it should.
Currently I'm not using this - in my company we've migrated from Delphi to C#.
My Delphi XE3 application used Interbase components to connect to a Firebird 2.5
SuperServer.
I started a new project to isolate the problem, and tried to connect to my software database. The results follows.
1 - I can connect to the database using TIBDatabase normally.
and I want to deploy it to use embedded Firebird my question is:
can I use Interbase components to connect to a embedded Firebird?
if yes then how can i do it?
if not then is there any free Firebird components?
While Interbase and Firebird are sill almost compatible API-wise, I recall some have reported having problems when using IB components (which come with Delphi) when connectiong to Firebird. These components are officially for Interbase only and thus you can be sure that over time the situation will get worse (more incompatible), not better. So I would recommend using components which officially support Firebird. I personally use UIB which is free, but there is others as well (both free and commercial).
can I use Interbase components to connect to a embedded Firebird?
By default you can use Interbase components to use Firebird.
if yes then how can i do it?
You must change the name of firebird client library, in common word.
In dbExpress and Firebird server edition => use fbClient.dll and
dbxFb.dll in client side of program.
In dbExpress and Firebird embedded edition => change name of
fbEmbed.dll to fbClient.dll and use dbxFb.dll in client side of
program(fbClient.dll and dbxFb.dll).
With IbExpress and and Firebird server edition => change name of
fbClient.dll to gds32.dll.
In addition, Daniel Magine writed an article about Firebird and dbExpress.
http://www.embarcadero.com/rad-in-action/database
if not then is there any free Firebird components?
You can use ZEOS.
UPDATE
In Firebird 3:
When does not contain a network protocol but just the database name, the Remote provider rejects it and the Engine12 provider comes to the fore and tries to open the named database file. If it succeeds, we get an embedded connection to the database.
We are migrating from Delphi 6 to Delphi 2010,earlier we were using BDE engine to connect to Sybase Database from Delphi 6. We found out that Delphi 2010 does not support BDE.
We are trying with dbexpress but we are not able to catch the exception(raise error) thrown by Sybase.
Could you please let me know if there is any other driver except dbexpress to connect to Sybase Database from Delphi 2010.
Thanks.
Regards,
AS
You can use AnyDAC to connect to:
Sybase SQL Anywhere (AnyDAC native driver)
Sybase Adaptive Server (AnyDAC ODBC bridge).
I suspect your real problem is that you have the Professional version of Delphi rather than Enterprise. As far as I know, BDE can still be used with Delphi 2010.
With Delphi 6 the Professional version allowed connections to remote databases. Somewhere between Delphi 6 and Delphi 2010 that policy was changed.
Anyway, you really need to give up on BDE and move forward.
Edit: (jeroen)
The BDE for relational access (aka the BDE SQL Links technology) has been deprecated since 2002, about 2 years after the introduction of dbExpress in Kylix and Delphi 6.
You could try a workaround:
Install Delphi 6
Update BDE to the latest available version (there should be some updates on Embarcadero site, I hope)
Install Delphi 2010
IIRC the available SQL Links should not be removed (otherwise it would break the older version), and they should still work in Delphi 2010. But that's really a stopgap try.
Devart's UniDac can connect to Sybase without using dbExpress, but I never used it.
Sybase drivers for dbExpress is included in Enterprise version of Delphi. If that is not an option you can use dbGO (ADO) that is included in Professional.
You can try ZEOSLIB which contains SyBase connectivity, along with many other SQL dbs.
As far as I can see, it requires you to remove your Query/Table objects and replace them with its own Table and Query replacement objects, but then, so would moving from BDE to ADO/dbGo or dBExpress.
And you really should get the BDE out of your application. It's dead as a doornail.
We are migrating a pretty big application crafted in Delphi 5 (still getting customers using this old versions) that uses BDE to connect to a SQL Server. The decided path to migrating is first Delphi 5 to Delphi 2010, then BDE to dbExpress (or dbGO, still undecided).
The problem is that BDE in Delphi 2010 doen't seems to have SERVER NAME parameter! (the one you need to set the host to connect to) and it neither seems to have a replace for that.
I've tried to force it in the strings of parameters unsuccesfuly. I still can not believe this, but maybe I'm missing something bad.
BDE support for SQL Links was removed from the BDE. SQL Server in the BDE was using SQL Links.
The announcement was made in 2002 in this article:
http://edn.embarcadero.com/article/28688
If you copy the old BDE files over the new ones in Program Files\Common files\Borland shared\BDE, you will have access again to SQL servers through BDE. I have done a quick test, and could access my Firebird 2.1 in Delphi 2010 IDE without problem. I still will have to test my application, which was Delphi 6. So I can't give a final conclusion, but it looks OK. If it is wise to continue with BDE maybe questionnable, but at least basically it still works.
I have simple application that uses dbExpress to connect Informix database.
If I compile it with TurboDelphi it works on both WinXP and Win2003.
When I use new Deplhi 2009 my app works ok on WinXP but do not start on Win2003.
No MessageBox with error, only info in EventLog:
Faulting application inf_dbexpress_test.exe, version 0.0.0.0, faulting
module kernel32.dll, version 5.2.3790.4062, fault address 0x0000bee7.
I think this is problem with dbExpress driver while my other app compiled with Delhi 2009 that uses
ODBC to connect Informix works on Win2003.
Anybody can test if Informix dbExpress drivers from Delphi 2009 works with Windows 2003?
Thanks for your help, but it do not work.
As for $INFORMIXDIR:
I reinstalled ClientSDK 3.5 and my $INFORMIXDIR is now:
c:\informix
(was c:\Program Files ...).
I can connect to DB from my app that uses ODBC.
But dbExpress app can not start, even in WinXP compatibility mode.
I have reported it in Delphi Quality Central as bug #67823:
Which turbo version do you have (the .net version or the Win32 version)? Do you have .net framework installed on 2003?
Hm maybe a strange suggestion, but one of the big differences introduces in Delphi 2009 is Unicode. All strings are now Unicode strings. Could that possibly be an explanation for the problem?