>Dear Experts.
>
>Where can I get Standard SQL language that applies on all the DBMS.
>I have problem when I write SQL for MS SQL Server when I doesn't run in MySQL. Like when I run " where first_name + last_name = cVariable" it works on MS SQL Server but doesn't work on MySQL. MySQL accepts " where first_name = cVariable1 AND last_name = cVariable2"
>
>Any suggestions?
>
>Thank in advance..
You could use ODBC and let it translate a query to the native SQL implementation.
There is no real SQL Standard as all manufacturerts, from MS SQL Server to Oracle to IBM to MySQL, etc. have added their own little enhancements.
If you write the statements yourself, using SQL Pass-Through you are basically sending the command unchanged/unstranslated by the ODBC Driver (or oleDB Provider if you used ADO). Therefore your data access layer would have to be smart enough to be able to switch. In .NET they somehow solved it by giving you different provider (generic, SQL Server, Oracle). In reality you have to know more about what back-end database you are dealing with.