1

I often find myself unable to use PostgreSQL or MySQL commands because it's a different 'language', but what syntax does Excel or more directly the Microsoft query uses? What standard does it follow? Thanks!

Joe
  • 6,767
  • 1
  • 16
  • 29
Mikael Blomkvist
  • 149
  • 2
  • 13
  • Can you give some specifics of code you're having trouble with? – Joe Jan 21 '14 at 16:24
  • 2
    Depends on the driver/provider e.g. [Excel SQL Syntax JET OleDB Reference?](http://stackoverflow.com/questions/7317268/excel-sql-syntax-jet-oledb-reference) – Alex K. Jan 21 '14 at 16:29

1 Answers1

0

The ODBC is a driver layer that is used to connect programs to your data sources. The SQL used is primarily determined by your database.

For example, if you are in Excel and using an ODBC to connect to an Oracle database, then your sql queries should use Oracle PL/SQL. If you are in Excel using an ODBC to connect to a MySql Database, then MySql commands will work.

The ODBC Driver itself can also be a factor. Ideally you should be using an ODBC designed to work with the specific type of Database you are using, and the specific version of it. Oracle 9i will have a different ODBC driver than Oracle 10g. But there are different Drivers from different sources for some database types. For example, Microsoft Makes a 'Microsoft ODBC for Oracle' which works with many oracle databases. But there are also ODBC drivers created by Oracle. Each ODBC will have different settings, but for the most part the SQL queries you write are processed on the Database itself.

So determine what type of database (or data source) you are using, then you can determine how to write your sql.

Damienknight
  • 1,876
  • 2
  • 18
  • 34