In Oracle I have:
SELECT t2.Regkood, t2.naitatel, t2.naitafaks, t3.lahtiolekuaeg, t1.*
FROM table1 t1, table2 t2, table3 t3
WHERE t1.client = t2.client AND t1.client = t3.client(+) AND t1.client = 414246
How do I get the same in SQL Server?
thanks
SELECT t2.Regkood,
t2.naitatel,
t2.naitafaks,
t3.lahtiolekuaeg,
t1.*
FROM table1 t1
INNER JOIN table2 t2
ON t1.client = t2.client
LEFT JOIN table3 t3
ON t1.client = t3.client
WHERE t1.client = 414246
Some samples to understand joins:
LEFT OUTER JOIN in ORACLE
SELECT *
FROM A, B
WHERE A.column = B.column(+)
RIGHT OUTER JOIN IN ORACLE
SELECT *
FROM A, B
WHERE A.column(+)=B.column
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With