p2p.wrox.com Forums

Need to download code?

View our list of code downloads.


  Return to Index  

asp_databases thread: Re: Fully Qualified table name?


Message #1 by "Moynul Islam" <moynul.islam@p...> on Mon, 17 Jun 2002 16:33:24
Using the following syntax:-

databasename.tableowner.tablename

e.g.


select * from pyinna.dbo.mytable
select * from pyinna.moynul.mytable
select * from master..sysusers


moynul
Message #2 by "Owen Mortensen" <ojm@a...> on Mon, 10 Jun 2002 14:48:50 -0700
This is a multi-part message in MIME format.

------=_NextPart_000_01A7_01C2108D.EF15ED60
Content-Type: text/plain;
	charset="us-ascii"
Content-Transfer-Encoding: 7bit

How do I specify the fully qualified table name so I can join tables in
two databases (on the same SQL-Server 7.0 machine)?
 
I need to do something like this:
 
Select UserName, eMail
FROM LocalTable lt INNER JOIN OuterTable Ot on it.Username = Ot.UserID
 
The OuterTable is a table in a different database (but on the same SQL
Server machine).
 
TIA,
Owen



  Return to Index