My first question is are the three different databases actually on different machines, or are they just different datasources on one machine? My second question is have you thought about what security holes you could be creating by using the same login for 3 different applications? My third thing is that from what I can read into the tables you're describing, your select statement should be something like this
 
SELECT orgName
FROM organizations
WHERE memberID = #session.memberID#
 
Other than all of that, what you're suggesting should work except for the fact that each of your fk constraints in your child tables will not actually be constraints since they will not be able to be pointed at the corresponding table since it is in another database. You will want to place a unique constraint and an index on that column from what I can read into this. It could possibly slow down your database, but I'm assuming that you're not going to be logging in and out at a horribly fast rate for it to matter.

Bruce Dunwiddie
Ticket Technology
P: 866.543.3331
F: 913.451.7832
[EMAIL PROTECTED]

-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]On Behalf Of Adaryl Wakefield
Sent: Tuesday, December 02, 2003 12:35 PM
To: [EMAIL PROTECTED]
Subject: [KCFusion] system intergration

I was just curious how someone with more experience would do this.
 
I have three applications that run off three different databases. Which means three differnet passwords, three different logins yadda yadda yadda. Im in the middle of creating a system where everything is controlled by one username and password set. Im doing this by taking the three primary parent tables (is that even the correct term?) and combining common attributes. What remains of the primary parent tables of the three applications after stripping out common attributes will become conceputally child tables to the super table. The super table will be moved into another database making that 4 total.
Here is what im thinking. You cant join tables accross databases so what I was thinking was holding the primary key of the super table in a session var to join the three "child" tables. Like
 
test1 DB
members(memberID PK, firstName, lastName)
 
test2 DB
organizations(orgNum PK, memberID FK)
 
<cfquery name="foo" datasource="test2">
SELECT orgName
FROM organizations
WHERE orgNum = #session.memberID#
</cfquery>
<!---Just pretend the lock is there--->
 
Thoughts? Ridicule?
 
Adaryl Wakefield
Aviator by passion
Programmer by sheer force of will

Reply via email to