>I just found out that in SQL Server, the WHERE clause has to be before the ORDER clause. Can someone confirms me that? If yes, is there a setting that affect that? It is not a big problem for me to adjust the code to support that however.
And not only, GROUP BY also need to be after WHERE.
Maybe because SQL Server needs first to get the records set and after that manipulate it.
I am not aware of settings that can be used to change this behavior.
Against Stupidity the Gods themselves Contend in Vain - Johann Christoph Friedrich von Schiller
The only thing normal about database guys is their tables.