Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

One app with two back ends?

Status
Not open for further replies.

Ronin441

Programmer
Feb 22, 2002
128
AU
I have an app that has a BDE back end. The people who write the suite that my software slots into have changed from using a Paradox BDE database to using an Interbase database.

So I've added Interbase support to my app, which is all well and good on a PC with both the BDE and Interbase client installed. But if the BDE is missing, I get an access violation when the app starts up (and it then continues happily), and if the Interbase client is missing, the app just dies instantly.

Is there some way I can make the app detect the presence of each database (particularly Interbase) before it loads the relevant data module?

Will not loading the relevant data module be enough to dodge the problem? Or will I have to do it through conditional compilation, and thus have two different flavours of my app out there?

-- Doug Burbidge mailto:dougburbidge@yahoo.com
 
What is exactly happening? Have they completely upscaled the paradox database to interbase?
In this case there is no need for using paradox.

If the conversion of data has been succesfull the only thing to do in the BDE explorer is to use the same alias as used by your app., use for driver INTRBASE and for Server Name the name of the server computer and location of the database.

To connect to interbase, you have to supply a username and a password, regardless if you are using your application or another tool like Borlands SQL-explorer, Interactive SQL or other 3rd party program.

Regards






Steven van Els
SAvanEls@cq-link.sr
 
It's not that they've upscaled the existing system; more that they've reinvented it. But there are still plenty of legacy systems out there; hence my desire to simultaneously support both back-ends.

New systems do not have the BDE installed, which is why I want to use pure Interbase components (TIBDatabase, TIBTransaction, TIBDataset) on those systems, rather than Interbase-via-BDE.

-- Doug Burbidge mailto:dougburbidge@yahoo.com
 
If the new systems don't have the BDE installed then probably they are using the native IB components.
In that way the application can talks only to interbase, connecting to paradox will generate a runtime error.

Another type of components are from dbExpress which is based on SQL, and will also kick-out the desktop databases like access and paradox

Another option is ADO, but then you will be tied to the Microsoft Windows OS. If you want to port to LINUX or other system, that means that you have to change all the data components in your app.

If they have re-invented the database, probably the bulk proccessing load will be on the server, that means validation, triggers, generators and stored procedures. That will make it difficult to use the same app. for both databases

Regards

Steven van Els
SAvanEls@cq-link.sr
 
All Interbase Client machines have a Dll - but I'm not at my machine so I can't remember it.
You can check for the presence of this dll on the machine before you load your IB module.

There is a call to start BDE but from what you wrote if BDE is not loaded then your program wont start anyway.
You can look in Program Files\Borland\Common Files\BDE or such like

mick
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top