Wednesday, March 21, 2012

Open Table Query View Only Cross Joins!URGENT

Does anyone know why when I open a table in the enterprise manager in the
query view I don't see the real table name I see table_1 and any query built
that way only produces cross joins any ideas?
EM enumerates the table names so that you can refer to more than one alias
of the same table in self-joins.
EM will automatically generate an INNER JOIN in the designer if a foreign
key exists between two of the tables. If no usable foreign key exists then
the query defaults to a CROSS JOIN. You can still add or change the join
type and criteria yourself.
David Portas
SQL Server MVP
|||Because Enterprise Manager tries to think for you. As David states, you can
toggle the SQL button and construct the query however you really want it.
Or, you can use Query Analyzer -- Enterprise Manager is rarely the best
choice for viewing/manipulating data.
See http://www.aspfaq.com/2455
http://www.aspfaq.com/
(Reverse address to reply.)
"Chris Calhoun" <calhoun_chris@.hotmail.com> wrote in message
news:u#EzQK9qEHA.3900@.TK2MSFTNGP10.phx.gbl...
> Does anyone know why when I open a table in the enterprise manager in the
> query view I don't see the real table name I see table_1 and any query
built
> that way only produces cross joins any ideas?
>

No comments:

Post a Comment