Radicore Forum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » RADICORE development » Data Dictionary » Subsystem in Different Database Systems
Re: Subsystem in Different Database Systems [message #576 is a reply to message #574] Thu, 25 January 2007 13:03 Go to previous messageGo to previous message
AJM is currently offline  AJM
Messages: 2355
Registered: April 2006
Location: Surrey, UK
Senior Member
Generally speaking an application has a single DBMS which may contain any number of database schemas, so the whole application is running on either on one (e.g. MySQL) or another (e.g. PostgreSQL or Oracle). It is extremely unusual to find a web application which accesses different DBMS engines at the same time.

That being said it is possible for Radicore to run different applications which use different DBMS engines, but it would require a little extra effort.

In the first place you would require a separate copy of the Data Dictionary for each DBMS. It would not be possible, for example, to import the details of a PostgreSQL database into a MySQL data dictionary.

As there is usually only one DBMS for the entire application its identity is specified as a global variable in the CONFIG.INC file. This means that you can switch the entire application from one DBMS to another by changing a single line of code.

This global variable is referenced in the constructor for each database table class as follows:
$this->dbms_engine = $GLOBALS['dbms'];

If you wish different tables to be served by different DBMS engines then you will have to change this line in the constructor so that it uses a hard-coded value instead of the global variable, as in:
$this->dbms_engine = 'pgsql';

If you are thinking of trying this be aware of the following:
(a) It is not possible to perform JOINs across different DBMS engines.
(b) It is not possible for a database transaction to span different DBMS engines.


 
Read Message
Read Message
Read Message
Read Message
Previous Topic: Icon Support
Next Topic: Importing a Database from Oracle
Goto Forum:
  


Current Time: Tue Aug 06 21:35:34 EDT 2024

Total time taken to generate the page: 0.00945 seconds