1

Really simple question what is the difference between DESCRIBE and EXPLAIN when using it in a MySQL query ?

They both look as though they product the same results.

Haim Evgi
  • 123,187
  • 45
  • 217
  • 223
Oliver Bayes-Shelton
  • 6,135
  • 11
  • 52
  • 88
  • 1
    DESCRIBE (and possibly EXPLAIN) are not standard SQL statements. Please specify which DBMS you are asking about. – sleske Jul 05 '10 at 10:55
  • 1
    Duplicate of http://stackoverflow.com/questions/3100247/explain-vs-desc-anomalies-in-mysql/ – Konerak Jul 05 '10 at 11:21

1 Answers1

2

DESCRIBE and EXPLAIN are synonyms when enquiring for the definition of tables, procedures, etc. EXPLAIN (some query) outlines the plan the query optimiser has come up with the perform your command.

12.3.1 and 12.3.2 of the reference manual have the full details.

Brian Hooper
  • 21,544
  • 24
  • 88
  • 139