云数据库 GAUSSDB-EXPLAIN:语法格式

时间:2024-11-02 18:50:36

语法格式

  • 显示SQL语句的执行计划,支持多种选项,对选项顺序无要求。
    EXPLAIN [ (  option  [, ...] )  ] statement;

    其中选项option子句的语法为。

    ANALYZE [ boolean ] |
        ANALYSE [ boolean ] |
        VERBOSE [ boolean ] |
        COSTS [ boolean ] |
        CPU [ boolean ] |
        DETAIL [ boolean ] |
        BUFFERS [ boolean ] |
        TIMING [ boolean ] |
        PLAN [ boolean ] |
        BLOCKNAME [ boolean ] |
        FORMAT { TEXT | XML | JSON | YAML }
        OPTEVAL [ boolean ]
  • 显示SQL语句的执行计划,且要按顺序给出选项。
    EXPLAIN  { [   ANALYZE  | ANALYSE    ] [ VERBOSE  ]  | PERFORMANCE  } statement;
support.huaweicloud.com/centralized-devg-v3-gaussdb/gaussdb-12-0611.html