Joining tables in different databases

Results 1 to 2 of 2

Thread: Joining tables in different databases

  1. #1
    Lynnsey Guest

    Default Joining tables in different databases

    I need to build a SQL query using a join - the only problem being that the tables are in different databases (on the same server though). How do I reference the tables so that my query will execute correctly? I know it has something to do with prefixing the table name with the database name. At the moment I am getting an error: "Invalid object name &#039tablename&#039".<BR><BR>Thanks!<BR>

  2. #2
    Join Date
    Dec 1969

    Default What kind of database?

    *PROBABLY* you can find out by looking at "Help" for the keywords "INTO" or "IN". But it depends on which DB. Some DB&#039s (e.g., IBM DB2 on many systems) don&#039t allow references to external tables.<BR><BR>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts