>>2. use INNER JOIN instead of old WHERE. That makes code more readable:
>
>I know this is an old arguement but...............
>
>readability is in the eye of the reader. I used WHERE for multi-table joins for several years before somebody (I
think it was Tamar) showed me situations where JOIN is more accurate. I now use JOIN but find WHERE more readable. I liken it to learning a foreign language. No matter how fluent one gets in a second language, it is always more comprehensible in your native tongue.
>
>There are many valid reasons to use JOINS, but for me (and, I assume, Beth) readability is generally not one of them.
You are right.
"Readability is in the eye of the reader"
Personally I didn't found WHERE to be more readable because I can't distinct where is the JOIN clause and where the real WHERE begins (WOW! how many wheres I have in that sentence:-))))))
Sometimes they could be equal but sometimes not. I can't remember right now a good example but sometimes you could get different results from:
SELECT *;
FROM Table1,Table2
WHERE Table1.Id = Table2.FK AND;
Table1.SomeField = Table2.SomeField AND;
Table2.SomeField = 1234
and
SELECT *;
FROM Table1
INNER JOIN Table2 ON Table1.Id = Table2.FK AND Table1.SomeField = Table2.SomeField
WHERE Table2.SomeField = 1234
and
SELECT *;
FROM Table1
INNER JOIN Table2 ON Table1.Id = Table2.FK
WHERE Table1.SomeField = Table2.SomeField AND Table2.SomeField = 1234
but as I said I cant give your the data where this could be true right now :-)
(it was something with NULLs)
Against Stupidity the Gods themselves Contend in Vain - Johann Christoph Friedrich von Schiller
The only thing normal about database guys is their tables.