Re: ANALYZE TABLE
The Babel parser doesn’t really do DDL (because there is too much variation among dialects).
The “server” parser might be a better place for this. It has a few, Calcite-specific DDL statements. It could have ANALYZE too.
In my opinion, Oracle made a mistake when they introduced ANALYE TABLE. A "ALTER TABLE … COMPUTE STATISTICS” command makes just as much sense.
> On Sep 20, 2018, at 7:18 AM, Vitalii Diravka <vitalii@xxxxxxxxxx> wrote:
> ANALYZE TABLE statement is commonly used by different SQL engines for
> collecting table statistics: PostgeSQL , MySQL , ORACLE ,
> Microsoft Transact-SQL - UPDATE STATISTICS - , SPARK SQL , Hive .
> But I didn't find ANALYZE TABLE statement in SQL specification.
> Is there any sense to add it to Calcite (for instance for query
> Or maybe it can be part of the "babel" parser? If so what dialect should be
>  https://www.postgresql.org/docs/8.1/static/sql-analyze.html
>  https://dev.mysql.com/doc/refman/8.0/en/analyze-table.html