If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > DB2 > Db2 Query For Take Data From Two Databases

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 12-12-03, 16:41
gbrito gbrito is offline
Registered User
 
Join Date: Dec 2003
Location: El Salvador
Posts: 18
Question Db2 Query For Take Data From Two Databases

Hi everyone, I'm new to DB2 and I'm try to get data from two databases from an application developped ussing Borland C++ Builder, the two DB are located on the same DB2 server, but I don't know how to access the second DB using SQL.

In informix IDS the sintax is DBNAME@hostname:table_name but in DB2 don't know....

Someone have the right SQL to do this.....


Thanks, in advance, regards


gbrito
Reply With Quote
  #2 (permalink)  
Old 12-15-03, 04:33
jsander jsander is offline
Registered User
 
Join Date: Apr 2003
Posts: 191
Re: Db2 Query For Take Data From Two Databases

Hi,

no can do, but you might want to try nicknames.

A Nickname is a reference to a table residing in another database.

There are usage limitations, though.

Read up on Federated Servers.

Johann

Quote:
Originally posted by gbrito
Hi everyone, I'm new to DB2 and I'm try to get data from two databases from an application developped ussing Borland C++ Builder, the two DB are located on the same DB2 server, but I don't know how to access the second DB using SQL.

In informix IDS the sintax is DBNAME@hostname:table_name but in DB2 don't know....

Someone have the right SQL to do this.....


Thanks, in advance, regards


gbrito
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On