Possible Duplicate:
SQL: What does =* mean?
I am going through some legacy code and found a query like this:
SELECT * from foo_table, bar_Table where foo_table.id *= bar_table.fac_id
What does the *= operator do?
Possible Duplicate:
SQL: What does =* mean?
I am going through some legacy code and found a query like this:
SELECT * from foo_table, bar_Table where foo_table.id *= bar_table.fac_id
What does the *= operator do?
They are LEFT OUTER JOIN
and RIGHT OUTER JOIN
. Which is which escapes me at the moment.
I believe that is an old style way of referring to left and right inner and outer joins. Here is an article about it, and it being deprecated:
That is the old and no longer recommended way of specifying table joins.
The modern equivalent to what you're seeing would be:
SELECT *
FROM foo_table
LEFT JOIN bar_Table ON foo_table.id = bar_table.fac_id
It means replace this code immediately as it is not guaranteed to give accurate results even as far back as SQL Server 2000. Sometimes instead of an outer join SQL Server intreprets this as a cross join. This is dangerous and incorrect code that has been deprecated.