Safecall error connecting to Interbase XE3 using DBX

I am trying to connect to interbase XE3 using schema modeler using DBX.

The connection string tests fine but in connection manager the list of tables and the fields is not built correctly and there are multiple safecall errors with the source object not providing proper error information.

At first, the tables section is empty but the list of stored procs is filled. Clicking on refresh on the tables can bring up the tables list but then some of the tables will have red crosses which refresh won’t remove. If the schema modeler is closed down and the procedure repeated, the list of tables with crosses is different. Sometimes refresh won’t bring up anything at all.

DA and interbase are both latest versions, just installed. XE2 had been installed previously on the system.

This occurs with the Employee.gdb example database as well as the target database. Both of these work fine with other db clients for example IBExpert.

Not sure where to go next.

Thanks

Nick

Further to the above, I can connect fine using IBDAC in Schema modeler so it doesn’t look like a problem with interbase.

I added the information for devart interbase/firbird driver to the dbxdriver.ini and the error behaviour is the same (actually slightly better as the table list comes up everytime) as for the included driver, some tables will list their fields and others will appear with a red cross. As before, the red crosses are random but don’t change once they appear.

I even switched the venderlib to fbembed for the devart driver and used the employee.fdb example got the same behaviour. Random red crosses.

The only variable left is the dbx connection in Schema Modeler itself.

Is there a problem with using dbx?
Also, can I use different connections in the application to those used to build the schema without inducing any problems?

Any help would be much appreciated.

Thanks

Nick

Hi Nick,

yes we can reproduce this situation and it looks like the problem is in incompartibility of DBX from D2007, which is used by DASM, and new Interbase. Can you try to switch from DBX driver to IBX? It should work without problem.

Thanks

Ok, thanks, that’s fine, I can work with that.

Are there any issues I need to be careful about with using different connections in DASM than in the application? I’m building on an application which was started with RO sdk and it’s already working ok with DBX. I’d rather not change over unless I have to.

Thanks.

Ok, for the record, I worked around the issue by switching the driver string before activating the server.

procedure TServerDataModule.ModuleCreate(Sender: TObject);
begin
ConnectionManager.Connections[0].ConnectionString:=MyDBXDriverString;
Server.Active := true;
end;

However, I then tried to get it to work with firebird embedded and the devart dbx driver but I found a bug in uDADBXDriver.pas when using XE3.

With TSQLConnection in xe3, LibraryName, Vendorlib and GetDriverFunc are now obsolete and don’t work so it needed to be changed around line 470.

Basically,

lc.LibraryName := GetProfileString( etc…
to
lc.Params.values[‘LibraryName’]:=GetProfileString( etc…
and so on for the others.

Also around line 527
lc.Params.Add(sName + ‘=’ + sValue);
to
lc.Params.values[sName]:=sValue;
to avoid duplicates.

Of course, also move lc.Params.clear before all of this.

Thanks

Nick

thx for report.
Logged as #61143