5
I wonder if it is possible to use AND
within a INNER JOIN
, example:
SELECT *
FROM tab1
INNER JOIN tab2
ON tab2.id2 = tab1.id1
AND tab2.camp1 = 'valor'
INNER JOIN tab3
ON tab3.id3 = tab2.id2;
I gave a very silly example, but the question is whether you have any way of using the AND
after the ON
and before another INNER JOIN
?
What would be a composite key?
– Rodrigo Fontes
When the use of composite primary key is recommended?
– Sorack