diff --git a/docs/zh/04-get-started/01-docker.md b/docs/zh/04-get-started/01-docker.md index 364e00f8f2..1d425fed6b 100644 --- a/docs/zh/04-get-started/01-docker.md +++ b/docs/zh/04-get-started/01-docker.md @@ -1,6 +1,6 @@ --- -sidebar_label: Docker -title: 通过 Docker 快速体验 TDengine +sidebar_label: 用Docker快速体验 +title: 用 Docker 快速体验 TDengine description: 使用 Docker 快速体验 TDengine 的高效写入和查询 --- diff --git a/docs/zh/04-get-started/03-package.md b/docs/zh/04-get-started/03-package.md index 7df41af831..de479fb06e 100644 --- a/docs/zh/04-get-started/03-package.md +++ b/docs/zh/04-get-started/03-package.md @@ -1,6 +1,6 @@ --- -sidebar_label: 安装包 -title: 使用安装包立即开始 +sidebar_label: 用安装包快速体验 +title: 使用安装包快速体验 TDengine description: 使用安装包快速体验 TDengine --- diff --git a/docs/zh/04-get-started/05-cloud.md b/docs/zh/04-get-started/05-cloud.md index 1d01abb1bb..bd76add527 100644 --- a/docs/zh/04-get-started/05-cloud.md +++ b/docs/zh/04-get-started/05-cloud.md @@ -1,6 +1,6 @@ --- -sidebar_label: 云服务 -title: 通过 云服务 快速体验 TDengine +sidebar_label: 用云服务快速体验 +title: 通过云服务 快速体验 TDengine toc_max_heading_level: 4 --- diff --git a/docs/zh/04-get-started/index.md b/docs/zh/04-get-started/index.md index 4422efbf60..4d9f7ceae5 100644 --- a/docs/zh/04-get-started/index.md +++ b/docs/zh/04-get-started/index.md @@ -1,5 +1,5 @@ --- -title: 立即开始 +title: 快速体验 description: '快速设置 TDengine 环境并体验其高效写入和查询' --- diff --git a/docs/zh/05-basic/index.md b/docs/zh/05-basic/index.md index 18dcd3fc9c..f579dcb3a0 100644 --- a/docs/zh/05-basic/index.md +++ b/docs/zh/05-basic/index.md @@ -1,6 +1,6 @@ --- -title: 快速入门 -description: 'TDengine 基本功能' +title: 基础功能 +description: 'TDengine 基础功能' --- 本章主要介绍 TDengine 的数据模型以及写入和查询功能。 diff --git a/docs/zh/08-develop/01-connect/_connect_c.mdx b/docs/zh/07-develop/01-connect/_connect_c.mdx similarity index 100% rename from docs/zh/08-develop/01-connect/_connect_c.mdx rename to docs/zh/07-develop/01-connect/_connect_c.mdx diff --git a/docs/zh/08-develop/01-connect/_connect_cs.mdx b/docs/zh/07-develop/01-connect/_connect_cs.mdx similarity index 100% rename from docs/zh/08-develop/01-connect/_connect_cs.mdx rename to docs/zh/07-develop/01-connect/_connect_cs.mdx diff --git a/docs/zh/08-develop/01-connect/_connect_go.mdx b/docs/zh/07-develop/01-connect/_connect_go.mdx similarity index 100% rename from docs/zh/08-develop/01-connect/_connect_go.mdx rename to docs/zh/07-develop/01-connect/_connect_go.mdx diff --git a/docs/zh/08-develop/01-connect/_connect_java.mdx b/docs/zh/07-develop/01-connect/_connect_java.mdx similarity index 100% rename from docs/zh/08-develop/01-connect/_connect_java.mdx rename to docs/zh/07-develop/01-connect/_connect_java.mdx diff --git a/docs/zh/08-develop/01-connect/_connect_node.mdx b/docs/zh/07-develop/01-connect/_connect_node.mdx similarity index 100% rename from docs/zh/08-develop/01-connect/_connect_node.mdx rename to docs/zh/07-develop/01-connect/_connect_node.mdx diff --git a/docs/zh/08-develop/01-connect/_connect_php.mdx b/docs/zh/07-develop/01-connect/_connect_php.mdx similarity index 100% rename from docs/zh/08-develop/01-connect/_connect_php.mdx rename to docs/zh/07-develop/01-connect/_connect_php.mdx diff --git a/docs/zh/08-develop/01-connect/_connect_python.mdx b/docs/zh/07-develop/01-connect/_connect_python.mdx similarity index 100% rename from docs/zh/08-develop/01-connect/_connect_python.mdx rename to docs/zh/07-develop/01-connect/_connect_python.mdx diff --git a/docs/zh/08-develop/01-connect/_connect_r.mdx b/docs/zh/07-develop/01-connect/_connect_r.mdx similarity index 100% rename from docs/zh/08-develop/01-connect/_connect_r.mdx rename to docs/zh/07-develop/01-connect/_connect_r.mdx diff --git a/docs/zh/08-develop/01-connect/_connect_rust.mdx b/docs/zh/07-develop/01-connect/_connect_rust.mdx similarity index 100% rename from docs/zh/08-develop/01-connect/_connect_rust.mdx rename to docs/zh/07-develop/01-connect/_connect_rust.mdx diff --git a/docs/zh/08-develop/01-connect/connection-type-zh.webp b/docs/zh/07-develop/01-connect/connection-type-zh.webp similarity index 100% rename from docs/zh/08-develop/01-connect/connection-type-zh.webp rename to docs/zh/07-develop/01-connect/connection-type-zh.webp diff --git a/docs/zh/08-develop/01-connect/index.md b/docs/zh/07-develop/01-connect/index.md similarity index 100% rename from docs/zh/08-develop/01-connect/index.md rename to docs/zh/07-develop/01-connect/index.md diff --git a/docs/zh/08-develop/02-sql.md b/docs/zh/07-develop/02-sql.md similarity index 100% rename from docs/zh/08-develop/02-sql.md rename to docs/zh/07-develop/02-sql.md diff --git a/docs/zh/08-develop/04-schemaless.md b/docs/zh/07-develop/04-schemaless.md similarity index 100% rename from docs/zh/08-develop/04-schemaless.md rename to docs/zh/07-develop/04-schemaless.md diff --git a/docs/zh/08-develop/05-stmt.md b/docs/zh/07-develop/05-stmt.md similarity index 100% rename from docs/zh/08-develop/05-stmt.md rename to docs/zh/07-develop/05-stmt.md diff --git a/docs/zh/08-develop/07-tmq.md b/docs/zh/07-develop/07-tmq.md similarity index 100% rename from docs/zh/08-develop/07-tmq.md rename to docs/zh/07-develop/07-tmq.md diff --git a/docs/zh/08-develop/09-udf.md b/docs/zh/07-develop/09-udf.md similarity index 100% rename from docs/zh/08-develop/09-udf.md rename to docs/zh/07-develop/09-udf.md diff --git a/docs/zh/08-develop/15-high.md b/docs/zh/07-develop/15-high.md similarity index 100% rename from docs/zh/08-develop/15-high.md rename to docs/zh/07-develop/15-high.md diff --git a/docs/zh/08-develop/_sub_c.mdx b/docs/zh/07-develop/_sub_c.mdx similarity index 100% rename from docs/zh/08-develop/_sub_c.mdx rename to docs/zh/07-develop/_sub_c.mdx diff --git a/docs/zh/08-develop/_sub_cs.mdx b/docs/zh/07-develop/_sub_cs.mdx similarity index 100% rename from docs/zh/08-develop/_sub_cs.mdx rename to docs/zh/07-develop/_sub_cs.mdx diff --git a/docs/zh/08-develop/_sub_go.mdx b/docs/zh/07-develop/_sub_go.mdx similarity index 100% rename from docs/zh/08-develop/_sub_go.mdx rename to docs/zh/07-develop/_sub_go.mdx diff --git a/docs/zh/08-develop/_sub_java.mdx b/docs/zh/07-develop/_sub_java.mdx similarity index 100% rename from docs/zh/08-develop/_sub_java.mdx rename to docs/zh/07-develop/_sub_java.mdx diff --git a/docs/zh/08-develop/_sub_java_ws.mdx b/docs/zh/07-develop/_sub_java_ws.mdx similarity index 100% rename from docs/zh/08-develop/_sub_java_ws.mdx rename to docs/zh/07-develop/_sub_java_ws.mdx diff --git a/docs/zh/08-develop/_sub_node.mdx b/docs/zh/07-develop/_sub_node.mdx similarity index 100% rename from docs/zh/08-develop/_sub_node.mdx rename to docs/zh/07-develop/_sub_node.mdx diff --git a/docs/zh/08-develop/_sub_python.mdx b/docs/zh/07-develop/_sub_python.mdx similarity index 100% rename from docs/zh/08-develop/_sub_python.mdx rename to docs/zh/07-develop/_sub_python.mdx diff --git a/docs/zh/08-develop/_sub_rust.mdx b/docs/zh/07-develop/_sub_rust.mdx similarity index 100% rename from docs/zh/08-develop/_sub_rust.mdx rename to docs/zh/07-develop/_sub_rust.mdx diff --git a/docs/zh/08-develop/addsource.png b/docs/zh/07-develop/addsource.png similarity index 100% rename from docs/zh/08-develop/addsource.png rename to docs/zh/07-develop/addsource.png diff --git a/docs/zh/08-develop/dashboard.png b/docs/zh/07-develop/dashboard.png similarity index 100% rename from docs/zh/08-develop/dashboard.png rename to docs/zh/07-develop/dashboard.png diff --git a/docs/zh/08-develop/dashboard2.png b/docs/zh/07-develop/dashboard2.png similarity index 100% rename from docs/zh/08-develop/dashboard2.png rename to docs/zh/07-develop/dashboard2.png diff --git a/docs/zh/08-develop/highvolume.webp b/docs/zh/07-develop/highvolume.webp similarity index 100% rename from docs/zh/08-develop/highvolume.webp rename to docs/zh/07-develop/highvolume.webp diff --git a/docs/zh/08-develop/img_5.png b/docs/zh/07-develop/img_5.png similarity index 100% rename from docs/zh/08-develop/img_5.png rename to docs/zh/07-develop/img_5.png diff --git a/docs/zh/08-develop/img_6.png b/docs/zh/07-develop/img_6.png similarity index 100% rename from docs/zh/08-develop/img_6.png rename to docs/zh/07-develop/img_6.png diff --git a/docs/zh/08-develop/img_7.png b/docs/zh/07-develop/img_7.png similarity index 100% rename from docs/zh/08-develop/img_7.png rename to docs/zh/07-develop/img_7.png diff --git a/docs/zh/08-develop/index.md b/docs/zh/07-develop/index.md similarity index 100% rename from docs/zh/08-develop/index.md rename to docs/zh/07-develop/index.md diff --git a/docs/zh/07-operation/tdengine-topology.png b/docs/zh/07-operation/tdengine-topology.png deleted file mode 100644 index c2a2dee550..0000000000 Binary files a/docs/zh/07-operation/tdengine-topology.png and /dev/null differ diff --git a/docs/zh/07-operation/01-intro.md b/docs/zh/08-operation/01-intro.md similarity index 100% rename from docs/zh/07-operation/01-intro.md rename to docs/zh/08-operation/01-intro.md diff --git a/docs/zh/07-operation/02-planning.md b/docs/zh/08-operation/02-planning.md similarity index 100% rename from docs/zh/07-operation/02-planning.md rename to docs/zh/08-operation/02-planning.md diff --git a/docs/zh/07-operation/03-deployment.md b/docs/zh/08-operation/03-deployment.md similarity index 100% rename from docs/zh/07-operation/03-deployment.md rename to docs/zh/08-operation/03-deployment.md diff --git a/docs/zh/07-operation/04-maintenance.md b/docs/zh/08-operation/04-maintenance.md similarity index 100% rename from docs/zh/07-operation/04-maintenance.md rename to docs/zh/08-operation/04-maintenance.md diff --git a/docs/zh/07-operation/05-monitor.md b/docs/zh/08-operation/05-monitor.md similarity index 100% rename from docs/zh/07-operation/05-monitor.md rename to docs/zh/08-operation/05-monitor.md diff --git a/docs/zh/07-operation/06-gui.md b/docs/zh/08-operation/06-gui.md similarity index 100% rename from docs/zh/07-operation/06-gui.md rename to docs/zh/08-operation/06-gui.md diff --git a/docs/zh/07-operation/09-backup.md b/docs/zh/08-operation/09-backup.md similarity index 100% rename from docs/zh/07-operation/09-backup.md rename to docs/zh/08-operation/09-backup.md diff --git a/docs/zh/07-operation/10-disaster.md b/docs/zh/08-operation/10-disaster.md similarity index 100% rename from docs/zh/07-operation/10-disaster.md rename to docs/zh/08-operation/10-disaster.md diff --git a/docs/zh/07-operation/12-multi.md b/docs/zh/08-operation/12-multi.md similarity index 100% rename from docs/zh/07-operation/12-multi.md rename to docs/zh/08-operation/12-multi.md diff --git a/docs/zh/07-operation/14-user.md b/docs/zh/08-operation/14-user.md similarity index 100% rename from docs/zh/07-operation/14-user.md rename to docs/zh/08-operation/14-user.md diff --git a/docs/zh/07-operation/16-security.md b/docs/zh/08-operation/16-security.md similarity index 100% rename from docs/zh/07-operation/16-security.md rename to docs/zh/08-operation/16-security.md diff --git a/docs/zh/07-operation/18-dual.md b/docs/zh/08-operation/18-dual.md similarity index 100% rename from docs/zh/07-operation/18-dual.md rename to docs/zh/08-operation/18-dual.md diff --git a/docs/zh/07-operation/Active-Standby.png b/docs/zh/08-operation/Active-Standby.png similarity index 100% rename from docs/zh/07-operation/Active-Standby.png rename to docs/zh/08-operation/Active-Standby.png diff --git a/docs/zh/07-operation/TDinsight-1-cluster-status.webp b/docs/zh/08-operation/TDinsight-1-cluster-status.webp similarity index 100% rename from docs/zh/07-operation/TDinsight-1-cluster-status.webp rename to docs/zh/08-operation/TDinsight-1-cluster-status.webp diff --git a/docs/zh/07-operation/grafana.png b/docs/zh/08-operation/grafana.png similarity index 100% rename from docs/zh/07-operation/grafana.png rename to docs/zh/08-operation/grafana.png diff --git a/docs/zh/07-operation/index.md b/docs/zh/08-operation/index.md similarity index 100% rename from docs/zh/07-operation/index.md rename to docs/zh/08-operation/index.md diff --git a/docs/zh/07-operation/pic/Active-Standby.png b/docs/zh/08-operation/pic/Active-Standby.png similarity index 100% rename from docs/zh/07-operation/pic/Active-Standby.png rename to docs/zh/08-operation/pic/Active-Standby.png diff --git a/docs/zh/07-operation/pic/agent-01.png b/docs/zh/08-operation/pic/agent-01.png similarity index 100% rename from docs/zh/07-operation/pic/agent-01.png rename to docs/zh/08-operation/pic/agent-01.png diff --git a/docs/zh/07-operation/pic/agent-02.png b/docs/zh/08-operation/pic/agent-02.png similarity index 100% rename from docs/zh/07-operation/pic/agent-02.png rename to docs/zh/08-operation/pic/agent-02.png diff --git a/docs/zh/07-operation/pic/agent-03.png b/docs/zh/08-operation/pic/agent-03.png similarity index 100% rename from docs/zh/07-operation/pic/agent-03.png rename to docs/zh/08-operation/pic/agent-03.png diff --git a/docs/zh/07-operation/pic/agent-04.png b/docs/zh/08-operation/pic/agent-04.png similarity index 100% rename from docs/zh/07-operation/pic/agent-04.png rename to docs/zh/08-operation/pic/agent-04.png diff --git a/docs/zh/07-operation/pic/datain-01.png b/docs/zh/08-operation/pic/datain-01.png similarity index 100% rename from docs/zh/07-operation/pic/datain-01.png rename to docs/zh/08-operation/pic/datain-01.png diff --git a/docs/zh/07-operation/pic/datain-02.png b/docs/zh/08-operation/pic/datain-02.png similarity index 100% rename from docs/zh/07-operation/pic/datain-02.png rename to docs/zh/08-operation/pic/datain-02.png diff --git a/docs/zh/07-operation/pic/datain-03.png b/docs/zh/08-operation/pic/datain-03.png similarity index 100% rename from docs/zh/07-operation/pic/datain-03.png rename to docs/zh/08-operation/pic/datain-03.png diff --git a/docs/zh/07-operation/pic/explorer-01-explorer-entry.jpeg b/docs/zh/08-operation/pic/explorer-01-explorer-entry.jpeg similarity index 100% rename from docs/zh/07-operation/pic/explorer-01-explorer-entry.jpeg rename to docs/zh/08-operation/pic/explorer-01-explorer-entry.jpeg diff --git a/docs/zh/07-operation/pic/explorer-02-createDbentry.jpeg b/docs/zh/08-operation/pic/explorer-02-createDbentry.jpeg similarity index 100% rename from docs/zh/07-operation/pic/explorer-02-createDbentry.jpeg rename to docs/zh/08-operation/pic/explorer-02-createDbentry.jpeg diff --git a/docs/zh/07-operation/pic/explorer-03-createDbPage.jpeg b/docs/zh/08-operation/pic/explorer-03-createDbPage.jpeg similarity index 100% rename from docs/zh/07-operation/pic/explorer-03-createDbPage.jpeg rename to docs/zh/08-operation/pic/explorer-03-createDbPage.jpeg diff --git a/docs/zh/07-operation/pic/explorer-04-createDbPage2.jpeg b/docs/zh/08-operation/pic/explorer-04-createDbPage2.jpeg similarity index 100% rename from docs/zh/07-operation/pic/explorer-04-createDbPage2.jpeg rename to docs/zh/08-operation/pic/explorer-04-createDbPage2.jpeg diff --git a/docs/zh/07-operation/pic/explorer-05-createDbtest01.jpeg b/docs/zh/08-operation/pic/explorer-05-createDbtest01.jpeg similarity index 100% rename from docs/zh/07-operation/pic/explorer-05-createDbtest01.jpeg rename to docs/zh/08-operation/pic/explorer-05-createDbtest01.jpeg diff --git a/docs/zh/07-operation/pic/explorer-06-sqlCreateDb.jpeg b/docs/zh/08-operation/pic/explorer-06-sqlCreateDb.jpeg similarity index 100% rename from docs/zh/07-operation/pic/explorer-06-sqlCreateDb.jpeg rename to docs/zh/08-operation/pic/explorer-06-sqlCreateDb.jpeg diff --git a/docs/zh/07-operation/pic/explorer-07-createDbtest02.jpeg b/docs/zh/08-operation/pic/explorer-07-createDbtest02.jpeg similarity index 100% rename from docs/zh/07-operation/pic/explorer-07-createDbtest02.jpeg rename to docs/zh/08-operation/pic/explorer-07-createDbtest02.jpeg diff --git a/docs/zh/07-operation/pic/explorer-08-createStbEntry.jpeg b/docs/zh/08-operation/pic/explorer-08-createStbEntry.jpeg similarity index 100% rename from docs/zh/07-operation/pic/explorer-08-createStbEntry.jpeg rename to docs/zh/08-operation/pic/explorer-08-createStbEntry.jpeg diff --git a/docs/zh/07-operation/pic/explorer-09-createStbPage.jpeg b/docs/zh/08-operation/pic/explorer-09-createStbPage.jpeg similarity index 100% rename from docs/zh/07-operation/pic/explorer-09-createStbPage.jpeg rename to docs/zh/08-operation/pic/explorer-09-createStbPage.jpeg diff --git a/docs/zh/07-operation/pic/explorer-10-createStbSucc.jpeg b/docs/zh/08-operation/pic/explorer-10-createStbSucc.jpeg similarity index 100% rename from docs/zh/07-operation/pic/explorer-10-createStbSucc.jpeg rename to docs/zh/08-operation/pic/explorer-10-createStbSucc.jpeg diff --git a/docs/zh/07-operation/pic/explorer-11-viewStableEntry.jpeg b/docs/zh/08-operation/pic/explorer-11-viewStableEntry.jpeg similarity index 100% rename from docs/zh/07-operation/pic/explorer-11-viewStableEntry.jpeg rename to docs/zh/08-operation/pic/explorer-11-viewStableEntry.jpeg diff --git a/docs/zh/07-operation/pic/explorer-12-viewStableInfo.jpeg b/docs/zh/08-operation/pic/explorer-12-viewStableInfo.jpeg similarity index 100% rename from docs/zh/07-operation/pic/explorer-12-viewStableInfo.jpeg rename to docs/zh/08-operation/pic/explorer-12-viewStableInfo.jpeg diff --git a/docs/zh/07-operation/pic/explorer-13-editStableEntry.jpeg b/docs/zh/08-operation/pic/explorer-13-editStableEntry.jpeg similarity index 100% rename from docs/zh/07-operation/pic/explorer-13-editStableEntry.jpeg rename to docs/zh/08-operation/pic/explorer-13-editStableEntry.jpeg diff --git a/docs/zh/07-operation/pic/explorer-14-editStableInfo.jpeg b/docs/zh/08-operation/pic/explorer-14-editStableInfo.jpeg similarity index 100% rename from docs/zh/07-operation/pic/explorer-14-editStableInfo.jpeg rename to docs/zh/08-operation/pic/explorer-14-editStableInfo.jpeg diff --git a/docs/zh/07-operation/pic/explorer-15-delStb.jpeg b/docs/zh/08-operation/pic/explorer-15-delStb.jpeg similarity index 100% rename from docs/zh/07-operation/pic/explorer-15-delStb.jpeg rename to docs/zh/08-operation/pic/explorer-15-delStb.jpeg diff --git a/docs/zh/07-operation/pic/explorer-16-sqlEditor.jpeg b/docs/zh/08-operation/pic/explorer-16-sqlEditor.jpeg similarity index 100% rename from docs/zh/07-operation/pic/explorer-16-sqlEditor.jpeg rename to docs/zh/08-operation/pic/explorer-16-sqlEditor.jpeg diff --git a/docs/zh/07-operation/pic/explorer-17-favoritesAdd.png b/docs/zh/08-operation/pic/explorer-17-favoritesAdd.png similarity index 100% rename from docs/zh/07-operation/pic/explorer-17-favoritesAdd.png rename to docs/zh/08-operation/pic/explorer-17-favoritesAdd.png diff --git a/docs/zh/07-operation/pic/explorer-18-favoritesAddPublic.png b/docs/zh/08-operation/pic/explorer-18-favoritesAddPublic.png similarity index 100% rename from docs/zh/07-operation/pic/explorer-18-favoritesAddPublic.png rename to docs/zh/08-operation/pic/explorer-18-favoritesAddPublic.png diff --git a/docs/zh/07-operation/pic/explorer-19-favoritesPublic.png b/docs/zh/08-operation/pic/explorer-19-favoritesPublic.png similarity index 100% rename from docs/zh/07-operation/pic/explorer-19-favoritesPublic.png rename to docs/zh/08-operation/pic/explorer-19-favoritesPublic.png diff --git a/docs/zh/07-operation/pic/explorer-20-favoritesCancelPublic.png b/docs/zh/08-operation/pic/explorer-20-favoritesCancelPublic.png similarity index 100% rename from docs/zh/07-operation/pic/explorer-20-favoritesCancelPublic.png rename to docs/zh/08-operation/pic/explorer-20-favoritesCancelPublic.png diff --git a/docs/zh/07-operation/pic/explorer-21-favoritesSearch.png b/docs/zh/08-operation/pic/explorer-21-favoritesSearch.png similarity index 100% rename from docs/zh/07-operation/pic/explorer-21-favoritesSearch.png rename to docs/zh/08-operation/pic/explorer-21-favoritesSearch.png diff --git a/docs/zh/07-operation/pic/explorer-22-favoritesDelete.png b/docs/zh/08-operation/pic/explorer-22-favoritesDelete.png similarity index 100% rename from docs/zh/07-operation/pic/explorer-22-favoritesDelete.png rename to docs/zh/08-operation/pic/explorer-22-favoritesDelete.png diff --git a/docs/zh/07-operation/pic/explorer-23-favoritesNotes.png b/docs/zh/08-operation/pic/explorer-23-favoritesNotes.png similarity index 100% rename from docs/zh/07-operation/pic/explorer-23-favoritesNotes.png rename to docs/zh/08-operation/pic/explorer-23-favoritesNotes.png diff --git a/docs/zh/07-operation/pic/management-01-importInfo.jpeg b/docs/zh/08-operation/pic/management-01-importInfo.jpeg similarity index 100% rename from docs/zh/07-operation/pic/management-01-importInfo.jpeg rename to docs/zh/08-operation/pic/management-01-importInfo.jpeg diff --git a/docs/zh/07-operation/pic/management-01-slowsql.jpeg b/docs/zh/08-operation/pic/management-01-slowsql.jpeg similarity index 100% rename from docs/zh/07-operation/pic/management-01-slowsql.jpeg rename to docs/zh/08-operation/pic/management-01-slowsql.jpeg diff --git a/docs/zh/07-operation/pic/management-01-systemEntry.jpeg b/docs/zh/08-operation/pic/management-01-systemEntry.jpeg similarity index 100% rename from docs/zh/07-operation/pic/management-01-systemEntry.jpeg rename to docs/zh/08-operation/pic/management-01-systemEntry.jpeg diff --git a/docs/zh/07-operation/pic/management-02-addUser.jpeg b/docs/zh/08-operation/pic/management-02-addUser.jpeg similarity index 100% rename from docs/zh/07-operation/pic/management-02-addUser.jpeg rename to docs/zh/08-operation/pic/management-02-addUser.jpeg diff --git a/docs/zh/07-operation/pic/management-02-addUserSucc.jpeg b/docs/zh/08-operation/pic/management-02-addUserSucc.jpeg similarity index 100% rename from docs/zh/07-operation/pic/management-02-addUserSucc.jpeg rename to docs/zh/08-operation/pic/management-02-addUserSucc.jpeg diff --git a/docs/zh/07-operation/pic/management-02-slowsql.jpeg b/docs/zh/08-operation/pic/management-02-slowsql.jpeg similarity index 100% rename from docs/zh/07-operation/pic/management-02-slowsql.jpeg rename to docs/zh/08-operation/pic/management-02-slowsql.jpeg diff --git a/docs/zh/07-operation/pic/management-04-backupEntry.jpeg b/docs/zh/08-operation/pic/management-04-backupEntry.jpeg similarity index 100% rename from docs/zh/07-operation/pic/management-04-backupEntry.jpeg rename to docs/zh/08-operation/pic/management-04-backupEntry.jpeg diff --git a/docs/zh/07-operation/pic/management-04-backupModal.jpeg b/docs/zh/08-operation/pic/management-04-backupModal.jpeg similarity index 100% rename from docs/zh/07-operation/pic/management-04-backupModal.jpeg rename to docs/zh/08-operation/pic/management-04-backupModal.jpeg diff --git a/docs/zh/07-operation/pic/management-06-cluster.jpeg b/docs/zh/08-operation/pic/management-06-cluster.jpeg similarity index 100% rename from docs/zh/07-operation/pic/management-06-cluster.jpeg rename to docs/zh/08-operation/pic/management-06-cluster.jpeg diff --git a/docs/zh/07-operation/pic/management-07-license.jpeg b/docs/zh/08-operation/pic/management-07-license.jpeg similarity index 100% rename from docs/zh/07-operation/pic/management-07-license.jpeg rename to docs/zh/08-operation/pic/management-07-license.jpeg diff --git a/docs/zh/07-operation/pic/management-08-activationCode.jpeg b/docs/zh/08-operation/pic/management-08-activationCode.jpeg similarity index 100% rename from docs/zh/07-operation/pic/management-08-activationCode.jpeg rename to docs/zh/08-operation/pic/management-08-activationCode.jpeg diff --git a/docs/zh/07-operation/pic/management-09-audit.jpeg b/docs/zh/08-operation/pic/management-09-audit.jpeg similarity index 100% rename from docs/zh/07-operation/pic/management-09-audit.jpeg rename to docs/zh/08-operation/pic/management-09-audit.jpeg diff --git a/docs/zh/07-operation/pic/management-10-replicationEntry.jpeg b/docs/zh/08-operation/pic/management-10-replicationEntry.jpeg similarity index 100% rename from docs/zh/07-operation/pic/management-10-replicationEntry.jpeg rename to docs/zh/08-operation/pic/management-10-replicationEntry.jpeg diff --git a/docs/zh/07-operation/pic/management-11-replicationModal.jpeg b/docs/zh/08-operation/pic/management-11-replicationModal.jpeg similarity index 100% rename from docs/zh/07-operation/pic/management-11-replicationModal.jpeg rename to docs/zh/08-operation/pic/management-11-replicationModal.jpeg diff --git a/docs/zh/07-operation/pic/management-12-licenseNew.jpeg b/docs/zh/08-operation/pic/management-12-licenseNew.jpeg similarity index 100% rename from docs/zh/07-operation/pic/management-12-licenseNew.jpeg rename to docs/zh/08-operation/pic/management-12-licenseNew.jpeg diff --git a/docs/zh/07-operation/pic/management-13-activationCodeNew.jpeg b/docs/zh/08-operation/pic/management-13-activationCodeNew.jpeg similarity index 100% rename from docs/zh/07-operation/pic/management-13-activationCodeNew.jpeg rename to docs/zh/08-operation/pic/management-13-activationCodeNew.jpeg diff --git a/docs/zh/07-operation/pic/monitor-01.jpg b/docs/zh/08-operation/pic/monitor-01.jpg similarity index 100% rename from docs/zh/07-operation/pic/monitor-01.jpg rename to docs/zh/08-operation/pic/monitor-01.jpg diff --git a/docs/zh/07-operation/pic/monitor-02.jpg b/docs/zh/08-operation/pic/monitor-02.jpg similarity index 100% rename from docs/zh/07-operation/pic/monitor-02.jpg rename to docs/zh/08-operation/pic/monitor-02.jpg diff --git a/docs/zh/07-operation/pic/monitor-03.png b/docs/zh/08-operation/pic/monitor-03.png similarity index 100% rename from docs/zh/07-operation/pic/monitor-03.png rename to docs/zh/08-operation/pic/monitor-03.png diff --git a/docs/zh/07-operation/pic/monitor-04.jpg b/docs/zh/08-operation/pic/monitor-04.jpg similarity index 100% rename from docs/zh/07-operation/pic/monitor-04.jpg rename to docs/zh/08-operation/pic/monitor-04.jpg diff --git a/docs/zh/07-operation/pic/monitor-05.png b/docs/zh/08-operation/pic/monitor-05.png similarity index 100% rename from docs/zh/07-operation/pic/monitor-05.png rename to docs/zh/08-operation/pic/monitor-05.png diff --git a/docs/zh/07-operation/pic/monitor-06.jpg b/docs/zh/08-operation/pic/monitor-06.jpg similarity index 100% rename from docs/zh/07-operation/pic/monitor-06.jpg rename to docs/zh/08-operation/pic/monitor-06.jpg diff --git a/docs/zh/07-operation/pic/monitor-07.png b/docs/zh/08-operation/pic/monitor-07.png similarity index 100% rename from docs/zh/07-operation/pic/monitor-07.png rename to docs/zh/08-operation/pic/monitor-07.png diff --git a/docs/zh/07-operation/pic/monitor-08.png b/docs/zh/08-operation/pic/monitor-08.png similarity index 100% rename from docs/zh/07-operation/pic/monitor-08.png rename to docs/zh/08-operation/pic/monitor-08.png diff --git a/docs/zh/07-operation/pic/monitor-09.jpg b/docs/zh/08-operation/pic/monitor-09.jpg similarity index 100% rename from docs/zh/07-operation/pic/monitor-09.jpg rename to docs/zh/08-operation/pic/monitor-09.jpg diff --git a/docs/zh/07-operation/pic/monitor-10.jpg b/docs/zh/08-operation/pic/monitor-10.jpg similarity index 100% rename from docs/zh/07-operation/pic/monitor-10.jpg rename to docs/zh/08-operation/pic/monitor-10.jpg diff --git a/docs/zh/07-operation/pic/stream-01-streamEntry.jpeg b/docs/zh/08-operation/pic/stream-01-streamEntry.jpeg similarity index 100% rename from docs/zh/07-operation/pic/stream-01-streamEntry.jpeg rename to docs/zh/08-operation/pic/stream-01-streamEntry.jpeg diff --git a/docs/zh/07-operation/pic/stream-02-createStreamEntry.jpeg b/docs/zh/08-operation/pic/stream-02-createStreamEntry.jpeg similarity index 100% rename from docs/zh/07-operation/pic/stream-02-createStreamEntry.jpeg rename to docs/zh/08-operation/pic/stream-02-createStreamEntry.jpeg diff --git a/docs/zh/07-operation/pic/stream-03-createStreamWizard.jpeg b/docs/zh/08-operation/pic/stream-03-createStreamWizard.jpeg similarity index 100% rename from docs/zh/07-operation/pic/stream-03-createStreamWizard.jpeg rename to docs/zh/08-operation/pic/stream-03-createStreamWizard.jpeg diff --git a/docs/zh/07-operation/pic/stream-04-createStreamWizard.jpeg b/docs/zh/08-operation/pic/stream-04-createStreamWizard.jpeg similarity index 100% rename from docs/zh/07-operation/pic/stream-04-createStreamWizard.jpeg rename to docs/zh/08-operation/pic/stream-04-createStreamWizard.jpeg diff --git a/docs/zh/07-operation/pic/stream-05-createStreamSucc1.jpeg b/docs/zh/08-operation/pic/stream-05-createStreamSucc1.jpeg similarity index 100% rename from docs/zh/07-operation/pic/stream-05-createStreamSucc1.jpeg rename to docs/zh/08-operation/pic/stream-05-createStreamSucc1.jpeg diff --git a/docs/zh/07-operation/pic/stream-06-createStreamSql.jpeg b/docs/zh/08-operation/pic/stream-06-createStreamSql.jpeg similarity index 100% rename from docs/zh/07-operation/pic/stream-06-createStreamSql.jpeg rename to docs/zh/08-operation/pic/stream-06-createStreamSql.jpeg diff --git a/docs/zh/07-operation/pic/stream-07-createStreamSucc2.jpeg b/docs/zh/08-operation/pic/stream-07-createStreamSucc2.jpeg similarity index 100% rename from docs/zh/07-operation/pic/stream-07-createStreamSucc2.jpeg rename to docs/zh/08-operation/pic/stream-07-createStreamSucc2.jpeg diff --git a/docs/zh/07-operation/pic/topic-01-dataSubscription.jpeg b/docs/zh/08-operation/pic/topic-01-dataSubscription.jpeg similarity index 100% rename from docs/zh/07-operation/pic/topic-01-dataSubscription.jpeg rename to docs/zh/08-operation/pic/topic-01-dataSubscription.jpeg diff --git a/docs/zh/07-operation/pic/topic-02-addTopic.jpeg b/docs/zh/08-operation/pic/topic-02-addTopic.jpeg similarity index 100% rename from docs/zh/07-operation/pic/topic-02-addTopic.jpeg rename to docs/zh/08-operation/pic/topic-02-addTopic.jpeg diff --git a/docs/zh/07-operation/pic/topic-03-addTopicWizard.jpeg b/docs/zh/08-operation/pic/topic-03-addTopicWizard.jpeg similarity index 100% rename from docs/zh/07-operation/pic/topic-03-addTopicWizard.jpeg rename to docs/zh/08-operation/pic/topic-03-addTopicWizard.jpeg diff --git a/docs/zh/07-operation/pic/topic-05-addTopicSucc1.jpeg b/docs/zh/08-operation/pic/topic-05-addTopicSucc1.jpeg similarity index 100% rename from docs/zh/07-operation/pic/topic-05-addTopicSucc1.jpeg rename to docs/zh/08-operation/pic/topic-05-addTopicSucc1.jpeg diff --git a/docs/zh/07-operation/pic/topic-06-addTopicSql.jpeg b/docs/zh/08-operation/pic/topic-06-addTopicSql.jpeg similarity index 100% rename from docs/zh/07-operation/pic/topic-06-addTopicSql.jpeg rename to docs/zh/08-operation/pic/topic-06-addTopicSql.jpeg diff --git a/docs/zh/07-operation/pic/topic-07-addTopicsSucc2.jpeg b/docs/zh/08-operation/pic/topic-07-addTopicsSucc2.jpeg similarity index 100% rename from docs/zh/07-operation/pic/topic-07-addTopicsSucc2.jpeg rename to docs/zh/08-operation/pic/topic-07-addTopicsSucc2.jpeg diff --git a/docs/zh/07-operation/pic/topic-08-shareTopic.jpeg b/docs/zh/08-operation/pic/topic-08-shareTopic.jpeg similarity index 100% rename from docs/zh/07-operation/pic/topic-08-shareTopic.jpeg rename to docs/zh/08-operation/pic/topic-08-shareTopic.jpeg diff --git a/docs/zh/07-operation/pic/topic-09-sample.jpeg b/docs/zh/08-operation/pic/topic-09-sample.jpeg similarity index 100% rename from docs/zh/07-operation/pic/topic-09-sample.jpeg rename to docs/zh/08-operation/pic/topic-09-sample.jpeg diff --git a/docs/zh/07-operation/pic/topic-10-consumer.jpeg b/docs/zh/08-operation/pic/topic-10-consumer.jpeg similarity index 100% rename from docs/zh/07-operation/pic/topic-10-consumer.jpeg rename to docs/zh/08-operation/pic/topic-10-consumer.jpeg diff --git a/docs/zh/08-operation/tdengine-topology.png b/docs/zh/08-operation/tdengine-topology.png new file mode 100644 index 0000000000..f31443ef7f Binary files /dev/null and b/docs/zh/08-operation/tdengine-topology.png differ diff --git a/docs/zh/14-reference/01-components/01-taosd.md b/docs/zh/14-reference/01-components/01-taosd.md index ff6b27092d..fbf086bf6b 100644 --- a/docs/zh/14-reference/01-components/01-taosd.md +++ b/docs/zh/14-reference/01-components/01-taosd.md @@ -33,7 +33,6 @@ taosd 命令行参数如下 | secondEp | taosd 启动时,如果 firstEp 连接不上,尝试连接集群中第二个 dnode 的 endpoint,缺省值:无 | | fqdn | 启动 taosd 后所监听的服务地址,缺省值:所在服务器上配置的第一个 hostname | | serverPort | 启动 taosd 后所监听的端口,缺省值:6030 | -| maxShellConns | 一个 dnode 容许的连接数,取值范围为 10-5000000,缺省值:5000 | | numOfRpcSessions | 允许一个客户端能创建的最大连接数,取值范围 100-100000,缺省值:30000 | | timeToGetAvailableConn | 获得可用连接的最长等待时间,取值范围 10-50000000,单位为毫秒,缺省值:500000 | @@ -433,3 +432,30 @@ taosd 会将监控指标上报给 taosKeeper,这些监控指标会被 taosKeep | duration | VARCHAR | TAG | sql执行耗时,取值范围:3-10s,10-100s,100-1000s,1000s- | | cluster\_id | VARCHAR | TAG | cluster id | +## 日志相关 + +TDengine 通过日志文件记录系统运行状态,帮助用户监控系统运行情况,排查问题,这里主要介绍 taosc 和 taosd 两个系统日志的相关说明。 + +TDengine 的日志文件主要包括普通日志和慢日志两种类型。 + +1. 普通日志行为说明 + 1. 同一台机器上可以起多个客户端进程,所以客户端日志命名方式为 taoslogX.Y,其中 X 为序号,为空或者 0 到 9,Y 为后缀 0 或者 1。 + 2. 同一台机器上只能有一个服务端进程。所以服务端日志命名方式为 taosdlog.Y,其中 Y 为后缀, 0 或者 1。 + + 序号和后缀确定规则如下(假设日志路径为 /var/log/taos/): + 1. 确定序号:使用 10 个序号作为日志命名方式,/var/log/taos/taoslog0.Y - /var/log/taos/taoslog9.Y,依次检测每个序号是否使用,找到第一个没使用的序号作为该进程的日志文件使用的序号。 如果 10 个序号都被进程使用,不使用序号,即 /var/log/taos/taoslog.Y,进程都往相同的文件里写(序号为空)。 + 2. 确定后缀:0 或者 1。比如确定序号为 3,备选的日志文件名就为 /var/log/taos/taoslog3.0 /var/log/taos/taoslog3.1。如果两个文件都不存在用后缀 0,一个存在一个不存在,用存在的后缀。两个都存在,用修改时间最近的那个后缀。 + 3. 如果日志文件超过配置的条数 numOfLogLines,会切换后缀名,继续写日志,比如/var/log/taos/taoslog3.0 写够了,切换到 /var/log/taos/taoslog3.1 继续写日志。/var/log/taos/taoslog3.0 会添加时间戳后缀重命名并压缩存储(异步线程操作)。 + 4. 通过配置 logKeepDays 控制日志文件保存几天,几天之外的日志会被删除。比如配置为 1,则一天之前的日志会在新日志压缩存储时检测删除。不是自然天。 + +系统除了记录普通日志以外,对于执行时间超过配置时间的 SQL 语句,会被记录到慢日志中。慢日志文件主要用于分析系统性能,排查性能问题。 + +2. 慢日志行为说明 + 1. 慢日志一方面会记录到本地慢日志文件中,另一方面会通过 taosAdapter 发送到 taosKeeper 进行结构化存储(需打开 monitorr 开关)。 + 2. 慢日志文件存储规则为: + 1. 慢日志文件一天一个,如果当天没有慢日志,没有当天的文件。 + 2. 文件名为 taosSlowLog.yyyy-mm-dd(taosSlowLog.2024-08-02),日志存储路径通过 logDir 配置。 + 3. 多个客户端的日志存储在相应日志路径下的同一个 taosSlowLog.yyyy.mm.dd 文件里。 + 4. 慢日志文件不自动删除,不压缩。 + 5. 使用和普通日志文件相同的三个参数 logDir, minimalLogDirGB, asyncLog。另外两个参数 numOfLogLines,logKeepDays 不适用于慢日志。 + \ No newline at end of file diff --git a/docs/zh/14-reference/01-components/08-taos-cli.md b/docs/zh/14-reference/01-components/08-taos-cli.md index 3eea24ac7b..c388e7edda 100644 --- a/docs/zh/14-reference/01-components/08-taos-cli.md +++ b/docs/zh/14-reference/01-components/08-taos-cli.md @@ -82,7 +82,7 @@ taos -h h1.taos.com -s "use db; show tables;" ## 配置文件 -也可以通过配置文件中的参数设置来控制 TDengine CLI 的行为。可用配置参数请参考[客户端配置](../taosc) +也可以通过配置文件中的参数设置来控制 TDengine CLI 的行为。可用配置参数请参考[客户端配置](../../components/taosc) ## TDengine CLI 小技巧 diff --git a/docs/zh/14-reference/02-tools/08-taos-cli.md b/docs/zh/14-reference/02-tools/08-taos-cli.md new file mode 100644 index 0000000000..c388e7edda --- /dev/null +++ b/docs/zh/14-reference/02-tools/08-taos-cli.md @@ -0,0 +1,102 @@ +--- +title: TDengine CLI 参考手册 +sidebar_label: taos +toc_max_heading_level: 4 +--- + +TDengine 命令行程序(以下简称 TDengine CLI)是用户操作 TDengine 实例并与之交互的最简洁最常用的方式。 使用前需要安装 TDengine Server 安装包或 TDengine Client 安装包。 + +## 启动 + +要进入 TDengine CLI,您只要在终端执行 `taos` 即可。 + +```bash +taos +``` + +如果连接服务成功,将会打印出欢迎消息和版本信息。如果失败,则会打印错误消息。 + +TDengine CLI 的提示符号如下: + +```shell +taos> +``` + +进入 TDengine CLI 后,你可执行各种 SQL 语句,包括插入、查询以及各种管理命令。 + +## 执行 SQL 脚本 + +在 TDengine CLI 里可以通过 `source` 命令来运行脚本文件中的多条 SQL 命令。 + +```sql +taos> source ; +``` + +## 在线修改显示字符宽度 + +可以在 TDengine CLI 里使用如下命令调整字符显示宽度 + +```sql +taos> SET MAX_BINARY_DISPLAY_WIDTH ; +``` + +如显示的内容后面以 ... 结尾时,表示该内容已被截断,可通过本命令修改显示字符宽度以显示完整的内容。 + +## 命令行参数 + +您可通过配置命令行参数来改变 TDengine CLI 的行为。以下为常用的几个命令行参数: + +- -h HOST: 要连接的 TDengine 服务端所在服务器的 FQDN, 默认为连接本地服务 +- -P PORT: 指定服务端所用端口号 +- -u USER: 连接时使用的用户名 +- -p PASSWORD: 连接服务端时使用的密码 +- -?, --help: 打印出所有命令行参数 + +还有更多其他参数: + +- -a AUTHSTR: 连接服务端的授权信息 +- -A: 通过用户名和密码计算授权信息 +- -B: 设置 BI 工具显示模式,设置后所有输出都遵循 BI 工具的格式进行输出 +- -c CONFIGDIR: 指定配置文件目录,Linux 环境下默认为 `/etc/taos`,该目录下的配置文件默认名称为 `taos.cfg` +- -C: 打印 -c 指定的目录中 `taos.cfg` 的配置参数 +- -d DATABASE: 指定连接到服务端时使用的数据库 +- -E dsn: 使用 WebSocket DSN 连接云服务或者提供 WebSocket 连接的服务端 +- -f FILE: 以非交互模式执行 SQL 脚本文件。文件中一个 SQL 语句只能占一行 +- -k: 测试服务端运行状态,0: unavailable,1: network ok,2: service ok,3: service degraded,4: exiting +- -l PKTLEN: 网络测试时使用的测试包大小 +- -n NETROLE: 网络连接测试时的测试范围,默认为 `client`, 可选值为 `client`、`server` +- -N PKTNUM: 网络测试时使用的测试包数量 +- -r: 将时间输出出无符号 64 位整数类型(即 C 语音中 uint64_t) +- -R: 使用 RESTful 模式连接服务端 +- -s COMMAND: 以非交互模式执行的 SQL 命令 +- -t: 测试服务端启动状态,状态同-k +- -w DISPLAYWIDTH: 客户端列显示宽度 +- -z TIMEZONE: 指定时区,默认为本地时区 +- -V: 打印出当前版本号 + +示例: + +```bash +taos -h h1.taos.com -s "use db; show tables;" +``` + +## 配置文件 + +也可以通过配置文件中的参数设置来控制 TDengine CLI 的行为。可用配置参数请参考[客户端配置](../../components/taosc) + +## TDengine CLI 小技巧 + +- 可以使用上下光标键查看历史输入的指令 +- 在 TDengine CLI 中使用 `alter user` 命令可以修改用户密码,缺省密码为 `taosdata` +- Ctrl+C 中止正在进行中的查询 +- 执行 `RESET QUERY CACHE` 可清除本地表 Schema 的缓存 +- 批量执行 SQL 语句。可以将一系列的 TDengine CLI 命令(以英文 ; 结尾,每个 SQL 语句为一行)按行存放在文件里,在 TDengine CLI 里执行命令 `source ` 自动执行该文件里所有的 SQL 语句 +- 输入 `q` 或 `quit` 或 `exit` 回车,可以退出 TDengine CLI + +## TDengine CLI 导出查询结果到文件中 + +- 可以使用符号 “>>” 导出查询结果到某个文件中,语法为: sql 查询语句 >> ‘输出文件名’; 输出文件如果不写路径的话,将输出至当前目录下。如 select * from d0 >> ‘/root/d0.csv’; 将把查询结果输出到 /root/d0.csv 中。 + +## TDengine CLI 导入文件中的数据到表中 + +- 可以使用 insert into table_name file '输入文件名',把上一步中导出的数据文件再导入到指定表中。如 insert into d0 file '/root/d0.csv'; 表示把上面导出的数据全部再导致至 d0 表中。 diff --git a/docs/zh/14-reference/02-tools/09-taosdump.md b/docs/zh/14-reference/02-tools/09-taosdump.md new file mode 100644 index 0000000000..7afe8721ee --- /dev/null +++ b/docs/zh/14-reference/02-tools/09-taosdump.md @@ -0,0 +1,127 @@ +--- +title: taosdump 参考手册 +sidebar_label: taosdump +toc_max_heading_level: 4 +--- + +taosdump 是一个支持从运行中的 TDengine 集群备份数据并将备份的数据恢复到相同或另一个运行中的 TDengine 集群中的工具应用程序。 + +taosdump 可以用数据库、超级表或普通表作为逻辑数据单元进行备份,也可以对数据库、超级 +表和普通表中指定时间段内的数据记录进行备份。使用时可以指定数据备份的目录路径,如果 +不指定位置,taosdump 默认会将数据备份到当前目录。 + +如果指定的位置已经有数据文件,taosdump 会提示用户并立即退出,避免数据被覆盖。这意味着同一路径只能被用于一次备份。 +如果看到相关提示,请小心操作。 + +taosdump 是一个逻辑备份工具,它不应被用于备份任何原始数据、环境设置、 +硬件信息、服务端配置或集群的拓扑结构。taosdump 使用 +[ Apache AVRO ](https://avro.apache.org/)作为数据文件格式来存储备份数据。 + +## 安装 + +taosdump 有两种安装方式: + +- 安装 taosTools 官方安装包, 请从[发布历史页面](https://docs.taosdata.com/releases/tools/)页面找到 taosTools 并下载安装。 + +- 单独编译 taos-tools 并安装, 详情请参考 [taos-tools](https://github.com/taosdata/taos-tools) 仓库。 + +## 常用使用场景 + +### taosdump 备份数据 + +1. 备份所有数据库:指定 `-A` 或 `--all-databases` 参数; +2. 备份多个指定数据库:使用 `-D db1,db2,...` 参数; +3. 备份指定数据库中的某些超级表或普通表:使用 `dbname stbname1 stbname2 tbname1 tbname2 ...` 参数,注意这种输入序列第一个参数为数据库名称,且只支持一个数据库,第二个和之后的参数为该数据库中的超级表或普通表名称,中间以空格分隔; +4. 备份系统 log 库:TDengine 集群通常会包含一个系统数据库,名为 `log`,这个数据库内的数据为 TDengine 自我运行的数据,taosdump 默认不会对 log 库进行备份。如果有特定需求对 log 库进行备份,可以使用 `-a` 或 `--allow-sys` 命令行参数。 +5. “宽容”模式备份:taosdump 1.4.1 之后的版本提供 `-n` 参数和 `-L` 参数,用于备份数据时不使用转义字符和“宽容”模式,可以在表名、列名、标签名没使用转义字符的情况下减少备份数据时间和备份数据占用空间。如果不确定符合使用 `-n` 和 `-L` 条件时请使用默认参数进行“严格”模式进行备份。转义字符的说明请参考[官方文档](../../taos-sql/escape)。 + +:::tip +- taosdump 1.4.1 之后的版本提供 `-I` 参数,用于解析 avro 文件 schema 和数据,如果指定 `-s` 参数将只解析 schema。 +- taosdump 1.4.2 之后的备份使用 `-B` 参数指定的批次数,默认值为 16384,如果在某些环境下由于网络速度或磁盘性能不足导致 "Error actual dump .. batch .." 可以通过 `-B` 参数调整为更小的值进行尝试。 +- taosdump 的导出不支持中断恢复,所以当进程意外终止后,正确的处理方式是删除当前已导出或生成的所有相关文件。 +- taosdump 的导入支持中断恢复,但是当进程重新启动时,会收到一些“表已经存在”的提示,可以忽视。 + +::: + +### taosdump 恢复数据 + +恢复指定路径下的数据文件:使用 `-i` 参数加上数据文件所在路径。如前面提及,不应该使用同一个目录备份不同数据集合,也不应该在同一路径多次备份同一数据集,否则备份数据会造成覆盖或多次备份。 + +:::tip +taosdump 内部使用 TDengine stmt binding API 进行恢复数据的写入,为提高数据恢复性能,目前使用 16384 为一次写入批次。如果备份数据中有比较多列数据,可能会导致产生 "WAL size exceeds limit" 错误,此时可以通过使用 `-B` 参数调整为一个更小的值进行尝试。 + +::: + +## 详细命令行参数列表 + +以下为 taosdump 详细命令行参数列表: + +``` +Usage: taosdump [OPTION...] dbname [tbname ...] + or: taosdump [OPTION...] --databases db1,db2,... + or: taosdump [OPTION...] --all-databases + or: taosdump [OPTION...] -i inpath + or: taosdump [OPTION...] -o outpath + + -h, --host=HOST Server host dumping data from. Default is + localhost. + -p, --password User password to connect to server. Default is + taosdata. + -P, --port=PORT Port to connect + -u, --user=USER User name used to connect to server. Default is + root. + -c, --config-dir=CONFIG_DIR Configure directory. Default is /etc/taos + -i, --inpath=INPATH Input file path. + -o, --outpath=OUTPATH Output file path. + -r, --resultFile=RESULTFILE DumpOut/In Result file path and name. + -a, --allow-sys Allow to dump system database + -A, --all-databases Dump all databases. + -D, --databases=DATABASES Dump inputted databases. Use comma to separate + databases' name. + -e, --escape-character Use escaped character for database name + -N, --without-property Dump database without its properties. + -s, --schemaonly Only dump tables' schema. + -d, --avro-codec=snappy Choose an avro codec among null, deflate, snappy, + and lzma. + -S, --start-time=START_TIME Start time to dump. Either epoch or + ISO8601/RFC3339 format is acceptable. ISO8601 + format example: 2017-10-01T00:00:00.000+0800 or + 2017-10-0100:00:00:000+0800 or '2017-10-01 + 00:00:00.000+0800' + -E, --end-time=END_TIME End time to dump. Either epoch or ISO8601/RFC3339 + format is acceptable. ISO8601 format example: + 2017-10-01T00:00:00.000+0800 or + 2017-10-0100:00:00.000+0800 or '2017-10-01 + 00:00:00.000+0800' + -B, --data-batch=DATA_BATCH Number of data per query/insert statement when + backup/restore. Default value is 16384. If you see + 'error actual dump .. batch ..' when backup or if + you see 'WAL size exceeds limit' error when + restore, please adjust the value to a smaller one + and try. The workable value is related to the + length of the row and type of table schema. + -I, --inspect inspect avro file content and print on screen + -L, --loose-mode Using loose mode if the table name and column name + use letter and number only. Default is NOT. + -n, --no-escape No escape char '`'. Default is using it. + -Q, --dot-replace Repalce dot character with underline character in + the table name.(Version 2.5.3) + -T, --thread-num=THREAD_NUM Number of thread for dump in file. Default is + 8. + -C, --cloud=CLOUD_DSN specify a DSN to access TDengine cloud service + -R, --restful Use RESTful interface to connect TDengine + -t, --timeout=SECONDS The timeout seconds for websocket to interact. + -g, --debug Print debug info. + -?, --help Give this help list + --usage Give a short usage message + -V, --version Print program version + -W, --rename=RENAME-LIST Rename database name with new name during + importing data. RENAME-LIST: + "db1=newDB1|db2=newDB2" means rename db1 to newDB1 + and rename db2 to newDB2 (Version 2.5.4) + +Mandatory or optional arguments to long options are also mandatory or optional +for any corresponding short options. + +Report bugs to . +``` diff --git a/docs/zh/14-reference/02-tools/10-taosbenchmark.md b/docs/zh/14-reference/02-tools/10-taosbenchmark.md new file mode 100644 index 0000000000..3f15d6b8e3 --- /dev/null +++ b/docs/zh/14-reference/02-tools/10-taosbenchmark.md @@ -0,0 +1,485 @@ +--- +title: taosBenchmark 参考手册 +sidebar_label: taosBenchmark +toc_max_heading_level: 4 +--- + +taosBenchmark (曾用名 taosdemo ) 是一个用于测试 TDengine 产品性能的工具。taosBenchmark 可以测试 TDengine 的插入、查询和订阅等功能的性能,它可以模拟由大量设备产生的大量数据,还可以灵活地控制数据库、超级表、标签列的数量和类型、数据列的数量和类型、子表的数量、每张子表的数据量、插入数据的时间间隔、taosBenchmark 的工作线程数量、是否以及如何插入乱序数据等。为了兼容过往用户的使用习惯,安装包提供 了 taosdemo 作为 taosBenchmark 的软链接。 + +## 安装 + +taosBenchmark 有两种安装方式: + +- 安装 TDengine 官方安装包的同时会自动安装 taosBenchmark, 详情请参考[ TDengine 安装](../../../get-started/)。 + +- 单独编译 taos-tools 并安装, 详情请参考 [taos-tools](https://github.com/taosdata/taos-tools) 仓库。 + +## 运行 + +### 配置和运行方式 + +taosBenchmark 需要在操作系统的终端执行,该工具支持两种配置方式:[命令行参数](#命令行参数详解) 和 [JSON 配置文件](#配置文件参数详解)。这两种方式是互斥的,在使用配置文件时只能使用一个命令行参数 `-f ` 指定配置文件。在使用命令行参数运行 taosBenchmark 并控制其行为时则不能使用 `-f` 参数而要用其它参数来进行配置。除此之外,taosBenchmark 还提供了一种特殊的运行方式,即无参数运行。 + +taosBenchmark 支持对 TDengine 做完备的性能测试,其所支持的 TDengine 功能分为三大类:写入、查询和订阅。这三种功能之间是互斥的,每次运行 taosBenchmark 只能选择其中之一。值得注意的是,所要测试的功能类型在使用命令行配置方式时是不可配置的,命令行配置方式只能测试写入性能。若要测试 TDengine 的查询和订阅性能,必须使用配置文件的方式,通过配置文件中的参数 `filetype` 指定所要测试的功能类型。 + +**在运行 taosBenchmark 之前要确保 TDengine 集群已经在正确运行。** + +### 无命令行参数运行 + +执行下列命令即可快速体验 taosBenchmark 对 TDengine 进行基于默认配置的写入性能测试。 + +```bash +taosBenchmark +``` + +在无参数运行时,taosBenchmark 默认连接 `/etc/taos` 下指定的 TDengine 集群,并在 TDengine 中创建一个名为 test 的数据库,test 数据库下创建名为 meters 的一张超级表,超级表下创建 10000 张表,每张表中写入 10000 条记录。注意,如果已有 test 数据库,这个命令会先删除该数据库后建立一个全新的 test 数据库。 + +### 使用命令行配置参数运行 + +在使用命令行参数运行 taosBenchmark 并控制其行为时,`-f ` 参数不能使用。所有配置参数都必须通过命令行指定。以下是使用命令行方式测试 taosBenchmark 写入性能的一个示例。 + +```bash +taosBenchmark -I stmt -n 200 -t 100 +``` + +上面的命令 `taosBenchmark` 将创建一个名为`test`的数据库,在其中建立一张超级表`meters`,在该超级表中建立 100 张子表并使用参数绑定的方式为每张子表插入 200 条记录。 + +### 使用配置文件运行 + +taosBenchmark 安装包中提供了配置文件的示例,位于 `/examples/taosbenchmark-json` 下 + +使用如下命令行即可运行 taosBenchmark 并通过配置文件控制其行为。 + +```bash +taosBenchmark -f +``` + +**下面是几个配置文件的示例:** + +#### 插入场景 JSON 配置文件示例 + +
+insert.json + +```json +{{#include /taos-tools/example/insert.json}} +``` + +
+ +#### 查询场景 JSON 配置文件示例 + +
+query.json + +```json +{{#include /taos-tools/example/query.json}} +``` + +
+ +#### 订阅场景 JSON 配置文件示例 + +
+tmq.json + +```json +{{#include /taos-tools/example/tmq.json}} +``` + +
+ +## 命令行参数详解 + +- **-f/--file \** : + 要使用的 JSON 配置文件,由该文件指定所有参数,本参数与命令行其他参数不能同时使用。没有默认值。 + +- **-c/--config-dir \** : + TDengine 集群配置文件所在的目录,默认路径是 /etc/taos 。 + +- **-h/--host \** : + 指定要连接的 TDengine 服务端的 FQDN,默认值为 localhost 。 + +- **-P/--port \** : + 要连接的 TDengine 服务器的端口号,默认值为 6030 。 + +- **-I/--interface \** : + 插入模式,可选项有 taosc, rest, stmt, sml, sml-rest, 分别对应普通写入、restful 接口写入、参数绑定接口写入、schemaless 接口写入、restful schemaless 接口写入 (由 taosAdapter 提供)。默认值为 taosc。 + +- **-u/--user \** : + 用于连接 TDengine 服务端的用户名,默认为 root 。 + +- **-U/--supplement-insert ** : + 写入数据而不提前建数据库和表,默认关闭。 + +- **-p/--password \** : + 用于连接 TDengine 服务端的密码,默认值为 taosdata。 + +- **-o/--output \** : + 结果输出文件的路径,默认值为 ./output.txt。 + +- **-T/--thread \** : + 插入数据的线程数量,默认为 8 。 + +- **-B/--interlace-rows \** : + 启用交错插入模式并同时指定向每个子表每次插入的数据行数。交错插入模式是指依次向每张子表插入由本参数所指定的行数并重复这个过程,直到所有子表的数据都插入完成。默认值为 0, 即向一张子表完成数据插入后才会向下一张子表进行数据插入。 + +- **-i/--insert-interval \** : + 指定交错插入模式的插入间隔,单位为 ms,默认值为 0。 只有当 `-B/--interlace-rows` 大于 0 时才起作用。意味着数据插入线程在为每个子表插入隔行扫描记录后,会等待该值指定的时间间隔后再进行下一轮写入。 + +- **-r/--rec-per-req \** : + 每次向 TDengine 请求写入的数据行数,默认值为 30000 。 + +- **-t/--tables \** : + 指定子表的数量,默认为 10000 。 + +- **-S/--timestampstep \** : + 每个子表中插入数据的时间戳步长,单位是 ms,默认值是 1。 + +- **-n/--records \** : + 每个子表插入的记录数,默认值为 10000 。 + +- **-d/--database \** : + 所使用的数据库的名称,默认值为 test 。 + +- **-b/--data-type \** : + 超级表的数据列的类型。如果不使用则默认为有三个数据列,其类型分别为 FLOAT, INT, FLOAT 。 + +- **-l/--columns \** : + 超级表的数据列的总数量。如果同时设置了该参数和 `-b/--data-type`,则最后的结果列数为两者取大。如果本参数指定的数量大于 `-b/--data-type` 指定的列数,则未指定的列类型默认为 INT, 例如: `-l 5 -b float,double`, 那么最后的列为 `FLOAT,DOUBLE,INT,INT,INT`。如果 columns 指定的数量小于或等于 `-b/--data-type` 指定的列数,则结果为 `-b/--data-type` 指定的列和类型,例如: `-l 3 -b float,double,float,bigint`,那么最后的列为 `FLOAT,DOUBLE,FLOAT,BIGINT` 。 + +- **-L/--partial-col-num \ **: + 指定某些列写入数据,其他列数据为 NULL。默认所有列都写入数据。 + +- **-A/--tag-type \** : + 超级表的标签列类型。nchar 和 binary 类型可以同时设置长度,例如: + +``` +taosBenchmark -A INT,DOUBLE,NCHAR,BINARY(16) +``` + +如果没有设置标签类型,默认是两个标签,其类型分别为 INT 和 BINARY(16)。 +注意:在有的 shell 比如 bash 命令里面 “()” 需要转义,则上述指令应为: + +``` +taosBenchmark -A INT,DOUBLE,NCHAR,BINARY\(16\) +``` + +- **-w/--binwidth \**: + nchar 和 binary 类型的默认长度,默认值为 64。 + +- **-m/--table-prefix \** : + 子表名称的前缀,默认值为 "d"。 + +- **-E/--escape-character** : + 开关参数,指定在超级表和子表名称中是否使用转义字符。默认值为不使用。 + +- **-C/--chinese** : + 开关参数,指定 nchar 和 binary 是否使用 Unicode 中文字符。默认值为不使用。 + +- **-N/--normal-table** : + 开关参数,指定只创建普通表,不创建超级表。默认值为 false。仅当插入模式为 taosc, stmt, rest 模式下可以使用。 + +- **-M/--random** : + 开关参数,插入数据为生成的随机值。默认值为 false。若配置此参数,则随机生成要插入的数据。对于数值类型的 标签列/数据列,其值为该类型取值范围内的随机值。对于 NCHAR 和 BINARY 类型的 标签列/数据列,其值为指定长度范围内的随机字符串。 + +- **-x/--aggr-func** : + 开关参数,指示插入后查询聚合函数。默认值为 false。 + +- **-y/--answer-yes** : + 开关参数,要求用户在提示后确认才能继续。默认值为 false 。 + +- **-O/--disorder \** : + 指定乱序数据的百分比概率,其值域为 [0,50]。默认为 0,即没有乱序数据。 + +- **-R/--disorder-range \** : + 指定乱序数据的时间戳回退范围。所生成的乱序时间戳为非乱序情况下应该使用的时间戳减去这个范围内的一个随机值。仅在 `-O/--disorder` 指定的乱序数据百分比大于 0 时有效。 + +- **-F/--prepare_rand \** : + 生成的随机数据中唯一值的数量。若为 1 则表示所有数据都相同。默认值为 10000 。 + +- **-a/--replica \** : + 创建数据库时指定其副本数,默认值为 1 。 + +- ** -k/--keep-trying \** : 失败后进行重试的次数,默认不重试。需使用 v3.0.9 以上版本。 + +- ** -z/--trying-interval \** : 失败重试间隔时间,单位为毫秒,仅在 -k 指定重试后有效。需使用 v3.0.9 以上版本。 + +- **-v/--vgroups \** : + 创建数据库时指定 vgroups 数,仅对 TDengine v3.0+ 有效。 + +- **-V/--version** : + 显示版本信息并退出。不能与其它参数混用。 + +- **-?/--help** : + 显示帮助信息并退出。不能与其它参数混用。 + +## 配置文件参数详解 + +### 通用配置参数 + +本节所列参数适用于所有功能模式。 + +- **filetype** : 要测试的功能,可选值为 `insert`, `query` 和 `subscribe`。分别对应插入、查询和订阅功能。每个配置文件中只能指定其中之一。 +- **cfgdir** : TDengine 客户端配置文件所在的目录,默认路径是 /etc/taos 。 + +- **host** : 指定要连接的 TDengine 服务端的 FQDN,默认值为 localhost。 + +- **port** : 要连接的 TDengine 服务器的端口号,默认值为 6030。 + +- **user** : 用于连接 TDengine 服务端的用户名,默认为 root。 + +- **password** : 用于连接 TDengine 服务端的密码,默认值为 taosdata。 + +### 插入场景配置参数 + +插入场景下 `filetype` 必须设置为 `insert`,该参数及其它通用参数详见[通用配置参数](#通用配置参数) + +- ** keep_trying ** : 失败后进行重试的次数,默认不重试。需使用 v3.0.9 以上版本。 + +- ** trying_interval ** : 失败重试间隔时间,单位为毫秒,仅在 keep_trying 指定重试后有效。需使用 v3.0.9 以上版本。 +- ** childtable_from 和 childtable_to ** : 指定写入子表范围,开闭区间为 [childtable_from, childtable_to). +  +- ** continue_if_fail ** : 允许用户定义失败后行为 + + “continue_if_fail”:  “no”, 失败 taosBenchmark 自动退出,默认行为 + “continue_if_fail”: “yes”, 失败 taosBenchmark 警告用户,并继续写入 + “continue_if_fail”: “smart”, 如果子表不存在失败,taosBenchmark 会建立子表并继续写入 + +#### 数据库相关配置参数 + +创建数据库时的相关参数在 json 配置文件中的 `dbinfo` 中配置,个别具体参数如下。其余参数均与 TDengine 中 `create database` 时所指定的数据库参数相对应,详见[../../taos-sql/database] + +- **name** : 数据库名。 + +- **drop** : 插入前是否删除数据库,可选项为 "yes" 或者 "no", 为 "no" 时不创建。默认删除。 + +#### 流式计算相关配置参数 + +创建流式计算的相关参数在 json 配置文件中的 `stream` 中配置,具体参数如下。 + +- **stream_name** : 流式计算的名称,必填项。 + +- **stream_stb** : 流式计算对应的超级表名称,必填项。 + +- **stream_sql** : 流式计算的sql语句,必填项。 + +- **trigger_mode** : 流式计算的触发模式,可选项。 + +- **watermark** : 流式计算的水印,可选项。 + +- **drop** : 是否创建流式计算,可选项为 "yes" 或者 "no", 为 "no" 时不创建。 + +#### 超级表相关配置参数 + +创建超级表时的相关参数在 json 配置文件中的 `super_tables` 中配置,具体参数如下。 + +- **name**: 超级表名,必须配置,没有默认值。 + +- **child_table_exists** : 子表是否已经存在,默认值为 "no",可选值为 "yes" 或 "no"。 + +- **child_table_count** : 子表的数量,默认值为 10。 + +- **child_table_prefix** : 子表名称的前缀,必选配置项,没有默认值。 + +- **escape_character** : 超级表和子表名称中是否包含转义字符,默认值为 "no",可选值为 "yes" 或 "no"。 + +- **auto_create_table** : 仅当 insert_mode 为 taosc, rest, stmt 并且 child_table_exists 为 "no" 时生效,该参数为 "yes" 表示 taosBenchmark 在插入数据时会自动创建不存在的表;为 "no" 则表示先提前建好所有表再进行插入。 + +- **batch_create_tbl_num** : 创建子表时每批次的建表数量,默认为 10。注:实际的批数不一定与该值相同,当执行的 SQL 语句大于支持的最大长度时,会自动截断再执行,继续创建。 + +- **data_source** : 数据的来源,默认为 taosBenchmark 随机产生,可以配置为 "rand" 和 "sample"。为 "sample" 时使用 sample_file 参数指定的文件内的数据。 + +- **insert_mode** : 插入模式,可选项有 taosc, rest, stmt, sml, sml-rest, 分别对应普通写入、restful 接口写入、参数绑定接口写入、schemaless 接口写入、restful schemaless 接口写入 (由 taosAdapter 提供)。默认值为 taosc 。 + +- **non_stop_mode** : 指定是否持续写入,若为 "yes" 则 insert_rows 失效,直到 Ctrl + C 停止程序,写入才会停止。默认值为 "no",即写入指定数量的记录后停止。注:即使在持续写入模式下 insert_rows 失效,但其也必须被配置为一个非零正整数。 + +- **line_protocol** : 使用行协议插入数据,仅当 insert_mode 为 sml 或 sml-rest 时生效,可选项为 line, telnet, json。 + +- **tcp_transfer** : telnet 模式下的通信协议,仅当 insert_mode 为 sml-rest 并且 line_protocol 为 telnet 时生效。如果不配置,则默认为 http 协议。 + +- **insert_rows** : 每个子表插入的记录数,默认为 0 。 + +- **childtable_offset** : 仅当 child_table_exists 为 yes 时生效,指定从超级表获取子表列表时的偏移量,即从第几个子表开始。 + +- **childtable_limit** : 仅当 child_table_exists 为 yes 时生效,指定从超级表获取子表列表的上限。 + +- **interlace_rows** : 启用交错插入模式并同时指定向每个子表每次插入的数据行数。交错插入模式是指依次向每张子表插入由本参数所指定的行数并重复这个过程,直到所有子表的数据都插入完成。默认值为 0, 即向一张子表完成数据插入后才会向下一张子表进行数据插入。 + +- **insert_interval** : 指定交错插入模式的插入间隔,单位为 ms,默认值为 0。 只有当 `-B/--interlace-rows` 大于 0 时才起作用。意味着数据插入线程在为每个子表插入隔行扫描记录后,会等待该值指定的时间间隔后再进行下一轮写入。 + +- **partial_col_num** : 若该值为正数 n 时, 则仅向前 n 列写入,仅当 insert_mode 为 taosc 和 rest 时生效,如果 n 为 0 则是向全部列写入。 + +- **disorder_ratio** : 指定乱序数据的百分比概率,其值域为 [0,50]。默认为 0,即没有乱序数据。 + +- **disorder_range** : 指定乱序数据的时间戳回退范围。所生成的乱序时间戳为非乱序情况下应该使用的时间戳减去这个范围内的一个随机值。仅在 `-O/--disorder` 指定的乱序数据百分比大于 0 时有效。 + +- **timestamp_step** : 每个子表中插入数据的时间戳步长,单位与数据库的 `precision` 一致,默认值是 1。 + +- **start_timestamp** : 每个子表的时间戳起始值,默认值是 now。 + +- **sample_format** : 样本数据文件的类型,现在只支持 "csv" 。 + +- **sample_file** : 指定 csv 格式的文件作为数据源,仅当 data_source 为 sample 时生效。若 csv 文件内的数据行数小于等于 prepared_rand,那么会循环读取 csv 文件数据直到与 prepared_rand 相同;否则则会只读取 prepared_rand 个数的行的数据。也即最终生成的数据行数为二者取小。 + +- **use_sample_ts** : 仅当 data_source 为 sample 时生效,表示 sample_file 指定的 csv 文件内是否包含第一列时间戳,默认为 no。 若设置为 yes, 则使用 csv 文件第一列作为时间戳,由于同一子表时间戳不能重复,生成的数据量取决于 csv 文件内的数据行数相同,此时 insert_rows 失效。 + +- **tags_file** : 仅当 insert_mode 为 taosc, rest 的模式下生效。 最终的 tag 的数值与 childtable_count 有关,如果 csv 文件内的 tag 数据行小于给定的子表数量,那么会循环读取 csv 文件数据直到生成 childtable_count 指定的子表数量;否则则只会读取 childtable_count 行 tag 数据。也即最终生成的子表数量为二者取小。 + +- **primary_key** : 指定超级表是否有复合主键,取值 1 和 0, 复合主键列只能是超级表的第二列,指定生成复合主键后要确保第二列符合复合主键的数据类型,否则会报错 +- **repeat_ts_min** : 数值类型,复合主键开启情况下指定生成相同时间戳记录的最小个数,生成相同时间戳记录的个数是在范围[repeat_ts_min, repeat_ts_max] 内的随机值, 最小值等于最大值时为固定个数 +- **repeat_ts_max** : 数值类型,复合主键开启情况下指定生成相同时间戳记录的最大个数 +- **sqls** : 字符串数组类型,指定超级表创建成功后要执行的 sql 数组,sql 中指定表名前面要带数据库名,否则会报未指定数据库错误 + +#### tsma配置参数 + +指定tsma的配置参数在 `super_tables` 中的 `tsmas` 中,具体参数如下。 + +- **name** : 指定 tsma 的名字,必选项。 + +- **function** : 指定 tsma 的函数,必选项。 + +- **interval** : 指定 tsma 的时间间隔,必选项。 + +- **sliding** : 指定 tsma 的窗口时间位移,必选项。 + +- **custom** : 指定 tsma 的创建语句结尾追加的自定义配置,可选项。 + +- **start_when_inserted** : 指定当插入多少行时创建 tsma,可选项,默认为 0。 + +#### 标签列与数据列配置参数 + +指定超级表标签列与数据列的配置参数分别在 `super_tables` 中的 `columns` 和 `tag` 中。 + +- **type** : 指定列类型,可选值请参考 TDengine 支持的数据类型。 + 注:JSON 数据类型比较特殊,只能用于标签,当使用 JSON 类型作为 tag 时有且只能有这一个标签,此时 count 和 len 代表的意义分别是 JSON tag 内的 key-value pair 的个数和每个 KV pair 的 value 的值的长度,value 默认为 string。 + +- **len** : 指定该数据类型的长度,对 NCHAR,BINARY 和 JSON 数据类型有效。如果对其他数据类型配置了该参数,若为 0 , 则代表该列始终都是以 null 值写入;如果不为 0 则被忽略。 + +- **count** : 指定该类型列连续出现的数量,例如 "count": 4096 即可生成 4096 个指定类型的列。 + +- **name** : 列的名字,若与 count 同时使用,比如 "name":"current", "count":3, 则 3 个列的名字分别为 current, current_2. current_3。 + +- **min** : 数据类型的 列/标签 的最小值。生成的值将大于或等于最小值。 + +- **max** : 数据类型的 列/标签 的最大值。生成的值将小于最小值。 + +- **fun** : 此列数据以函数填充,目前只支持 sin 和 cos 两函数,输入参数为时间戳换算成角度值,换算公式: 角度 x = 输入的时间列ts值 % 360。同时支持系数调节,随机波动因子调节,以固定格式的表达式展现,如 fun=“10\*sin(x)+100\*random(5)” , x 表示角度,取值 0 ~ 360度,增长步长与时间列步长一致。10 表示乘的系数,100 表示加或减的系数,5 表示波动幅度在 5% 的随机范围内。目前支持的数据类型为 int, bigint, float, double 四种数据类型。注意:表达式为固定模式,不可前后颠倒。 + +- **values** : nchar/binary 列/标签的值域,将从值中随机选择。 + +- **sma**: 将该列加入 SMA 中,值为 "yes" 或者 "no",默认为 "no"。 + +- **encode**: 字符串类型,指定此列两级压缩中的第一级编码算法,详细参见创建超级表 + +- **compress**: 字符串类型,指定此列两级压缩中的第二级加密算法,详细参见创建超级表 + +- **level**: 字符串类型,指定此列两级压缩中的第二级加密算法的压缩率高低,详细参见创建超级表 + +- **gen**: 字符串类型,指定此列生成数据的方式,不指定为随机,若指定为 “order”, 会按自然数顺序增长 + +- **fillNull**: 字符串类型,指定此列是否随机插入 NULL 值,可指定为 “true” 或 "false", 只有当 generate_row_rule 为 2 时有效 + +#### 插入行为配置参数 + +- **thread_count** : 插入数据的线程数量,默认为 8。 + +- **thread_bind_vgroup** : 写入时 vgroup 是否和写入线程绑定,绑定后可提升写入速度, 取值为 "yes" 或 "no",默认值为 “no”, 设置为 “no” 后与原来行为一致。 当设为 “yes” 时,如果 thread_count 数量大小写入数据库的 vgroups 数量, thread_count 自动调整为 vgroups 数量;如果 thread_count 数量小于 vgroups 数量,写入线程数量不做调整,一个线程写完一个 vgroup 数据后再写下一个,同时保持一个 vgroup 同时只能由一个线程写入的规则。 + +- **create_table_thread_count** : 建表的线程数量,默认为 8。 + +- **connection_pool_size** : 预先建立的与 TDengine 服务端之间的连接的数量。若不配置,则与所指定的线程数相同。 + +- **result_file** : 结果输出文件的路径,默认值为 ./output.txt。 + +- **confirm_parameter_prompt** : 开关参数,要求用户在提示后确认才能继续。默认值为 false 。 + +- **interlace_rows** : 启用交错插入模式并同时指定向每个子表每次插入的数据行数。交错插入模式是指依次向每张子表插入由本参数所指定的行数并重复这个过程,直到所有子表的数据都插入完成。默认值为 0, 即向一张子表完成数据插入后才会向下一张子表进行数据插入。 + 在 `super_tables` 中也可以配置该参数,若配置则以 `super_tables` 中的配置为高优先级,覆盖全局设置。 + +- **insert_interval** : + 指定交错插入模式的插入间隔,单位为 ms,默认值为 0。 只有当 `-B/--interlace-rows` 大于 0 时才起作用。意味着数据插入线程在为每个子表插入隔行扫描记录后,会等待该值指定的时间间隔后再进行下一轮写入。 + 在 `super_tables` 中也可以配置该参数,若配置则以 `super_tables` 中的配置为高优先级,覆盖全局设置。 + +- **num_of_records_per_req** : + 每次向 TDengine 请求写入的数据行数,默认值为 30000 。当其设置过大时,TDengine 客户端驱动会返回相应的错误信息,此时需要调低这个参数的设置以满足写入要求。 + +- **prepare_rand** : 生成的随机数据中唯一值的数量。若为 1 则表示所有数据都相同。默认值为 10000 。 + +- **pre_load_tb_meta** :是否提前加载子表的 meta 数据,取值为 “yes” or "no"。当子表数量非常多时,打开此选项可提高写入速度。 + +### 查询场景配置参数 + +查询场景下 `filetype` 必须设置为 `query`。 +`query_times` 指定运行查询的次数,数值类型 + +查询场景可以通过设置 `kill_slow_query_threshold` 和 `kill_slow_query_interval` 参数来控制杀掉慢查询语句的执行,threshold 控制如果 exec_usec 超过指定时间的查询将被 taosBenchmark 杀掉,单位为秒;interval 控制休眠时间,避免持续查询慢查询消耗 CPU ,单位为秒。 + +其它通用参数详见[通用配置参数](#通用配置参数)。 + +#### 执行指定查询语句的配置参数 + +查询指定表(可以指定超级表、子表或普通表)的配置参数在 `specified_table_query` 中设置。 + +- **query_interval** : 查询时间间隔,单位是秒,默认值为 0。 + +- **threads** : 执行查询 SQL 的线程数,默认值为 1。 + +- **sqls**: + - **sql**: 执行的 SQL 命令,必填。 + - **result**: 保存查询结果的文件,未指定则不保存。 + +#### 查询超级表的配置参数 + +查询超级表的配置参数在 `super_table_query` 中设置。 + +- **stblname** : 指定要查询的超级表的名称,必填。 + +- **query_interval** : 查询时间间隔,单位是秒,默认值为 0。 + +- **threads** : 执行查询 SQL 的线程数,默认值为 1。 + +- **sqls** : + - **sql** : 执行的 SQL 命令,必填;对于超级表的查询 SQL,在 SQL 命令中保留 "xxxx",程序会自动将其替换为超级表的所有子表名。 + 替换为超级表中所有的子表名。 + - **result** : 保存查询结果的文件,未指定则不保存。 + +### 订阅场景配置参数 + +订阅场景下 `filetype` 必须设置为 `subscribe`,该参数及其它通用参数详见[通用配置参数](#通用配置参数) + +#### 执行指定订阅语句的配置参数 + +订阅指定表(可以指定超级表、子表或者普通表)的配置参数在 `specified_table_query` 中设置。 + +- **threads/concurrent** : 执行 SQL 的线程数,默认为 1。 + +- **sqls** : + - **sql** : 执行的 SQL 命令,必填。 + + +#### 配置文件中数据类型书写对照表 + +| # | **引擎** | **taosBenchmark** +| --- | :----------------: | :---------------: +| 1 | TIMESTAMP | timestamp +| 2 | INT | int +| 3 | INT UNSIGNED | uint +| 4 | BIGINT | bigint +| 5 | BIGINT UNSIGNED | ubigint +| 6 | FLOAT | float +| 7 | DOUBLE | double +| 8 | BINARY | binary +| 9 | SMALLINT | smallint +| 10 | SMALLINT UNSIGNED | usmallint +| 11 | TINYINT | tinyint +| 12 | TINYINT UNSIGNED | utinyint +| 13 | BOOL | bool +| 14 | NCHAR | nchar +| 15 | VARCHAR | varchar +| 15 | JSON | json + +注意:taosBenchmark 配置文件中数据类型必须小写方可识别 + + + diff --git a/docs/zh/14-reference/02-tools/index.md b/docs/zh/14-reference/02-tools/index.md new file mode 100644 index 0000000000..37ed3a460e --- /dev/null +++ b/docs/zh/14-reference/02-tools/index.md @@ -0,0 +1,13 @@ +--- +title: 工具 +description: TDengine 工具 +--- + +本节详细说明 TDengine 中的主要工具的功能和用法。 + +```mdx-code-block +import DocCardList from '@theme/DocCardList'; +import {useCurrentSidebarCategory} from '@docusaurus/theme-common'; + + +``` \ No newline at end of file diff --git a/docs/zh/14-reference/03-taos-sql/20-keywords.md b/docs/zh/14-reference/03-taos-sql/20-keywords.md index 4d2454ed5a..1ef0d07e14 100644 --- a/docs/zh/14-reference/03-taos-sql/20-keywords.md +++ b/docs/zh/14-reference/03-taos-sql/20-keywords.md @@ -131,6 +131,7 @@ description: TDengine 保留关键字的详细列表 ### H - HAVING +- HOST ### I diff --git a/docs/zh/14-reference/05-connector/43-r-lang.mdx b/docs/zh/14-reference/05-connector/43-r-lang.mdx index e8929e5ca0..13734dec8c 100644 --- a/docs/zh/14-reference/05-connector/43-r-lang.mdx +++ b/docs/zh/14-reference/05-connector/43-r-lang.mdx @@ -7,7 +7,7 @@ title: R Language Connector import Tabs from '@theme/Tabs'; import TabItem from '@theme/TabItem'; -import Rdemo from "../../08-develop/01-connect/_connect_r.mdx" +import Rdemo from "../../07-develop/01-connect/_connect_r.mdx" 通过 R 语言中的 RJDBC 库可以使 R 语言程序支持访问 TDengine 数据。以下是安装过程、配置过程以及 R 语言示例代码。 diff --git a/include/common/tdataformat.h b/include/common/tdataformat.h index 1179e710cd..d8a88d038d 100644 --- a/include/common/tdataformat.h +++ b/include/common/tdataformat.h @@ -116,7 +116,7 @@ typedef struct { int32_t tValueColumnInit(SValueColumn *valCol); int32_t tValueColumnDestroy(SValueColumn *valCol); -int32_t tValueColumnClear(SValueColumn *valCol); +void tValueColumnClear(SValueColumn *valCol); int32_t tValueColumnAppend(SValueColumn *valCol, const SValue *value); int32_t tValueColumnUpdate(SValueColumn *valCol, int32_t idx, const SValue *value); int32_t tValueColumnGet(SValueColumn *valCol, int32_t idx, SValue *value); diff --git a/include/common/tmsg.h b/include/common/tmsg.h index 8b3016043f..bc61e21d16 100644 --- a/include/common/tmsg.h +++ b/include/common/tmsg.h @@ -462,6 +462,7 @@ typedef enum ENodeType { typedef struct { int32_t vgId; + uint8_t option; // 0x0 REQ_OPT_TBNAME, 0x01 REQ_OPT_TBUID const char* dbFName; const char* tbName; } SBuildTableInput; @@ -1459,6 +1460,7 @@ typedef struct { int32_t walFsyncPeriod; int16_t hashPrefix; int16_t hashSuffix; + int8_t hashMethod; int8_t walLevel; int8_t precision; int8_t compression; @@ -2044,10 +2046,13 @@ typedef struct { int32_t tSerializeSAlterVnodeHashRangeReq(void* buf, int32_t bufLen, SAlterVnodeHashRangeReq* pReq); int32_t tDeserializeSAlterVnodeHashRangeReq(void* buf, int32_t bufLen, SAlterVnodeHashRangeReq* pReq); +#define REQ_OPT_TBNAME 0x0 +#define REQ_OPT_TBUID 0x01 typedef struct { SMsgHead header; char dbFName[TSDB_DB_FNAME_LEN]; char tbName[TSDB_TABLE_NAME_LEN]; + uint8_t option; } STableInfoReq; int32_t tSerializeSTableInfoReq(void* buf, int32_t bufLen, STableInfoReq* pReq); diff --git a/include/common/tmsgdef.h b/include/common/tmsgdef.h index ff524faefd..6c3db83e4f 100644 --- a/include/common/tmsgdef.h +++ b/include/common/tmsgdef.h @@ -309,6 +309,7 @@ TD_DEF_MSG_TYPE(TDMT_VND_ARB_HEARTBEAT, "vnode-arb-hb", NULL, NULL) TD_DEF_MSG_TYPE(TDMT_VND_ARB_CHECK_SYNC, "vnode-arb-check-sync", NULL, NULL) TD_DEF_MSG_TYPE(TDMT_VND_FETCH_TTL_EXPIRED_TBS, "vnode-fetch-ttl-expired-tbs", NULL, NULL) + TD_DEF_MSG_TYPE(TDMT_VND_TABLE_NAME, "vnode-table-name", NULL, NULL) TD_CLOSE_MSG_SEG(TDMT_VND_MSG) TD_NEW_MSG_SEG(TDMT_SCH_MSG) // 3<<8 diff --git a/include/libs/catalog/catalog.h b/include/libs/catalog/catalog.h index 11ed7c7da6..df3f87973f 100644 --- a/include/libs/catalog/catalog.h +++ b/include/libs/catalog/catalog.h @@ -96,6 +96,7 @@ typedef struct SCatalogReq { SArray* pView; // element is STablesReq SArray* pTableTSMAs; // element is STablesReq SArray* pTSMAs; // element is STablesReq + SArray* pTableName; // element is STablesReq bool qNodeRequired; // valid qnode bool dNodeRequired; // valid dnode bool svrVerRequired; @@ -417,6 +418,8 @@ int32_t catalogGetTsma(SCatalog* pCtg, SRequestConnInfo* pConn, const SName* pTs int32_t catalogAsyncUpdateDbTsmaVersion(SCatalog* pCtg, int32_t tsmaVersion, const char* dbFName, int64_t dbId); +int32_t ctgHashValueComp(void const* lp, void const* rp); + /** * Destroy catalog and relase all resources */ diff --git a/include/libs/nodes/cmdnodes.h b/include/libs/nodes/cmdnodes.h index 21de2eff9a..2a18e800b8 100644 --- a/include/libs/nodes/cmdnodes.h +++ b/include/libs/nodes/cmdnodes.h @@ -240,6 +240,7 @@ typedef struct SDropTableStmt { ENodeType type; SNodeList* pTables; bool withTsma; + bool withOpt; } SDropTableStmt; typedef struct SDropSuperTableStmt { @@ -247,6 +248,7 @@ typedef struct SDropSuperTableStmt { char dbName[TSDB_DB_NAME_LEN]; char tableName[TSDB_TABLE_NAME_LEN]; bool ignoreNotExists; + bool withOpt; } SDropSuperTableStmt; typedef struct SAlterTableStmt { diff --git a/include/libs/qcom/query.h b/include/libs/qcom/query.h index c8c4fcad44..bcb1aa90d1 100644 --- a/include/libs/qcom/query.h +++ b/include/libs/qcom/query.h @@ -330,6 +330,7 @@ int32_t getAsofJoinReverseOp(EOperatorType op); int32_t queryCreateCTableMetaFromMsg(STableMetaRsp* msg, SCTableMeta* pMeta); int32_t queryCreateTableMetaFromMsg(STableMetaRsp* msg, bool isSuperTable, STableMeta** pMeta); +int32_t queryCreateTableMetaExFromMsg(STableMetaRsp* msg, bool isSuperTable, STableMeta** pMeta); char* jobTaskStatusStr(int32_t status); SSchema createSchema(int8_t type, int32_t bytes, col_id_t colId, const char* name); diff --git a/source/common/src/systable.c b/source/common/src/systable.c index 2f3ffecf61..be841d9682 100644 --- a/source/common/src/systable.c +++ b/source/common/src/systable.c @@ -159,6 +159,7 @@ static const SSysDbTableSchema userStbsSchema[] = { {.name = "watermark", .bytes = 64 + VARSTR_HEADER_SIZE, .type = TSDB_DATA_TYPE_VARCHAR, .sysInfo = false}, {.name = "max_delay", .bytes = 64 + VARSTR_HEADER_SIZE, .type = TSDB_DATA_TYPE_VARCHAR, .sysInfo = false}, {.name = "rollup", .bytes = 128 + VARSTR_HEADER_SIZE, .type = TSDB_DATA_TYPE_VARCHAR, .sysInfo = false}, + {.name = "uid", .bytes = 8, .type = TSDB_DATA_TYPE_BIGINT, .sysInfo = false}, }; static const SSysDbTableSchema streamSchema[] = { diff --git a/source/common/src/tdataformat.c b/source/common/src/tdataformat.c index 4b44e4af43..4ef9bf481c 100644 --- a/source/common/src/tdataformat.c +++ b/source/common/src/tdataformat.c @@ -481,6 +481,10 @@ int32_t tRowBuildFromBind(SBindInfo *infos, int32_t numOfInfos, bool infoSorted, }; if (IS_VAR_DATA_TYPE(infos[iInfo].type)) { value.nData = infos[iInfo].bind->length[iRow]; + if (value.nData > pTSchema->columns[iInfo].bytes - VARSTR_HEADER_SIZE) { + code = TSDB_CODE_INVALID_PARA; + goto _exit; + } value.pData = (uint8_t *)infos[iInfo].bind->buffer + infos[iInfo].bind->buffer_length * iRow; } else { (void)memcpy(&value.val, (uint8_t *)infos[iInfo].bind->buffer + infos[iInfo].bind->buffer_length * iRow, @@ -1704,7 +1708,7 @@ bool tTagGet(const STag *pTag, STagVal *pTagVal) { offset = pTag->idx[midx]; } - (void)tGetTagVal(p + offset, &tv, isJson); + int32_t nt = tGetTagVal(p + offset, &tv, isJson); if (isJson) { c = tTagValJsonCmprFn(pTagVal, &tv); } else { @@ -1754,7 +1758,7 @@ int32_t tTagToValArray(const STag *pTag, SArray **ppArray) { } else { offset = pTag->idx[iTag]; } - (void)tGetTagVal(p + offset, &tv, pTag->flags & TD_TAG_JSON); + int32_t nt = tGetTagVal(p + offset, &tv, pTag->flags & TD_TAG_JSON); if (taosArrayPush(*ppArray, &tv) == NULL) { code = terrno; goto _err; @@ -1784,7 +1788,7 @@ void tTagSetCid(const STag *pTag, int16_t iTag, int16_t cid) { offset = pTag->idx[iTag]; } - (void)tPutI16v(p + offset, cid); + int32_t nt = tPutI16v(p + offset, cid); } // STSchema ======================================== @@ -3279,6 +3283,10 @@ int32_t tRowBuildFromBind2(SBindInfo2 *infos, int32_t numOfInfos, bool infoSorte int32_t length = infos[iInfo].bind->length[iRow]; uint8_t **data = &((uint8_t **)TARRAY_DATA(bufArray))[iInfo]; value.nData = length; + if (value.nData > pTSchema->columns[iInfo].bytes - VARSTR_HEADER_SIZE) { + code = TSDB_CODE_INVALID_PARA; + goto _exit; + } value.pData = *data; *data += length; // value.pData = (uint8_t *)infos[iInfo].bind->buffer + infos[iInfo].bind->buffer_length * iRow; @@ -3352,16 +3360,16 @@ static int32_t tColDataCopyRowSingleCol(SColData *pFromColData, int32_t iFromRow SET_BIT1(pToColData->pBitMap, iToRow, GET_BIT1(pFromColData->pBitMap, iFromRow)); } break; case HAS_VALUE: { - (void)tColDataCopyRowCell(pFromColData, iFromRow, pToColData, iToRow); + TAOS_CHECK_RETURN(tColDataCopyRowCell(pFromColData, iFromRow, pToColData, iToRow)); } break; case (HAS_VALUE | HAS_NONE): case (HAS_VALUE | HAS_NULL): { SET_BIT1(pToColData->pBitMap, iToRow, GET_BIT1(pFromColData->pBitMap, iFromRow)); - (void)tColDataCopyRowCell(pFromColData, iFromRow, pToColData, iToRow); + TAOS_CHECK_RETURN(tColDataCopyRowCell(pFromColData, iFromRow, pToColData, iToRow)); } break; case (HAS_VALUE | HAS_NULL | HAS_NONE): { SET_BIT2(pToColData->pBitMap, iToRow, GET_BIT2(pFromColData->pBitMap, iFromRow)); - (void)tColDataCopyRowCell(pFromColData, iFromRow, pToColData, iToRow); + TAOS_CHECK_RETURN(tColDataCopyRowCell(pFromColData, iFromRow, pToColData, iToRow)); } break; default: return -1; @@ -3434,24 +3442,24 @@ static int32_t tColDataMergeSortMerge(SColData *aColData, int32_t start, int32_t tColDataArrGetRowKey(aColData, nColData, j, &keyj); while (i <= mid && j <= end) { if (tRowKeyCompare(&keyi, &keyj) <= 0) { - (void)tColDataCopyRowAppend(aColData, i++, aDstColData, nColData); + TAOS_CHECK_RETURN(tColDataCopyRowAppend(aColData, i++, aDstColData, nColData)); tColDataArrGetRowKey(aColData, nColData, i, &keyi); } else { - (void)tColDataCopyRowAppend(aColData, j++, aDstColData, nColData); + TAOS_CHECK_RETURN(tColDataCopyRowAppend(aColData, j++, aDstColData, nColData)); tColDataArrGetRowKey(aColData, nColData, j, &keyj); } } while (i <= mid) { - (void)tColDataCopyRowAppend(aColData, i++, aDstColData, nColData); + TAOS_CHECK_RETURN(tColDataCopyRowAppend(aColData, i++, aDstColData, nColData)); } while (j <= end) { - (void)tColDataCopyRowAppend(aColData, j++, aDstColData, nColData); + TAOS_CHECK_RETURN(tColDataCopyRowAppend(aColData, j++, aDstColData, nColData)); } for (i = start, k = 0; i <= end; ++i, ++k) { - (void)tColDataCopyRow(aDstColData, k, aColData, i, nColData); + TAOS_CHECK_RETURN(tColDataCopyRow(aDstColData, k, aColData, i, nColData)); } if (aDstColData) { @@ -3600,7 +3608,7 @@ int32_t tColDataSortMerge(SArray **arr) { // sort ------- if (doSort) { - (void)tColDataSort(aColData, nColData); + TAOS_CHECK_RETURN(tColDataSort(aColData, nColData)); } if (doMerge != 1) { @@ -4171,12 +4179,12 @@ int32_t tValueColumnDestroy(SValueColumn *valCol) { return 0; } -int32_t tValueColumnClear(SValueColumn *valCol) { +void tValueColumnClear(SValueColumn *valCol) { valCol->type = TSDB_DATA_TYPE_NULL; valCol->numOfValues = 0; tBufferClear(&valCol->data); tBufferClear(&valCol->offsets); - return 0; + return; } int32_t tValueColumnAppend(SValueColumn *valCol, const SValue *value) { @@ -4247,17 +4255,17 @@ int32_t tValueColumnGet(SValueColumn *valCol, int32_t idx, SValue *value) { int32_t offset, nextOffset; SBufferReader reader = BUFFER_READER_INITIALIZER(idx * sizeof(offset), &valCol->offsets); - (void)tBufferGetI32(&reader, &offset); + TAOS_CHECK_RETURN(tBufferGetI32(&reader, &offset)); if (idx == valCol->numOfValues - 1) { nextOffset = tBufferGetSize(&valCol->data); } else { - (void)tBufferGetI32(&reader, &nextOffset); + TAOS_CHECK_RETURN(tBufferGetI32(&reader, &nextOffset)); } value->nData = nextOffset - offset; value->pData = (uint8_t *)tBufferGetDataAt(&valCol->data, offset); } else { SBufferReader reader = BUFFER_READER_INITIALIZER(idx * tDataTypes[value->type].bytes, &valCol->data); - (void)tBufferGet(&reader, tDataTypes[value->type].bytes, &value->val); + TAOS_CHECK_RETURN(tBufferGet(&reader, tDataTypes[value->type].bytes, &value->val)); } return 0; } @@ -4309,7 +4317,7 @@ int32_t tValueColumnDecompress(void *input, const SValueColumnCompressInfo *info SBuffer *assist) { int32_t code; - (void)tValueColumnClear(valCol); + tValueColumnClear(valCol); valCol->type = info->type; // offset if (IS_VAR_DATA_TYPE(valCol->type)) { diff --git a/source/common/src/tmsg.c b/source/common/src/tmsg.c index c1d943ab5c..557ac07bbd 100644 --- a/source/common/src/tmsg.c +++ b/source/common/src/tmsg.c @@ -4912,6 +4912,7 @@ int32_t tSerializeSDbCfgRspImpl(SEncoder *encoder, const SDbCfgRsp *pRsp) { TAOS_CHECK_RETURN(tEncodeI32(encoder, pRsp->s3ChunkSize)); TAOS_CHECK_RETURN(tEncodeI32(encoder, pRsp->s3KeepLocal)); TAOS_CHECK_RETURN(tEncodeI8(encoder, pRsp->s3Compact)); + TAOS_CHECK_RETURN(tEncodeI8(encoder, pRsp->hashMethod)); return 0; } @@ -5003,6 +5004,11 @@ int32_t tDeserializeSDbCfgRspImpl(SDecoder *decoder, SDbCfgRsp *pRsp) { TAOS_CHECK_RETURN(tDecodeI32(decoder, &pRsp->s3KeepLocal)); TAOS_CHECK_RETURN(tDecodeI8(decoder, &pRsp->s3Compact)); } + if (!tDecodeIsEnd(decoder)) { + TAOS_CHECK_RETURN(tDecodeI8(decoder, &pRsp->hashMethod)); + } else { + pRsp->hashMethod = 1; // default value + } return 0; } @@ -5720,6 +5726,7 @@ int32_t tSerializeSTableInfoReq(void *buf, int32_t bufLen, STableInfoReq *pReq) TAOS_CHECK_EXIT(tStartEncode(&encoder)); TAOS_CHECK_EXIT(tEncodeCStr(&encoder, pReq->dbFName)); TAOS_CHECK_EXIT(tEncodeCStr(&encoder, pReq->tbName)); + TAOS_CHECK_EXIT(tEncodeU8(&encoder, pReq->option)); tEndEncode(&encoder); _exit: @@ -5754,6 +5761,11 @@ int32_t tDeserializeSTableInfoReq(void *buf, int32_t bufLen, STableInfoReq *pReq TAOS_CHECK_EXIT(tStartDecode(&decoder)); TAOS_CHECK_EXIT(tDecodeCStrTo(&decoder, pReq->dbFName)); TAOS_CHECK_EXIT(tDecodeCStrTo(&decoder, pReq->tbName)); + if (!tDecodeIsEnd(&decoder)) { + TAOS_CHECK_EXIT(tDecodeU8(&decoder, &pReq->option)); + } else { + pReq->option = 0; + } tEndDecode(&decoder); _exit: diff --git a/source/common/test/msgTypeTable.ini b/source/common/test/msgTypeTable.ini index 6e5721075c..0325183d8b 100644 --- a/source/common/test/msgTypeTable.ini +++ b/source/common/test/msgTypeTable.ini @@ -382,6 +382,8 @@ TDMT_VND_ARB_CHECK_SYNC = 613 TDMT_VND_ARB_CHECK_SYNC_RSP = 614 TDMT_VND_FETCH_TTL_EXPIRED_TBS = 615 TDMT_VND_FETCH_TTL_EXPIRED_TBS_RSP = 616 +TDMT_VND_TABLE_NAME = 617 +TDMT_VND_TABLE_NAME_RSP = 618 TDMT_SCH_QUERY = 769 TDMT_SCH_QUERY_RSP = 770 TDMT_SCH_MERGE_QUERY = 771 diff --git a/source/dnode/mgmt/mgmt_vnode/src/vmHandle.c b/source/dnode/mgmt/mgmt_vnode/src/vmHandle.c index f020ba2f5e..54e2bac66d 100644 --- a/source/dnode/mgmt/mgmt_vnode/src/vmHandle.c +++ b/source/dnode/mgmt/mgmt_vnode/src/vmHandle.c @@ -992,6 +992,7 @@ SArray *vmGetMsgHandles() { if (dmSetMgmtHandle(pArray, TDMT_VND_DROP_INDEX, vmPutMsgToWriteQueue, 0) == NULL) goto _OVER; if (dmSetMgmtHandle(pArray, TDMT_VND_QUERY_COMPACT_PROGRESS, vmPutMsgToFetchQueue, 0) == NULL) goto _OVER; if (dmSetMgmtHandle(pArray, TDMT_VND_KILL_COMPACT, vmPutMsgToWriteQueue, 0) == NULL) goto _OVER; + if (dmSetMgmtHandle(pArray, TDMT_VND_TABLE_NAME, vmPutMsgToFetchQueue, 0) == NULL) goto _OVER; if (dmSetMgmtHandle(pArray, TDMT_STREAM_TASK_DEPLOY, vmPutMsgToWriteQueue, 0) == NULL) goto _OVER; if (dmSetMgmtHandle(pArray, TDMT_STREAM_TASK_DROP, vmPutMsgToWriteQueue, 0) == NULL) goto _OVER; diff --git a/source/dnode/mnode/impl/src/mndDb.c b/source/dnode/mnode/impl/src/mndDb.c index 4a09aa44a0..374dff8d0c 100644 --- a/source/dnode/mnode/impl/src/mndDb.c +++ b/source/dnode/mnode/impl/src/mndDb.c @@ -1329,6 +1329,7 @@ static void mndDumpDbCfgInfo(SDbCfgRsp *cfgRsp, SDbObj *pDb) { cfgRsp->walFsyncPeriod = pDb->cfg.walFsyncPeriod; cfgRsp->hashPrefix = pDb->cfg.hashPrefix; cfgRsp->hashSuffix = pDb->cfg.hashSuffix; + cfgRsp->hashMethod = pDb->cfg.hashMethod; cfgRsp->walLevel = pDb->cfg.walLevel; cfgRsp->precision = pDb->cfg.precision; cfgRsp->compression = pDb->cfg.compression; diff --git a/source/dnode/mnode/impl/src/mndStb.c b/source/dnode/mnode/impl/src/mndStb.c index 915741ec49..fa9e4fa8fa 100644 --- a/source/dnode/mnode/impl/src/mndStb.c +++ b/source/dnode/mnode/impl/src/mndStb.c @@ -3626,6 +3626,11 @@ static int32_t mndRetrieveStb(SRpcMsg *pReq, SShowObj *pShow, SSDataBlock *pBloc pColInfo = taosArrayGet(pBlock->pDataBlock, cols++); RETRIEVE_CHECK_GOTO(colDataSetVal(pColInfo, numOfRows, (const char *)rollup, false), pStb, &lino, _ERROR); + pColInfo = taosArrayGet(pBlock->pDataBlock, cols++); + if (pColInfo) { + RETRIEVE_CHECK_GOTO(colDataSetVal(pColInfo, numOfRows, (const char *)(&pStb->uid), false), pStb, &lino, _ERROR); + } + numOfRows++; sdbRelease(pSdb, pStb); } diff --git a/source/dnode/vnode/inc/vnode.h b/source/dnode/vnode/inc/vnode.h index 443e4433cc..204311aa98 100644 --- a/source/dnode/vnode/inc/vnode.h +++ b/source/dnode/vnode/inc/vnode.h @@ -125,7 +125,7 @@ int32_t metaGetTableTags(void *pVnode, uint64_t suid, SArray *uidList); int32_t metaGetTableTagsByUids(void *pVnode, int64_t suid, SArray *uidList); int32_t metaReadNext(SMetaReader *pReader); const void *metaGetTableTagVal(const void *tag, int16_t type, STagVal *tagVal); -int metaGetTableNameByUid(void *meta, uint64_t uid, char *tbName); +int32_t metaGetTableNameByUid(void *pVnode, uint64_t uid, char *tbName); int metaGetTableSzNameByUid(void *meta, uint64_t uid, char *tbName); int metaGetTableUidByName(void *pVnode, char *tbName, uint64_t *uid); diff --git a/source/dnode/vnode/src/tsdb/tsdbUtil2.c b/source/dnode/vnode/src/tsdb/tsdbUtil2.c index 4bccf7df13..cc9f8ce3ad 100644 --- a/source/dnode/vnode/src/tsdb/tsdbUtil2.c +++ b/source/dnode/vnode/src/tsdb/tsdbUtil2.c @@ -108,8 +108,8 @@ int32_t tStatisBlockClear(STbStatisBlock *statisBlock) { TAOS_UNUSED(tBufferClear(&statisBlock->buffers[i])); } for (int32_t i = 0; i < TD_MAX_PK_COLS; ++i) { - TAOS_UNUSED(tValueColumnClear(&statisBlock->firstKeyPKs[i])); - TAOS_UNUSED(tValueColumnClear(&statisBlock->lastKeyPKs[i])); + tValueColumnClear(&statisBlock->firstKeyPKs[i]); + tValueColumnClear(&statisBlock->lastKeyPKs[i]); } return 0; } @@ -267,8 +267,8 @@ void tBrinBlockClear(SBrinBlock *brinBlock) { TAOS_UNUSED(tBufferClear(&brinBlock->buffers[i])); } for (int32_t i = 0; i < TD_MAX_PK_COLS; ++i) { - TAOS_UNUSED(tValueColumnClear(&brinBlock->firstKeyPKs[i])); - TAOS_UNUSED(tValueColumnClear(&brinBlock->lastKeyPKs[i])); + tValueColumnClear(&brinBlock->firstKeyPKs[i]); + tValueColumnClear(&brinBlock->lastKeyPKs[i]); } } diff --git a/source/dnode/vnode/src/vnd/vnodeQuery.c b/source/dnode/vnode/src/vnd/vnodeQuery.c index 8c31b38d00..d616bfd4ce 100644 --- a/source/dnode/vnode/src/vnd/vnodeQuery.c +++ b/source/dnode/vnode/src/vnd/vnodeQuery.c @@ -55,6 +55,7 @@ int32_t vnodeGetTableMeta(SVnode *pVnode, SRpcMsg *pMsg, bool direct) { SMetaReader mer1 = {0}; SMetaReader mer2 = {0}; char tableFName[TSDB_TABLE_FNAME_LEN]; + bool reqTbUid = false; SRpcMsg rpcMsg = {0}; int32_t code = 0; int32_t rspLen = 0; @@ -68,20 +69,33 @@ int32_t vnodeGetTableMeta(SVnode *pVnode, SRpcMsg *pMsg, bool direct) { goto _exit4; } + if (infoReq.option == REQ_OPT_TBUID) reqTbUid = true; metaRsp.dbId = pVnode->config.dbId; (void)strcpy(metaRsp.tbName, infoReq.tbName); (void)memcpy(metaRsp.dbFName, infoReq.dbFName, sizeof(metaRsp.dbFName)); - (void)sprintf(tableFName, "%s.%s", infoReq.dbFName, infoReq.tbName); - code = vnodeValidateTableHash(pVnode, tableFName); - if (code) { - goto _exit4; + if (!reqTbUid) { + TAOS_UNUSED(sprintf(tableFName, "%s.%s", infoReq.dbFName, infoReq.tbName)); + code = vnodeValidateTableHash(pVnode, tableFName); + if (code) { + goto _exit4; + } } // query meta metaReaderDoInit(&mer1, pVnode->pMeta, META_READER_LOCK); - - if (metaGetTableEntryByName(&mer1, infoReq.tbName) < 0) { + if (reqTbUid) { + errno = 0; + uint64_t tbUid = taosStr2UInt64(infoReq.tbName, NULL, 10); + if (errno == ERANGE || tbUid == 0) { + code = TSDB_CODE_TDB_TABLE_NOT_EXIST; + goto _exit3; + } + char tbName[TSDB_TABLE_NAME_LEN + VARSTR_HEADER_SIZE] = {0}; + TAOS_CHECK_GOTO(metaGetTableNameByUid(pVnode, tbUid, tbName), NULL, _exit3); + tstrncpy(metaRsp.tbName, varDataVal(tbName), TSDB_TABLE_NAME_LEN); + TAOS_CHECK_GOTO(metaGetTableEntryByName(&mer1, varDataVal(tbName)), NULL, _exit3); + } else if (metaGetTableEntryByName(&mer1, infoReq.tbName) < 0) { code = terrno; goto _exit3; } @@ -107,7 +121,7 @@ int32_t vnodeGetTableMeta(SVnode *pVnode, SRpcMsg *pMsg, bool direct) { schema = mer1.me.ntbEntry.schemaRow; } else { vError("vnodeGetTableMeta get invalid table type:%d", mer1.me.type); - return TSDB_CODE_APP_ERROR; + goto _exit3; } metaRsp.numOfTags = schemaTag.nCols; @@ -175,7 +189,7 @@ _exit4: rpcMsg.msgType = pMsg->msgType; if (code) { - qError("get table %s meta failed cause of %s", infoReq.tbName, tstrerror(code)); + qError("get table %s meta with %" PRIu8 " failed cause of %s", infoReq.tbName, infoReq.option, tstrerror(code)); } if (direct) { @@ -400,6 +414,12 @@ int32_t vnodeGetBatchMeta(SVnode *pVnode, SRpcMsg *pMsg) { qWarn("vnodeGetBatchMeta failed, msgType:%d", req->msgType); } break; + case TDMT_VND_TABLE_NAME: + // error code has been set into reqMsg, no need to handle it here. + if (TSDB_CODE_SUCCESS != vnodeGetTableMeta(pVnode, &reqMsg, false)) { + qWarn("vnodeGetBatchName failed, msgType:%d", req->msgType); + } + break; case TDMT_VND_TABLE_CFG: // error code has been set into reqMsg, no need to handle it here. if (TSDB_CODE_SUCCESS != vnodeGetTableCfg(pVnode, &reqMsg, false)) { diff --git a/source/dnode/vnode/src/vnd/vnodeSvr.c b/source/dnode/vnode/src/vnd/vnodeSvr.c index acbf2b90eb..9c0c3136ee 100644 --- a/source/dnode/vnode/src/vnd/vnodeSvr.c +++ b/source/dnode/vnode/src/vnd/vnodeSvr.c @@ -786,7 +786,7 @@ int32_t vnodeProcessQueryMsg(SVnode *pVnode, SRpcMsg *pMsg, SQueueInfo *pInfo) { int32_t vnodeProcessFetchMsg(SVnode *pVnode, SRpcMsg *pMsg, SQueueInfo *pInfo) { vTrace("vgId:%d, msg:%p in fetch queue is processing", pVnode->config.vgId, pMsg); if ((pMsg->msgType == TDMT_SCH_FETCH || pMsg->msgType == TDMT_VND_TABLE_META || pMsg->msgType == TDMT_VND_TABLE_CFG || - pMsg->msgType == TDMT_VND_BATCH_META) && + pMsg->msgType == TDMT_VND_BATCH_META || pMsg->msgType == TDMT_VND_TABLE_NAME) && !syncIsReadyForRead(pVnode->sync)) { vnodeRedirectRpcMsg(pVnode, pMsg, terrno); return 0; @@ -807,6 +807,7 @@ int32_t vnodeProcessFetchMsg(SVnode *pVnode, SRpcMsg *pMsg, SQueueInfo *pInfo) { case TDMT_SCH_QUERY_HEARTBEAT: return qWorkerProcessHbMsg(pVnode, pVnode->pQuery, pMsg, 0); case TDMT_VND_TABLE_META: + case TDMT_VND_TABLE_NAME: return vnodeGetTableMeta(pVnode, pMsg, true); case TDMT_VND_TABLE_CFG: return vnodeGetTableCfg(pVnode, pMsg, true); diff --git a/source/libs/catalog/inc/catalogInt.h b/source/libs/catalog/inc/catalogInt.h index 380e5224e1..0882db52a6 100644 --- a/source/libs/catalog/inc/catalogInt.h +++ b/source/libs/catalog/inc/catalogInt.h @@ -132,6 +132,7 @@ typedef enum { CTG_TASK_GET_VIEW, CTG_TASK_GET_TB_TSMA, CTG_TASK_GET_TSMA, + CTG_TASK_GET_TB_NAME, } CTG_TASK_TYPE; typedef enum { @@ -205,6 +206,14 @@ typedef struct SCtgTbMetasCtx { SArray* pFetchs; } SCtgTbMetasCtx; +typedef struct SCtgTbNamesCtx { + int32_t fetchNum; + SRWLatch lock; + SArray* pNames; + SArray* pResList; + SArray* pFetchs; +} SCtgTbNamesCtx; + typedef struct SCtgTbIndexCtx { SName* pName; } SCtgTbIndexCtx; @@ -421,6 +430,7 @@ typedef struct SCtgJob { int32_t viewNum; int32_t tbTsmaNum; int32_t tsmaNum; // currently, only 1 is possible + int32_t tbNameNum; } SCtgJob; typedef struct SCtgMsgCtx { @@ -797,7 +807,8 @@ typedef struct SCtgCacheItemInfo { #define CTG_IS_BATCH_TASK(_taskType) \ ((CTG_TASK_GET_TB_META_BATCH == (_taskType)) || (CTG_TASK_GET_TB_HASH_BATCH == (_taskType)) || \ - (CTG_TASK_GET_VIEW == (_taskType)) || (CTG_TASK_GET_TB_TSMA == (_taskType))) + (CTG_TASK_GET_VIEW == (_taskType)) || (CTG_TASK_GET_TB_TSMA == (_taskType)) || \ + (CTG_TASK_GET_TB_NAME == (_taskType))) #define CTG_GET_TASK_MSGCTX(_task, _id) \ (CTG_IS_BATCH_TASK((_task)->type) ? taosArrayGet((_task)->msgCtxs, (_id)) : &(_task)->msgCtx) @@ -996,6 +1007,8 @@ int32_t ctgRemoveTbMetaFromCache(SCatalog* pCtg, SName* pTableName, bool syncReq int32_t ctgGetTbMetaFromCache(SCatalog* pCtg, SCtgTbMetaCtx* ctx, STableMeta** pTableMeta); int32_t ctgGetTbMetasFromCache(SCatalog* pCtg, SRequestConnInfo* pConn, SCtgTbMetasCtx* ctx, int32_t dbIdx, int32_t* fetchIdx, int32_t baseResIdx, SArray* pList); +int32_t ctgGetTbNamesFromCache(SCatalog* pCtg, SRequestConnInfo* pConn, SCtgTbNamesCtx* ctx, int32_t dbIdx, + int32_t* fetchIdx, int32_t baseResIdx, SArray* pList); int32_t ctgCloneDbCfgInfo(void* pSrc, SDbCfgInfo** ppDst); int32_t ctgOpUpdateVgroup(SCtgCacheOperation* action); diff --git a/source/libs/catalog/src/ctgAsync.c b/source/libs/catalog/src/ctgAsync.c index c1cb6f8f44..46f4f86484 100644 --- a/source/libs/catalog/src/ctgAsync.c +++ b/source/libs/catalog/src/ctgAsync.c @@ -588,6 +588,35 @@ int32_t ctgInitGetTSMATask(SCtgJob* pJob, int32_t taskId, void* param) { return TSDB_CODE_SUCCESS; } +static int32_t ctgInitGetTbNamesTask(SCtgJob* pJob, int32_t taskId, void* param) { + SCtgTask task = {0}; + task.type = CTG_TASK_GET_TB_NAME; + task.taskId = taskId; + task.pJob = pJob; + + SCtgTbNamesCtx* pTaskCtx = taosMemoryCalloc(1, sizeof(SCtgTbNamesCtx)); + if (NULL == pTaskCtx) { + CTG_ERR_RET(terrno); + } + task.taskCtx = pTaskCtx; + taosInitRWLatch(&pTaskCtx->lock); + pTaskCtx->pNames = param; + pTaskCtx->pResList = taosArrayInit(pJob->tbNameNum, sizeof(SMetaRes)); + if (NULL == pTaskCtx->pResList) { + qError("qid:0x%" PRIx64 " taosArrayInit %d SMetaRes %d failed", pJob->queryId, pJob->tbNameNum, + (int32_t)sizeof(SMetaRes)); + ctgFreeTask(&task, true); + CTG_ERR_RET(terrno); + } + + if (NULL == taosArrayPush(pJob->pTasks, &task)) { + ctgFreeTask(&task, true); + CTG_ERR_RET(terrno); + } + + return TSDB_CODE_SUCCESS; +} + int32_t ctgHandleForceUpdateView(SCatalog* pCtg, const SCatalogReq* pReq) { int32_t viewNum = taosArrayGetSize(pReq->pView); for (int32_t i = 0; i < viewNum; ++i) { @@ -822,9 +851,10 @@ int32_t ctgInitJob(SCatalog* pCtg, SRequestConnInfo* pConn, SCtgJob** job, const int32_t viewNum = (int32_t)ctgGetTablesReqNum(pReq->pView); int32_t tbTsmaNum = (int32_t)taosArrayGetSize(pReq->pTableTSMAs); int32_t tsmaNum = (int32_t)taosArrayGetSize(pReq->pTSMAs); + int32_t tbNameNum = (int32_t)ctgGetTablesReqNum(pReq->pTableName); int32_t taskNum = tbMetaNum + dbVgNum + udfNum + tbHashNum + qnodeNum + dnodeNum + svrVerNum + dbCfgNum + indexNum + - userNum + dbInfoNum + tbIndexNum + tbCfgNum + tbTagNum + viewNum + tbTsmaNum; + userNum + dbInfoNum + tbIndexNum + tbCfgNum + tbTagNum + viewNum + tbTsmaNum + tbNameNum; *job = taosMemoryCalloc(1, sizeof(SCtgJob)); if (NULL == *job) { @@ -859,6 +889,7 @@ int32_t ctgInitJob(SCatalog* pCtg, SRequestConnInfo* pConn, SCtgJob** job, const pJob->viewNum = viewNum; pJob->tbTsmaNum = tbTsmaNum; pJob->tsmaNum = tsmaNum; + pJob->tbNameNum = tbNameNum; #if CTG_BATCH_FETCH pJob->pBatchs = @@ -991,6 +1022,9 @@ int32_t ctgInitJob(SCatalog* pCtg, SRequestConnInfo* pConn, SCtgJob** job, const if (tsmaNum > 0) { CTG_ERR_JRET(ctgInitTask(pJob, CTG_TASK_GET_TSMA, pReq->pTSMAs, NULL)); } + if (tbNameNum > 0) { + CTG_ERR_JRET(ctgInitTask(pJob, CTG_TASK_GET_TB_NAME, pReq->pTableName, NULL)); + } if (qnodeNum) { CTG_ERR_JRET(ctgInitTask(pJob, CTG_TASK_GET_QNODE, NULL, NULL)); } @@ -1059,6 +1093,18 @@ int32_t ctgDumpTbMetasRes(SCtgTask* pTask) { return TSDB_CODE_SUCCESS; } +static int32_t ctgDumpTbNamesRes(SCtgTask* pTask) { + if (pTask->subTask) { + return TSDB_CODE_SUCCESS; + } + + SCtgJob* pJob = pTask->pJob; + + pJob->jobRes.pTableMeta = pTask->res; + + return TSDB_CODE_SUCCESS; +} + int32_t ctgDumpDbVgRes(SCtgTask* pTask) { if (pTask->subTask) { return TSDB_CODE_SUCCESS; @@ -1858,6 +1904,201 @@ _return: CTG_RET(code); } +static int32_t ctgHandleGetTbNamesRsp(SCtgTaskReq* tReq, int32_t reqType, const SDataBuf* pMsg, int32_t rspCode) { + int32_t code = 0; + SCtgDBCache* dbCache = NULL; + SCtgTask* pTask = tReq->pTask; + SCatalog* pCtg = pTask->pJob->pCtg; + SRequestConnInfo* pConn = &pTask->pJob->conn; + SCtgMsgCtx* pMsgCtx = CTG_GET_TASK_MSGCTX(pTask, tReq->msgIdx); + SCtgTbNamesCtx* ctx = (SCtgTbNamesCtx*)pTask->taskCtx; + bool taskDone = false; + bool lock = false; + + if (NULL == pMsgCtx) { + ctgError("fail to get task msgCtx, taskType:%d", pTask->type); + CTG_ERR_JRET(TSDB_CODE_CTG_INTERNAL_ERROR); + } + + SCtgFetch* pFetch = taosArrayGet(ctx->pFetchs, tReq->msgIdx); + if (NULL == pFetch) { + ctgError("fail to get the %dth fetch, fetchNum:%d", tReq->msgIdx, (int32_t)taosArrayGetSize(ctx->pFetchs)); + CTG_ERR_JRET(TSDB_CODE_CTG_INTERNAL_ERROR); + } + + int32_t flag = pFetch->flag; + int32_t* vgId = &pFetch->vgId; + SName* pName = NULL; + CTG_ERR_JRET(ctgGetFetchName(ctx->pNames, pFetch, &pName)); + + if (reqType == TDMT_VND_TABLE_NAME) { + taosWLockLatch(&ctx->lock); + lock = true; + } + + CTG_ERR_JRET(ctgProcessRspMsg(pMsgCtx->out, reqType, pMsg->pData, pMsg->len, rspCode, pMsgCtx->target)); + + switch (reqType) { + case TDMT_MND_USE_DB: { + SUseDbOutput* pOut = (SUseDbOutput*)pMsgCtx->out; + CTG_ERR_RET(ctgMakeVgArray(pOut->dbVgroup)); + SArray* pVgArray = NULL; + TSWAP(pVgArray, pOut->dbVgroup->vgArray); + int32_t vgSize = taosArrayGetSize(pVgArray); + if (0 == vgSize) { + taosArrayDestroy(pVgArray); + ctgTaskError("no vgroup got, dbName:%s", pName->dbname); + CTG_ERR_RET(TSDB_CODE_CTG_INTERNAL_ERROR); + } + for (int32_t i = 0; i < vgSize; ++i) { + SVgroupInfo* vgInfo = TARRAY_GET_ELEM(pVgArray, i); + if (NULL == vgInfo) { + taosArrayDestroy(pVgArray); + ctgTaskError("fail to get the %dth vgInfo, vgSize:%d", i, vgSize); + CTG_ERR_RET(TSDB_CODE_CTG_INTERNAL_ERROR); + } + ctgTaskDebug("will refresh tbmeta, not supposed to be stb, tbName:%s, flag:%d, vgId:%d", + tNameGetTableName(pName), flag, vgInfo->vgId); + // *vgId = vgInfo->vgId; + if (i > 0) atomic_add_fetch_32(&ctx->fetchNum, 1); + code = ctgGetTbMetaFromVnode(pCtg, pConn, pName, vgInfo, NULL, tReq); + if (code) { + taosArrayDestroy(pVgArray); + CTG_ERR_JRET(code); + } + } + taosArrayDestroy(pVgArray); + + return TSDB_CODE_SUCCESS; + } + case TDMT_MND_TABLE_META: { + STableMetaOutput* pOut = (STableMetaOutput*)pMsgCtx->out; + + if (CTG_IS_META_NULL(pOut->metaType)) { + if (CTG_FLAG_IS_STB(flag)) { + char dbFName[TSDB_DB_FNAME_LEN] = {0}; + (void)tNameGetFullDbName(pName, dbFName); + + CTG_ERR_RET(ctgAcquireVgInfoFromCache(pCtg, dbFName, &dbCache)); + if (NULL != dbCache) { + SVgroupInfo vgInfo = {0}; + CTG_ERR_JRET(ctgGetVgInfoFromHashValue(pCtg, &pConn->mgmtEps, dbCache->vgCache.vgInfo, pName, &vgInfo)); + + ctgTaskDebug("will refresh tbmeta, supposed to be stb, tbName:%s, flag:%d", tNameGetTableName(pName), flag); + + *vgId = vgInfo.vgId; + CTG_ERR_JRET(ctgGetTbMetaFromVnode(pCtg, pConn, pName, &vgInfo, NULL, tReq)); + + ctgReleaseVgInfoToCache(pCtg, dbCache); + dbCache = NULL; + } else { + SBuildUseDBInput input = {0}; + + tstrncpy(input.db, dbFName, tListLen(input.db)); + input.vgVersion = CTG_DEFAULT_INVALID_VERSION; + + CTG_ERR_JRET(ctgGetDBVgInfoFromMnode(pCtg, pConn, &input, NULL, tReq)); + } + + return TSDB_CODE_SUCCESS; + } + + ctgTaskError("no tbmeta got, tbName:%s", tNameGetTableName(pName)); + (void)ctgRemoveTbMetaFromCache(pCtg, pName, false); // cache update not fatal error + + CTG_ERR_JRET(CTG_ERR_CODE_TABLE_NOT_EXIST); + } + + if (pMsgCtx->lastOut) { + TSWAP(pMsgCtx->out, pMsgCtx->lastOut); + STableMetaOutput* pLastOut = (STableMetaOutput*)pMsgCtx->out; + TSWAP(pLastOut->tbMeta, pOut->tbMeta); + } + + break; + } + case TDMT_VND_TABLE_NAME: { + STableMetaOutput* pOut = (STableMetaOutput*)pMsgCtx->out; + + if (CTG_IS_META_NULL(pOut->metaType)) { + ctgTaskError("no tbmeta got, tbName:%s", tNameGetTableName(pName)); + CTG_ERR_JRET(CTG_ERR_CODE_TABLE_NOT_EXIST); + } + + break; + } + default: + ctgTaskError("invalid reqType %d", reqType); + CTG_ERR_JRET(TSDB_CODE_INVALID_MSG); + } + + STableMetaOutput* pOut = (STableMetaOutput*)pMsgCtx->out; + if (CTG_IS_META_BOTH(pOut->metaType)) { + TAOS_MEMCPY(pOut->tbMeta, &pOut->ctbMeta, sizeof(pOut->ctbMeta)); + } + + SMetaRes* pRes = taosArrayGet(ctx->pResList, pFetch->resIdx); + if (NULL == pRes) { + ctgTaskError("fail to get the %dth res in pResList, resNum:%d", pFetch->resIdx, + (int32_t)taosArrayGetSize(ctx->pResList)); + CTG_ERR_JRET(TSDB_CODE_CTG_INTERNAL_ERROR); + } + + if (!pRes->pRes) { + pRes->code = 0; + pRes->pRes = pOut->tbMeta; + pOut->tbMeta = NULL; + } else { + taosMemoryFreeClear(pOut->tbMeta); + } + + if (0 == atomic_sub_fetch_32(&ctx->fetchNum, 1)) { + TSWAP(pTask->res, ctx->pResList); + taskDone = true; + } + +_return: + if (dbCache) { + ctgReleaseVgInfoToCache(pCtg, dbCache); + } + + if (code) { + SMetaRes* pRes = taosArrayGet(ctx->pResList, pFetch->resIdx); + if (NULL == pRes) { + ctgTaskError("fail to get the %dth res in pResList, resNum:%d", pFetch->resIdx, + (int32_t)taosArrayGetSize(ctx->pResList)); + } else { + if (0 == atomic_sub_fetch_32(&ctx->fetchNum, 1)) { + TSWAP(pTask->res, ctx->pResList); + taskDone = true; + } + if (TDMT_VND_TABLE_NAME == reqType) { + if (!pRes->pRes && (0 == pRes->code)) pRes->code = code; + } else { + pRes->pRes = NULL; + pRes->code = code; + } + if (taskDone == true) { + ctgTaskError("Get table %d.%s.%s meta failed with error %s", pName->acctId, pName->dbname, pName->tname, + tstrerror(code)); + } + } + } + + if (pTask->res && taskDone) { + int32_t newCode = ctgHandleTaskEnd(pTask, code); + if (newCode && TSDB_CODE_SUCCESS == code) { + code = newCode; + } + } + + if (lock) { + taosWUnLockLatch(&ctx->lock); + } + + CTG_RET(code); +} + int32_t ctgHandleGetDbVgRsp(SCtgTaskReq* tReq, int32_t reqType, const SDataBuf* pMsg, int32_t rspCode) { int32_t code = 0; SCtgTask* pTask = tReq->pTask; @@ -3730,6 +3971,70 @@ int32_t ctgLaunchGetTSMATask(SCtgTask* pTask) { return TSDB_CODE_SUCCESS; } +static int32_t ctgLaunchGetTbNamesTask(SCtgTask* pTask) { + SCatalog* pCtg = pTask->pJob->pCtg; + SRequestConnInfo* pConn = &pTask->pJob->conn; + SCtgTbNamesCtx* pCtx = (SCtgTbNamesCtx*)pTask->taskCtx; + SCtgJob* pJob = pTask->pJob; + SName* pName = NULL; + + int32_t dbNum = taosArrayGetSize(pCtx->pNames); + int32_t fetchIdx = 0; + int32_t baseResIdx = 0; + for (int32_t i = 0; i < dbNum; ++i) { + STablesReq* pReq = TARRAY_GET_ELEM(pCtx->pNames, i); + if (NULL == pReq) { + ctgError("fail to get the %dth STablesReq, num:%d", i, dbNum); + CTG_ERR_RET(TSDB_CODE_CTG_INVALID_INPUT); + } + + ctgDebug("start to check tbname metas in db %s, tbNum %ld", pReq->dbFName, taosArrayGetSize(pReq->pTables)); + CTG_ERR_RET(ctgGetTbNamesFromCache(pCtg, pConn, pCtx, i, &fetchIdx, baseResIdx, pReq->pTables)); + baseResIdx += taosArrayGetSize(pReq->pTables); + } + + pCtx->fetchNum = taosArrayGetSize(pCtx->pFetchs); + if (pCtx->fetchNum <= 0) { + TSWAP(pTask->res, pCtx->pResList); + + CTG_ERR_RET(ctgHandleTaskEnd(pTask, 0)); + return TSDB_CODE_SUCCESS; + } + + pTask->msgCtxs = taosArrayInit_s(sizeof(SCtgMsgCtx), pCtx->fetchNum); + if (NULL == pTask->msgCtxs) { + ctgError("taosArrayInit_s %d SCtgMsgCtx %d failed", pCtx->fetchNum, (int32_t)sizeof(SCtgMsgCtx)); + CTG_ERR_RET(terrno); + } + + for (int32_t i = 0; i < pCtx->fetchNum; ++i) { + SCtgFetch* pFetch = taosArrayGet(pCtx->pFetchs, i); + if (NULL == pFetch) { + ctgError("fail to get the %dth fetch in pCtx->pFetchs, fetchNum:%d", i, pCtx->fetchNum); + CTG_ERR_RET(TSDB_CODE_CTG_INTERNAL_ERROR); + } + + CTG_ERR_RET(ctgGetFetchName(pCtx->pNames, pFetch, &pName)); + + SCtgMsgCtx* pMsgCtx = CTG_GET_TASK_MSGCTX(pTask, i); + if (NULL == pMsgCtx) { + ctgError("fail to get the %dth pMsgCtx", i); + CTG_ERR_RET(TSDB_CODE_CTG_INTERNAL_ERROR); + } + + if (NULL == pMsgCtx->pBatchs) { + pMsgCtx->pBatchs = pJob->pBatchs; + } + + SCtgTaskReq tReq; + tReq.pTask = pTask; + tReq.msgIdx = pFetch->fetchIdx; + CTG_ERR_RET(ctgAsyncRefreshTbMeta(&tReq, pFetch->flag, pName, &pFetch->vgId)); + } + + return TSDB_CODE_SUCCESS; +} + int32_t ctgDumpTbTSMARes(SCtgTask* pTask) { if (pTask->subTask) { return TSDB_CODE_SUCCESS; @@ -3876,6 +4181,7 @@ SCtgAsyncFps gCtgAsyncFps[] = { {ctgInitGetViewsTask, ctgLaunchGetViewsTask, ctgHandleGetViewsRsp, ctgDumpViewsRes, NULL, NULL}, {ctgInitGetTbTSMATask, ctgLaunchGetTbTSMATask, ctgHandleGetTbTSMARsp, ctgDumpTbTSMARes, NULL, NULL}, {ctgInitGetTSMATask, ctgLaunchGetTSMATask, ctgHandleGetTSMARsp, ctgDumpTSMARes, NULL, NULL}, + {ctgInitGetTbNamesTask, ctgLaunchGetTbNamesTask, ctgHandleGetTbNamesRsp, ctgDumpTbNamesRes, NULL, NULL}, }; int32_t ctgMakeAsyncRes(SCtgJob* pJob) { diff --git a/source/libs/catalog/src/ctgCache.c b/source/libs/catalog/src/ctgCache.c index ea51627ba5..80650a6095 100644 --- a/source/libs/catalog/src/ctgCache.c +++ b/source/libs/catalog/src/ctgCache.c @@ -3691,6 +3691,39 @@ _return: CTG_RET(code); } +int32_t ctgGetTbNamesFromCache(SCatalog *pCtg, SRequestConnInfo *pConn, SCtgTbNamesCtx *ctx, int32_t dbIdx, + int32_t *fetchIdx, int32_t baseResIdx, SArray *pList) { + int32_t tbNum = taosArrayGetSize(pList); + char dbFName[TSDB_DB_FNAME_LEN] = {0}; + int32_t flag = CTG_FLAG_UNKNOWN_STB; + int32_t code = TSDB_CODE_SUCCESS; + uint64_t lastSuid = 0; + STableMeta *lastTableMeta = NULL; + SName *pName = taosArrayGet(pList, 0); + if (NULL == pName) { + ctgError("fail to get the 0th SName from tableList, tableNum:%d", (int32_t)taosArrayGetSize(pList)); + CTG_ERR_JRET(TSDB_CODE_CTG_INVALID_INPUT); + } + + if (IS_SYS_DBNAME(pName->dbname)) { + CTG_FLAG_SET_SYS_DB(flag); + TAOS_STRCPY(dbFName, pName->dbname); + } else { + (void)tNameGetFullDbName(pName, dbFName); + } + + ctgDebug("db %s not in cache", dbFName); + for (int32_t i = 0; i < tbNum; ++i) { + CTG_ERR_JRET(ctgAddFetch(&ctx->pFetchs, dbIdx, i, fetchIdx, baseResIdx + i, flag)); + if (NULL == taosArrayPush(ctx->pResList, &(SMetaData){0})) { + CTG_ERR_JRET(TSDB_CODE_OUT_OF_MEMORY); + } + } + +_return: + return code; +} + int32_t ctgGetTbHashVgroupFromCache(SCatalog *pCtg, const SName *pTableName, SVgroupInfo **pVgroup) { if (IS_SYS_DBNAME(pTableName->dbname)) { ctgError("no valid vgInfo for db, dbname:%s", pTableName->dbname); diff --git a/source/libs/catalog/src/ctgRemote.c b/source/libs/catalog/src/ctgRemote.c index 402686a219..d6e941c819 100644 --- a/source/libs/catalog/src/ctgRemote.c +++ b/source/libs/catalog/src/ctgRemote.c @@ -297,6 +297,27 @@ int32_t ctgProcessRspMsg(void* out, int32_t reqType, char* msg, int32_t msgSize, qDebug("Got table meta from vnode, tbFName:%s", target); break; } + case TDMT_VND_TABLE_NAME: { + if (TSDB_CODE_SUCCESS != rspCode) { + if (CTG_TABLE_NOT_EXIST(rspCode)) { + SET_META_TYPE_NULL(((STableMetaOutput*)out)->metaType); + qDebug("tablemeta not exist in vnode, tbFName:%s", target); + return TSDB_CODE_SUCCESS; + } + + qError("error rsp for table meta from vnode, code:%s, tbFName:%s", tstrerror(rspCode), target); + CTG_ERR_RET(rspCode); + } + + code = queryProcessMsgRsp[TMSG_INDEX(reqType)](out, msg, msgSize); + if (code) { + qError("Process vnode tablemeta rsp failed, code:%s, tbFName:%s", tstrerror(code), target); + CTG_ERR_RET(code); + } + + qDebug("Got table meta from vnode, tbFName:%s", target); + break; + } case TDMT_VND_TABLE_CFG: { if (TSDB_CODE_SUCCESS != rspCode) { qError("error rsp for table cfg from vnode, code:%s, tbFName:%s", tstrerror(rspCode), target); @@ -600,7 +621,7 @@ int32_t ctgAddBatch(SCatalog* pCtg, int32_t vgId, SRequestConnInfo* pConn, SCtgT if (TDMT_VND_TABLE_CFG == msgType) { SCtgTbCfgCtx* ctx = (SCtgTbCfgCtx*)pTask->taskCtx; pName = ctx->pName; - } else if (TDMT_VND_TABLE_META == msgType) { + } else if (TDMT_VND_TABLE_META == msgType || TDMT_VND_TABLE_NAME == msgType) { if (CTG_TASK_GET_TB_META_BATCH == pTask->type) { SCtgTbMetasCtx* ctx = (SCtgTbMetasCtx*)pTask->taskCtx; SCtgFetch* fetch = taosArrayGet(ctx->pFetchs, tReq->msgIdx); @@ -614,6 +635,10 @@ int32_t ctgAddBatch(SCatalog* pCtg, int32_t vgId, SRequestConnInfo* pConn, SCtgT ctgError("fail to get %d SName, totalTables:%d", pFetch->tbIdx, (int32_t)taosArrayGetSize(pTbReq->pTables)); CTG_ERR_JRET(TSDB_CODE_CTG_INTERNAL_ERROR); } + } else if (CTG_TASK_GET_TB_NAME == pTask->type) { + SCtgTbNamesCtx* ctx = (SCtgTbNamesCtx*)pTask->taskCtx; + SCtgFetch* fetch = taosArrayGet(ctx->pFetchs, tReq->msgIdx); + CTG_ERR_JRET(ctgGetFetchName(ctx->pNames, fetch, &pName)); } else { SCtgTbMetaCtx* ctx = (SCtgTbMetaCtx*)pTask->taskCtx; pName = ctx->pName; @@ -677,7 +702,7 @@ int32_t ctgAddBatch(SCatalog* pCtg, int32_t vgId, SRequestConnInfo* pConn, SCtgT if (TDMT_VND_TABLE_CFG == msgType) { SCtgTbCfgCtx* ctx = (SCtgTbCfgCtx*)pTask->taskCtx; pName = ctx->pName; - } else if (TDMT_VND_TABLE_META == msgType) { + } else if (TDMT_VND_TABLE_META == msgType || TDMT_VND_TABLE_NAME == msgType) { if (CTG_TASK_GET_TB_META_BATCH == pTask->type) { SCtgTbMetasCtx* ctx = (SCtgTbMetasCtx*)pTask->taskCtx; SCtgFetch* fetch = taosArrayGet(ctx->pFetchs, tReq->msgIdx); @@ -691,6 +716,10 @@ int32_t ctgAddBatch(SCatalog* pCtg, int32_t vgId, SRequestConnInfo* pConn, SCtgT ctgError("fail to get %d SName, totalTables:%d", pFetch->tbIdx, (int32_t)taosArrayGetSize(pTbReq->pTables)); CTG_ERR_JRET(TSDB_CODE_CTG_INTERNAL_ERROR); } + } else if (CTG_TASK_GET_TB_NAME == pTask->type) { + SCtgTbMetasCtx* ctx = (SCtgTbMetasCtx*)pTask->taskCtx; + SCtgFetch* fetch = taosArrayGet(ctx->pFetchs, tReq->msgIdx); + CTG_ERR_JRET(ctgGetFetchName(ctx->pNames, fetch, &pName)); } else { SCtgTbMetaCtx* ctx = (SCtgTbMetaCtx*)pTask->taskCtx; pName = ctx->pName; @@ -1337,7 +1366,7 @@ int32_t ctgGetTbMetaFromVnode(SCatalog* pCtg, SRequestConnInfo* pConn, const SNa SCtgTask* pTask = tReq ? tReq->pTask : NULL; char dbFName[TSDB_DB_FNAME_LEN]; (void)tNameGetFullDbName(pTableName, dbFName); - int32_t reqType = TDMT_VND_TABLE_META; + int32_t reqType = (pTask && pTask->type == CTG_TASK_GET_TB_NAME ? TDMT_VND_TABLE_NAME : TDMT_VND_TABLE_META); char tbFName[TSDB_TABLE_FNAME_LEN]; (void)sprintf(tbFName, "%s.%s", dbFName, pTableName->tname); void* (*mallocFp)(int64_t) = pTask ? (MallocType)taosMemoryMalloc : (MallocType)rpcMallocCont; @@ -1346,10 +1375,12 @@ int32_t ctgGetTbMetaFromVnode(SCatalog* pCtg, SRequestConnInfo* pConn, const SNa ctgDebug("try to get table meta from vnode, vgId:%d, ep num:%d, ep %s:%d, tbFName:%s", vgroupInfo->vgId, vgroupInfo->epSet.numOfEps, pEp->fqdn, pEp->port, tbFName); - SBuildTableInput bInput = { - .vgId = vgroupInfo->vgId, .dbFName = dbFName, .tbName = (char*)tNameGetTableName(pTableName)}; - char* msg = NULL; - int32_t msgLen = 0; + SBuildTableInput bInput = {.vgId = vgroupInfo->vgId, + .option = reqType == TDMT_VND_TABLE_NAME ? REQ_OPT_TBUID : REQ_OPT_TBNAME, + .dbFName = dbFName, + .tbName = (char*)tNameGetTableName(pTableName)}; + char* msg = NULL; + int32_t msgLen = 0; int32_t code = queryBuildMsg[TMSG_INDEX(reqType)](&bInput, &msg, 0, &msgLen, mallocFp); if (code) { diff --git a/source/libs/catalog/src/ctgUtil.c b/source/libs/catalog/src/ctgUtil.c index e3ae0419d8..96cd783d2f 100644 --- a/source/libs/catalog/src/ctgUtil.c +++ b/source/libs/catalog/src/ctgUtil.c @@ -111,6 +111,8 @@ char* ctgTaskTypeStr(CTG_TASK_TYPE type) { return "[get table TSMA]"; case CTG_TASK_GET_TSMA: return "[get TSMA]"; + case CTG_TASK_GET_TB_NAME: + return "[bget table name]"; default: return "unknown"; } @@ -584,7 +586,8 @@ void ctgFreeMsgCtx(SCtgMsgCtx* pCtx) { break; } case TDMT_VND_TABLE_META: - case TDMT_MND_TABLE_META: { + case TDMT_MND_TABLE_META: + case TDMT_VND_TABLE_NAME: { STableMetaOutput* pOut = (STableMetaOutput*)pCtx->out; taosMemoryFree(pOut->tbMeta); taosMemoryFreeClear(pCtx->out); @@ -844,6 +847,15 @@ void ctgFreeTaskRes(CTG_TASK_TYPE type, void** pRes) { *pRes = NULL; break; } + case CTG_TASK_GET_TB_NAME: { + SArray* pArray = (SArray*)*pRes; + int32_t num = taosArrayGetSize(pArray); + for (int32_t i = 0; i < num; ++i) { + ctgFreeBatchMeta(taosArrayGet(pArray, i)); + } + *pRes = NULL; // no need to free it + break; + } default: qError("invalid task type %d", type); break; @@ -906,6 +918,11 @@ void ctgFreeSubTaskRes(CTG_TASK_TYPE type, void** pRes) { *pRes = NULL; break; } + case CTG_TASK_GET_TB_NAME: { + taosArrayDestroyEx(*pRes, ctgFreeBatchMeta); + *pRes = NULL; + break; + } default: qError("invalid task type %d", type); break; @@ -1016,6 +1033,21 @@ void ctgFreeTaskCtx(SCtgTask* pTask) { taosMemoryFreeClear(pTask->taskCtx); break; } + case CTG_TASK_GET_TB_NAME: { + SCtgTbNamesCtx* taskCtx = (SCtgTbNamesCtx*)pTask->taskCtx; + taosArrayDestroyEx(taskCtx->pResList, ctgFreeBatchMeta); + taosArrayDestroy(taskCtx->pFetchs); + // NO NEED TO FREE pNames + + taosArrayDestroyEx(pTask->msgCtxs, (FDelete)ctgFreeTbMetasMsgCtx); + + if (pTask->msgCtx.lastOut) { + ctgFreeSTableMetaOutput((STableMetaOutput*)pTask->msgCtx.lastOut); + pTask->msgCtx.lastOut = NULL; + } + taosMemoryFreeClear(pTask->taskCtx); + break; + } default: qError("invalid task type %d", pTask->type); break; @@ -1140,6 +1172,8 @@ int32_t ctgGenerateVgList(SCatalog* pCtg, SHashObj* vgHash, SArray** pList) { pIter = taosHashIterate(vgHash, pIter); } + taosArraySort(vgList, ctgVgInfoComp); + *pList = vgList; ctgDebug("Got vgList from cache, vgNum:%d", vgNum); @@ -1533,7 +1567,8 @@ int32_t ctgMakeVgArray(SDBVgInfo* dbInfo) { } if (dbInfo->vgHash && NULL == dbInfo->vgArray) { - dbInfo->vgArray = taosArrayInit(100, sizeof(SVgroupInfo)); + int32_t vgSize = taosHashGetSize(dbInfo->vgHash); + dbInfo->vgArray = taosArrayInit(vgSize, sizeof(SVgroupInfo)); if (NULL == dbInfo->vgArray) { CTG_ERR_RET(terrno); } @@ -1669,7 +1704,7 @@ int32_t ctgCloneTableIndex(SArray* pIndex, SArray** pRes) { } int32_t ctgUpdateSendTargetInfo(SMsgSendInfo* pMsgSendInfo, int32_t msgType, char* dbFName, int32_t vgId) { - if (msgType == TDMT_VND_TABLE_META || msgType == TDMT_VND_TABLE_CFG || msgType == TDMT_VND_BATCH_META) { + if (msgType == TDMT_VND_TABLE_META || msgType == TDMT_VND_TABLE_CFG || msgType == TDMT_VND_BATCH_META || msgType == TDMT_VND_TABLE_NAME) { pMsgSendInfo->target.type = TARGET_TYPE_VNODE; pMsgSendInfo->target.vgId = vgId; pMsgSendInfo->target.dbFName = taosStrdup(dbFName); diff --git a/source/libs/executor/inc/executorInt.h b/source/libs/executor/inc/executorInt.h index 48adb22927..4a2d6bfcd3 100644 --- a/source/libs/executor/inc/executorInt.h +++ b/source/libs/executor/inc/executorInt.h @@ -844,8 +844,8 @@ void initLimitInfo(const SNode* pLimit, const SNode* pSLimit, SLimitInfo* pLimit void resetLimitInfoForNextGroup(SLimitInfo* pLimitInfo); bool applyLimitOffset(SLimitInfo* pLimitInfo, SSDataBlock* pBlock, SExecTaskInfo* pTaskInfo); -void applyAggFunctionOnPartialTuples(SExecTaskInfo* taskInfo, SqlFunctionCtx* pCtx, SColumnInfoData* pTimeWindowData, - int32_t offset, int32_t forwardStep, int32_t numOfTotal, int32_t numOfOutput); +int32_t applyAggFunctionOnPartialTuples(SExecTaskInfo* taskInfo, SqlFunctionCtx* pCtx, SColumnInfoData* pTimeWindowData, + int32_t offset, int32_t forwardStep, int32_t numOfTotal, int32_t numOfOutput); int32_t extractDataBlockFromFetchRsp(SSDataBlock* pRes, char* pData, SArray* pColList, char** pNextStart); void updateLoadRemoteInfo(SLoadRemoteDataInfo* pInfo, int64_t numOfRows, int32_t dataLen, int64_t startTs, @@ -916,8 +916,8 @@ SSDataBlock* buildCreateTableBlock(SExprSupp* tbName, SExprSupp* tag); SExprInfo* createExpr(SNodeList* pNodeList, int32_t* numOfExprs); void destroyExprInfo(SExprInfo* pExpr, int32_t numOfExprs); -void copyResultrowToDataBlock(SExprInfo* pExprInfo, int32_t numOfExprs, SResultRow* pRow, SqlFunctionCtx* pCtx, - SSDataBlock* pBlock, const int32_t* rowEntryOffset, SExecTaskInfo* pTaskInfo); +int32_t copyResultrowToDataBlock(SExprInfo* pExprInfo, int32_t numOfExprs, SResultRow* pRow, SqlFunctionCtx* pCtx, + SSDataBlock* pBlock, const int32_t* rowEntryOffset, SExecTaskInfo* pTaskInfo); void doUpdateNumOfRows(SqlFunctionCtx* pCtx, SResultRow* pRow, int32_t numOfExprs, const int32_t* rowEntryOffset); void doClearBufferedBlocks(SStreamScanInfo* pInfo); diff --git a/source/libs/executor/src/aggregateoperator.c b/source/libs/executor/src/aggregateoperator.c index 4605d19464..f1c9f1d32b 100644 --- a/source/libs/executor/src/aggregateoperator.c +++ b/source/libs/executor/src/aggregateoperator.c @@ -613,8 +613,9 @@ int32_t initAggSup(SExprSupp* pSup, SAggSupporter* pAggSup, SExprInfo* pExprInfo return TSDB_CODE_SUCCESS; } -void applyAggFunctionOnPartialTuples(SExecTaskInfo* taskInfo, SqlFunctionCtx* pCtx, SColumnInfoData* pTimeWindowData, - int32_t offset, int32_t forwardStep, int32_t numOfTotal, int32_t numOfOutput) { +int32_t applyAggFunctionOnPartialTuples(SExecTaskInfo* taskInfo, SqlFunctionCtx* pCtx, SColumnInfoData* pTimeWindowData, + int32_t offset, int32_t forwardStep, int32_t numOfTotal, int32_t numOfOutput) { + int32_t code = TSDB_CODE_SUCCESS; for (int32_t k = 0; k < numOfOutput; ++k) { // keep it temporarily SFunctionCtxStatus status = {0}; @@ -641,15 +642,14 @@ void applyAggFunctionOnPartialTuples(SExecTaskInfo* taskInfo, SqlFunctionCtx* pC SScalarParam out = {.columnData = &idata}; SScalarParam tw = {.numOfRows = 5, .columnData = pTimeWindowData}; - int32_t code = pCtx[k].sfp.process(&tw, 1, &out); + code = pCtx[k].sfp.process(&tw, 1, &out); if (code != TSDB_CODE_SUCCESS) { qError("%s failed at line %d since %s", __func__, __LINE__, tstrerror(code)); taskInfo->code = code; - T_LONG_JMP(taskInfo->env, code); + return code; } pEntryInfo->numOfRes = 1; } else { - int32_t code = TSDB_CODE_SUCCESS; if (functionNeedToExecute(&pCtx[k]) && pCtx[k].fpSet.process != NULL) { if ((&pCtx[k])->input.pData[0] == NULL) { code = TSDB_CODE_QRY_EXECUTOR_INTERNAL_ERROR; @@ -664,7 +664,7 @@ void applyAggFunctionOnPartialTuples(SExecTaskInfo* taskInfo, SqlFunctionCtx* pC } qError("%s apply functions error, code: %s", GET_TASKID(taskInfo), tstrerror(code)); taskInfo->code = code; - T_LONG_JMP(taskInfo->env, code); + return code; } } @@ -672,6 +672,7 @@ void applyAggFunctionOnPartialTuples(SExecTaskInfo* taskInfo, SqlFunctionCtx* pC functionCtxRestore(&pCtx[k], &status); } } + return code; } void functionCtxSave(SqlFunctionCtx* pCtx, SFunctionCtxStatus* pStatus) { diff --git a/source/libs/executor/src/countwindowoperator.c b/source/libs/executor/src/countwindowoperator.c index 2233d58ef8..542a7c89a9 100644 --- a/source/libs/executor/src/countwindowoperator.c +++ b/source/libs/executor/src/countwindowoperator.c @@ -149,8 +149,9 @@ void doCountWindowAggImpl(SOperatorInfo* pOperator, SSDataBlock* pBlock) { pInfo->pRow->win.ekey = tsCols[num + i - 1]; updateTimeWindowInfo(&pInfo->twAggSup.timeWindowData, &pInfo->pRow->win, 0); - applyAggFunctionOnPartialTuples(pTaskInfo, pExprSup->pCtx, &pInfo->twAggSup.timeWindowData, i, num, - pBlock->info.rows, pExprSup->numOfExprs); + code = applyAggFunctionOnPartialTuples(pTaskInfo, pExprSup->pCtx, &pInfo->twAggSup.timeWindowData, i, num, + pBlock->info.rows, pExprSup->numOfExprs); + QUERY_CHECK_CODE(code, lino, _end); if (pInfo->windowCount != pInfo->windowSliding) { if (prevRows <= pInfo->windowSliding) { if (pBuffInfo->winRows > pInfo->windowSliding) { @@ -164,8 +165,9 @@ void doCountWindowAggImpl(SOperatorInfo* pOperator, SSDataBlock* pBlock) { } if (pBuffInfo->winRows == pInfo->windowCount) { doUpdateNumOfRows(pExprSup->pCtx, pInfo->pRow, pExprSup->numOfExprs, pExprSup->rowEntryInfoOffset); - copyResultrowToDataBlock(pExprSup->pExprInfo, pExprSup->numOfExprs, pInfo->pRow, pExprSup->pCtx, pRes, - pExprSup->rowEntryInfoOffset, pTaskInfo); + code = copyResultrowToDataBlock(pExprSup->pExprInfo, pExprSup->numOfExprs, pInfo->pRow, pExprSup->pCtx, pRes, + pExprSup->rowEntryInfoOffset, pTaskInfo); + QUERY_CHECK_CODE(code, lino, _end); pRes->info.rows += pInfo->pRow->numOfRows; clearWinStateBuff(pBuffInfo); pInfo->preStateIndex = pInfo->countSup.curStateIndex; @@ -205,8 +207,9 @@ static void buildCountResult(SExprSupp* pExprSup, SCountWindowSupp* pCountSup, S continue; } doUpdateNumOfRows(pExprSup->pCtx, pResultRow, pExprSup->numOfExprs, pExprSup->rowEntryInfoOffset); - copyResultrowToDataBlock(pExprSup->pExprInfo, pExprSup->numOfExprs, pResultRow, pExprSup->pCtx, pBlock, - pExprSup->rowEntryInfoOffset, pTaskInfo); + code = copyResultrowToDataBlock(pExprSup->pExprInfo, pExprSup->numOfExprs, pResultRow, pExprSup->pCtx, pBlock, + pExprSup->rowEntryInfoOffset, pTaskInfo); + QUERY_CHECK_CODE(code, lino, _end); pBlock->info.rows += pResultRow->numOfRows; clearWinStateBuff(pBuff); clearResultRowInitFlag(pExprSup->pCtx, pExprSup->numOfExprs); diff --git a/source/libs/executor/src/eventwindowoperator.c b/source/libs/executor/src/eventwindowoperator.c index 0f3a08c14b..e164e07252 100644 --- a/source/libs/executor/src/eventwindowoperator.c +++ b/source/libs/executor/src/eventwindowoperator.c @@ -260,8 +260,10 @@ static int32_t setSingleOutputTupleBufv1(SResultRowInfo* pResultRowInfo, STimeWi return setResultRowInitCtx(*pResult, pExprSup->pCtx, pExprSup->numOfExprs, pExprSup->rowEntryInfoOffset); } -static void doEventWindowAggImpl(SEventWindowOperatorInfo* pInfo, SExprSupp* pSup, int32_t startIndex, int32_t endIndex, - const SSDataBlock* pBlock, int64_t* tsList, SExecTaskInfo* pTaskInfo) { +static int32_t doEventWindowAggImpl(SEventWindowOperatorInfo* pInfo, SExprSupp* pSup, int32_t startIndex, + int32_t endIndex, const SSDataBlock* pBlock, int64_t* tsList, + SExecTaskInfo* pTaskInfo) { + int32_t code = TSDB_CODE_SUCCESS; SWindowRowsSup* pRowSup = &pInfo->winSup; int32_t numOfOutput = pSup->numOfExprs; @@ -269,15 +271,16 @@ static void doEventWindowAggImpl(SEventWindowOperatorInfo* pInfo, SExprSupp* pSu doKeepTuple(pRowSup, tsList[endIndex], pBlock->info.id.groupId); - int32_t ret = - setSingleOutputTupleBufv1(&pInfo->binfo.resultRowInfo, &pRowSup->win, &pInfo->pRow, pSup, &pInfo->aggSup); - if (ret != TSDB_CODE_SUCCESS) { // null data, too many state code - T_LONG_JMP(pTaskInfo->env, TSDB_CODE_APP_ERROR); + code = setSingleOutputTupleBufv1(&pInfo->binfo.resultRowInfo, &pRowSup->win, &pInfo->pRow, pSup, &pInfo->aggSup); + if (code != TSDB_CODE_SUCCESS) { // null data, too many state code + qError("failed to set single output tuple buffer, code:%d", code); + return code; } updateTimeWindowInfo(&pInfo->twAggSup.timeWindowData, &pRowSup->win, 0); - applyAggFunctionOnPartialTuples(pTaskInfo, pSup->pCtx, &pInfo->twAggSup.timeWindowData, startIndex, numOfRows, - pBlock->info.rows, numOfOutput); + code = applyAggFunctionOnPartialTuples(pTaskInfo, pSup->pCtx, &pInfo->twAggSup.timeWindowData, startIndex, numOfRows, + pBlock->info.rows, numOfOutput); + return code; } int32_t eventWindowAggImpl(SOperatorInfo* pOperator, SEventWindowOperatorInfo* pInfo, SSDataBlock* pBlock) { @@ -287,11 +290,11 @@ int32_t eventWindowAggImpl(SOperatorInfo* pOperator, SEventWindowOperatorInfo* p SExprSupp* pSup = &pOperator->exprSupp; SSDataBlock* pRes = pInfo->binfo.pRes; int64_t gid = pBlock->info.id.groupId; + SColumnInfoData *ps = NULL, *pe = NULL; SColumnInfoData* pColInfoData = taosArrayGet(pBlock->pDataBlock, pInfo->tsSlotId); QUERY_CHECK_NULL(pColInfoData, code, lino, _return, terrno); TSKEY* tsList = (TSKEY*)pColInfoData->pData; SWindowRowsSup* pRowSup = &pInfo->winSup; - SColumnInfoData *ps = NULL, *pe = NULL; int32_t rowIndex = 0; pRowSup->numOfRows = 0; @@ -333,7 +336,8 @@ int32_t eventWindowAggImpl(SOperatorInfo* pOperator, SEventWindowOperatorInfo* p } if (rowIndex < pBlock->info.rows) { - doEventWindowAggImpl(pInfo, pSup, startIndex, rowIndex, pBlock, tsList, pTaskInfo); + code = doEventWindowAggImpl(pInfo, pSup, startIndex, rowIndex, pBlock, tsList, pTaskInfo); + QUERY_CHECK_CODE(code, lino, _return); doUpdateNumOfRows(pSup->pCtx, pInfo->pRow, pSup->numOfExprs, pSup->rowEntryInfoOffset); // check buffer size @@ -343,8 +347,9 @@ int32_t eventWindowAggImpl(SOperatorInfo* pOperator, SEventWindowOperatorInfo* p QUERY_CHECK_CODE(code, lino, _return); } - copyResultrowToDataBlock(pSup->pExprInfo, pSup->numOfExprs, pInfo->pRow, pSup->pCtx, pRes, - pSup->rowEntryInfoOffset, pTaskInfo); + code = copyResultrowToDataBlock(pSup->pExprInfo, pSup->numOfExprs, pInfo->pRow, pSup->pCtx, pRes, + pSup->rowEntryInfoOffset, pTaskInfo); + QUERY_CHECK_CODE(code, lino, _return); pRes->info.rows += pInfo->pRow->numOfRows; pInfo->pRow->numOfRows = 0; @@ -352,7 +357,8 @@ int32_t eventWindowAggImpl(SOperatorInfo* pOperator, SEventWindowOperatorInfo* p pInfo->inWindow = false; rowIndex += 1; } else { - doEventWindowAggImpl(pInfo, pSup, startIndex, pBlock->info.rows - 1, pBlock, tsList, pTaskInfo); + code = doEventWindowAggImpl(pInfo, pSup, startIndex, pBlock->info.rows - 1, pBlock, tsList, pTaskInfo); + QUERY_CHECK_CODE(code, lino, _return); } } else { // find the first start value that is fulfill for the start condition for (; rowIndex < pBlock->info.rows; ++rowIndex) { diff --git a/source/libs/executor/src/executorInt.c b/source/libs/executor/src/executorInt.c index b5c05c8558..07224961f9 100644 --- a/source/libs/executor/src/executorInt.c +++ b/source/libs/executor/src/executorInt.c @@ -666,8 +666,8 @@ void doUpdateNumOfRows(SqlFunctionCtx* pCtx, SResultRow* pRow, int32_t numOfExpr } } -void copyResultrowToDataBlock(SExprInfo* pExprInfo, int32_t numOfExprs, SResultRow* pRow, SqlFunctionCtx* pCtx, - SSDataBlock* pBlock, const int32_t* rowEntryOffset, SExecTaskInfo* pTaskInfo) { +int32_t copyResultrowToDataBlock(SExprInfo* pExprInfo, int32_t numOfExprs, SResultRow* pRow, SqlFunctionCtx* pCtx, + SSDataBlock* pBlock, const int32_t* rowEntryOffset, SExecTaskInfo* pTaskInfo) { int32_t code = TSDB_CODE_SUCCESS; int32_t lino = 0; for (int32_t j = 0; j < numOfExprs; ++j) { @@ -690,7 +690,7 @@ void copyResultrowToDataBlock(SExprInfo* pExprInfo, int32_t numOfExprs, SResultR int32_t winCode = pCtx[j].fpSet.finalize(&pCtx[j], pBlock); if (TAOS_FAILED(winCode)) { qError("%s build result data block error, code %s", GET_TASKID(pTaskInfo), tstrerror(winCode)); - T_LONG_JMP(pTaskInfo->env, winCode); + QUERY_CHECK_CODE(winCode, lino, _end); } } else if (strcmp(pCtx[j].pExpr->pExpr->_function.functionName, "_select_value") == 0) { // do nothing @@ -710,8 +710,8 @@ void copyResultrowToDataBlock(SExprInfo* pExprInfo, int32_t numOfExprs, SResultR _end: if (code != TSDB_CODE_SUCCESS) { qError("%s failed at line %d since %s", __func__, lino, tstrerror(code)); - T_LONG_JMP(pTaskInfo->env, code); } + return code; } // todo refactor. SResultRow has direct pointer in miainfo @@ -747,7 +747,12 @@ void finalizeResultRows(SDiskbasedBuf* pBuf, SResultRowPosition* resultRowPositi T_LONG_JMP(pTaskInfo->env, code); } - copyResultrowToDataBlock(pExprInfo, pSup->numOfExprs, pRow, pCtx, pBlock, rowEntryOffset, pTaskInfo); + code = copyResultrowToDataBlock(pExprInfo, pSup->numOfExprs, pRow, pCtx, pBlock, rowEntryOffset, pTaskInfo); + if (TAOS_FAILED(code)) { + releaseBufPage(pBuf, page); + qError("%s copy result row to datablock failed, code %s", GET_TASKID(pTaskInfo), tstrerror(code)); + T_LONG_JMP(pTaskInfo->env, code); + } releaseBufPage(pBuf, page); pBlock->info.rows += pRow->numOfRows; @@ -818,9 +823,9 @@ void doCopyToSDataBlockByHash(SExecTaskInfo* pTaskInfo, SSDataBlock* pBlock, SEx pGroupResInfo->iter = iter; pGroupResInfo->dataPos = pData; - copyResultrowToDataBlock(pExprInfo, numOfExprs, pRow, pCtx, pBlock, rowEntryOffset, pTaskInfo); - + code = copyResultrowToDataBlock(pExprInfo, numOfExprs, pRow, pCtx, pBlock, rowEntryOffset, pTaskInfo); releaseBufPage(pBuf, page); + QUERY_CHECK_CODE(code, lino, _end); pBlock->info.rows += pRow->numOfRows; if (pBlock->info.rows >= threshold) { break; @@ -892,9 +897,10 @@ void doCopyToSDataBlock(SExecTaskInfo* pTaskInfo, SSDataBlock* pBlock, SExprSupp } pGroupResInfo->index += 1; - copyResultrowToDataBlock(pExprInfo, numOfExprs, pRow, pCtx, pBlock, rowEntryOffset, pTaskInfo); - + code = copyResultrowToDataBlock(pExprInfo, numOfExprs, pRow, pCtx, pBlock, rowEntryOffset, pTaskInfo); releaseBufPage(pBuf, page); + QUERY_CHECK_CODE(code, lino, _end); + pBlock->info.rows += pRow->numOfRows; if (pBlock->info.rows >= threshold) { break; diff --git a/source/libs/executor/src/groupcacheoperator.c b/source/libs/executor/src/groupcacheoperator.c index 06706b57ee..e4f6d73b7b 100644 --- a/source/libs/executor/src/groupcacheoperator.c +++ b/source/libs/executor/src/groupcacheoperator.c @@ -373,8 +373,16 @@ _return: return code; } + +void freeGcBlkBufInfo(void* ptr) { + SGcBlkBufInfo* pBlk = (SGcBlkBufInfo*)ptr; + taosMemoryFreeClear(pBlk->pBuf); +} + + static int32_t addBlkToDirtyBufList(SGroupCacheOperatorInfo* pGCache, SGcDownstreamCtx* pCtx, SGcBlkCacheInfo* pCache, SGcBlkBufInfo* pBufInfo) { if (0 != taosHashPut(pCache->pDirtyBlk, &pBufInfo->basic.blkId, sizeof(pBufInfo->basic.blkId), pBufInfo, sizeof(*pBufInfo))) { + freeGcBlkBufInfo(pBufInfo); return TSDB_CODE_OUT_OF_MEMORY; } pBufInfo = taosHashGet(pCache->pDirtyBlk, &pBufInfo->basic.blkId, sizeof(pBufInfo->basic.blkId)); @@ -1239,10 +1247,6 @@ _return: return code; } -void freeGcBlkBufInfo(void* ptr) { - SGcBlkBufInfo* pBlk = (SGcBlkBufInfo*)ptr; - taosMemoryFree(pBlk->pBuf); -} static int32_t initGroupCacheBlockCache(SGroupCacheOperatorInfo* pInfo) { SGcBlkCacheInfo* pCache = &pInfo->blkCache; diff --git a/source/libs/executor/src/groupoperator.c b/source/libs/executor/src/groupoperator.c index 83a579615c..c862a44461 100644 --- a/source/libs/executor/src/groupoperator.c +++ b/source/libs/executor/src/groupoperator.c @@ -329,8 +329,11 @@ static void doHashGroupbyAgg(SOperatorInfo* pOperator, SSDataBlock* pBlock) { } int32_t rowIndex = j - num; - applyAggFunctionOnPartialTuples(pTaskInfo, pCtx, NULL, rowIndex, num, pBlock->info.rows, - pOperator->exprSupp.numOfExprs); + ret = applyAggFunctionOnPartialTuples(pTaskInfo, pCtx, NULL, rowIndex, num, pBlock->info.rows, + pOperator->exprSupp.numOfExprs); + if (ret != TSDB_CODE_SUCCESS) { + T_LONG_JMP(pTaskInfo->env, ret); + } // assign the group keys or user input constant values if required doAssignGroupKeys(pCtx, pOperator->exprSupp.numOfExprs, pBlock->info.rows, rowIndex); @@ -347,8 +350,11 @@ static void doHashGroupbyAgg(SOperatorInfo* pOperator, SSDataBlock* pBlock) { } int32_t rowIndex = pBlock->info.rows - num; - applyAggFunctionOnPartialTuples(pTaskInfo, pCtx, NULL, rowIndex, num, pBlock->info.rows, - pOperator->exprSupp.numOfExprs); + ret = applyAggFunctionOnPartialTuples(pTaskInfo, pCtx, NULL, rowIndex, num, pBlock->info.rows, + pOperator->exprSupp.numOfExprs); + if (ret != TSDB_CODE_SUCCESS) { + T_LONG_JMP(pTaskInfo->env, ret); + } doAssignGroupKeys(pCtx, pOperator->exprSupp.numOfExprs, pBlock->info.rows, rowIndex); } } diff --git a/source/libs/executor/src/streamtimewindowoperator.c b/source/libs/executor/src/streamtimewindowoperator.c index 09bf73c1ee..fb8d8d654e 100644 --- a/source/libs/executor/src/streamtimewindowoperator.c +++ b/source/libs/executor/src/streamtimewindowoperator.c @@ -1172,8 +1172,9 @@ static int32_t doStreamIntervalAggImpl(SOperatorInfo* pOperator, SSDataBlock* pS } updateTimeWindowInfo(&pInfo->twAggSup.timeWindowData, &nextWin, 1); - applyAggFunctionOnPartialTuples(pTaskInfo, pSup->pCtx, &pInfo->twAggSup.timeWindowData, startPos, forwardRows, - pSDataBlock->info.rows, numOfOutput); + code = applyAggFunctionOnPartialTuples(pTaskInfo, pSup->pCtx, &pInfo->twAggSup.timeWindowData, startPos, + forwardRows, pSDataBlock->info.rows, numOfOutput); + QUERY_CHECK_CODE(code, lino, _end); key.ts = nextWin.skey; if (pInfo->delKey.ts > key.ts) { @@ -2442,7 +2443,7 @@ int32_t doOneWindowAggImpl(SColumnInfoData* pTimeWindowData, SResultWindowInfo* QUERY_CHECK_CODE(code, lino, _end); updateTimeWindowInfo(pTimeWindowData, &pCurWin->sessionWin.win, winDelta); - applyAggFunctionOnPartialTuples(pTaskInfo, pSup->pCtx, pTimeWindowData, startIndex, winRows, rows, numOutput); + code = applyAggFunctionOnPartialTuples(pTaskInfo, pSup->pCtx, pTimeWindowData, startIndex, winRows, rows, numOutput); _end: if (code != TSDB_CODE_SUCCESS) { @@ -5474,8 +5475,9 @@ static void doStreamMidIntervalAggImpl(SOperatorInfo* pOperator, SSDataBlock* pS } updateTimeWindowInfo(&pInfo->twAggSup.timeWindowData, &nextWin, 1); - applyAggFunctionOnPartialTuples(pTaskInfo, pSup->pCtx, &pInfo->twAggSup.timeWindowData, startPos, forwardRows, - pSDataBlock->info.rows, numOfOutput); + code = applyAggFunctionOnPartialTuples(pTaskInfo, pSup->pCtx, &pInfo->twAggSup.timeWindowData, startPos, + forwardRows, pSDataBlock->info.rows, numOfOutput); + QUERY_CHECK_CODE(code, lino, _end); key.ts = nextWin.skey; if (pInfo->delKey.ts > key.ts) { diff --git a/source/libs/executor/src/timewindowoperator.c b/source/libs/executor/src/timewindowoperator.c index 0cd506d15a..fa914d3ee8 100644 --- a/source/libs/executor/src/timewindowoperator.c +++ b/source/libs/executor/src/timewindowoperator.c @@ -653,8 +653,11 @@ static void doInterpUnclosedTimeWindow(SOperatorInfo* pOperatorInfo, int32_t num setNotInterpoWindowKey(pSup->pCtx, numOfExprs, RESULT_ROW_START_INTERP); updateTimeWindowInfo(&pInfo->twAggSup.timeWindowData, &w, 1); - applyAggFunctionOnPartialTuples(pTaskInfo, pSup->pCtx, &pInfo->twAggSup.timeWindowData, startPos, 0, - pBlock->info.rows, numOfExprs); + ret = applyAggFunctionOnPartialTuples(pTaskInfo, pSup->pCtx, &pInfo->twAggSup.timeWindowData, startPos, 0, + pBlock->info.rows, numOfExprs); + if (ret != TSDB_CODE_SUCCESS) { + T_LONG_JMP(pTaskInfo->env, ret); + } if (isResultRowInterpolated(pResult, RESULT_ROW_END_INTERP)) { closeResultRow(pr); @@ -799,8 +802,11 @@ static bool hashIntervalAgg(SOperatorInfo* pOperatorInfo, SResultRowInfo* pResul } updateTimeWindowInfo(&pInfo->twAggSup.timeWindowData, &win, 1); - applyAggFunctionOnPartialTuples(pTaskInfo, pSup->pCtx, &pInfo->twAggSup.timeWindowData, startPos, forwardRows, + ret = applyAggFunctionOnPartialTuples(pTaskInfo, pSup->pCtx, &pInfo->twAggSup.timeWindowData, startPos, forwardRows, pBlock->info.rows, numOfOutput); + if (ret != TSDB_CODE_SUCCESS) { + T_LONG_JMP(pTaskInfo->env, ret); + } doCloseWindow(pResultRowInfo, pInfo, pResult); @@ -838,8 +844,11 @@ static bool hashIntervalAgg(SOperatorInfo* pOperatorInfo, SResultRowInfo* pResul } #endif updateTimeWindowInfo(&pInfo->twAggSup.timeWindowData, &nextWin, 1); - applyAggFunctionOnPartialTuples(pTaskInfo, pSup->pCtx, &pInfo->twAggSup.timeWindowData, startPos, forwardRows, - pBlock->info.rows, numOfOutput); + ret = applyAggFunctionOnPartialTuples(pTaskInfo, pSup->pCtx, &pInfo->twAggSup.timeWindowData, startPos, forwardRows, + pBlock->info.rows, numOfOutput); + if (ret != TSDB_CODE_SUCCESS) { + T_LONG_JMP(pTaskInfo->env, ret); + } doCloseWindow(pResultRowInfo, pInfo, pResult); } @@ -1031,8 +1040,11 @@ static void doStateWindowAggImpl(SOperatorInfo* pOperator, SStateWindowOperatorI } updateTimeWindowInfo(&pInfo->twAggSup.timeWindowData, &window, 0); - applyAggFunctionOnPartialTuples(pTaskInfo, pSup->pCtx, &pInfo->twAggSup.timeWindowData, pRowSup->startRowIndex, - pRowSup->numOfRows, pBlock->info.rows, numOfOutput); + ret = applyAggFunctionOnPartialTuples(pTaskInfo, pSup->pCtx, &pInfo->twAggSup.timeWindowData, + pRowSup->startRowIndex, pRowSup->numOfRows, pBlock->info.rows, numOfOutput); + if (ret != TSDB_CODE_SUCCESS) { + T_LONG_JMP(pTaskInfo->env, ret); + } // here we start a new session window doKeepNewWindowStartInfo(pRowSup, tsList, j, gid); @@ -1056,8 +1068,11 @@ static void doStateWindowAggImpl(SOperatorInfo* pOperator, SStateWindowOperatorI } updateTimeWindowInfo(&pInfo->twAggSup.timeWindowData, &pRowSup->win, 0); - applyAggFunctionOnPartialTuples(pTaskInfo, pSup->pCtx, &pInfo->twAggSup.timeWindowData, pRowSup->startRowIndex, - pRowSup->numOfRows, pBlock->info.rows, numOfOutput); + ret = applyAggFunctionOnPartialTuples(pTaskInfo, pSup->pCtx, &pInfo->twAggSup.timeWindowData, pRowSup->startRowIndex, + pRowSup->numOfRows, pBlock->info.rows, numOfOutput); + if (ret != TSDB_CODE_SUCCESS) { + T_LONG_JMP(pTaskInfo->env, ret); + } } static int32_t openStateWindowAggOptr(SOperatorInfo* pOperator) { @@ -1492,8 +1507,11 @@ static void doSessionWindowAggImpl(SOperatorInfo* pOperator, SSessionAggOperator // pInfo->numOfRows data belong to the current session window updateTimeWindowInfo(&pInfo->twAggSup.timeWindowData, &window, 0); - applyAggFunctionOnPartialTuples(pTaskInfo, pSup->pCtx, &pInfo->twAggSup.timeWindowData, pRowSup->startRowIndex, - pRowSup->numOfRows, pBlock->info.rows, numOfOutput); + ret = applyAggFunctionOnPartialTuples(pTaskInfo, pSup->pCtx, &pInfo->twAggSup.timeWindowData, pRowSup->startRowIndex, + pRowSup->numOfRows, pBlock->info.rows, numOfOutput); + if (ret != TSDB_CODE_SUCCESS) { + T_LONG_JMP(pTaskInfo->env, ret); + } } // here we start a new session window @@ -1511,8 +1529,11 @@ static void doSessionWindowAggImpl(SOperatorInfo* pOperator, SSessionAggOperator } updateTimeWindowInfo(&pInfo->twAggSup.timeWindowData, &pRowSup->win, 0); - applyAggFunctionOnPartialTuples(pTaskInfo, pSup->pCtx, &pInfo->twAggSup.timeWindowData, pRowSup->startRowIndex, - pRowSup->numOfRows, pBlock->info.rows, numOfOutput); + ret = applyAggFunctionOnPartialTuples(pTaskInfo, pSup->pCtx, &pInfo->twAggSup.timeWindowData, pRowSup->startRowIndex, + pRowSup->numOfRows, pBlock->info.rows, numOfOutput); + if (ret != TSDB_CODE_SUCCESS) { + T_LONG_JMP(pTaskInfo->env, ret); + } } static int32_t doSessionWindowAggNext(SOperatorInfo* pOperator, SSDataBlock** ppRes) { @@ -1874,8 +1895,11 @@ static void doMergeAlignedIntervalAggImpl(SOperatorInfo* pOperatorInfo, SResultR } updateTimeWindowInfo(&iaInfo->twAggSup.timeWindowData, &currWin, 1); - applyAggFunctionOnPartialTuples(pTaskInfo, pSup->pCtx, &iaInfo->twAggSup.timeWindowData, startPos, - currPos - startPos, pBlock->info.rows, pSup->numOfExprs); + ret = applyAggFunctionOnPartialTuples(pTaskInfo, pSup->pCtx, &iaInfo->twAggSup.timeWindowData, startPos, + currPos - startPos, pBlock->info.rows, pSup->numOfExprs); + if (ret != TSDB_CODE_SUCCESS) { + T_LONG_JMP(pTaskInfo->env, ret); + } finalizeResultRows(iaInfo->aggSup.pResultBuf, &pResultRowInfo->cur, pSup, pResultBlock, pTaskInfo); resetResultRow(miaInfo->pResultRow, iaInfo->aggSup.resultRowSize - sizeof(SResultRow)); @@ -1894,8 +1918,11 @@ static void doMergeAlignedIntervalAggImpl(SOperatorInfo* pOperatorInfo, SResultR } updateTimeWindowInfo(&iaInfo->twAggSup.timeWindowData, &currWin, 1); - applyAggFunctionOnPartialTuples(pTaskInfo, pSup->pCtx, &iaInfo->twAggSup.timeWindowData, startPos, currPos - startPos, - pBlock->info.rows, pSup->numOfExprs); + ret = applyAggFunctionOnPartialTuples(pTaskInfo, pSup->pCtx, &iaInfo->twAggSup.timeWindowData, startPos, + currPos - startPos, pBlock->info.rows, pSup->numOfExprs); + if (ret != TSDB_CODE_SUCCESS) { + T_LONG_JMP(pTaskInfo->env, ret); + } } static void cleanupAfterGroupResultGen(SMergeAlignedIntervalAggOperatorInfo* pMiaInfo, SSDataBlock* pRes) { @@ -2223,8 +2250,11 @@ static void doMergeIntervalAggImpl(SOperatorInfo* pOperatorInfo, SResultRowInfo* } updateTimeWindowInfo(&iaInfo->twAggSup.timeWindowData, &win, 1); - applyAggFunctionOnPartialTuples(pTaskInfo, pExprSup->pCtx, &iaInfo->twAggSup.timeWindowData, startPos, forwardRows, + ret = applyAggFunctionOnPartialTuples(pTaskInfo, pExprSup->pCtx, &iaInfo->twAggSup.timeWindowData, startPos, forwardRows, pBlock->info.rows, numOfOutput); + if (ret != TSDB_CODE_SUCCESS) { + T_LONG_JMP(pTaskInfo->env, ret); + } doCloseWindow(pResultRowInfo, iaInfo, pResult); // output previous interval results after this interval (&win) is closed @@ -2262,8 +2292,11 @@ static void doMergeIntervalAggImpl(SOperatorInfo* pOperatorInfo, SResultRowInfo* } updateTimeWindowInfo(&iaInfo->twAggSup.timeWindowData, &nextWin, 1); - applyAggFunctionOnPartialTuples(pTaskInfo, pExprSup->pCtx, &iaInfo->twAggSup.timeWindowData, startPos, forwardRows, - pBlock->info.rows, numOfOutput); + code = applyAggFunctionOnPartialTuples(pTaskInfo, pExprSup->pCtx, &iaInfo->twAggSup.timeWindowData, startPos, + forwardRows, pBlock->info.rows, numOfOutput); + if (code != TSDB_CODE_SUCCESS) { + T_LONG_JMP(pTaskInfo->env, code); + } doCloseWindow(pResultRowInfo, iaInfo, pResult); // output previous interval results after this interval (&nextWin) is closed diff --git a/source/libs/monitorfw/inc/taos_metric_formatter_i.h b/source/libs/monitorfw/inc/taos_metric_formatter_i.h index 54e683fa91..2c891dae95 100644 --- a/source/libs/monitorfw/inc/taos_metric_formatter_i.h +++ b/source/libs/monitorfw/inc/taos_metric_formatter_i.h @@ -30,7 +30,7 @@ taos_metric_formatter_t *taos_metric_formatter_new(); /** * @brief API PRIVATE taos_metric_formatter destructor */ -int taos_metric_formatter_destroy(taos_metric_formatter_t *self); +void taos_metric_formatter_destroy(taos_metric_formatter_t *self); /** * @brief API PRIVATE Loads the help text diff --git a/source/libs/monitorfw/inc/taos_string_builder_i.h b/source/libs/monitorfw/inc/taos_string_builder_i.h index 933d778691..02ca0a0900 100644 --- a/source/libs/monitorfw/inc/taos_string_builder_i.h +++ b/source/libs/monitorfw/inc/taos_string_builder_i.h @@ -31,7 +31,7 @@ taos_string_builder_t *taos_string_builder_new(void); * API PRIVATE * @brief Destroys a taos_string_builder* */ -int taos_string_builder_destroy(taos_string_builder_t *self); +void taos_string_builder_destroy(taos_string_builder_t *self); /** * API PRIVATE diff --git a/source/libs/monitorfw/inc/taos_test.h b/source/libs/monitorfw/inc/taos_test.h index b881b2cee2..11e145a7fa 100644 --- a/source/libs/monitorfw/inc/taos_test.h +++ b/source/libs/monitorfw/inc/taos_test.h @@ -23,6 +23,11 @@ if (!(i)) return 1; #define TAOS_TEST_PARA_NULL(i) \ if (!(i)) return NULL; +#define TAOS_TEST_PARA_VOID(i) \ + if (!(i)) { \ + TAOS_LOG("parameter is NULL"); \ + return; \ + } #endif // TAOS_TEST #endif // TAOS_TEST_H diff --git a/source/libs/monitorfw/src/taos_collector.c b/source/libs/monitorfw/src/taos_collector.c index 21ebb3f737..a7ea9f0f61 100644 --- a/source/libs/monitorfw/src/taos_collector.c +++ b/source/libs/monitorfw/src/taos_collector.c @@ -39,18 +39,24 @@ taos_collector_t *taos_collector_new(const char *name) { self->name = taos_strdup(name); self->metrics = taos_map_new(); if (self->metrics == NULL) { - (void)taos_collector_destroy(self); + if (taos_collector_destroy(self) != 0) { + TAOS_LOG("taos_collector_destroy failed"); + } return NULL; } r = taos_map_set_free_value_fn(self->metrics, &taos_metric_free_generic); if (r) { - (void)taos_collector_destroy(self); + if (taos_collector_destroy(self) != 0) { + TAOS_LOG("taos_collector_destroy failed"); + } return NULL; } self->collect_fn = &taos_collector_default_collect; self->string_builder = taos_string_builder_new(); if (self->string_builder == NULL) { - (void)taos_collector_destroy(self); + if (taos_collector_destroy(self) != 0) { + TAOS_LOG("taos_collector_destroy failed"); + } return NULL; } self->proc_limits_file_path = NULL; @@ -70,8 +76,7 @@ int taos_collector_destroy(taos_collector_t *self) { self->metrics = NULL; if(self->string_builder != NULL){ - r = taos_string_builder_destroy(self->string_builder); - if (r) ret = r; + taos_string_builder_destroy(self->string_builder); self->string_builder = NULL; } @@ -93,7 +98,9 @@ int taos_collector_destroy_generic(void *gen) { void taos_collector_free_generic(void *gen) { taos_collector_t *self = (taos_collector_t *)gen; - (void)taos_collector_destroy(self); + if (taos_collector_destroy(self) != 0) { + TAOS_LOG("taos_collector_destroy failed"); + } } int taos_collector_set_collect_fn(taos_collector_t *self, taos_collect_fn *fn) { diff --git a/source/libs/monitorfw/src/taos_collector_registry.c b/source/libs/monitorfw/src/taos_collector_registry.c index 94295bf9c0..bfdbf92156 100644 --- a/source/libs/monitorfw/src/taos_collector_registry.c +++ b/source/libs/monitorfw/src/taos_collector_registry.c @@ -50,7 +50,7 @@ taos_collector_registry_t *taos_collector_registry_new(const char *name) { self->name = taos_strdup(name); self->collectors = taos_map_new(); - (void)taos_map_set_free_value_fn(self->collectors, &taos_collector_free_generic); + if (taos_map_set_free_value_fn(self->collectors, &taos_collector_free_generic) != 0) return NULL; if (taos_map_set(self->collectors, "default", taos_collector_new("default")) != 0) return NULL; self->metric_formatter = taos_metric_formatter_new(); @@ -86,17 +86,14 @@ int taos_collector_registry_destroy(taos_collector_registry_t *self) { self->collectors = NULL; if (r) ret = r; - r = taos_metric_formatter_destroy(self->metric_formatter); + taos_metric_formatter_destroy(self->metric_formatter); self->metric_formatter = NULL; - if (r) ret = r; - r = taos_string_builder_destroy(self->string_builder); + taos_string_builder_destroy(self->string_builder); self->string_builder = NULL; - if (r) ret = r; - r = taos_string_builder_destroy(self->string_builder_batch); + taos_string_builder_destroy(self->string_builder_batch); self->string_builder_batch = NULL; - if (r) ret = r; r = pthread_rwlock_destroy(self->lock); taos_free(self->lock); @@ -241,13 +238,25 @@ const char *taos_collector_registry_bridge_new(taos_collector_registry_t *self, SJson* pJson = tjsonCreateArray(); SJson* item = tjsonCreateObject(); - (void)tjsonAddItemToArray(pJson, item); - (void)tjsonAddStringToObject(item, "ts", ts); - (void)tjsonAddDoubleToObject(item, "protocol", 2); - SJson* array = tjsonCreateArray(); - (void)tjsonAddItemToObject(item, "tables", array); + if (tjsonAddItemToArray(pJson, item) != 0) { + tjsonDelete(pJson); + return NULL; + } + if (tjsonAddStringToObject(item, "ts", ts) != 0) { + tjsonDelete(pJson); + return NULL; + } + if (tjsonAddDoubleToObject(item, "protocol", 2) != 0) { + tjsonDelete(pJson); + return NULL; + } + SJson *array = tjsonCreateArray(); + if (tjsonAddItemToObject(item, "tables", array) != 0) { + tjsonDelete(pJson); + return NULL; + } - if(taos_metric_formatter_load_metrics_new(self->metric_formatter, self->collectors, ts, format, array) != 0){ + if (taos_metric_formatter_load_metrics_new(self->metric_formatter, self->collectors, ts, format, array) != 0) { TAOS_LOG("failed to load metrics"); tjsonDelete(pJson); return NULL; @@ -294,9 +303,8 @@ const char *taos_collector_registry_bridge_new(taos_collector_registry_t *self, r = taos_string_builder_clear(tmp_builder); if (r) goto _OVER;; - r = taos_string_builder_destroy(tmp_builder); + taos_string_builder_destroy(tmp_builder); tmp_builder = NULL; - if (r) goto _OVER;; tjsonDelete(pJson); return data; @@ -304,7 +312,7 @@ const char *taos_collector_registry_bridge_new(taos_collector_registry_t *self, _OVER: tjsonDelete(pJson); if(tmp_builder != NULL){ - (void)taos_string_builder_destroy(tmp_builder); + taos_string_builder_destroy(tmp_builder); } return NULL; diff --git a/source/libs/monitorfw/src/taos_map.c b/source/libs/monitorfw/src/taos_map.c index 2f5bf566c2..bf1b85c534 100644 --- a/source/libs/monitorfw/src/taos_map.c +++ b/source/libs/monitorfw/src/taos_map.c @@ -45,21 +45,19 @@ taos_map_node_t *taos_map_node_new(const char *key, void *value, taos_map_node_f return self; } -int taos_map_node_destroy(taos_map_node_t *self) { - TAOS_TEST_PARA(self != NULL); - if (self == NULL) return 0; +void taos_map_node_destroy(taos_map_node_t *self) { + TAOS_TEST_PARA_VOID(self != NULL); taos_free((void *)self->key); self->key = NULL; if (self->value != NULL) (*self->free_value_fn)(self->value); self->value = NULL; taos_free(self); self = NULL; - return 0; } void taos_map_node_free(void *item) { taos_map_node_t *map_node = (taos_map_node_t *)item; - (void)taos_map_node_destroy(map_node); + taos_map_node_destroy(map_node); } taos_linked_list_compare_t taos_map_node_compare(void *item_a, void *item_b) { @@ -87,7 +85,9 @@ taos_map_t *taos_map_new() { // we will only have to deallocate each key once. That will happen on taos_map_node_destroy. r = taos_linked_list_set_free_fn(self->keys, taos_linked_list_no_op_free); if (r) { - (void)taos_map_destroy(self); + if (taos_map_destroy(self) != 0) { + TAOS_LOG("TAOS_MAP_DESTROY_ERROR"); + } return NULL; } @@ -98,12 +98,16 @@ taos_map_t *taos_map_new() { self->addrs[i] = taos_linked_list_new(); r = taos_linked_list_set_free_fn(self->addrs[i], taos_map_node_free); if (r) { - (void)taos_map_destroy(self); + if (taos_map_destroy(self) != 0) { + TAOS_LOG("TAOS_MAP_DESTROY_ERROR"); + } return NULL; } r = taos_linked_list_set_compare_fn(self->addrs[i], taos_map_node_compare); if (r) { - (void)taos_map_destroy(self); + if (taos_map_destroy(self) != 0) { + TAOS_LOG("TAOS_MAP_DESTROY_ERROR"); + } return NULL; } } @@ -112,7 +116,9 @@ taos_map_t *taos_map_new() { r = pthread_rwlock_init(self->rwlock, NULL); if (r) { TAOS_LOG(TAOS_PTHREAD_RWLOCK_INIT_ERROR); - (void)taos_map_destroy(self); + if (taos_map_destroy(self) != 0) { + TAOS_LOG("TAOS_MAP_DESTROY_ERROR"); + } return NULL; } @@ -188,12 +194,12 @@ static void *taos_map_get_internal(const char *key, size_t *size, size_t *max_si taos_map_node_t *current_map_node = (taos_map_node_t *)current_node->item; taos_linked_list_compare_t result = taos_linked_list_compare(list, current_map_node, temp_map_node); if (result == TAOS_EQUAL) { - (void)taos_map_node_destroy(temp_map_node); + taos_map_node_destroy(temp_map_node); temp_map_node = NULL; return current_map_node->value; } } - (void)taos_map_node_destroy(temp_map_node); + taos_map_node_destroy(temp_map_node); temp_map_node = NULL; return NULL; } @@ -388,7 +394,7 @@ static int taos_map_delete_internal(const char *key, size_t *size, size_t *max_s break; } } - r = taos_map_node_destroy(temp_map_node); + taos_map_node_destroy(temp_map_node); temp_map_node = NULL; return r; } diff --git a/source/libs/monitorfw/src/taos_metric.c b/source/libs/monitorfw/src/taos_metric.c index 42564437d0..9d55680c4d 100644 --- a/source/libs/monitorfw/src/taos_metric.c +++ b/source/libs/monitorfw/src/taos_metric.c @@ -49,12 +49,12 @@ taos_metric_t *taos_metric_new(taos_metric_type_t metric_type, const char *name, for (int i = 0; i < label_key_count; i++) { if (strcmp(label_keys[i], "le") == 0) { TAOS_LOG(TAOS_METRIC_INVALID_LABEL_NAME); - (void)taos_metric_destroy(self); + if (taos_metric_destroy(self) != 0) return NULL; return NULL; } if (strcmp(label_keys[i], "quantile") == 0) { TAOS_LOG(TAOS_METRIC_INVALID_LABEL_NAME); - (void)taos_metric_destroy(self); + if (taos_metric_destroy(self) != 0) return NULL; return NULL; } k[i] = taos_strdup(label_keys[i]); @@ -68,14 +68,14 @@ taos_metric_t *taos_metric_new(taos_metric_type_t metric_type, const char *name, } else { r = taos_map_set_free_value_fn(self->samples, &taos_metric_sample_free_generic); if (r) { - (void)taos_metric_destroy(self); + if (taos_metric_destroy(self) != 0) return NULL; return NULL; } } self->formatter = taos_metric_formatter_new(); if (self->formatter == NULL) { - (void)taos_metric_destroy(self); + if (taos_metric_destroy(self) != 0) return NULL; return NULL; } self->rwlock = (pthread_rwlock_t *)taos_malloc(sizeof(pthread_rwlock_t)); @@ -101,9 +101,8 @@ int taos_metric_destroy(taos_metric_t *self) { if (r) ret = r; } - r = taos_metric_formatter_destroy(self->formatter); + taos_metric_formatter_destroy(self->formatter); self->formatter = NULL; - if (r) ret = r; r = pthread_rwlock_destroy(self->rwlock); if (r) { @@ -140,7 +139,9 @@ int taos_metric_destroy_generic(void *item) { void taos_metric_free_generic(void *item) { taos_metric_t *self = (taos_metric_t *)item; - (void)taos_metric_destroy(self); + if (taos_metric_destroy(self) != 0) { + TAOS_LOG("taos_metric_destroy failed"); + } } taos_metric_sample_t *taos_metric_sample_from_labels(taos_metric_t *self, const char **label_values) { diff --git a/source/libs/monitorfw/src/taos_metric_formatter.c b/source/libs/monitorfw/src/taos_metric_formatter.c index cb1edd30b6..31796c20df 100644 --- a/source/libs/monitorfw/src/taos_metric_formatter.c +++ b/source/libs/monitorfw/src/taos_metric_formatter.c @@ -22,6 +22,7 @@ // Private #include "taos_collector_t.h" #include "taos_linked_list_t.h" +#include "taos_log.h" #include "taos_map_i.h" #include "taos_metric_formatter_i.h" #include "taos_metric_sample_t.h" @@ -33,35 +34,28 @@ taos_metric_formatter_t *taos_metric_formatter_new() { taos_metric_formatter_t *self = (taos_metric_formatter_t *)taos_malloc(sizeof(taos_metric_formatter_t)); self->string_builder = taos_string_builder_new(); if (self->string_builder == NULL) { - (void)taos_metric_formatter_destroy(self); + taos_metric_formatter_destroy(self); return NULL; } self->err_builder = taos_string_builder_new(); if (self->err_builder == NULL) { - (void)taos_metric_formatter_destroy(self); + taos_metric_formatter_destroy(self); return NULL; } return self; } -int taos_metric_formatter_destroy(taos_metric_formatter_t *self) { - TAOS_TEST_PARA(self != NULL); - if (self == NULL) return 0; +void taos_metric_formatter_destroy(taos_metric_formatter_t *self) { + TAOS_TEST_PARA_VOID(self != NULL); - int r = 0; - int ret = 0; - - r = taos_string_builder_destroy(self->string_builder); + taos_string_builder_destroy(self->string_builder); self->string_builder = NULL; - if (r) ret = r; - r = taos_string_builder_destroy(self->err_builder); + taos_string_builder_destroy(self->err_builder); self->err_builder = NULL; - if (r) ret = r; taos_free(self); self = NULL; - return ret; } /* int taos_metric_formatter_load_help(taos_metric_formatter_t *self, const char *name, const char *help) { diff --git a/source/libs/monitorfw/src/taos_metric_formatter_custom.c b/source/libs/monitorfw/src/taos_metric_formatter_custom.c index da05d09d9c..6e7ded62bb 100644 --- a/source/libs/monitorfw/src/taos_metric_formatter_custom.c +++ b/source/libs/monitorfw/src/taos_metric_formatter_custom.c @@ -88,17 +88,46 @@ int taos_metric_formatter_load_sample_new(taos_metric_formatter_t *self, taos_me char* value = *(pair + 1); SJson* tag = tjsonCreateObject(); - (void)tjsonAddStringToObject(tag, "name", key); - (void)tjsonAddStringToObject(tag, "value", value); - - (void)tjsonAddItemToArray(arrayTag, tag); + if ((r = tjsonAddStringToObject(tag, "name", key)) != 0) { + taosMemoryFreeClear(arr); + taosMemoryFreeClear(keyvalue); + taosMemoryFreeClear(keyvalues); + return r; + } + if ((r = tjsonAddStringToObject(tag, "value", value)) != 0) { + taosMemoryFreeClear(arr); + taosMemoryFreeClear(keyvalue); + taosMemoryFreeClear(keyvalues); + return r; + } + if ((r = tjsonAddItemToArray(arrayTag, tag)) != 0) { + taosMemoryFreeClear(arr); + taosMemoryFreeClear(keyvalue); + taosMemoryFreeClear(keyvalues); + return r; + } + } + if ((r = tjsonAddItemToObject(item, "tags", arrayTag)) != 0) { + taosMemoryFreeClear(arr); + taosMemoryFreeClear(keyvalue); + taosMemoryFreeClear(keyvalues); + return r; } - (void)tjsonAddItemToObject(item, "tags", arrayTag); metrics = tjsonCreateArray(); - (void)tjsonAddItemToObject(item, "metrics", metrics); + if ((r = tjsonAddItemToObject(item, "metrics", metrics)) != 0) { + taosMemoryFreeClear(arr); + taosMemoryFreeClear(keyvalue); + taosMemoryFreeClear(keyvalues); + return r; + } - (void)tjsonAddItemToArray(arrayMetricGroups, item); + if ((r = tjsonAddItemToArray(arrayMetricGroups, item)) != 0) { + taosMemoryFreeClear(arr); + taosMemoryFreeClear(keyvalue); + taosMemoryFreeClear(keyvalues); + return r; + } } else{ metrics = tjsonGetObjectItem(item, "metrics"); @@ -109,20 +138,20 @@ int taos_metric_formatter_load_sample_new(taos_metric_formatter_t *self, taos_me taosMemoryFreeClear(keyvalues); SJson* metric = tjsonCreateObject(); - (void)tjsonAddStringToObject(metric, "name", metricName); + if ((r = tjsonAddStringToObject(metric, "name", metricName)) != 0) return r; double old_value = 0; #define USE_EXCHANGE #ifdef USE_EXCHANGE - (void)taos_metric_sample_exchange(sample, 0, &old_value); + if ((r = taos_metric_sample_exchange(sample, 0, &old_value)) != 0) return r; #else old_value = sample->r_value; taos_metric_sample_set(sample, 0); #endif - (void)tjsonAddDoubleToObject(metric, "value", old_value); - (void)tjsonAddDoubleToObject(metric, "type", metric_type); - (void)tjsonAddItemToArray(metrics, metric); + if ((r = tjsonAddDoubleToObject(metric, "value", old_value)) != 0) return r; + if ((r = tjsonAddDoubleToObject(metric, "type", metric_type)) != 0) return r; + if ((r = tjsonAddItemToArray(metrics, metric)) != 0) return r; return 0; } @@ -150,7 +179,10 @@ int taos_metric_formatter_load_metric_new(taos_metric_formatter_t *self, taos_me SJson* table = tjsonGetArrayItem(tableArray, i); char tableName[MONITOR_TABLENAME_LEN] = {0}; - (void)tjsonGetStringValue(table, "name", tableName); + if ((r = tjsonGetStringValue(table, "name", tableName)) != 0) { + taosMemoryFreeClear(name); + return r; + } if(strcmp(tableName, arr[0]) == 0){ isFound = true; arrayMetricGroups = tjsonGetObjectItem(table, "metric_groups"); @@ -161,10 +193,16 @@ int taos_metric_formatter_load_metric_new(taos_metric_formatter_t *self, taos_me if(!isFound){ table = tjsonCreateObject(); - (void)tjsonAddStringToObject(table, "name", arr[0]); + if ((r = tjsonAddStringToObject(table, "name", arr[0])) != 0) { + taosMemoryFreeClear(name); + return r; + } arrayMetricGroups = tjsonCreateArray(); - (void)tjsonAddItemToObject(table, "metric_groups", arrayMetricGroups); + if ((r = tjsonAddItemToObject(table, "metric_groups", arrayMetricGroups)) != 0) { + taosMemoryFreeClear(name); + return r; + } } int32_t sample_count = 0; @@ -183,7 +221,10 @@ int taos_metric_formatter_load_metric_new(taos_metric_formatter_t *self, taos_me } if(!isFound && sample_count > 0){ - (void)tjsonAddItemToArray(tableArray, table); + if ((r = tjsonAddItemToArray(tableArray, table)) != 0) { + taosMemoryFreeClear(name); + return r; + } } else{ if(table != NULL) tjsonDelete(table); diff --git a/source/libs/monitorfw/src/taos_metric_sample.c b/source/libs/monitorfw/src/taos_metric_sample.c index e4b41d5475..ca41cf1a83 100644 --- a/source/libs/monitorfw/src/taos_metric_sample.c +++ b/source/libs/monitorfw/src/taos_metric_sample.c @@ -44,7 +44,6 @@ taos_metric_sample_t *taos_metric_sample_new(taos_metric_type_t type, const char int taos_metric_sample_destroy(taos_metric_sample_t *self) { TAOS_TEST_PARA(self != NULL); - if (self == NULL) return 0; taos_free((void *)self->l_value); self->l_value = NULL; taos_free((void *)self); @@ -63,7 +62,9 @@ int taos_metric_sample_destroy_generic(void *gen) { void taos_metric_sample_free_generic(void *gen) { taos_metric_sample_t *self = (taos_metric_sample_t *)gen; - (void)taos_metric_sample_destroy(self); + if(taos_metric_sample_destroy(self) != 0) { + TAOS_LOG(TAOS_METRIC_SAMPLE_DESTROY_ERROR); + } } int taos_metric_sample_add(taos_metric_sample_t *self, double r_value) { diff --git a/source/libs/monitorfw/src/taos_monitor_util.c b/source/libs/monitorfw/src/taos_monitor_util.c index 2285ed9e71..06ae4993c5 100644 --- a/source/libs/monitorfw/src/taos_monitor_util.c +++ b/source/libs/monitorfw/src/taos_monitor_util.c @@ -84,10 +84,10 @@ bool taos_monitor_is_match(const SJson* tags, char** pairs, int32_t count) { SJson* item = tjsonGetArrayItem(tags, i); char item_name[MONITOR_TAG_NAME_LEN] = {0}; - (void)tjsonGetStringValue(item, "name", item_name); + if (tjsonGetStringValue(item, "name", item_name) != 0) return false; char item_value[MONITOR_TAG_VALUE_LEN] = {0}; - (void)tjsonGetStringValue(item, "value", item_value); + if (tjsonGetStringValue(item, "value", item_value) != 0) return false; bool isfound = false; for(int32_t j = 0; j < count; j++){ diff --git a/source/libs/monitorfw/src/taos_string_builder.c b/source/libs/monitorfw/src/taos_string_builder.c index 6e3fe1d2e3..b1a5a098bc 100644 --- a/source/libs/monitorfw/src/taos_string_builder.c +++ b/source/libs/monitorfw/src/taos_string_builder.c @@ -20,6 +20,7 @@ #include "taos_alloc.h" // Private +#include "taos_log.h" #include "taos_string_builder_i.h" #include "taos_string_builder_t.h" #include "taos_test.h" @@ -44,7 +45,7 @@ taos_string_builder_t *taos_string_builder_new(void) { self->init_size = TAOS_STRING_BUILDER_INIT_SIZE; r = taos_string_builder_init(self); if (r) { - (void)taos_string_builder_destroy(self); + taos_string_builder_destroy(self); return NULL; } @@ -61,14 +62,12 @@ int taos_string_builder_init(taos_string_builder_t *self) { return 0; } -int taos_string_builder_destroy(taos_string_builder_t *self) { - TAOS_TEST_PARA(self != NULL); - if (self == NULL) return 0; +void taos_string_builder_destroy(taos_string_builder_t *self) { + TAOS_TEST_PARA_VOID(self != NULL); taos_free(self->str); self->str = NULL; taos_free(self); self = NULL; - return 0; } /** diff --git a/source/libs/nodes/src/nodesCodeFuncs.c b/source/libs/nodes/src/nodesCodeFuncs.c index b0b293306e..f70540bfe1 100644 --- a/source/libs/nodes/src/nodesCodeFuncs.c +++ b/source/libs/nodes/src/nodesCodeFuncs.c @@ -6040,6 +6040,7 @@ static int32_t jsonToDropTableStmt(const SJson* pJson, void* pObj) { static const char* jkDropSuperTableStmtDbName = "DbName"; static const char* jkDropSuperTableStmtTableName = "TableName"; static const char* jkDropSuperTableStmtIgnoreNotExists = "IgnoreNotExists"; +static const char* jkDropSuperTableStmtwithOpt = "withOpt"; static int32_t dropStableStmtToJson(const void* pObj, SJson* pJson) { const SDropSuperTableStmt* pNode = (const SDropSuperTableStmt*)pObj; @@ -6051,6 +6052,9 @@ static int32_t dropStableStmtToJson(const void* pObj, SJson* pJson) { if (TSDB_CODE_SUCCESS == code) { code = tjsonAddBoolToObject(pJson, jkDropSuperTableStmtIgnoreNotExists, pNode->ignoreNotExists); } + if (TSDB_CODE_SUCCESS == code) { + code = tjsonAddBoolToObject(pJson, jkDropSuperTableStmtwithOpt, pNode->withOpt); + } return code; } @@ -6065,6 +6069,9 @@ static int32_t jsonToDropStableStmt(const SJson* pJson, void* pObj) { if (TSDB_CODE_SUCCESS == code) { code = tjsonGetBoolValue(pJson, jkDropSuperTableStmtIgnoreNotExists, &pNode->ignoreNotExists); } + if (TSDB_CODE_SUCCESS == code) { + code = tjsonGetBoolValue(pJson, jkDropSuperTableStmtwithOpt, &pNode->withOpt); + } return code; } diff --git a/source/libs/parser/inc/parAst.h b/source/libs/parser/inc/parAst.h index f67f1d23b6..a2aec77c2e 100644 --- a/source/libs/parser/inc/parAst.h +++ b/source/libs/parser/inc/parAst.h @@ -211,8 +211,8 @@ SNode* createCreateSubTableFromFileClause(SAstCreateContext* pCxt, bool ignoreEx SNodeList* pSpecificTags, const SToken* pFilePath); SNode* createCreateMultiTableStmt(SAstCreateContext* pCxt, SNodeList* pSubTables); SNode* createDropTableClause(SAstCreateContext* pCxt, bool ignoreNotExists, SNode* pRealTable); -SNode* createDropTableStmt(SAstCreateContext* pCxt, SNodeList* pTables); -SNode* createDropSuperTableStmt(SAstCreateContext* pCxt, bool ignoreNotExists, SNode* pRealTable); +SNode* createDropTableStmt(SAstCreateContext* pCxt, bool withOpt, SNodeList* pTables); +SNode* createDropSuperTableStmt(SAstCreateContext* pCxt, bool withOpt, bool ignoreNotExists, SNode* pRealTable); SNode* createAlterTableModifyOptions(SAstCreateContext* pCxt, SNode* pRealTable, SNode* pOptions); SNode* createAlterTableAddModifyCol(SAstCreateContext* pCxt, SNode* pRealTable, int8_t alterType, SToken* pColName, SDataType dataType); diff --git a/source/libs/parser/inc/parTranslater.h b/source/libs/parser/inc/parTranslater.h index 93d6645e12..3cb3be4e90 100644 --- a/source/libs/parser/inc/parTranslater.h +++ b/source/libs/parser/inc/parTranslater.h @@ -43,6 +43,7 @@ typedef struct STranslateContext { bool createStream; bool stableQuery; bool showRewrite; + bool withOpt; SNode* pPrevRoot; SNode* pPostRoot; bool dual; // whether select stmt without from stmt, true for without. diff --git a/source/libs/parser/inc/parUtil.h b/source/libs/parser/inc/parUtil.h index f0f1ea51b0..857c7604a9 100644 --- a/source/libs/parser/inc/parUtil.h +++ b/source/libs/parser/inc/parUtil.h @@ -111,7 +111,8 @@ typedef struct SParseMetaCache { SHashObj* pTableCfg; // key is tbFName, element is STableCfg* SHashObj* pViews; // key is viewFName, element is SViewMeta* SHashObj* pTableTSMAs; // key is tbFName, elements are SArray - SHashObj* pTSMAs; // key is tsmaFName, elemetns are STableTSMAInfo* + SHashObj* pTSMAs; // key is tsmaFName, elements are STableTSMAInfo* + SHashObj* pTableName; // key is tbFUid, elements is STableMeta*(append with tbName) SArray* pDnodes; // element is SEpSet bool dnodeRequired; } SParseMetaCache; @@ -141,6 +142,7 @@ int32_t buildCatalogReq(const SParseMetaCache* pMetaCache, SCatalogReq* pCatalog int32_t putMetaDataToCache(const SCatalogReq* pCatalogReq, const SMetaData* pMetaData, SParseMetaCache* pMetaCache); int32_t reserveTableMetaInCache(int32_t acctId, const char* pDb, const char* pTable, SParseMetaCache* pMetaCache); int32_t reserveTableMetaInCacheExt(const SName* pName, SParseMetaCache* pMetaCache); +int32_t reserveTableUidInCache(int32_t acctId, const char* pDb, const char* pTable, SParseMetaCache* pMetaCache); int32_t reserveViewMetaInCache(int32_t acctId, const char* pDb, const char* pView, SParseMetaCache* pMetaCache); int32_t reserveViewMetaInCacheExt(const SName* pName, SParseMetaCache* pMetaCache); int32_t reserveDbVgInfoInCache(int32_t acctId, const char* pDb, SParseMetaCache* pMetaCache); @@ -159,10 +161,12 @@ int32_t reserveDnodeRequiredInCache(SParseMetaCache* pMetaCache); int32_t reserveTableTSMAInfoInCache(int32_t acctId, const char* pDb, const char* pTable, SParseMetaCache* pMetaCache); int32_t reserveTSMAInfoInCache(int32_t acctId, const char* pDb, const char* pTsmaName, SParseMetaCache* pMetaCache); int32_t getTableMetaFromCache(SParseMetaCache* pMetaCache, const SName* pName, STableMeta** pMeta); +int32_t getTableNameFromCache(SParseMetaCache* pMetaCache, const SName* pName, char* pTbName); int32_t getViewMetaFromCache(SParseMetaCache* pMetaCache, const SName* pName, STableMeta** pMeta); int32_t buildTableMetaFromViewMeta(STableMeta** pMeta, SViewMeta* pViewMeta); int32_t getDbVgInfoFromCache(SParseMetaCache* pMetaCache, const char* pDbFName, SArray** pVgInfo); int32_t getTableVgroupFromCache(SParseMetaCache* pMetaCache, const SName* pName, SVgroupInfo* pVgroup); +int32_t getDbTableVgroupFromCache(SParseMetaCache* pMetaCache, const SName* pName, SVgroupInfo* pVgroup); int32_t getDbVgVersionFromCache(SParseMetaCache* pMetaCache, const char* pDbFName, int32_t* pVersion, int64_t* pDbId, int32_t* pTableNum, int64_t* pStateTs); int32_t getDbCfgFromCache(SParseMetaCache* pMetaCache, const char* pDbFName, SDbCfgInfo* pInfo); diff --git a/source/libs/parser/inc/sql.y b/source/libs/parser/inc/sql.y index 4e53747e5b..ae908f0826 100644 --- a/source/libs/parser/inc/sql.y +++ b/source/libs/parser/inc/sql.y @@ -124,8 +124,8 @@ sysinfo_opt(A) ::= . sysinfo_opt(A) ::= SYSINFO NK_INTEGER(B). { A = taosStr2Int8(B.z, NULL, 10); } /************************************************ grant/revoke ********************************************************/ -cmd ::= GRANT privileges(A) ON priv_level(B) with_opt(D) TO user_name(C). { pCxt->pRootNode = createGrantStmt(pCxt, A, &B, &C, D); } -cmd ::= REVOKE privileges(A) ON priv_level(B) with_opt(D) FROM user_name(C). { pCxt->pRootNode = createRevokeStmt(pCxt, A, &B, &C, D); } +cmd ::= GRANT privileges(A) ON priv_level(B) with_clause_opt(D) TO user_name(C). { pCxt->pRootNode = createGrantStmt(pCxt, A, &B, &C, D); } +cmd ::= REVOKE privileges(A) ON priv_level(B) with_clause_opt(D) FROM user_name(C). { pCxt->pRootNode = createRevokeStmt(pCxt, A, &B, &C, D); } %type privileges { int64_t } %destructor privileges { } @@ -151,8 +151,8 @@ priv_level(A) ::= db_name(B) NK_DOT NK_STAR(C). priv_level(A) ::= db_name(B) NK_DOT table_name(C). { A.first = B; A.second = C; } priv_level(A) ::= topic_name(B). { A.first = B; A.second = nil_token; } -with_opt(A) ::= . { A = NULL; } -with_opt(A) ::= WITH search_condition(B). { A = B; } +with_clause_opt(A) ::= . { A = NULL; } +with_clause_opt(A) ::= WITH search_condition(B). { A = B; } /************************************************ create encrypt_key *********************************************/ cmd ::= CREATE ENCRYPT_KEY NK_STRING(A). { pCxt->pRootNode = createEncryptKeyStmt(pCxt, &A); } @@ -357,8 +357,8 @@ cmd ::= CREATE TABLE not_exists_opt(B) USING full_table_name(C) NK_LP tag_list_opt(D) NK_RP FILE NK_STRING(E). { pCxt->pRootNode = createCreateSubTableFromFileClause(pCxt, B, C, D, &E); } cmd ::= CREATE STABLE not_exists_opt(A) full_table_name(B) NK_LP column_def_list(C) NK_RP tags_def(D) table_options(E). { pCxt->pRootNode = createCreateTableStmt(pCxt, A, B, C, D, E); } -cmd ::= DROP TABLE multi_drop_clause(A). { pCxt->pRootNode = createDropTableStmt(pCxt, A); } -cmd ::= DROP STABLE exists_opt(A) full_table_name(B). { pCxt->pRootNode = createDropSuperTableStmt(pCxt, A, B); } +cmd ::= DROP TABLE with_opt(A) multi_drop_clause(B). { pCxt->pRootNode = createDropTableStmt(pCxt, A, B); } +cmd ::= DROP STABLE with_opt(A) exists_opt(B) full_table_name(C). { pCxt->pRootNode = createDropSuperTableStmt(pCxt, A, B, C); } cmd ::= ALTER TABLE alter_table_clause(A). { pCxt->pRootNode = A; } cmd ::= ALTER STABLE alter_table_clause(A). { pCxt->pRootNode = setAlterSuperTableType(A); } @@ -399,6 +399,11 @@ multi_drop_clause(A) ::= multi_drop_clause(B) NK_COMMA drop_table_clause(C). drop_table_clause(A) ::= exists_opt(B) full_table_name(C). { A = createDropTableClause(pCxt, B, C); } +%type with_opt { bool } +%destructor with_opt { } +with_opt(A) ::= . { A = false; } +with_opt(A) ::= WITH. { A = true; } + %type specific_cols_opt { SNodeList* } %destructor specific_cols_opt { nodesDestroyList($$); } specific_cols_opt(A) ::= . { A = NULL; } diff --git a/source/libs/parser/src/parAstCreater.c b/source/libs/parser/src/parAstCreater.c index 55fda8c8de..e52c8865c7 100644 --- a/source/libs/parser/src/parAstCreater.c +++ b/source/libs/parser/src/parAstCreater.c @@ -2355,19 +2355,20 @@ _err: return NULL; } -SNode* createDropTableStmt(SAstCreateContext* pCxt, SNodeList* pTables) { +SNode* createDropTableStmt(SAstCreateContext* pCxt, bool withOpt, SNodeList* pTables) { CHECK_PARSER_STATUS(pCxt); SDropTableStmt* pStmt = NULL; pCxt->errCode = nodesMakeNode(QUERY_NODE_DROP_TABLE_STMT, (SNode**)&pStmt); CHECK_MAKE_NODE(pStmt); pStmt->pTables = pTables; + pStmt->withOpt = withOpt; return (SNode*)pStmt; _err: nodesDestroyList(pTables); return NULL; } -SNode* createDropSuperTableStmt(SAstCreateContext* pCxt, bool ignoreNotExists, SNode* pRealTable) { +SNode* createDropSuperTableStmt(SAstCreateContext* pCxt, bool withOpt, bool ignoreNotExists, SNode* pRealTable) { CHECK_PARSER_STATUS(pCxt); SDropSuperTableStmt* pStmt = NULL; pCxt->errCode = nodesMakeNode(QUERY_NODE_DROP_SUPER_TABLE_STMT, (SNode**)&pStmt); @@ -2375,6 +2376,7 @@ SNode* createDropSuperTableStmt(SAstCreateContext* pCxt, bool ignoreNotExists, S strcpy(pStmt->dbName, ((SRealTableNode*)pRealTable)->table.dbName); strcpy(pStmt->tableName, ((SRealTableNode*)pRealTable)->table.tableName); pStmt->ignoreNotExists = ignoreNotExists; + pStmt->withOpt = withOpt; nodesDestroyNode(pRealTable); return (SNode*)pStmt; _err: diff --git a/source/libs/parser/src/parAstParser.c b/source/libs/parser/src/parAstParser.c index d323d45c81..f4dd91f392 100644 --- a/source/libs/parser/src/parAstParser.c +++ b/source/libs/parser/src/parAstParser.c @@ -379,13 +379,24 @@ static int32_t collectMetaKeyFromDropTable(SCollectMetaKeyCxt* pCxt, SDropTableS SNode* pNode = NULL; FOREACH(pNode, pStmt->pTables) { SDropTableClause* pClause = (SDropTableClause*)pNode; - code = reserveTableMetaInCache(pCxt->pParseCxt->acctId, pClause->dbName, pClause->tableName, pCxt->pMetaCache); - if (TSDB_CODE_SUCCESS == code) { - code = reserveTableVgroupInCache(pCxt->pParseCxt->acctId, pClause->dbName, pClause->tableName, pCxt->pMetaCache); - } - if (TSDB_CODE_SUCCESS == code) { - code = reserveUserAuthInCache(pCxt->pParseCxt->acctId, pCxt->pParseCxt->pUser, pClause->dbName, - pClause->tableName, AUTH_TYPE_WRITE, pCxt->pMetaCache); + if (pStmt->withOpt) { + code = reserveTableUidInCache(pCxt->pParseCxt->acctId, pClause->dbName, pClause->tableName, pCxt->pMetaCache); + if (TSDB_CODE_SUCCESS == code) { + code = reserveDbVgInfoInCache(pCxt->pParseCxt->acctId, pClause->dbName, pCxt->pMetaCache); + } + if (TSDB_CODE_SUCCESS == code) { + code = reserveDbCfgInCache(pCxt->pParseCxt->acctId, pClause->dbName, pCxt->pMetaCache); + } + } else { + code = reserveTableMetaInCache(pCxt->pParseCxt->acctId, pClause->dbName, pClause->tableName, pCxt->pMetaCache); + if (TSDB_CODE_SUCCESS == code) { + code = + reserveTableVgroupInCache(pCxt->pParseCxt->acctId, pClause->dbName, pClause->tableName, pCxt->pMetaCache); + } + if (TSDB_CODE_SUCCESS == code) { + code = reserveUserAuthInCache(pCxt->pParseCxt->acctId, pCxt->pParseCxt->pUser, pClause->dbName, + pClause->tableName, AUTH_TYPE_WRITE, pCxt->pMetaCache); + } } if (TSDB_CODE_SUCCESS != code) { break; @@ -395,6 +406,9 @@ static int32_t collectMetaKeyFromDropTable(SCollectMetaKeyCxt* pCxt, SDropTableS } static int32_t collectMetaKeyFromDropStable(SCollectMetaKeyCxt* pCxt, SDropSuperTableStmt* pStmt) { + if (pStmt->withOpt) { + return reserveTableUidInCache(pCxt->pParseCxt->acctId, pStmt->dbName, pStmt->tableName, pCxt->pMetaCache); + } return reserveUserAuthInCache(pCxt->pParseCxt->acctId, pCxt->pParseCxt->pUser, pStmt->dbName, pStmt->tableName, AUTH_TYPE_WRITE, pCxt->pMetaCache); } diff --git a/source/libs/parser/src/parAuthenticator.c b/source/libs/parser/src/parAuthenticator.c index 9f738b32e8..0eb07d8143 100644 --- a/source/libs/parser/src/parAuthenticator.c +++ b/source/libs/parser/src/parAuthenticator.c @@ -290,7 +290,10 @@ static int32_t authCreateMultiTable(SAuthCxt* pCxt, SCreateMultiTablesStmt* pStm static int32_t authDropTable(SAuthCxt* pCxt, SDropTableStmt* pStmt) { int32_t code = TSDB_CODE_SUCCESS; - SNode* pNode = NULL; + if (pStmt->withOpt && !pCxt->pParseCxt->isSuperUser) { + return TSDB_CODE_PAR_PERMISSION_DENIED; + } + SNode* pNode = NULL; FOREACH(pNode, pStmt->pTables) { SDropTableClause* pClause = (SDropTableClause*)pNode; code = checkAuth(pCxt, pClause->dbName, pClause->tableName, AUTH_TYPE_WRITE, NULL); @@ -302,6 +305,9 @@ static int32_t authDropTable(SAuthCxt* pCxt, SDropTableStmt* pStmt) { } static int32_t authDropStable(SAuthCxt* pCxt, SDropSuperTableStmt* pStmt) { + if (pStmt->withOpt && !pCxt->pParseCxt->isSuperUser) { + return TSDB_CODE_PAR_PERMISSION_DENIED; + } return checkAuth(pCxt, pStmt->dbName, pStmt->tableName, AUTH_TYPE_WRITE, NULL); } diff --git a/source/libs/parser/src/parTranslater.c b/source/libs/parser/src/parTranslater.c index 9e2220994f..0a871967cf 100755 --- a/source/libs/parser/src/parTranslater.c +++ b/source/libs/parser/src/parTranslater.c @@ -478,6 +478,99 @@ static int32_t getViewMetaImpl(SParseContext* pParCxt, SParseMetaCache* pMetaCac } #endif +static int32_t getTargetNameImpl(SParseContext* pParCxt, SParseMetaCache* pMetaCache, const SName* pName, + char* pTbName) { + int32_t code = TSDB_CODE_SUCCESS; + if (pParCxt->async) { + code = getTableNameFromCache(pMetaCache, pName, pTbName); + } else { + code = TSDB_CODE_PAR_INTERNAL_ERROR; + } + if (TSDB_CODE_SUCCESS != code && TSDB_CODE_PAR_TABLE_NOT_EXIST != code) { + parserError("0x%" PRIx64 " catalogGetTableMeta error, code:%s, dbName:%s, tbName:%s", pParCxt->requestId, + tstrerror(code), pName->dbname, pName->tname); + } + return code; +} + +static int32_t getTargetName(STranslateContext* pCxt, const SName* pName, char* pTbName) { + SParseContext* pParCxt = pCxt->pParseCxt; + int32_t code = collectUseDatabase(pName, pCxt->pDbs); + if (TSDB_CODE_SUCCESS == code) { + code = collectUseTable(pName, pCxt->pTables); + } + if (TSDB_CODE_SUCCESS == code) { + code = getTargetNameImpl(pParCxt, pCxt->pMetaCache, pName, pTbName); + } + if (TSDB_CODE_SUCCESS != code && TSDB_CODE_PAR_TABLE_NOT_EXIST != code) { + parserError("0x%" PRIx64 " catalogGetTableMeta error, code:%s, dbName:%s, tbName:%s", pCxt->pParseCxt->requestId, + tstrerror(code), pName->dbname, pName->tname); + } + return code; +} + +static int32_t rewriteDropTableWithMetaCache(STranslateContext* pCxt) { + int32_t code = TSDB_CODE_SUCCESS; + SParseContext* pParCxt = pCxt->pParseCxt; + SParseMetaCache* pMetaCache = pCxt->pMetaCache; + int32_t tbMetaSize = taosHashGetSize(pMetaCache->pTableMeta); + int32_t tbMetaExSize = taosHashGetSize(pMetaCache->pTableName); + + if (tbMetaSize > 0 || tbMetaExSize <= 0) { + return TSDB_CODE_PAR_INTERNAL_ERROR; + } + if (!pMetaCache->pTableMeta && + !(pMetaCache->pTableMeta = + taosHashInit(tbMetaExSize, taosGetDefaultHashFunction(TSDB_DATA_TYPE_BINARY), true, HASH_NO_LOCK))) { + return TSDB_CODE_OUT_OF_MEMORY; + } + + SMetaRes** ppMetaRes = NULL; + char dbName[TSDB_DB_NAME_LEN] = {0}; + while ((ppMetaRes = taosHashIterate(pMetaCache->pTableName, ppMetaRes))) { + if (!(*ppMetaRes)) { + taosHashCancelIterate(pMetaCache->pTableName, ppMetaRes); + return TSDB_CODE_PAR_INTERNAL_ERROR; + } + + char* pKey = taosHashGetKey(ppMetaRes, NULL); + STableMeta* pMeta = (STableMeta*)(*ppMetaRes)->pRes; + if (!pMeta) { + taosHashCancelIterate(pMetaCache->pTableName, ppMetaRes); + return TSDB_CODE_PAR_INTERNAL_ERROR; + } + char* pDbStart = strstr(pKey, "."); + char* pDbEnd = pDbStart ? strstr(pDbStart + 1, ".") : NULL; + if (!pDbEnd) { + taosHashCancelIterate(pMetaCache->pTableName, ppMetaRes); + return TSDB_CODE_PAR_INTERNAL_ERROR; + } + tstrncpy(dbName, pDbStart + 1, pDbEnd - pDbStart); + + int32_t metaSize = + sizeof(STableMeta) + sizeof(SSchema) * (pMeta->tableInfo.numOfColumns + pMeta->tableInfo.numOfTags); + int32_t schemaExtSize = + (useCompress(pMeta->tableType) && pMeta->schemaExt) ? sizeof(SSchemaExt) * pMeta->tableInfo.numOfColumns : 0; + const char* pTbName = (const char*)pMeta + metaSize + schemaExtSize; + + SName name = {0}; + toName(pParCxt->acctId, dbName, pTbName, &name); + + char fullName[TSDB_TABLE_FNAME_LEN]; + code = tNameExtractFullName(&name, fullName); + if (TSDB_CODE_SUCCESS != code) { + taosHashCancelIterate(pMetaCache->pTableName, ppMetaRes); + return code; + } + + if ((code = taosHashPut(pMetaCache->pTableMeta, fullName, strlen(fullName), ppMetaRes, POINTER_BYTES))) { + taosHashCancelIterate(pMetaCache->pTableName, ppMetaRes); + return code; + } + } + return code; +} + int32_t getTargetMetaImpl(SParseContext* pParCxt, SParseMetaCache* pMetaCache, const SName* pName, STableMeta** pMeta, bool couldBeView) { int32_t code = TSDB_CODE_SUCCESS; @@ -617,7 +710,11 @@ static int32_t getTableHashVgroupImpl(STranslateContext* pCxt, const SName* pNam } if (TSDB_CODE_SUCCESS == code) { if (pParCxt->async) { - code = getTableVgroupFromCache(pCxt->pMetaCache, pName, pInfo); + if(pCxt->withOpt) { + code = getDbTableVgroupFromCache(pCxt->pMetaCache, pName, pInfo); + } else { + code = getTableVgroupFromCache(pCxt->pMetaCache, pName, pInfo); + } } else { SRequestConnInfo conn = {.pTrans = pParCxt->pTransporter, .requestId = pParCxt->requestId, @@ -14460,12 +14557,53 @@ int32_t serializeVgroupsDropTableBatch(SHashObj* pVgroupHashmap, SArray** pOut) return code; } +static int32_t rewriteDropTableWithOpt(STranslateContext* pCxt, SQuery* pQuery) { + int32_t code = TSDB_CODE_SUCCESS; + SDropTableStmt* pStmt = (SDropTableStmt*)pQuery->pRoot; + if (!pStmt->withOpt) return code; + pCxt->withOpt = true; + + SNode* pNode = NULL; + char pTableName[TSDB_TABLE_NAME_LEN] = {0}; + FOREACH(pNode, pStmt->pTables) { + SDropTableClause* pClause = (SDropTableClause*)pNode; + if (IS_SYS_DBNAME(pClause->dbName)) { + return generateSyntaxErrMsgExt(&pCxt->msgBuf, TSDB_CODE_TSC_INVALID_OPERATION, + "Cannot drop table of system database: `%s`.`%s`", pClause->dbName, + pClause->tableName); + } + for (int32_t i = 0; i < TSDB_TABLE_NAME_LEN; i++) { + if (pClause->tableName[i] == '\0') { + break; + } + if (!isdigit(pClause->tableName[i])) { + return generateSyntaxErrMsgExt(&pCxt->msgBuf, TSDB_CODE_PAR_TABLE_NOT_EXIST, "Table does not exist: `%s`.`%s`", + pClause->dbName, pClause->tableName); + } + } + SName name = {0}; + toName(pCxt->pParseCxt->acctId, pClause->dbName, pClause->tableName, &name); + int32_t code = getTargetName(pCxt, &name, pTableName); + if (TSDB_CODE_SUCCESS != code) { + return generateSyntaxErrMsgExt(&pCxt->msgBuf, code, "%s: db:`%s`, tbuid:`%s`", tstrerror(code), pClause->dbName, + pClause->tableName); + } + tstrncpy(pClause->tableName, pTableName, TSDB_TABLE_NAME_LEN); // rewrite table uid to table name + } + + code = rewriteDropTableWithMetaCache(pCxt); + + TAOS_RETURN(code); +} + static int32_t rewriteDropTable(STranslateContext* pCxt, SQuery* pQuery) { SDropTableStmt* pStmt = (SDropTableStmt*)pQuery->pRoot; int8_t tableType; SNode* pNode; SArray* pTsmas = NULL; + TAOS_CHECK_RETURN(rewriteDropTableWithOpt(pCxt, pQuery)); + SHashObj* pVgroupHashmap = taosHashInit(4, taosGetDefaultHashFunction(TSDB_DATA_TYPE_INT), false, HASH_NO_LOCK); if (NULL == pVgroupHashmap) { return terrno; @@ -14482,8 +14620,10 @@ static int32_t rewriteDropTable(STranslateContext* pCxt, SQuery* pQuery) { return code; } if (tableType == TSDB_SUPER_TABLE && LIST_LENGTH(pStmt->pTables) > 1) { + taosHashCleanup(pVgroupHashmap); return generateSyntaxErrMsg(&pCxt->msgBuf, TSDB_CODE_PAR_INVALID_DROP_STABLE); } + if (pCxt->withOpt) continue; if (pCxt->pMetaCache) code = getTableTsmasFromCache(pCxt->pMetaCache, &name, &pTsmas); if (TSDB_CODE_SUCCESS != code) { taosHashCleanup(pVgroupHashmap); @@ -14545,6 +14685,47 @@ static int32_t rewriteDropTable(STranslateContext* pCxt, SQuery* pQuery) { return rewriteToVnodeModifyOpStmt(pQuery, pBufArray); } +static int32_t rewriteDropSuperTablewithOpt(STranslateContext* pCxt, SQuery* pQuery) { + int32_t code = TSDB_CODE_SUCCESS; + SDropSuperTableStmt* pStmt = (SDropSuperTableStmt*)pQuery->pRoot; + if (!pStmt->withOpt) return code; + pCxt->withOpt = true; + + if (IS_SYS_DBNAME(pStmt->dbName)) { + return generateSyntaxErrMsgExt(&pCxt->msgBuf, TSDB_CODE_TSC_INVALID_OPERATION, + "Cannot drop table of system database: `%s`.`%s`", pStmt->dbName, pStmt->tableName); + } + + for (int32_t i = 0; i < TSDB_TABLE_NAME_LEN; i++) { + if (pStmt->tableName[i] == '\0') { + break; + } + if (!isdigit(pStmt->tableName[i])) { + return generateSyntaxErrMsgExt(&pCxt->msgBuf, TSDB_CODE_PAR_TABLE_NOT_EXIST, "Table does not exist: `%s`.`%s`", + pStmt->dbName, pStmt->tableName); + } + } + + char pTableName[TSDB_TABLE_NAME_LEN] = {0}; + SName name = {0}; + toName(pCxt->pParseCxt->acctId, pStmt->dbName, pStmt->tableName, &name); + code = getTargetName(pCxt, &name, pTableName); + if (TSDB_CODE_SUCCESS != code) { + return generateSyntaxErrMsgExt(&pCxt->msgBuf, code, "%s: db:`%s`, tbuid:`%s`", tstrerror(code), pStmt->dbName, + pStmt->tableName); + } + tstrncpy(pStmt->tableName, pTableName, TSDB_TABLE_NAME_LEN); // rewrite table uid to table name + + code = rewriteDropTableWithMetaCache(pCxt); + + TAOS_RETURN(code); +} + +static int32_t rewriteDropSuperTable(STranslateContext* pCxt, SQuery* pQuery) { + TAOS_CHECK_RETURN(rewriteDropSuperTablewithOpt(pCxt, pQuery)); + TAOS_RETURN(0); +} + static int32_t buildUpdateTagValReq(STranslateContext* pCxt, SAlterTableStmt* pStmt, STableMeta* pTableMeta, SVAlterTbReq* pReq) { SName tbName = {0}; @@ -15616,6 +15797,9 @@ static int32_t rewriteQuery(STranslateContext* pCxt, SQuery* pQuery) { case QUERY_NODE_DROP_TABLE_STMT: code = rewriteDropTable(pCxt, pQuery); break; + case QUERY_NODE_DROP_SUPER_TABLE_STMT: + code = rewriteDropSuperTable(pCxt, pQuery); + break; case QUERY_NODE_ALTER_TABLE_STMT: code = rewriteAlterTable(pCxt, pQuery); break; diff --git a/source/libs/parser/src/parUtil.c b/source/libs/parser/src/parUtil.c index 76a8303cad..1b90144a2c 100644 --- a/source/libs/parser/src/parUtil.c +++ b/source/libs/parser/src/parUtil.c @@ -804,6 +804,9 @@ int32_t buildCatalogReq(const SParseMetaCache* pMetaCache, SCatalogReq* pCatalog if (TSDB_CODE_SUCCESS == code) { code = buildTableReqFromDb(pMetaCache->pTSMAs, &pCatalogReq->pTSMAs); } + if (TSDB_CODE_SUCCESS == code) { + code = buildTableReqFromDb(pMetaCache->pTableName, &pCatalogReq->pTableName); + } #ifdef TD_ENTERPRISE if (TSDB_CODE_SUCCESS == code) { code = buildTableReqFromDb(pMetaCache->pTableMeta, &pCatalogReq->pView); @@ -960,6 +963,9 @@ int32_t putMetaDataToCache(const SCatalogReq* pCatalogReq, const SMetaData* pMet if (TSDB_CODE_SUCCESS == code) { code = putDbTableDataToCache(pCatalogReq->pTSMAs, pMetaData->pTsmas, &pMetaCache->pTSMAs); } + if (TSDB_CODE_SUCCESS == code) { + code = putDbTableDataToCache(pCatalogReq->pTableName, pMetaData->pTableMeta, &pMetaCache->pTableName); + } #ifdef TD_ENTERPRISE if (TSDB_CODE_SUCCESS == code) { code = putDbTableDataToCache(pCatalogReq->pView, pMetaData->pView, &pMetaCache->pViews); @@ -1019,8 +1025,12 @@ int32_t reserveTableMetaInCacheExt(const SName* pName, SParseMetaCache* pMetaCac return reserveTableReqInDbCache(pName->acctId, pName->dbname, pName->tname, &pMetaCache->pTableMeta); } +int32_t reserveTableUidInCache(int32_t acctId, const char* pDb, const char* pTable, SParseMetaCache* pMetaCache) { + return reserveTableReqInDbCache(acctId, pDb, pTable, &pMetaCache->pTableName); +} + int32_t getTableMetaFromCache(SParseMetaCache* pMetaCache, const SName* pName, STableMeta** pMeta) { - char fullName[TSDB_TABLE_FNAME_LEN]; + char fullName[TSDB_TABLE_FNAME_LEN]; int32_t code = tNameExtractFullName(pName, fullName); if (TSDB_CODE_SUCCESS != code) { return code; @@ -1036,6 +1046,27 @@ int32_t getTableMetaFromCache(SParseMetaCache* pMetaCache, const SName* pName, S return code; } +int32_t getTableNameFromCache(SParseMetaCache* pMetaCache, const SName* pName, char* pTbName) { + char fullName[TSDB_TABLE_FNAME_LEN]; + int32_t code = tNameExtractFullName(pName, fullName); + if (TSDB_CODE_SUCCESS != code) { + return code; + } + const STableMeta* pMeta = NULL; + code = getMetaDataFromHash(fullName, strlen(fullName), pMetaCache->pTableName, (void**)&pMeta); + if (TSDB_CODE_SUCCESS == code) { + if (!pMeta) code = TSDB_CODE_PAR_INTERNAL_ERROR; + int32_t metaSize = + sizeof(STableMeta) + sizeof(SSchema) * (pMeta->tableInfo.numOfColumns + pMeta->tableInfo.numOfTags); + int32_t schemaExtSize = + (useCompress(pMeta->tableType) && pMeta->schemaExt) ? sizeof(SSchemaExt) * pMeta->tableInfo.numOfColumns : 0; + const char* pTableName = (const char*)pMeta + metaSize + schemaExtSize; + tstrncpy(pTbName, pTableName, TSDB_TABLE_NAME_LEN); + } + + return code; +} + int32_t buildTableMetaFromViewMeta(STableMeta** pMeta, SViewMeta* pViewMeta) { *pMeta = taosMemoryCalloc(1, sizeof(STableMeta) + pViewMeta->numOfCols * sizeof(SSchema)); if (NULL == *pMeta) { @@ -1121,6 +1152,38 @@ int32_t getTableVgroupFromCache(SParseMetaCache* pMetaCache, const SName* pName, return code; } +int32_t getDbTableVgroupFromCache(SParseMetaCache* pMetaCache, const SName* pName, SVgroupInfo* pVgroup) { + char fullName[TSDB_TABLE_FNAME_LEN]; + int32_t code = tNameExtractFullName(pName, fullName); + if (TSDB_CODE_SUCCESS != code) { + return code; + } + const char* pDb = strstr(fullName, "."); + if (pDb == NULL) return TSDB_CODE_PAR_INTERNAL_ERROR; + pDb = strstr(pDb + 1, "."); + if (pDb == NULL) return TSDB_CODE_PAR_INTERNAL_ERROR; + int32_t fullDbLen = pDb - fullName; + int32_t fullTbLen = strlen(fullName); + + SArray* pVgArray = NULL; + SDbCfgInfo* pDbCfg = NULL; + code = getMetaDataFromHash(fullName, fullDbLen, pMetaCache->pDbVgroup, (void**)&pVgArray); + if (TSDB_CODE_SUCCESS == code) { + code = getMetaDataFromHash(fullName, fullDbLen, pMetaCache->pDbCfg, (void**)&pDbCfg); + } + if (TSDB_CODE_SUCCESS == code) { + uint32_t hashValue = + taosGetTbHashVal(fullName, fullTbLen, pDbCfg->hashMethod, pDbCfg->hashPrefix, pDbCfg->hashSuffix); + SVgroupInfo* pVg = taosArraySearch(pVgArray, &hashValue, ctgHashValueComp, TD_EQ); + if (pVg) { + memcpy(pVgroup, pVg, sizeof(SVgroupInfo)); + } else { + code = TSDB_CODE_PAR_INTERNAL_ERROR; + } + } + return code; +} + int32_t reserveDbVgVersionInCache(int32_t acctId, const char* pDb, SParseMetaCache* pMetaCache) { return reserveDbReqInCache(acctId, pDb, &pMetaCache->pDbInfo); } @@ -1396,11 +1459,13 @@ void destoryParseMetaCache(SParseMetaCache* pMetaCache, bool request) { destoryParseTablesMetaReqHash(pMetaCache->pTableVgroup); destoryParseTablesMetaReqHash(pMetaCache->pViews); destoryParseTablesMetaReqHash(pMetaCache->pTSMAs); + destoryParseTablesMetaReqHash(pMetaCache->pTableName); } else { taosHashCleanup(pMetaCache->pTableMeta); taosHashCleanup(pMetaCache->pTableVgroup); taosHashCleanup(pMetaCache->pViews); taosHashCleanup(pMetaCache->pTSMAs); + taosHashCleanup(pMetaCache->pTableName); } taosHashCleanup(pMetaCache->pDbVgroup); taosHashCleanup(pMetaCache->pDbCfg); diff --git a/source/libs/parser/src/parser.c b/source/libs/parser/src/parser.c index 2de61ab669..8ac1acb1a2 100644 --- a/source/libs/parser/src/parser.c +++ b/source/libs/parser/src/parser.c @@ -351,6 +351,7 @@ void destoryCatalogReq(SCatalogReq* pCatalogReq) { #endif taosArrayDestroy(pCatalogReq->pTableTSMAs); taosArrayDestroy(pCatalogReq->pTSMAs); + taosArrayDestroy(pCatalogReq->pTableName); } else { taosArrayDestroyEx(pCatalogReq->pTableMeta, destoryTablesReq); taosArrayDestroyEx(pCatalogReq->pTableHash, destoryTablesReq); @@ -359,6 +360,7 @@ void destoryCatalogReq(SCatalogReq* pCatalogReq) { #endif taosArrayDestroyEx(pCatalogReq->pTableTSMAs, destoryTablesReq); taosArrayDestroyEx(pCatalogReq->pTSMAs, destoryTablesReq); + taosArrayDestroyEx(pCatalogReq->pTableName, destoryTablesReq); } taosArrayDestroy(pCatalogReq->pUdf); taosArrayDestroy(pCatalogReq->pIndex); diff --git a/source/libs/parser/src/sql.c b/source/libs/parser/src/sql.c index 47a43f1485..2c7f473d9a 100644 --- a/source/libs/parser/src/sql.c +++ b/source/libs/parser/src/sql.c @@ -1,6 +1,3 @@ -/* This file is automatically generated by Lemon from input grammar -** source file "sql.y". -*/ /* ** 2000-05-29 ** @@ -25,7 +22,10 @@ ** The following is the concatenation of all %include directives from the ** input grammar file: */ +#include +#include /************ Begin %include sections from the grammar ************************/ + #include #include #include @@ -42,393 +42,11 @@ #define YYSTACKDEPTH 0 /**************** End of %include directives **********************************/ -/* These constants specify the various numeric values for terminal symbols. -***************** Begin token definitions *************************************/ -#ifndef TK_OR -#define TK_OR 1 -#define TK_AND 2 -#define TK_UNION 3 -#define TK_ALL 4 -#define TK_MINUS 5 -#define TK_EXCEPT 6 -#define TK_INTERSECT 7 -#define TK_NK_BITAND 8 -#define TK_NK_BITOR 9 -#define TK_NK_LSHIFT 10 -#define TK_NK_RSHIFT 11 -#define TK_NK_PLUS 12 -#define TK_NK_MINUS 13 -#define TK_NK_STAR 14 -#define TK_NK_SLASH 15 -#define TK_NK_REM 16 -#define TK_NK_CONCAT 17 -#define TK_CREATE 18 -#define TK_ACCOUNT 19 -#define TK_NK_ID 20 -#define TK_PASS 21 -#define TK_NK_STRING 22 -#define TK_ALTER 23 -#define TK_PPS 24 -#define TK_TSERIES 25 -#define TK_STORAGE 26 -#define TK_STREAMS 27 -#define TK_QTIME 28 -#define TK_DBS 29 -#define TK_USERS 30 -#define TK_CONNS 31 -#define TK_STATE 32 -#define TK_NK_COMMA 33 -#define TK_HOST 34 -#define TK_IS_IMPORT 35 -#define TK_NK_INTEGER 36 -#define TK_CREATEDB 37 -#define TK_USER 38 -#define TK_ENABLE 39 -#define TK_SYSINFO 40 -#define TK_ADD 41 -#define TK_DROP 42 -#define TK_GRANT 43 -#define TK_ON 44 -#define TK_TO 45 -#define TK_REVOKE 46 -#define TK_FROM 47 -#define TK_SUBSCRIBE 48 -#define TK_READ 49 -#define TK_WRITE 50 -#define TK_NK_DOT 51 -#define TK_WITH 52 -#define TK_ENCRYPT_KEY 53 -#define TK_DNODE 54 -#define TK_PORT 55 -#define TK_DNODES 56 -#define TK_RESTORE 57 -#define TK_NK_IPTOKEN 58 -#define TK_FORCE 59 -#define TK_UNSAFE 60 -#define TK_CLUSTER 61 -#define TK_LOCAL 62 -#define TK_QNODE 63 -#define TK_BNODE 64 -#define TK_SNODE 65 -#define TK_MNODE 66 -#define TK_VNODE 67 -#define TK_DATABASE 68 -#define TK_USE 69 -#define TK_FLUSH 70 -#define TK_TRIM 71 -#define TK_S3MIGRATE 72 -#define TK_COMPACT 73 -#define TK_IF 74 -#define TK_NOT 75 -#define TK_EXISTS 76 -#define TK_BUFFER 77 -#define TK_CACHEMODEL 78 -#define TK_CACHESIZE 79 -#define TK_COMP 80 -#define TK_DURATION 81 -#define TK_NK_VARIABLE 82 -#define TK_MAXROWS 83 -#define TK_MINROWS 84 -#define TK_KEEP 85 -#define TK_PAGES 86 -#define TK_PAGESIZE 87 -#define TK_TSDB_PAGESIZE 88 -#define TK_PRECISION 89 -#define TK_REPLICA 90 -#define TK_VGROUPS 91 -#define TK_SINGLE_STABLE 92 -#define TK_RETENTIONS 93 -#define TK_SCHEMALESS 94 -#define TK_WAL_LEVEL 95 -#define TK_WAL_FSYNC_PERIOD 96 -#define TK_WAL_RETENTION_PERIOD 97 -#define TK_WAL_RETENTION_SIZE 98 -#define TK_WAL_ROLL_PERIOD 99 -#define TK_WAL_SEGMENT_SIZE 100 -#define TK_STT_TRIGGER 101 -#define TK_TABLE_PREFIX 102 -#define TK_TABLE_SUFFIX 103 -#define TK_S3_CHUNKSIZE 104 -#define TK_S3_KEEPLOCAL 105 -#define TK_S3_COMPACT 106 -#define TK_KEEP_TIME_OFFSET 107 -#define TK_ENCRYPT_ALGORITHM 108 -#define TK_NK_COLON 109 -#define TK_BWLIMIT 110 -#define TK_START 111 -#define TK_TIMESTAMP 112 -#define TK_END 113 -#define TK_TABLE 114 -#define TK_NK_LP 115 -#define TK_NK_RP 116 -#define TK_USING 117 -#define TK_FILE 118 -#define TK_STABLE 119 -#define TK_COLUMN 120 -#define TK_MODIFY 121 -#define TK_RENAME 122 -#define TK_TAG 123 -#define TK_SET 124 -#define TK_NK_EQ 125 -#define TK_TAGS 126 -#define TK_BOOL 127 -#define TK_TINYINT 128 -#define TK_SMALLINT 129 -#define TK_INT 130 -#define TK_INTEGER 131 -#define TK_BIGINT 132 -#define TK_FLOAT 133 -#define TK_DOUBLE 134 -#define TK_BINARY 135 -#define TK_NCHAR 136 -#define TK_UNSIGNED 137 -#define TK_JSON 138 -#define TK_VARCHAR 139 -#define TK_MEDIUMBLOB 140 -#define TK_BLOB 141 -#define TK_VARBINARY 142 -#define TK_GEOMETRY 143 -#define TK_DECIMAL 144 -#define TK_COMMENT 145 -#define TK_MAX_DELAY 146 -#define TK_WATERMARK 147 -#define TK_ROLLUP 148 -#define TK_TTL 149 -#define TK_SMA 150 -#define TK_DELETE_MARK 151 -#define TK_FIRST 152 -#define TK_LAST 153 -#define TK_SHOW 154 -#define TK_FULL 155 -#define TK_PRIVILEGES 156 -#define TK_DATABASES 157 -#define TK_TABLES 158 -#define TK_STABLES 159 -#define TK_MNODES 160 -#define TK_QNODES 161 -#define TK_ARBGROUPS 162 -#define TK_FUNCTIONS 163 -#define TK_INDEXES 164 -#define TK_ACCOUNTS 165 -#define TK_APPS 166 -#define TK_CONNECTIONS 167 -#define TK_LICENCES 168 -#define TK_GRANTS 169 -#define TK_LOGS 170 -#define TK_MACHINES 171 -#define TK_ENCRYPTIONS 172 -#define TK_QUERIES 173 -#define TK_SCORES 174 -#define TK_TOPICS 175 -#define TK_VARIABLES 176 -#define TK_BNODES 177 -#define TK_SNODES 178 -#define TK_TRANSACTIONS 179 -#define TK_DISTRIBUTED 180 -#define TK_CONSUMERS 181 -#define TK_SUBSCRIPTIONS 182 -#define TK_VNODES 183 -#define TK_ALIVE 184 -#define TK_VIEWS 185 -#define TK_VIEW 186 -#define TK_COMPACTS 187 -#define TK_NORMAL 188 -#define TK_CHILD 189 -#define TK_LIKE 190 -#define TK_TBNAME 191 -#define TK_QTAGS 192 -#define TK_AS 193 -#define TK_SYSTEM 194 -#define TK_TSMA 195 -#define TK_INTERVAL 196 -#define TK_RECURSIVE 197 -#define TK_TSMAS 198 -#define TK_FUNCTION 199 -#define TK_INDEX 200 -#define TK_COUNT 201 -#define TK_LAST_ROW 202 -#define TK_META 203 -#define TK_ONLY 204 -#define TK_TOPIC 205 -#define TK_CONSUMER 206 -#define TK_GROUP 207 -#define TK_DESC 208 -#define TK_DESCRIBE 209 -#define TK_RESET 210 -#define TK_QUERY 211 -#define TK_CACHE 212 -#define TK_EXPLAIN 213 -#define TK_ANALYZE 214 -#define TK_VERBOSE 215 -#define TK_NK_BOOL 216 -#define TK_RATIO 217 -#define TK_NK_FLOAT 218 -#define TK_OUTPUTTYPE 219 -#define TK_AGGREGATE 220 -#define TK_BUFSIZE 221 -#define TK_LANGUAGE 222 -#define TK_REPLACE 223 -#define TK_STREAM 224 -#define TK_INTO 225 -#define TK_PAUSE 226 -#define TK_RESUME 227 -#define TK_PRIMARY 228 -#define TK_KEY 229 -#define TK_TRIGGER 230 -#define TK_AT_ONCE 231 -#define TK_WINDOW_CLOSE 232 -#define TK_IGNORE 233 -#define TK_EXPIRED 234 -#define TK_FILL_HISTORY 235 -#define TK_UPDATE 236 -#define TK_SUBTABLE 237 -#define TK_UNTREATED 238 -#define TK_KILL 239 -#define TK_CONNECTION 240 -#define TK_TRANSACTION 241 -#define TK_BALANCE 242 -#define TK_VGROUP 243 -#define TK_LEADER 244 -#define TK_MERGE 245 -#define TK_REDISTRIBUTE 246 -#define TK_SPLIT 247 -#define TK_DELETE 248 -#define TK_INSERT 249 -#define TK_NK_BIN 250 -#define TK_NK_HEX 251 -#define TK_NULL 252 -#define TK_NK_QUESTION 253 -#define TK_NK_ALIAS 254 -#define TK_NK_ARROW 255 -#define TK_ROWTS 256 -#define TK_QSTART 257 -#define TK_QEND 258 -#define TK_QDURATION 259 -#define TK_WSTART 260 -#define TK_WEND 261 -#define TK_WDURATION 262 -#define TK_IROWTS 263 -#define TK_ISFILLED 264 -#define TK_CAST 265 -#define TK_POSITION 266 -#define TK_IN 267 -#define TK_FOR 268 -#define TK_NOW 269 -#define TK_TODAY 270 -#define TK_RAND 271 -#define TK_SUBSTR 272 -#define TK_SUBSTRING 273 -#define TK_BOTH 274 -#define TK_TRAILING 275 -#define TK_LEADING 276 -#define TK_TIMEZONE 277 -#define TK_CLIENT_VERSION 278 -#define TK_SERVER_VERSION 279 -#define TK_SERVER_STATUS 280 -#define TK_CURRENT_USER 281 -#define TK_PI 282 -#define TK_CASE 283 -#define TK_WHEN 284 -#define TK_THEN 285 -#define TK_ELSE 286 -#define TK_BETWEEN 287 -#define TK_IS 288 -#define TK_NK_LT 289 -#define TK_NK_GT 290 -#define TK_NK_LE 291 -#define TK_NK_GE 292 -#define TK_NK_NE 293 -#define TK_MATCH 294 -#define TK_NMATCH 295 -#define TK_CONTAINS 296 -#define TK_JOIN 297 -#define TK_INNER 298 -#define TK_LEFT 299 -#define TK_RIGHT 300 -#define TK_OUTER 301 -#define TK_SEMI 302 -#define TK_ANTI 303 -#define TK_ASOF 304 -#define TK_WINDOW 305 -#define TK_WINDOW_OFFSET 306 -#define TK_JLIMIT 307 -#define TK_SELECT 308 -#define TK_NK_HINT 309 -#define TK_DISTINCT 310 -#define TK_WHERE 311 -#define TK_PARTITION 312 -#define TK_BY 313 -#define TK_SESSION 314 -#define TK_STATE_WINDOW 315 -#define TK_EVENT_WINDOW 316 -#define TK_COUNT_WINDOW 317 -#define TK_SLIDING 318 -#define TK_FILL 319 -#define TK_VALUE 320 -#define TK_VALUE_F 321 -#define TK_NONE 322 -#define TK_PREV 323 -#define TK_NULL_F 324 -#define TK_LINEAR 325 -#define TK_NEXT 326 -#define TK_HAVING 327 -#define TK_RANGE 328 -#define TK_EVERY 329 -#define TK_ORDER 330 -#define TK_SLIMIT 331 -#define TK_SOFFSET 332 -#define TK_LIMIT 333 -#define TK_OFFSET 334 -#define TK_ASC 335 -#define TK_NULLS 336 -#define TK_ABORT 337 -#define TK_AFTER 338 -#define TK_ATTACH 339 -#define TK_BEFORE 340 -#define TK_BEGIN 341 -#define TK_BITAND 342 -#define TK_BITNOT 343 -#define TK_BITOR 344 -#define TK_BLOCKS 345 -#define TK_CHANGE 346 -#define TK_COMMA 347 -#define TK_CONCAT 348 -#define TK_CONFLICT 349 -#define TK_COPY 350 -#define TK_DEFERRED 351 -#define TK_DELIMITERS 352 -#define TK_DETACH 353 -#define TK_DIVIDE 354 -#define TK_DOT 355 -#define TK_EACH 356 -#define TK_FAIL 357 -#define TK_GLOB 358 -#define TK_ID 359 -#define TK_IMMEDIATE 360 -#define TK_IMPORT 361 -#define TK_INITIALLY 362 -#define TK_INSTEAD 363 -#define TK_ISNULL 364 -#define TK_MODULES 365 -#define TK_NK_BITNOT 366 -#define TK_NK_SEMI 367 -#define TK_NOTNULL 368 -#define TK_OF 369 -#define TK_PLUS 370 -#define TK_PRIVILEGE 371 -#define TK_RAISE 372 -#define TK_RESTRICT 373 -#define TK_ROW 374 -#define TK_STAR 375 -#define TK_STATEMENT 376 -#define TK_STRICT 377 -#define TK_STRING 378 -#define TK_TIMES 379 -#define TK_VALUES 380 -#define TK_VARIABLE 381 -#define TK_WAL 382 -#endif -/**************** End token definitions ***************************************/ +/* These constants specify the various numeric values for terminal symbols +** in a format understandable to "makeheaders". This section is blank unless +** "lemon" is run with the "-m" command-line option. +***************** Begin makeheaders token definitions *************************/ +/**************** End makeheaders token definitions ***************************/ /* The next sections is a series of control #defines. ** various aspects of the generated parser. @@ -453,7 +71,7 @@ ** the minor type might be the name of the identifier. ** Each non-terminal can have a different minor type. ** Terminal symbols all have the same minor type, though. -** This macros defines the minor type for terminal +** This macros defines the minor type for terminal ** symbols. ** YYMINORTYPE is the data type used for all minor types. ** This is typically a union of many types, one of @@ -467,9 +85,6 @@ ** ParseARG_STORE Code to store %extra_argument into yypParser ** ParseARG_FETCH Code to extract %extra_argument from yypParser ** ParseCTX_* As ParseARG_ except for %extra_context -** YYREALLOC Name of the realloc() function to use -** YYFREE Name of the free() function to use -** YYDYNSTACK True if stack space should be extended on heap ** YYERRORSYMBOL is the code number of the error symbol. If not ** defined, then do no error processing. ** YYNSTATE the combined number of states. @@ -483,71 +98,64 @@ ** YY_NO_ACTION The yy_action[] code for no-op ** YY_MIN_REDUCE Minimum value for reduce actions ** YY_MAX_REDUCE Maximum value for reduce actions -** YY_MIN_DSTRCTR Minimum symbol value that has a destructor -** YY_MAX_DSTRCTR Maximum symbol value that has a destructor */ #ifndef INTERFACE # define INTERFACE 1 #endif /************* Begin control #defines *****************************************/ #define YYCODETYPE unsigned short int -#define YYNOCODE 566 +#define YYNOCODE 567 #define YYACTIONTYPE unsigned short int -#define ParseTOKENTYPE SToken +#define ParseTOKENTYPE SToken typedef union { int yyinit; ParseTOKENTYPE yy0; - EFillMode yy58; - int8_t yy107; - int64_t yy145; - EOperatorType yy164; - ENullOrder yy417; - bool yy429; - SToken yy461; - STokenPair yy517; - SAlterOption yy533; - int32_t yy696; - SNodeList* yy712; - SNode* yy724; - EOrder yy746; - ETrimType yy796; - EJoinSubType yy798; - SShowTablesOption yy801; - EJoinType yy916; - EShowKind yy973; - SDataType yy1016; + EFillMode yy18; + EJoinType yy36; + ENullOrder yy109; + bool yy173; + SNodeList* yy334; + SAlterOption yy389; + STokenPair yy399; + EOperatorType yy506; + SToken yy533; + EShowKind yy537; + SNode* yy560; + int64_t yy585; + EJoinSubType yy648; + ETrimType yy672; + SShowTablesOption yy709; + int8_t yy719; + int32_t yy802; + SDataType yy952; + EOrder yy974; } YYMINORTYPE; #ifndef YYSTACKDEPTH #define YYSTACKDEPTH 100 #endif #define ParseARG_SDECL SAstCreateContext* pCxt ; -#define ParseARG_PDECL , SAstCreateContext* pCxt -#define ParseARG_PARAM ,pCxt +#define ParseARG_PDECL , SAstCreateContext* pCxt +#define ParseARG_PARAM ,pCxt #define ParseARG_FETCH SAstCreateContext* pCxt =yypParser->pCxt ; #define ParseARG_STORE yypParser->pCxt =pCxt ; -#define YYREALLOC realloc -#define YYFREE free -#define YYDYNSTACK 0 #define ParseCTX_SDECL #define ParseCTX_PDECL #define ParseCTX_PARAM #define ParseCTX_FETCH #define ParseCTX_STORE #define YYFALLBACK 1 -#define YYNSTATE 1007 -#define YYNRULE 771 -#define YYNRULE_WITH_ACTION 771 +#define YYNSTATE 1009 +#define YYNRULE 773 +#define YYNRULE_WITH_ACTION 773 #define YYNTOKEN 383 -#define YY_MAX_SHIFT 1006 -#define YY_MIN_SHIFTREDUCE 1492 -#define YY_MAX_SHIFTREDUCE 2262 -#define YY_ERROR_ACTION 2263 -#define YY_ACCEPT_ACTION 2264 -#define YY_NO_ACTION 2265 -#define YY_MIN_REDUCE 2266 -#define YY_MAX_REDUCE 3036 -#define YY_MIN_DSTRCTR 384 -#define YY_MAX_DSTRCTR 565 +#define YY_MAX_SHIFT 1008 +#define YY_MIN_SHIFTREDUCE 1495 +#define YY_MAX_SHIFTREDUCE 2267 +#define YY_ERROR_ACTION 2268 +#define YY_ACCEPT_ACTION 2269 +#define YY_NO_ACTION 2270 +#define YY_MIN_REDUCE 2271 +#define YY_MAX_REDUCE 3043 /************* End control #defines *******************************************/ #define YY_NLOOKAHEAD ((int)(sizeof(yy_lookahead)/sizeof(yy_lookahead[0]))) @@ -563,27 +171,11 @@ typedef union { # define yytestcase(X) #endif -/* Macro to determine if stack space has the ability to grow using -** heap memory. -*/ -#if YYSTACKDEPTH<=0 || YYDYNSTACK -# define YYGROWABLESTACK 1 -#else -# define YYGROWABLESTACK 0 -#endif - -/* Guarantee a minimum number of initial stack slots. - */ -#if YYSTACKDEPTH<=0 -# undef YYSTACKDEPTH -# define YYSTACKDEPTH 2 /* Need a minimum stack size */ -#endif - /* Next are the tables used to determine what action to take based on the ** current state and lookahead token. These tables are used to implement ** functions that take a state number and lookahead value and return an -** action integer. +** action integer. ** ** Suppose the action integer is N. Then the action is determined as ** follows @@ -630,1204 +222,1187 @@ typedef union { ** yy_default[] Default action for each state. ** *********** Begin parsing tables **********************************************/ -#define YY_ACTTAB_COUNT (4470) +#define YY_ACTTAB_COUNT (4386) static const YYACTIONTYPE yy_action[] = { - /* 0 */ 823, 672, 2448, 3009, 673, 2314, 680, 2463, 3004, 673, - /* 10 */ 2314, 3004, 59, 57, 522, 44, 352, 2527, 2529, 2461, - /* 20 */ 500, 2267, 1984, 2629, 898, 2754, 822, 230, 517, 2010, - /* 30 */ 3008, 3005, 824, 575, 3005, 3007, 1982, 492, 2089, 2358, - /* 40 */ 2289, 2796, 150, 2626, 885, 149, 148, 147, 146, 145, - /* 50 */ 144, 143, 142, 141, 759, 2009, 838, 52, 51, 835, - /* 60 */ 169, 58, 56, 55, 54, 53, 2266, 871, 2084, 2013, - /* 70 */ 753, 868, 757, 755, 300, 299, 940, 2009, 870, 3009, - /* 80 */ 835, 169, 1990, 637, 635, 2814, 437, 3004, 506, 244, - /* 90 */ 159, 158, 157, 156, 155, 154, 153, 152, 151, 194, - /* 100 */ 2761, 2761, 903, 880, 835, 169, 3008, 898, 520, 2476, - /* 110 */ 3005, 3006, 1003, 584, 2598, 60, 974, 973, 972, 971, - /* 120 */ 530, 126, 970, 969, 174, 964, 963, 962, 961, 960, - /* 130 */ 959, 958, 173, 952, 951, 950, 529, 528, 947, 946, - /* 140 */ 945, 210, 209, 944, 525, 943, 942, 941, 2795, 1537, - /* 150 */ 2264, 2843, 2092, 2093, 2554, 133, 2797, 884, 2799, 2800, - /* 160 */ 879, 1756, 1757, 867, 2844, 903, 772, 246, 1544, 2465, - /* 170 */ 212, 223, 2906, 250, 52, 51, 494, 2902, 58, 56, - /* 180 */ 55, 54, 53, 2796, 139, 2914, 2915, 2521, 167, 2919, - /* 190 */ 136, 2045, 2055, 1539, 1542, 1543, 231, 2010, 838, 520, - /* 200 */ 2476, 2091, 2094, 2012, 2953, 206, 2914, 834, 3009, 161, - /* 210 */ 833, 58, 56, 55, 54, 53, 1985, 3004, 1983, 106, - /* 220 */ 677, 898, 9, 866, 105, 2012, 674, 2814, 837, 199, - /* 230 */ 2914, 2915, 506, 167, 2919, 822, 230, 2156, 813, 533, - /* 240 */ 3005, 824, 226, 2761, 532, 880, 903, 196, 1830, 1831, - /* 250 */ 481, 2676, 1988, 1989, 2042, 2407, 2044, 2047, 2048, 2049, - /* 260 */ 2050, 2051, 2052, 2053, 2054, 876, 869, 899, 2474, 901, - /* 270 */ 900, 865, 2076, 2077, 2078, 2079, 2080, 2083, 2085, 2086, - /* 280 */ 2087, 2088, 2090, 2, 59, 57, 2181, 160, 835, 169, - /* 290 */ 2795, 104, 500, 2843, 1984, 718, 789, 133, 2797, 884, - /* 300 */ 2799, 2800, 879, 2014, 3004, 867, 2844, 903, 1982, 614, - /* 310 */ 2089, 303, 212, 2571, 2906, 302, 62, 898, 494, 2902, - /* 320 */ 688, 2249, 3010, 230, 613, 112, 2796, 3005, 824, 1857, - /* 330 */ 1858, 52, 51, 2156, 2009, 58, 56, 55, 54, 53, - /* 340 */ 2084, 881, 2771, 868, 52, 51, 2954, 19, 58, 56, - /* 350 */ 55, 54, 53, 2470, 1990, 150, 34, 2755, 149, 148, - /* 360 */ 147, 146, 145, 144, 143, 142, 141, 59, 57, 400, - /* 370 */ 2814, 2775, 552, 2511, 2256, 500, 334, 1984, 1856, 1859, - /* 380 */ 2153, 2154, 2155, 204, 1003, 329, 2761, 15, 880, 115, - /* 390 */ 2185, 1982, 2534, 2089, 449, 691, 2009, 479, 334, 761, - /* 400 */ 460, 78, 52, 51, 527, 526, 58, 56, 55, 54, - /* 410 */ 53, 2532, 62, 200, 2914, 2915, 2156, 167, 2919, 2534, - /* 420 */ 506, 2777, 2780, 2084, 2092, 2093, 868, 490, 1991, 74, - /* 430 */ 19, 899, 2474, 2795, 903, 903, 2843, 1990, 2532, 2226, - /* 440 */ 133, 2797, 884, 2799, 2800, 879, 899, 2474, 867, 2844, - /* 450 */ 903, 160, 2066, 171, 266, 180, 2877, 2906, 675, 723, - /* 460 */ 2322, 494, 2902, 2045, 2055, 1655, 524, 1003, 116, 454, - /* 470 */ 15, 812, 2042, 2091, 2094, 2926, 2153, 2154, 2155, 2926, - /* 480 */ 2926, 2926, 2926, 2926, 612, 739, 738, 737, 1985, 611, - /* 490 */ 1983, 823, 729, 166, 733, 866, 547, 610, 732, 3004, - /* 500 */ 2814, 2255, 1885, 731, 736, 474, 473, 2092, 2093, 730, - /* 510 */ 556, 1657, 74, 472, 726, 725, 724, 822, 230, 2119, - /* 520 */ 237, 2100, 3005, 824, 1988, 1989, 2042, 2009, 2044, 2047, - /* 530 */ 2048, 2049, 2050, 2051, 2052, 2053, 2054, 876, 869, 558, - /* 540 */ 554, 901, 900, 865, 2076, 2077, 2045, 2055, 695, 2083, - /* 550 */ 2085, 2086, 2087, 2088, 2090, 2, 2091, 2094, 2926, 2153, - /* 560 */ 2154, 2155, 2926, 2926, 2926, 2926, 2926, 2046, 219, 40, - /* 570 */ 1717, 1985, 811, 1983, 940, 52, 51, 2771, 866, 58, - /* 580 */ 56, 55, 54, 53, 2120, 1708, 930, 929, 928, 1712, - /* 590 */ 927, 1714, 1715, 926, 923, 2603, 1723, 920, 1725, 1726, - /* 600 */ 917, 914, 911, 2214, 45, 336, 2775, 1988, 1989, 2042, - /* 610 */ 1994, 2044, 2047, 2048, 2049, 2050, 2051, 2052, 2053, 2054, - /* 620 */ 876, 869, 336, 631, 901, 900, 865, 2076, 2077, 773, - /* 630 */ 2043, 2921, 2083, 2085, 2086, 2087, 2088, 2090, 2, 12, - /* 640 */ 59, 57, 2158, 2159, 2160, 2161, 2162, 197, 500, 2278, - /* 650 */ 1984, 770, 512, 2796, 471, 469, 2777, 2779, 495, 268, - /* 660 */ 2918, 2125, 839, 675, 1982, 2322, 2089, 12, 881, 10, - /* 670 */ 903, 805, 804, 2212, 2213, 2215, 2216, 2217, 590, 2598, - /* 680 */ 2629, 43, 496, 2114, 2115, 2116, 2117, 2118, 2122, 2123, - /* 690 */ 2124, 255, 2796, 315, 502, 393, 2084, 2814, 2046, 868, - /* 700 */ 2626, 885, 74, 19, 1564, 336, 1563, 878, 2629, 462, - /* 710 */ 1990, 682, 2668, 2761, 219, 880, 630, 254, 773, 789, - /* 720 */ 165, 12, 74, 59, 57, 2095, 63, 3004, 2627, 885, - /* 730 */ 628, 500, 248, 1984, 468, 466, 2814, 720, 621, 2598, - /* 740 */ 1003, 2602, 1565, 15, 117, 3010, 230, 1982, 568, 2089, - /* 750 */ 3005, 824, 2761, 567, 880, 480, 2676, 859, 722, 2878, - /* 760 */ 2795, 2043, 721, 2843, 2361, 899, 2474, 134, 2797, 884, - /* 770 */ 2799, 2800, 879, 2288, 669, 867, 2844, 903, 3008, 2084, - /* 780 */ 2092, 2093, 868, 667, 2906, 235, 663, 659, 2905, 2902, - /* 790 */ 52, 51, 253, 1990, 58, 56, 55, 54, 53, 2795, - /* 800 */ 775, 2668, 2843, 2458, 467, 789, 432, 2797, 884, 2799, - /* 810 */ 2800, 879, 877, 3004, 867, 2844, 903, 858, 2871, 2045, - /* 820 */ 2055, 2534, 566, 1003, 565, 194, 60, 899, 2474, 2091, - /* 830 */ 2094, 3010, 230, 2761, 1953, 2477, 3005, 824, 899, 2474, - /* 840 */ 842, 739, 738, 737, 1985, 515, 1983, 67, 729, 166, - /* 850 */ 733, 866, 343, 344, 732, 692, 564, 342, 572, 731, - /* 860 */ 736, 474, 473, 2092, 2093, 730, 511, 510, 689, 472, - /* 870 */ 726, 725, 724, 938, 186, 185, 935, 934, 933, 183, - /* 880 */ 1988, 1989, 2042, 184, 2044, 2047, 2048, 2049, 2050, 2051, - /* 890 */ 2052, 2053, 2054, 876, 869, 336, 808, 901, 900, 865, - /* 900 */ 2076, 2077, 2045, 2055, 1544, 2083, 2085, 2086, 2087, 2088, - /* 910 */ 2090, 2, 2091, 2094, 2616, 336, 693, 52, 51, 336, - /* 920 */ 1717, 58, 56, 55, 54, 53, 2450, 1985, 1990, 1983, - /* 930 */ 1542, 1543, 690, 2622, 866, 1708, 930, 929, 928, 1712, - /* 940 */ 927, 1714, 1715, 875, 874, 931, 1723, 873, 1725, 1726, - /* 950 */ 872, 914, 911, 52, 51, 954, 47, 58, 56, 55, - /* 960 */ 54, 53, 2287, 1988, 1989, 2042, 66, 2044, 2047, 2048, - /* 970 */ 2049, 2050, 2051, 2052, 2053, 2054, 876, 869, 899, 2474, - /* 980 */ 901, 900, 865, 2076, 2077, 2121, 746, 1650, 2083, 2085, - /* 990 */ 2086, 2087, 2088, 2090, 2, 59, 57, 1984, 573, 504, - /* 1000 */ 861, 760, 2878, 500, 219, 1984, 899, 2474, 2796, 899, - /* 1010 */ 2474, 1982, 899, 2474, 814, 809, 802, 798, 224, 1982, - /* 1020 */ 301, 2089, 2761, 881, 956, 2061, 592, 1952, 2714, 606, - /* 1030 */ 2286, 2602, 607, 1651, 52, 51, 749, 2013, 58, 56, - /* 1040 */ 55, 54, 53, 743, 741, 2534, 899, 2474, 2796, 48, - /* 1050 */ 298, 2084, 2814, 505, 868, 1667, 1564, 1990, 1563, 514, - /* 1060 */ 513, 2225, 2126, 881, 2532, 1990, 608, 2478, 2761, 1666, - /* 1070 */ 880, 938, 186, 185, 935, 934, 933, 183, 59, 57, - /* 1080 */ 899, 2474, 41, 899, 2474, 789, 500, 1003, 1984, 2581, - /* 1090 */ 2761, 112, 2814, 3004, 1565, 1003, 84, 386, 60, 2074, - /* 1100 */ 694, 83, 1982, 2471, 2089, 826, 14, 13, 2761, 465, - /* 1110 */ 880, 3010, 230, 38, 125, 2795, 3005, 824, 2843, 2469, - /* 1120 */ 2285, 393, 134, 2797, 884, 2799, 2800, 879, 769, 503, - /* 1130 */ 867, 2844, 903, 582, 2084, 2092, 2093, 868, 193, 2906, - /* 1140 */ 42, 2467, 2197, 862, 2902, 642, 52, 51, 1990, 2479, - /* 1150 */ 58, 56, 55, 54, 53, 2795, 899, 2474, 2843, 899, - /* 1160 */ 2474, 2701, 198, 2797, 884, 2799, 2800, 879, 899, 2474, - /* 1170 */ 867, 2844, 903, 2206, 2045, 2055, 306, 392, 1003, 314, - /* 1180 */ 2761, 60, 2677, 2013, 2091, 2094, 311, 2207, 841, 899, - /* 1190 */ 2474, 1985, 2534, 1983, 899, 2474, 899, 2474, 96, 1985, - /* 1200 */ 521, 1983, 899, 2474, 286, 2705, 866, 1567, 1568, 347, - /* 1210 */ 225, 2532, 790, 2964, 855, 172, 354, 1546, 2092, 2093, - /* 1220 */ 205, 2133, 892, 2008, 2009, 2466, 788, 1988, 1989, 712, - /* 1230 */ 708, 704, 700, 2205, 285, 1988, 1989, 2042, 2447, 2044, - /* 1240 */ 2047, 2048, 2049, 2050, 2051, 2052, 2053, 2054, 876, 869, - /* 1250 */ 2528, 2529, 901, 900, 865, 2076, 2077, 2045, 2055, 540, - /* 1260 */ 2083, 2085, 2086, 2087, 2088, 2090, 2, 2091, 2094, 52, - /* 1270 */ 51, 2014, 2013, 58, 56, 55, 54, 53, 899, 2474, - /* 1280 */ 113, 2682, 1985, 304, 1983, 283, 52, 51, 2534, 866, - /* 1290 */ 58, 56, 55, 54, 53, 52, 51, 523, 893, 58, - /* 1300 */ 56, 55, 54, 53, 52, 51, 193, 850, 58, 56, - /* 1310 */ 55, 54, 53, 899, 2474, 714, 713, 2479, 1988, 1989, - /* 1320 */ 2042, 2534, 2044, 2047, 2048, 2049, 2050, 2051, 2052, 2053, - /* 1330 */ 2054, 876, 869, 897, 39, 901, 900, 865, 2076, 2077, - /* 1340 */ 2533, 1671, 305, 2083, 2085, 2086, 2087, 2088, 2090, 2, - /* 1350 */ 59, 57, 271, 899, 2474, 1670, 233, 2178, 500, 2284, - /* 1360 */ 1984, 282, 2283, 2282, 2796, 273, 280, 72, 1911, 1912, - /* 1370 */ 2281, 278, 686, 382, 1982, 2280, 2089, 2062, 786, 881, - /* 1380 */ 2277, 2324, 2276, 938, 186, 185, 935, 934, 933, 183, - /* 1390 */ 270, 2275, 52, 51, 2064, 2046, 58, 56, 55, 54, - /* 1400 */ 53, 55, 54, 53, 2274, 221, 2084, 957, 2814, 868, - /* 1410 */ 2433, 170, 2067, 2273, 2877, 2272, 2271, 2014, 2921, 2761, - /* 1420 */ 1990, 2009, 2761, 2761, 2761, 2270, 880, 716, 715, 2536, - /* 1430 */ 2761, 644, 2921, 59, 57, 2761, 2269, 2715, 735, 734, - /* 1440 */ 2761, 500, 2761, 1984, 193, 968, 966, 2917, 906, 932, - /* 1450 */ 1003, 2761, 2525, 60, 817, 2480, 722, 1982, 2043, 2089, - /* 1460 */ 721, 2916, 52, 51, 2761, 90, 58, 56, 55, 54, - /* 1470 */ 53, 2795, 827, 2761, 2843, 2761, 2761, 830, 133, 2797, - /* 1480 */ 884, 2799, 2800, 879, 399, 2761, 867, 2844, 903, 2084, - /* 1490 */ 2092, 2093, 868, 3024, 789, 2906, 2761, 2294, 996, 494, - /* 1500 */ 2902, 46, 3004, 1990, 936, 937, 2014, 2525, 2525, 2478, - /* 1510 */ 52, 51, 2451, 3, 58, 56, 55, 54, 53, 103, - /* 1520 */ 3010, 230, 2408, 2167, 162, 3005, 824, 65, 291, 2045, - /* 1530 */ 2055, 289, 293, 1003, 295, 292, 15, 294, 102, 2091, - /* 1540 */ 2094, 176, 52, 51, 727, 175, 58, 56, 55, 54, - /* 1550 */ 53, 864, 297, 728, 1985, 296, 1983, 2345, 52, 51, - /* 1560 */ 2343, 866, 58, 56, 55, 54, 53, 1648, 763, 176, - /* 1570 */ 762, 796, 2326, 2092, 2093, 61, 1646, 61, 213, 740, - /* 1580 */ 2279, 766, 742, 2334, 640, 2258, 2259, 2967, 184, 341, - /* 1590 */ 1988, 1989, 2042, 806, 2044, 2047, 2048, 2049, 2050, 2051, - /* 1600 */ 2052, 2053, 2054, 876, 869, 744, 2332, 901, 900, 865, - /* 1610 */ 2076, 2077, 2045, 2055, 204, 2083, 2085, 2086, 2087, 2088, - /* 1620 */ 2090, 2, 2091, 2094, 1901, 1993, 89, 992, 747, 61, - /* 1630 */ 14, 13, 76, 445, 444, 61, 61, 1985, 789, 1983, - /* 1640 */ 61, 61, 2782, 507, 866, 1992, 3004, 89, 330, 181, - /* 1650 */ 2063, 774, 1909, 162, 2201, 2043, 907, 516, 2211, 2089, - /* 1660 */ 2210, 320, 322, 2177, 3010, 230, 2060, 836, 184, 3005, - /* 1670 */ 824, 840, 345, 1988, 1989, 2042, 86, 2044, 2047, 2048, - /* 1680 */ 2049, 2050, 2051, 2052, 2053, 2054, 876, 869, 164, 2084, - /* 1690 */ 901, 900, 865, 2076, 2077, 137, 361, 360, 2083, 2085, - /* 1700 */ 2086, 2087, 2088, 2090, 2, 441, 2784, 2007, 789, 847, - /* 1710 */ 363, 362, 2065, 909, 619, 2127, 3004, 464, 2075, 2068, - /* 1720 */ 365, 364, 195, 2056, 1854, 639, 182, 406, 2111, 184, - /* 1730 */ 1844, 2815, 357, 163, 3010, 230, 896, 367, 366, 3005, - /* 1740 */ 824, 598, 181, 641, 2400, 2399, 404, 88, 442, 600, - /* 1750 */ 87, 1699, 369, 368, 371, 370, 373, 372, 1628, 398, - /* 1760 */ 578, 443, 375, 374, 377, 376, 379, 378, 381, 380, - /* 1770 */ 131, 828, 128, 264, 654, 652, 649, 647, 831, 948, - /* 1780 */ 949, 2315, 2957, 1601, 803, 486, 810, 482, 844, 2607, - /* 1790 */ 531, 549, 2321, 2522, 782, 2958, 1730, 332, 2968, 818, - /* 1800 */ 819, 463, 1620, 1618, 1629, 327, 335, 1996, 2608, 1738, - /* 1810 */ 5, 2434, 1745, 586, 534, 539, 1743, 458, 2007, 74, - /* 1820 */ 548, 2017, 238, 559, 239, 187, 560, 1995, 562, 1602, - /* 1830 */ 391, 241, 1878, 2008, 576, 252, 583, 1975, 585, 1951, - /* 1840 */ 591, 589, 633, 609, 2609, 2588, 596, 627, 626, 625, - /* 1850 */ 624, 623, 618, 617, 616, 615, 446, 620, 75, 605, - /* 1860 */ 604, 603, 602, 601, 595, 594, 593, 2796, 588, 587, - /* 1870 */ 461, 509, 508, 1976, 579, 1818, 1819, 2600, 622, 629, - /* 1880 */ 646, 1837, 881, 632, 2961, 645, 643, 257, 634, 258, - /* 1890 */ 901, 900, 648, 650, 651, 261, 653, 655, 2083, 2085, - /* 1900 */ 2086, 2087, 2088, 2090, 2015, 4, 670, 671, 678, 681, - /* 1910 */ 269, 2814, 100, 99, 571, 679, 108, 243, 2010, 683, - /* 1920 */ 272, 2016, 684, 2018, 685, 275, 687, 2761, 277, 880, - /* 1930 */ 563, 561, 2019, 2623, 109, 2020, 110, 2617, 111, 696, - /* 1940 */ 717, 284, 750, 440, 719, 435, 550, 2464, 2796, 546, - /* 1950 */ 542, 538, 535, 564, 138, 751, 288, 765, 2460, 114, - /* 1960 */ 290, 767, 2011, 881, 776, 2974, 394, 189, 2691, 2688, - /* 1970 */ 177, 135, 307, 2462, 2795, 777, 2457, 2843, 2796, 190, - /* 1980 */ 310, 133, 2797, 884, 2799, 2800, 879, 2669, 191, 867, - /* 1990 */ 2844, 903, 2814, 881, 2687, 800, 3024, 784, 2906, 781, - /* 2000 */ 807, 312, 494, 2902, 2973, 2972, 845, 793, 2761, 8, - /* 2010 */ 880, 2945, 336, 816, 778, 203, 321, 324, 794, 792, - /* 2020 */ 821, 2925, 2814, 323, 791, 820, 487, 325, 328, 317, - /* 2030 */ 319, 3027, 783, 829, 832, 168, 2012, 2175, 2761, 2173, - /* 2040 */ 880, 326, 216, 1, 232, 337, 3003, 395, 331, 178, - /* 2050 */ 843, 2637, 396, 848, 179, 2795, 2636, 2635, 2843, 491, - /* 2060 */ 856, 2796, 133, 2797, 884, 2799, 2800, 879, 2922, 853, - /* 2070 */ 867, 2844, 903, 350, 73, 849, 881, 3024, 2997, 2906, - /* 2080 */ 886, 891, 888, 494, 2902, 2795, 890, 2887, 2843, 397, - /* 2090 */ 355, 2796, 133, 2797, 884, 2799, 2800, 879, 2475, 124, - /* 2100 */ 867, 2844, 903, 2753, 2752, 2814, 881, 3024, 2938, 2906, - /* 2110 */ 2748, 2747, 127, 494, 2902, 2739, 2738, 2730, 2729, 2745, - /* 2120 */ 2744, 2761, 2736, 880, 2735, 2724, 401, 1516, 384, 998, - /* 2130 */ 999, 2723, 2742, 1000, 995, 2814, 188, 64, 387, 423, - /* 2140 */ 2741, 2733, 905, 388, 1002, 2732, 769, 470, 405, 2721, - /* 2150 */ 518, 2761, 2720, 880, 434, 424, 2718, 2717, 2713, 2712, - /* 2160 */ 2526, 2711, 436, 403, 97, 2706, 536, 537, 2795, 1935, - /* 2170 */ 1936, 2843, 236, 541, 2704, 133, 2797, 884, 2799, 2800, - /* 2180 */ 879, 543, 544, 867, 2844, 903, 545, 1934, 2796, 2703, - /* 2190 */ 3024, 450, 2906, 2702, 451, 459, 494, 2902, 2795, 2700, - /* 2200 */ 551, 2843, 2699, 881, 553, 133, 2797, 884, 2799, 2800, - /* 2210 */ 879, 2698, 555, 867, 2844, 903, 2697, 557, 527, 526, - /* 2220 */ 3024, 1922, 2906, 2673, 240, 2672, 494, 2902, 1998, 242, - /* 2230 */ 1881, 2796, 2814, 98, 1880, 2650, 2649, 2648, 569, 570, - /* 2240 */ 2647, 2646, 1991, 2590, 2089, 574, 881, 1817, 2761, 577, - /* 2250 */ 880, 2587, 2586, 2580, 580, 581, 2577, 2576, 245, 101, - /* 2260 */ 2575, 2574, 2579, 2578, 2573, 247, 2572, 2570, 2569, 2796, - /* 2270 */ 2568, 2567, 2565, 249, 2084, 2814, 599, 2564, 597, 2563, - /* 2280 */ 2562, 2561, 2585, 2560, 881, 2559, 2558, 2583, 1990, 2566, - /* 2290 */ 2557, 2761, 2556, 880, 2555, 2795, 2553, 2552, 2843, 2551, - /* 2300 */ 2550, 2549, 133, 2797, 884, 2799, 2800, 879, 2548, 251, - /* 2310 */ 867, 2844, 903, 2814, 2547, 2546, 107, 2881, 863, 2906, - /* 2320 */ 2545, 2544, 2543, 494, 2902, 2615, 2584, 2582, 2542, 2761, - /* 2330 */ 2541, 880, 1823, 2540, 256, 2539, 636, 2538, 2795, 638, - /* 2340 */ 2537, 2843, 2535, 447, 2365, 133, 2797, 884, 2799, 2800, - /* 2350 */ 879, 1668, 259, 867, 2844, 903, 1672, 448, 2364, 1664, - /* 2360 */ 2879, 260, 2906, 2363, 2362, 2360, 494, 2902, 2357, 2356, - /* 2370 */ 262, 263, 656, 657, 660, 658, 2795, 2349, 661, 2843, - /* 2380 */ 211, 1545, 2796, 133, 2797, 884, 2799, 2800, 879, 662, - /* 2390 */ 664, 867, 2844, 903, 666, 665, 2336, 881, 860, 2310, - /* 2400 */ 2906, 93, 668, 265, 494, 2902, 2781, 2309, 2671, 2667, - /* 2410 */ 222, 676, 2657, 2645, 2644, 267, 94, 274, 2621, 2614, - /* 2420 */ 2452, 2359, 1999, 2355, 1994, 279, 2814, 276, 1594, 281, - /* 2430 */ 697, 699, 2353, 698, 701, 702, 703, 2351, 705, 706, - /* 2440 */ 2348, 707, 2761, 710, 880, 711, 709, 2331, 2329, 2796, - /* 2450 */ 2330, 2328, 2306, 2454, 2453, 1749, 1654, 85, 2002, 2004, - /* 2460 */ 1750, 1653, 1652, 1649, 881, 1647, 287, 1645, 1636, 2346, - /* 2470 */ 2344, 1644, 1643, 745, 1642, 901, 900, 1641, 1638, 2796, - /* 2480 */ 1637, 475, 965, 2083, 2085, 2086, 2087, 2088, 2090, 882, - /* 2490 */ 967, 1635, 2843, 2814, 881, 476, 134, 2797, 884, 2799, - /* 2500 */ 2800, 879, 2335, 477, 867, 2844, 903, 2333, 478, 2761, - /* 2510 */ 748, 880, 2305, 2906, 2304, 2303, 752, 453, 2902, 2302, - /* 2520 */ 754, 2301, 2300, 2814, 756, 758, 140, 1916, 1918, 1915, - /* 2530 */ 2670, 1920, 1891, 1906, 768, 2666, 1887, 33, 309, 2761, - /* 2540 */ 1889, 880, 68, 79, 69, 2656, 779, 313, 2643, 2642, - /* 2550 */ 3009, 17, 795, 22, 35, 780, 2795, 6, 316, 2843, - /* 2560 */ 7, 483, 23, 201, 2797, 884, 2799, 2800, 879, 771, - /* 2570 */ 24, 867, 2844, 903, 785, 1866, 1865, 2228, 787, 2202, - /* 2580 */ 192, 797, 801, 318, 2796, 799, 2795, 1006, 215, 2843, - /* 2590 */ 227, 2209, 202, 134, 2797, 884, 2799, 2800, 879, 881, - /* 2600 */ 37, 867, 2844, 903, 214, 2796, 390, 2782, 25, 36, - /* 2610 */ 2906, 2196, 95, 2168, 2166, 2903, 228, 2170, 77, 229, - /* 2620 */ 881, 994, 220, 2243, 26, 825, 3025, 2248, 2814, 2249, - /* 2630 */ 18, 990, 986, 982, 978, 2796, 385, 2242, 488, 2247, - /* 2640 */ 2246, 489, 2150, 2149, 2761, 333, 880, 71, 207, 2814, - /* 2650 */ 881, 2641, 2620, 118, 119, 2619, 340, 2204, 217, 346, - /* 2660 */ 846, 81, 120, 2613, 121, 2761, 852, 880, 348, 349, - /* 2670 */ 27, 2102, 854, 70, 351, 11, 2101, 13, 2000, 2814, - /* 2680 */ 21, 28, 132, 208, 29, 218, 20, 358, 49, 497, - /* 2690 */ 2059, 2795, 2058, 916, 2843, 2761, 2057, 880, 409, 2797, - /* 2700 */ 884, 2799, 2800, 879, 919, 32, 867, 2844, 903, 2027, - /* 2710 */ 2112, 922, 2795, 925, 50, 2843, 2035, 883, 851, 433, - /* 2720 */ 2797, 884, 2799, 2800, 879, 2796, 16, 867, 2844, 903, - /* 2730 */ 2612, 30, 31, 122, 82, 2449, 894, 887, 353, 123, - /* 2740 */ 881, 359, 2795, 128, 91, 2843, 895, 889, 2856, 198, - /* 2750 */ 2797, 884, 2799, 2800, 879, 2855, 902, 867, 2844, 903, - /* 2760 */ 2071, 80, 904, 356, 2262, 857, 2796, 908, 339, 2814, - /* 2770 */ 1731, 2261, 519, 338, 910, 912, 1728, 913, 383, 1722, - /* 2780 */ 1727, 881, 915, 1724, 918, 2761, 1718, 880, 921, 1716, - /* 2790 */ 924, 129, 308, 130, 1721, 1720, 1744, 92, 1719, 1740, - /* 2800 */ 2965, 1592, 939, 1632, 1631, 1630, 1627, 1624, 1623, 484, - /* 2810 */ 2814, 1622, 1621, 953, 1619, 1617, 1616, 955, 1615, 1662, - /* 2820 */ 1661, 234, 1613, 1612, 1610, 1611, 2761, 1609, 880, 1608, - /* 2830 */ 1607, 2796, 2795, 1658, 1656, 2843, 1604, 1603, 2354, 433, - /* 2840 */ 2797, 884, 2799, 2800, 879, 1600, 881, 867, 2844, 903, - /* 2850 */ 485, 2796, 1599, 1598, 1597, 975, 977, 976, 2352, 979, - /* 2860 */ 980, 981, 2350, 2347, 983, 984, 881, 988, 985, 987, - /* 2870 */ 989, 2796, 2327, 2795, 2325, 2814, 2843, 991, 993, 1534, - /* 2880 */ 433, 2797, 884, 2799, 2800, 879, 878, 2299, 867, 2844, - /* 2890 */ 903, 2761, 1517, 880, 997, 2814, 1522, 389, 1001, 1004, - /* 2900 */ 1524, 1986, 402, 1005, 2265, 2265, 2265, 2265, 2265, 2265, - /* 2910 */ 2265, 2761, 2265, 880, 2265, 2814, 2265, 2265, 2265, 2265, - /* 2920 */ 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, - /* 2930 */ 2265, 2761, 2265, 880, 2265, 2265, 2265, 2265, 2795, 2265, - /* 2940 */ 2265, 2843, 2265, 2265, 2265, 426, 2797, 884, 2799, 2800, - /* 2950 */ 879, 2265, 2265, 867, 2844, 903, 2796, 2265, 2795, 2265, - /* 2960 */ 2265, 2843, 2265, 2265, 2265, 201, 2797, 884, 2799, 2800, - /* 2970 */ 879, 881, 2265, 867, 2844, 903, 2796, 2265, 2795, 2265, - /* 2980 */ 2265, 2843, 2265, 2265, 2265, 432, 2797, 884, 2799, 2800, - /* 2990 */ 879, 881, 2265, 867, 2844, 903, 2265, 2872, 2265, 815, - /* 3000 */ 2814, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, - /* 3010 */ 2265, 2265, 2265, 2265, 2265, 2265, 2761, 2265, 880, 2265, - /* 3020 */ 2814, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 3026, 2265, - /* 3030 */ 2265, 2265, 2265, 2265, 2265, 2265, 2761, 2265, 880, 2265, - /* 3040 */ 498, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, - /* 3050 */ 2265, 2265, 2796, 2265, 2265, 2265, 2265, 2265, 2265, 2265, - /* 3060 */ 493, 2265, 2265, 2795, 2265, 2265, 2843, 881, 2265, 2265, - /* 3070 */ 433, 2797, 884, 2799, 2800, 879, 2265, 2265, 867, 2844, - /* 3080 */ 903, 2265, 2265, 2795, 2265, 2265, 2843, 2265, 2796, 2265, - /* 3090 */ 418, 2797, 884, 2799, 2800, 879, 2814, 2265, 867, 2844, - /* 3100 */ 903, 2265, 2265, 881, 2265, 2265, 2265, 2265, 2265, 2265, - /* 3110 */ 2265, 2265, 2761, 2265, 880, 2265, 2265, 2265, 2265, 2265, - /* 3120 */ 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2796, - /* 3130 */ 2265, 2265, 2814, 2265, 2265, 2265, 499, 2265, 2265, 2265, - /* 3140 */ 2265, 2265, 2265, 2265, 881, 2265, 2265, 2265, 2761, 2265, - /* 3150 */ 880, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2795, - /* 3160 */ 2265, 2265, 2843, 2265, 2265, 2265, 433, 2797, 884, 2799, - /* 3170 */ 2800, 879, 501, 2814, 867, 2844, 903, 2265, 2265, 2265, - /* 3180 */ 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2761, - /* 3190 */ 2265, 880, 2265, 2265, 2265, 2795, 2265, 2265, 2843, 2265, - /* 3200 */ 2265, 2265, 433, 2797, 884, 2799, 2800, 879, 2265, 2265, - /* 3210 */ 867, 2844, 903, 2796, 2265, 2265, 2265, 2265, 2265, 2265, - /* 3220 */ 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 881, 2265, - /* 3230 */ 2265, 2265, 2265, 2265, 2796, 2265, 2795, 2265, 2265, 2843, - /* 3240 */ 2265, 2265, 2265, 414, 2797, 884, 2799, 2800, 879, 881, - /* 3250 */ 2265, 867, 2844, 903, 2265, 2265, 2265, 2814, 2265, 2265, - /* 3260 */ 2265, 2265, 2796, 2265, 2265, 2265, 2265, 2265, 2265, 2265, - /* 3270 */ 2265, 2265, 2265, 2761, 2265, 880, 2265, 881, 2814, 2265, - /* 3280 */ 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, - /* 3290 */ 2265, 2265, 2265, 2265, 2761, 2265, 880, 2265, 2265, 2265, - /* 3300 */ 2265, 2265, 2796, 2265, 2265, 2265, 2814, 2265, 2265, 2265, - /* 3310 */ 2265, 2265, 2265, 2265, 2265, 2265, 2265, 881, 2265, 2265, - /* 3320 */ 764, 2265, 2761, 2843, 880, 2265, 2265, 428, 2797, 884, - /* 3330 */ 2799, 2800, 879, 2265, 2265, 867, 2844, 903, 2265, 2265, - /* 3340 */ 2265, 2795, 2265, 2265, 2843, 2796, 2814, 2265, 410, 2797, - /* 3350 */ 884, 2799, 2800, 879, 2265, 2265, 867, 2844, 903, 2265, - /* 3360 */ 881, 2265, 2761, 2265, 880, 2265, 2265, 2265, 2265, 2795, - /* 3370 */ 2265, 2265, 2843, 2265, 2265, 2265, 407, 2797, 884, 2799, - /* 3380 */ 2800, 879, 2265, 2265, 867, 2844, 903, 2796, 2265, 2814, - /* 3390 */ 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, - /* 3400 */ 2265, 2265, 881, 2265, 2265, 2761, 2265, 880, 2265, 2795, - /* 3410 */ 2265, 2265, 2843, 2265, 2265, 2265, 411, 2797, 884, 2799, - /* 3420 */ 2800, 879, 2265, 2265, 867, 2844, 903, 2796, 2265, 2265, - /* 3430 */ 2265, 2814, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, - /* 3440 */ 2265, 2265, 881, 2265, 2265, 2265, 2265, 2761, 2265, 880, - /* 3450 */ 2265, 2265, 2795, 2265, 2265, 2843, 2265, 2265, 2265, 425, - /* 3460 */ 2797, 884, 2799, 2800, 879, 2265, 2265, 867, 2844, 903, - /* 3470 */ 2796, 2814, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, - /* 3480 */ 2265, 2265, 2265, 2265, 2265, 881, 2265, 2761, 2265, 880, - /* 3490 */ 2265, 2265, 2265, 2265, 2795, 2265, 2265, 2843, 2265, 2265, - /* 3500 */ 2265, 412, 2797, 884, 2799, 2800, 879, 2265, 2265, 867, - /* 3510 */ 2844, 903, 2265, 2265, 2814, 2265, 2796, 2265, 2265, 2265, - /* 3520 */ 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, - /* 3530 */ 2761, 881, 880, 2265, 2795, 2265, 2265, 2843, 2265, 2265, - /* 3540 */ 2265, 413, 2797, 884, 2799, 2800, 879, 2265, 2265, 867, - /* 3550 */ 2844, 903, 2265, 2796, 2265, 2265, 2265, 2265, 2265, 2265, - /* 3560 */ 2814, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 881, 2265, - /* 3570 */ 2265, 2265, 2265, 2265, 2265, 2265, 2761, 2795, 880, 2265, - /* 3580 */ 2843, 2265, 2265, 2265, 429, 2797, 884, 2799, 2800, 879, - /* 3590 */ 2265, 2265, 867, 2844, 903, 2265, 2265, 2814, 2265, 2796, - /* 3600 */ 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, - /* 3610 */ 2265, 2265, 2265, 2761, 881, 880, 2265, 2265, 2265, 2265, - /* 3620 */ 2265, 2796, 2265, 2795, 2265, 2265, 2843, 2265, 2265, 2265, - /* 3630 */ 415, 2797, 884, 2799, 2800, 879, 881, 2265, 867, 2844, - /* 3640 */ 903, 2265, 2265, 2814, 2265, 2265, 2265, 2265, 2265, 2265, - /* 3650 */ 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2761, - /* 3660 */ 2795, 880, 2265, 2843, 2796, 2814, 2265, 430, 2797, 884, - /* 3670 */ 2799, 2800, 879, 2265, 2265, 867, 2844, 903, 2265, 881, - /* 3680 */ 2265, 2761, 2265, 880, 2265, 2265, 2265, 2265, 2265, 2796, - /* 3690 */ 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, - /* 3700 */ 2265, 2265, 2265, 2265, 881, 2265, 2795, 2265, 2814, 2843, - /* 3710 */ 2796, 2265, 2265, 416, 2797, 884, 2799, 2800, 879, 2265, - /* 3720 */ 2265, 867, 2844, 903, 2761, 881, 880, 2265, 2795, 2265, - /* 3730 */ 2265, 2843, 2796, 2814, 2265, 431, 2797, 884, 2799, 2800, - /* 3740 */ 879, 2265, 2265, 867, 2844, 903, 2265, 881, 2265, 2761, - /* 3750 */ 2265, 880, 2265, 2265, 2814, 2265, 2265, 2265, 2265, 2265, - /* 3760 */ 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, - /* 3770 */ 2761, 2795, 880, 2265, 2843, 2265, 2814, 2265, 417, 2797, - /* 3780 */ 884, 2799, 2800, 879, 2265, 2265, 867, 2844, 903, 2265, - /* 3790 */ 2265, 2265, 2761, 2265, 880, 2265, 2795, 2265, 2265, 2843, - /* 3800 */ 2265, 2265, 2265, 408, 2797, 884, 2799, 2800, 879, 2265, - /* 3810 */ 2265, 867, 2844, 903, 2265, 2265, 2265, 2795, 2265, 2265, - /* 3820 */ 2843, 2265, 2265, 2265, 419, 2797, 884, 2799, 2800, 879, - /* 3830 */ 2265, 2265, 867, 2844, 903, 2265, 2265, 2265, 2265, 2795, - /* 3840 */ 2265, 2265, 2843, 2265, 2265, 2265, 420, 2797, 884, 2799, - /* 3850 */ 2800, 879, 2265, 2265, 867, 2844, 903, 2796, 2265, 2265, - /* 3860 */ 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, - /* 3870 */ 2265, 2265, 881, 2265, 2265, 2265, 2796, 2265, 2265, 2265, - /* 3880 */ 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, - /* 3890 */ 2265, 881, 2265, 2265, 2265, 2265, 2796, 2265, 2265, 2265, - /* 3900 */ 2265, 2814, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, - /* 3910 */ 2265, 881, 2265, 2265, 2265, 2265, 2265, 2761, 2265, 880, - /* 3920 */ 2814, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, - /* 3930 */ 2265, 2265, 2265, 2265, 2265, 2265, 2761, 2265, 880, 2265, - /* 3940 */ 2814, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, - /* 3950 */ 2265, 2265, 2265, 2265, 2265, 2265, 2761, 2265, 880, 2265, - /* 3960 */ 2265, 2265, 2265, 2796, 2795, 2265, 2265, 2843, 2265, 2265, - /* 3970 */ 2265, 421, 2797, 884, 2799, 2800, 879, 2265, 881, 867, - /* 3980 */ 2844, 903, 2265, 2795, 2265, 2265, 2843, 2265, 2265, 2265, - /* 3990 */ 422, 2797, 884, 2799, 2800, 879, 2265, 2265, 867, 2844, - /* 4000 */ 903, 2796, 2265, 2795, 2265, 2265, 2843, 2814, 2265, 2265, - /* 4010 */ 438, 2797, 884, 2799, 2800, 879, 881, 2265, 867, 2844, - /* 4020 */ 903, 2265, 2265, 2761, 2265, 880, 2265, 2265, 2265, 2265, - /* 4030 */ 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, - /* 4040 */ 2265, 2265, 2265, 2265, 2265, 2814, 2265, 2796, 2265, 2265, - /* 4050 */ 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, - /* 4060 */ 2265, 2761, 881, 880, 2265, 2265, 2265, 2265, 2796, 2265, - /* 4070 */ 2795, 2265, 2265, 2843, 2265, 2265, 2265, 439, 2797, 884, - /* 4080 */ 2799, 2800, 879, 881, 2265, 867, 2844, 903, 2265, 2265, - /* 4090 */ 2265, 2814, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, - /* 4100 */ 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2761, 2795, 880, - /* 4110 */ 2265, 2843, 2814, 2265, 2265, 2808, 2797, 884, 2799, 2800, - /* 4120 */ 879, 2265, 2265, 867, 2844, 903, 2265, 2265, 2761, 2265, - /* 4130 */ 880, 2265, 2265, 2265, 2265, 2265, 2796, 2265, 2265, 2265, - /* 4140 */ 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, - /* 4150 */ 2265, 881, 2265, 2265, 2795, 2265, 2265, 2843, 2796, 2265, - /* 4160 */ 2265, 2807, 2797, 884, 2799, 2800, 879, 2265, 2265, 867, - /* 4170 */ 2844, 903, 2265, 881, 2265, 2795, 2265, 2265, 2843, 2796, - /* 4180 */ 2814, 2265, 2806, 2797, 884, 2799, 2800, 879, 2265, 2265, - /* 4190 */ 867, 2844, 903, 2265, 881, 2265, 2761, 2265, 880, 2265, - /* 4200 */ 2265, 2265, 2814, 2265, 2796, 2265, 2265, 2265, 2265, 2265, - /* 4210 */ 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2761, 881, - /* 4220 */ 880, 2265, 2265, 2814, 2265, 2265, 2265, 2265, 2265, 2265, - /* 4230 */ 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2761, - /* 4240 */ 2265, 880, 2265, 2795, 2265, 2265, 2843, 2265, 2814, 2265, - /* 4250 */ 455, 2797, 884, 2799, 2800, 879, 2265, 2265, 867, 2844, - /* 4260 */ 903, 2265, 2265, 2265, 2761, 2795, 880, 2265, 2843, 2265, - /* 4270 */ 2265, 2265, 456, 2797, 884, 2799, 2800, 879, 2265, 2265, - /* 4280 */ 867, 2844, 903, 2265, 2265, 2265, 2795, 2265, 2265, 2843, - /* 4290 */ 2265, 2265, 2265, 452, 2797, 884, 2799, 2800, 879, 2265, - /* 4300 */ 2265, 867, 2844, 903, 2265, 2265, 2265, 2265, 2265, 2265, - /* 4310 */ 2265, 2795, 2265, 2265, 2843, 2265, 2265, 2265, 457, 2797, - /* 4320 */ 884, 2799, 2800, 879, 2265, 2796, 867, 2844, 903, 2265, - /* 4330 */ 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, - /* 4340 */ 881, 2265, 2265, 2265, 2265, 2796, 2265, 2265, 2265, 2265, - /* 4350 */ 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, - /* 4360 */ 881, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2814, - /* 4370 */ 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, - /* 4380 */ 2265, 2265, 2265, 2265, 2265, 2761, 2265, 880, 2265, 2814, - /* 4390 */ 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, - /* 4400 */ 2265, 2265, 2265, 2265, 2265, 2761, 2265, 880, 2265, 2265, - /* 4410 */ 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, - /* 4420 */ 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, 2265, - /* 4430 */ 2265, 2265, 882, 2265, 2265, 2843, 2265, 2265, 2265, 428, - /* 4440 */ 2797, 884, 2799, 2800, 879, 2265, 2265, 867, 2844, 903, - /* 4450 */ 2265, 2265, 2795, 2265, 2265, 2843, 2265, 2265, 2265, 427, - /* 4460 */ 2797, 884, 2799, 2800, 879, 2265, 2265, 867, 2844, 903, + /* 0 */ 44, 354, 464, 2712, 570, 586, 2605, 2269, 219, 569, + /* 10 */ 2689, 506, 59, 57, 136, 674, 2721, 219, 675, 2319, + /* 20 */ 502, 2272, 1989, 522, 2483, 52, 51, 2014, 679, 58, + /* 30 */ 56, 55, 54, 53, 676, 2609, 1987, 2578, 2094, 2363, + /* 40 */ 2803, 2331, 150, 873, 2609, 149, 148, 147, 146, 145, + /* 50 */ 144, 143, 142, 141, 872, 840, 2636, 542, 52, 51, + /* 60 */ 246, 791, 58, 56, 55, 54, 53, 78, 2089, 3011, + /* 70 */ 494, 870, 307, 791, 483, 2683, 2633, 887, 196, 837, + /* 80 */ 169, 3011, 1995, 34, 1670, 2821, 2412, 3017, 230, 529, + /* 90 */ 528, 682, 3012, 826, 675, 2319, 994, 535, 1669, 3017, + /* 100 */ 230, 2768, 534, 882, 3012, 826, 2761, 473, 471, 519, + /* 110 */ 2722, 900, 1005, 1996, 815, 60, 976, 975, 974, 973, + /* 120 */ 532, 2928, 972, 971, 174, 966, 965, 964, 963, 962, + /* 130 */ 961, 960, 173, 954, 953, 952, 531, 530, 949, 948, + /* 140 */ 947, 210, 209, 946, 527, 945, 944, 943, 2802, 814, + /* 150 */ 2925, 2850, 2097, 2098, 791, 133, 2804, 886, 2806, 2807, + /* 160 */ 881, 125, 3011, 869, 2851, 905, 2231, 791, 223, 508, + /* 170 */ 212, 774, 2913, 250, 644, 3011, 496, 2909, 74, 2821, + /* 180 */ 3017, 230, 2803, 905, 2528, 3012, 826, 470, 468, 2472, + /* 190 */ 722, 2050, 2060, 3017, 230, 2541, 231, 840, 3012, 826, + /* 200 */ 9, 2096, 2099, 492, 2960, 206, 2921, 836, 614, 161, + /* 210 */ 835, 724, 2015, 613, 2539, 723, 1990, 3011, 1988, 106, + /* 220 */ 900, 612, 96, 868, 105, 52, 51, 2821, 761, 58, + /* 230 */ 56, 55, 54, 53, 402, 824, 230, 2018, 2518, 172, + /* 240 */ 3012, 826, 775, 2768, 755, 882, 759, 757, 302, 301, + /* 250 */ 2471, 813, 1993, 1994, 2047, 2183, 2049, 2052, 2053, 2054, + /* 260 */ 2055, 2056, 2057, 2058, 2059, 878, 871, 901, 2481, 903, + /* 270 */ 902, 867, 2081, 2082, 2083, 2084, 2085, 2088, 2090, 2091, + /* 280 */ 2092, 2093, 2095, 2, 59, 57, 2186, 160, 2803, 900, + /* 290 */ 2802, 104, 502, 2850, 1989, 1999, 720, 133, 2804, 886, + /* 300 */ 2806, 2807, 881, 880, 1658, 869, 2851, 905, 1987, 2636, + /* 310 */ 2094, 2161, 212, 2485, 2913, 62, 52, 51, 496, 2909, + /* 320 */ 58, 56, 55, 54, 53, 684, 2675, 2803, 577, 2634, + /* 330 */ 887, 52, 51, 2821, 74, 58, 56, 55, 54, 53, + /* 340 */ 2089, 690, 883, 870, 1761, 1762, 2961, 19, 2047, 2768, + /* 350 */ 1660, 882, 837, 169, 1995, 150, 901, 2481, 149, 148, + /* 360 */ 147, 146, 145, 144, 143, 142, 141, 59, 57, 693, + /* 370 */ 3016, 338, 2821, 2161, 771, 502, 526, 1989, 3011, 639, + /* 380 */ 637, 2541, 439, 456, 1005, 244, 126, 15, 2768, 507, + /* 390 */ 882, 1987, 2126, 2094, 2463, 469, 2802, 3015, 2014, 2850, + /* 400 */ 2539, 3012, 3014, 434, 2804, 886, 2806, 2807, 881, 879, + /* 410 */ 226, 869, 2851, 905, 860, 2878, 940, 186, 185, 937, + /* 420 */ 936, 935, 183, 2089, 2097, 2098, 870, 1567, 2470, 1566, + /* 430 */ 19, 592, 2605, 2124, 568, 2802, 567, 1995, 2850, 2071, + /* 440 */ 2535, 2536, 198, 2804, 886, 2806, 2807, 881, 514, 2161, + /* 450 */ 869, 2851, 905, 2933, 2158, 2159, 2160, 2933, 2933, 2933, + /* 460 */ 2933, 2933, 74, 2050, 2060, 1568, 2453, 1005, 566, 2131, + /* 470 */ 15, 2019, 549, 2096, 2099, 2190, 697, 839, 199, 2921, + /* 480 */ 2922, 2014, 167, 2926, 901, 2481, 248, 517, 1990, 41, + /* 490 */ 1988, 508, 792, 2971, 2219, 868, 237, 671, 2125, 2163, + /* 500 */ 2164, 2165, 2166, 2167, 160, 905, 669, 2097, 2098, 665, + /* 510 */ 661, 2015, 204, 725, 331, 2933, 2158, 2159, 2160, 2933, + /* 520 */ 2933, 2933, 2933, 2933, 1993, 1994, 2047, 338, 2049, 2052, + /* 530 */ 2053, 2054, 2055, 2056, 2057, 2058, 2059, 878, 871, 810, + /* 540 */ 942, 903, 902, 867, 2081, 2082, 2050, 2060, 942, 2088, + /* 550 */ 2090, 2091, 2092, 2093, 2095, 2, 2096, 2099, 2271, 900, + /* 560 */ 2636, 2182, 807, 806, 2217, 2218, 2220, 2221, 2222, 1835, + /* 570 */ 1836, 1990, 63, 1988, 504, 2130, 1570, 1571, 868, 219, + /* 580 */ 2633, 887, 159, 158, 157, 156, 155, 154, 153, 152, + /* 590 */ 151, 45, 2158, 2159, 2160, 43, 498, 2119, 2120, 2121, + /* 600 */ 2122, 2123, 2127, 2128, 2129, 3016, 2610, 1993, 1994, 2047, + /* 610 */ 772, 2049, 2052, 2053, 2054, 2055, 2056, 2057, 2058, 2059, + /* 620 */ 878, 871, 2017, 2017, 903, 902, 867, 2081, 2082, 1567, + /* 630 */ 1958, 1566, 2088, 2090, 2091, 2092, 2093, 2095, 2, 12, + /* 640 */ 59, 57, 724, 1862, 1863, 165, 723, 691, 502, 554, + /* 650 */ 1989, 12, 2051, 2803, 62, 338, 1722, 816, 811, 804, + /* 660 */ 800, 2778, 513, 512, 1987, 2014, 2094, 1568, 883, 1957, + /* 670 */ 2329, 1713, 932, 931, 930, 1717, 929, 1719, 1720, 928, + /* 680 */ 925, 2541, 1728, 922, 1730, 1731, 919, 916, 913, 2803, + /* 690 */ 1995, 2782, 1861, 1864, 2014, 197, 2089, 2283, 2821, 870, + /* 700 */ 844, 516, 515, 19, 883, 58, 56, 55, 54, 53, + /* 710 */ 1995, 2541, 692, 2629, 2768, 2048, 882, 388, 2254, 462, + /* 720 */ 12, 2778, 10, 59, 57, 2100, 694, 825, 901, 2481, + /* 730 */ 2539, 502, 266, 1989, 2821, 3011, 677, 2541, 2327, 2105, + /* 740 */ 1005, 2784, 2787, 15, 861, 2014, 2885, 1987, 235, 2094, + /* 750 */ 2768, 2782, 882, 824, 230, 905, 852, 933, 3012, 826, + /* 760 */ 74, 2802, 305, 193, 2850, 338, 304, 3016, 133, 2804, + /* 770 */ 886, 2806, 2807, 881, 2487, 3011, 869, 2851, 905, 2089, + /* 780 */ 2097, 2098, 870, 3031, 829, 2913, 2623, 558, 695, 496, + /* 790 */ 2909, 901, 2481, 1995, 3015, 336, 336, 2802, 3012, 3013, + /* 800 */ 2850, 2784, 2786, 497, 201, 2804, 886, 2806, 2807, 881, + /* 810 */ 825, 67, 869, 2851, 905, 905, 560, 556, 3011, 2050, + /* 820 */ 2060, 524, 2456, 1005, 2534, 2536, 60, 52, 51, 2096, + /* 830 */ 2099, 58, 56, 55, 54, 53, 824, 230, 345, 346, + /* 840 */ 115, 3012, 826, 344, 1990, 451, 1988, 338, 481, 775, + /* 850 */ 763, 868, 505, 52, 51, 175, 2294, 58, 56, 55, + /* 860 */ 54, 53, 193, 2097, 2098, 2051, 827, 3032, 2762, 1674, + /* 870 */ 52, 51, 790, 2486, 58, 56, 55, 54, 53, 2468, + /* 880 */ 1993, 1994, 2047, 1673, 2049, 2052, 2053, 2054, 2055, 2056, + /* 890 */ 2057, 2058, 2059, 878, 871, 901, 2481, 903, 902, 867, + /* 900 */ 2081, 2082, 2050, 2060, 2466, 2088, 2090, 2091, 2092, 2093, + /* 910 */ 2095, 2, 2096, 2099, 2588, 574, 2051, 2768, 52, 51, + /* 920 */ 1722, 2018, 58, 56, 55, 54, 53, 1990, 2048, 1988, + /* 930 */ 306, 508, 777, 2675, 868, 1713, 932, 931, 930, 1717, + /* 940 */ 929, 1719, 1720, 877, 876, 905, 1728, 875, 1730, 1731, + /* 950 */ 874, 916, 913, 338, 837, 169, 268, 47, 584, 646, + /* 960 */ 677, 2230, 2327, 1993, 1994, 2047, 1540, 2049, 2052, 2053, + /* 970 */ 2054, 2055, 2056, 2057, 2058, 2059, 878, 871, 2202, 2048, + /* 980 */ 903, 902, 867, 2081, 2082, 1547, 901, 2481, 2088, 2090, + /* 990 */ 2091, 2092, 2093, 2095, 2, 59, 57, 863, 633, 2885, + /* 1000 */ 1989, 395, 2293, 502, 317, 1989, 575, 1547, 2803, 2292, + /* 1010 */ 1542, 1545, 1546, 72, 1987, 1916, 1917, 623, 2605, 1987, + /* 1020 */ 394, 2094, 194, 883, 788, 2968, 2066, 2261, 741, 740, + /* 1030 */ 739, 522, 2483, 1545, 1546, 731, 166, 735, 55, 54, + /* 1040 */ 53, 734, 2455, 3015, 901, 2481, 733, 738, 476, 475, + /* 1050 */ 2291, 2089, 732, 2821, 870, 117, 474, 728, 727, 726, + /* 1060 */ 1995, 482, 2683, 2768, 594, 1995, 255, 901, 2481, 2768, + /* 1070 */ 2768, 882, 253, 901, 2481, 313, 901, 2481, 59, 57, + /* 1080 */ 139, 2921, 2922, 830, 167, 2926, 502, 608, 1989, 112, + /* 1090 */ 1005, 632, 254, 609, 225, 1005, 610, 395, 60, 2079, + /* 1100 */ 901, 2481, 1987, 2211, 2094, 630, 2290, 748, 467, 901, + /* 1110 */ 2481, 2768, 2289, 38, 956, 224, 2802, 2212, 2474, 2850, + /* 1120 */ 696, 2288, 762, 133, 2804, 886, 2806, 2807, 881, 2476, + /* 1130 */ 401, 869, 2851, 905, 2089, 2097, 2098, 870, 3031, 2018, + /* 1140 */ 2913, 303, 901, 2481, 496, 2909, 901, 2481, 1995, 901, + /* 1150 */ 2481, 2561, 901, 2481, 2260, 2019, 2485, 751, 2684, 901, + /* 1160 */ 2481, 2708, 308, 2210, 745, 743, 316, 2768, 2287, 843, + /* 1170 */ 194, 300, 349, 2768, 2050, 2060, 525, 2286, 1005, 857, + /* 1180 */ 2484, 60, 2768, 958, 2096, 2099, 193, 940, 186, 185, + /* 1190 */ 937, 936, 935, 183, 1990, 959, 1988, 2486, 2438, 1990, + /* 1200 */ 729, 1988, 2366, 52, 51, 2018, 868, 58, 56, 55, + /* 1210 */ 54, 53, 901, 2481, 901, 2481, 2543, 84, 2097, 2098, + /* 1220 */ 52, 51, 83, 1651, 58, 56, 55, 54, 53, 2768, + /* 1230 */ 1993, 1994, 356, 2413, 894, 1993, 1994, 2047, 2768, 2049, + /* 1240 */ 2052, 2053, 2054, 2055, 2056, 2057, 2058, 2059, 878, 871, + /* 1250 */ 14, 13, 903, 902, 867, 2081, 2082, 2050, 2060, 39, + /* 1260 */ 2088, 2090, 2091, 2092, 2093, 2095, 2, 2096, 2099, 52, + /* 1270 */ 51, 901, 2481, 58, 56, 55, 54, 53, 2284, 741, + /* 1280 */ 740, 739, 1990, 2014, 1988, 112, 731, 166, 735, 868, + /* 1290 */ 3, 895, 734, 901, 2481, 901, 2481, 733, 738, 476, + /* 1300 */ 475, 716, 715, 732, 65, 2285, 616, 474, 728, 727, + /* 1310 */ 726, 2067, 233, 899, 2475, 384, 718, 717, 1993, 1994, + /* 1320 */ 2047, 615, 2049, 2052, 2053, 2054, 2055, 2056, 2057, 2058, + /* 1330 */ 2059, 878, 871, 2541, 2974, 903, 902, 867, 2081, 2082, + /* 1340 */ 2928, 523, 2282, 2088, 2090, 2091, 2092, 2093, 2095, 2, + /* 1350 */ 59, 57, 2539, 737, 736, 970, 968, 116, 502, 288, + /* 1360 */ 1989, 934, 204, 2803, 2532, 2138, 2768, 2281, 2928, 2924, + /* 1370 */ 828, 642, 768, 2019, 1987, 205, 2094, 2069, 883, 170, + /* 1380 */ 2981, 2280, 2884, 2279, 714, 710, 706, 702, 40, 287, + /* 1390 */ 2278, 1890, 1653, 2277, 52, 51, 819, 2923, 58, 56, + /* 1400 */ 55, 54, 53, 2768, 42, 221, 2089, 162, 2821, 870, + /* 1410 */ 52, 51, 2276, 2541, 58, 56, 55, 54, 53, 1549, + /* 1420 */ 1995, 102, 837, 169, 2768, 2013, 882, 908, 2768, 791, + /* 1430 */ 2299, 998, 2540, 59, 57, 285, 2275, 3011, 1654, 2019, + /* 1440 */ 284, 502, 2768, 1989, 2768, 2274, 938, 332, 184, 2532, + /* 1450 */ 1005, 2768, 832, 60, 2768, 3017, 230, 1987, 776, 2094, + /* 1460 */ 3012, 826, 52, 51, 866, 2172, 58, 56, 55, 54, + /* 1470 */ 53, 2802, 939, 2768, 2850, 2532, 176, 176, 133, 2804, + /* 1480 */ 886, 2806, 2807, 881, 90, 798, 869, 2851, 905, 2089, + /* 1490 */ 2097, 2098, 870, 3031, 765, 2913, 764, 2768, 293, 496, + /* 1500 */ 2909, 291, 730, 1995, 52, 51, 2768, 271, 58, 56, + /* 1510 */ 55, 54, 53, 2263, 2264, 791, 282, 2048, 1631, 295, + /* 1520 */ 273, 280, 294, 3011, 808, 1649, 278, 688, 164, 2050, + /* 1530 */ 2060, 66, 297, 1005, 299, 296, 15, 298, 103, 2096, + /* 1540 */ 2099, 3017, 230, 46, 2350, 270, 3012, 826, 200, 2921, + /* 1550 */ 2922, 61, 167, 2926, 1990, 61, 1988, 213, 950, 1906, + /* 1560 */ 1914, 868, 14, 13, 1632, 184, 742, 2348, 2206, 838, + /* 1570 */ 2072, 2822, 343, 2097, 2098, 89, 61, 1998, 2789, 52, + /* 1580 */ 51, 1623, 76, 58, 56, 55, 54, 53, 2452, 744, + /* 1590 */ 1993, 1994, 2047, 61, 2049, 2052, 2053, 2054, 2055, 2056, + /* 1600 */ 2057, 2058, 2059, 878, 871, 2339, 61, 903, 902, 867, + /* 1610 */ 2081, 2082, 2050, 2060, 2337, 2088, 2090, 2091, 2092, 2093, + /* 1620 */ 2095, 2, 2096, 2099, 52, 51, 1997, 746, 58, 56, + /* 1630 */ 55, 54, 53, 61, 2216, 909, 749, 1990, 2215, 1988, + /* 1640 */ 322, 2116, 2791, 61, 868, 89, 52, 51, 842, 324, + /* 1650 */ 58, 56, 55, 54, 53, 347, 52, 51, 849, 2070, + /* 1660 */ 58, 56, 55, 54, 53, 2132, 363, 362, 2405, 181, + /* 1670 */ 365, 364, 162, 1993, 1994, 2047, 2080, 2049, 2052, 2053, + /* 1680 */ 2054, 2055, 2056, 2057, 2058, 2059, 878, 871, 184, 2073, + /* 1690 */ 903, 902, 867, 2081, 2082, 367, 366, 951, 2088, 2090, + /* 1700 */ 2091, 2092, 2093, 2095, 2, 443, 2803, 2012, 369, 368, + /* 1710 */ 86, 371, 370, 911, 621, 841, 2061, 466, 373, 372, + /* 1720 */ 1621, 883, 195, 182, 184, 641, 1859, 408, 1849, 375, + /* 1730 */ 374, 2404, 2068, 940, 186, 185, 937, 936, 935, 183, + /* 1740 */ 131, 600, 128, 643, 163, 181, 406, 88, 444, 602, + /* 1750 */ 87, 2821, 359, 833, 2065, 898, 377, 376, 2320, 2001, + /* 1760 */ 580, 445, 379, 378, 137, 381, 380, 2768, 2964, 882, + /* 1770 */ 1604, 1704, 791, 264, 656, 654, 651, 649, 383, 382, + /* 1780 */ 3011, 805, 488, 812, 484, 846, 2614, 551, 533, 2326, + /* 1790 */ 2529, 784, 2965, 400, 2975, 820, 1735, 334, 3017, 230, + /* 1800 */ 329, 465, 821, 3012, 826, 2615, 1743, 1750, 2000, 337, + /* 1810 */ 2439, 5, 541, 588, 2802, 536, 1605, 2850, 460, 74, + /* 1820 */ 2012, 133, 2804, 886, 2806, 2807, 881, 1748, 187, 869, + /* 1830 */ 2851, 905, 550, 2022, 171, 562, 180, 2884, 2913, 561, + /* 1840 */ 239, 238, 496, 2909, 2616, 2595, 241, 629, 628, 627, + /* 1850 */ 626, 625, 620, 619, 618, 617, 448, 564, 75, 607, + /* 1860 */ 606, 605, 604, 603, 597, 596, 595, 1883, 590, 589, + /* 1870 */ 463, 393, 578, 2803, 581, 1823, 1824, 2013, 585, 252, + /* 1880 */ 587, 1842, 591, 593, 635, 611, 598, 622, 883, 647, + /* 1890 */ 802, 2607, 624, 631, 634, 636, 648, 645, 258, 650, + /* 1900 */ 257, 652, 261, 653, 655, 657, 2020, 672, 4, 673, + /* 1910 */ 680, 683, 100, 99, 573, 48, 681, 243, 2821, 269, + /* 1920 */ 108, 2015, 685, 2021, 272, 686, 2023, 689, 687, 275, + /* 1930 */ 565, 563, 2024, 2630, 2768, 277, 882, 109, 2025, 2624, + /* 1940 */ 110, 2803, 111, 442, 1702, 286, 552, 698, 283, 548, + /* 1950 */ 544, 540, 537, 566, 752, 719, 883, 113, 3004, 138, + /* 1960 */ 721, 753, 437, 2698, 767, 2469, 290, 769, 2465, 292, + /* 1970 */ 114, 189, 2016, 309, 779, 396, 778, 135, 2676, 2803, + /* 1980 */ 177, 2802, 2467, 2462, 2850, 190, 2821, 191, 133, 2804, + /* 1990 */ 886, 2806, 2807, 881, 883, 2695, 869, 2851, 905, 314, + /* 2000 */ 2694, 786, 2768, 3031, 882, 2913, 2803, 783, 809, 496, + /* 2010 */ 2909, 795, 338, 847, 2980, 2979, 818, 793, 323, 8, + /* 2020 */ 2952, 883, 203, 2945, 2821, 325, 796, 327, 794, 823, + /* 2030 */ 822, 3034, 780, 2932, 489, 319, 330, 785, 312, 326, + /* 2040 */ 2768, 321, 882, 834, 328, 831, 168, 2017, 2180, 2802, + /* 2050 */ 1, 2821, 2850, 216, 2178, 845, 133, 2804, 886, 2806, + /* 2060 */ 2807, 881, 529, 528, 869, 2851, 905, 2768, 3010, 882, + /* 2070 */ 339, 3031, 2003, 2913, 2803, 178, 2929, 496, 2909, 2644, + /* 2080 */ 397, 2643, 2642, 850, 398, 851, 1996, 2802, 2094, 883, + /* 2090 */ 2850, 493, 179, 855, 133, 2804, 886, 2806, 2807, 881, + /* 2100 */ 858, 73, 869, 2851, 905, 2894, 890, 888, 352, 2888, + /* 2110 */ 892, 2913, 2803, 2760, 2802, 496, 2909, 2850, 2089, 2821, + /* 2120 */ 232, 133, 2804, 886, 2806, 2807, 881, 883, 357, 869, + /* 2130 */ 2851, 905, 1995, 893, 333, 2768, 3031, 882, 2913, 447, + /* 2140 */ 446, 399, 496, 2909, 124, 127, 1519, 2482, 403, 509, + /* 2150 */ 2759, 1000, 907, 1001, 2755, 2754, 2803, 2821, 386, 188, + /* 2160 */ 2746, 389, 865, 518, 1004, 2094, 2745, 2737, 1002, 997, + /* 2170 */ 2736, 883, 2752, 2768, 390, 882, 2751, 2743, 2742, 2731, + /* 2180 */ 2730, 405, 2802, 2749, 2720, 2850, 2748, 2740, 2739, 133, + /* 2190 */ 2804, 886, 2806, 2807, 881, 2089, 2728, 869, 2851, 905, + /* 2200 */ 472, 2821, 771, 2727, 2886, 64, 2913, 2725, 2724, 2533, + /* 2210 */ 496, 2909, 425, 436, 520, 452, 426, 2768, 407, 882, + /* 2220 */ 2802, 438, 453, 2850, 2719, 2718, 97, 133, 2804, 886, + /* 2230 */ 2806, 2807, 881, 2713, 538, 869, 2851, 905, 2803, 539, + /* 2240 */ 1940, 1941, 862, 236, 2913, 543, 2711, 545, 496, 2909, + /* 2250 */ 546, 547, 1939, 883, 2710, 2709, 461, 2707, 553, 2706, + /* 2260 */ 2705, 557, 555, 2704, 2802, 559, 2004, 2850, 1999, 1927, + /* 2270 */ 2680, 134, 2804, 886, 2806, 2807, 881, 240, 2679, 869, + /* 2280 */ 2851, 905, 242, 2821, 98, 1886, 1885, 2657, 2913, 571, + /* 2290 */ 572, 2654, 2912, 2909, 2656, 2655, 2653, 2597, 576, 2768, + /* 2300 */ 1822, 882, 2007, 2009, 2594, 579, 2593, 2587, 582, 2584, + /* 2310 */ 583, 2583, 245, 101, 2582, 2581, 2586, 2585, 247, 903, + /* 2320 */ 902, 2803, 2580, 2579, 2577, 2576, 2575, 2088, 2090, 2091, + /* 2330 */ 2092, 2093, 2095, 249, 599, 2574, 883, 601, 2572, 2571, + /* 2340 */ 2570, 2569, 2568, 1980, 2592, 1956, 2802, 2567, 2566, 2850, + /* 2350 */ 2565, 2590, 2573, 134, 2804, 886, 2806, 2807, 881, 2564, + /* 2360 */ 2563, 869, 2851, 905, 2562, 2560, 2821, 2559, 2558, 2557, + /* 2370 */ 2913, 2556, 2555, 2554, 864, 2909, 2553, 511, 510, 1981, + /* 2380 */ 251, 107, 2768, 2552, 882, 2551, 2550, 2622, 2591, 2589, + /* 2390 */ 2549, 2548, 1828, 2547, 256, 2546, 903, 902, 638, 2545, + /* 2400 */ 640, 2544, 2542, 1671, 2088, 2090, 2091, 2092, 2093, 2095, + /* 2410 */ 2803, 2370, 2369, 449, 1675, 450, 1667, 259, 2368, 2367, + /* 2420 */ 2365, 260, 2362, 262, 263, 883, 660, 2361, 659, 884, + /* 2430 */ 658, 773, 2850, 662, 2354, 2341, 134, 2804, 886, 2806, + /* 2440 */ 2807, 881, 664, 666, 869, 2851, 905, 2803, 668, 1008, + /* 2450 */ 663, 670, 2315, 2913, 667, 2821, 265, 455, 2909, 211, + /* 2460 */ 93, 2788, 883, 1548, 222, 678, 2314, 94, 392, 267, + /* 2470 */ 2678, 2768, 2674, 882, 2664, 2803, 2652, 274, 276, 2651, + /* 2480 */ 279, 2628, 281, 996, 220, 2621, 2457, 2364, 2360, 699, + /* 2490 */ 883, 700, 2821, 992, 988, 984, 980, 1597, 387, 701, + /* 2500 */ 2358, 703, 704, 705, 2356, 707, 709, 2353, 2768, 711, + /* 2510 */ 882, 708, 712, 2336, 2334, 713, 2335, 2333, 2802, 2311, + /* 2520 */ 2821, 2850, 2459, 2458, 1754, 134, 2804, 886, 2806, 2807, + /* 2530 */ 881, 85, 1657, 869, 2851, 905, 2768, 1755, 882, 1656, + /* 2540 */ 289, 1655, 2913, 2351, 132, 1652, 2349, 2910, 1650, 360, + /* 2550 */ 1639, 1648, 477, 478, 1647, 2802, 1646, 967, 2850, 969, + /* 2560 */ 499, 1645, 411, 2804, 886, 2806, 2807, 881, 1644, 32, + /* 2570 */ 869, 2851, 905, 1641, 1640, 1638, 2340, 479, 2338, 480, + /* 2580 */ 853, 2803, 2310, 2802, 750, 747, 2850, 2309, 2308, 754, + /* 2590 */ 435, 2804, 886, 2806, 2807, 881, 883, 2307, 869, 2851, + /* 2600 */ 905, 756, 2306, 758, 2305, 760, 2803, 1921, 1923, 140, + /* 2610 */ 1920, 1925, 33, 2677, 79, 311, 2673, 1892, 68, 2663, + /* 2620 */ 1894, 883, 781, 2650, 2649, 358, 2821, 859, 3016, 69, + /* 2630 */ 341, 1896, 1911, 770, 782, 340, 1871, 315, 1870, 22, + /* 2640 */ 17, 797, 2768, 787, 882, 789, 485, 192, 35, 25, + /* 2650 */ 2233, 2821, 2207, 6, 310, 318, 799, 801, 803, 7, + /* 2660 */ 23, 320, 24, 215, 37, 2214, 202, 2768, 2201, 882, + /* 2670 */ 2171, 214, 227, 36, 95, 2803, 2173, 2789, 228, 2175, + /* 2680 */ 77, 229, 26, 2248, 2253, 2254, 2247, 490, 2252, 2802, + /* 2690 */ 883, 486, 2850, 2251, 491, 2155, 198, 2804, 886, 2806, + /* 2700 */ 2807, 881, 2154, 71, 869, 2851, 905, 335, 2648, 2627, + /* 2710 */ 207, 118, 119, 2626, 2802, 342, 120, 2850, 2803, 2209, + /* 2720 */ 2821, 435, 2804, 886, 2806, 2807, 881, 217, 2620, 869, + /* 2730 */ 2851, 905, 348, 883, 854, 81, 2768, 351, 882, 121, + /* 2740 */ 2803, 70, 350, 27, 13, 18, 848, 2972, 2107, 11, + /* 2750 */ 2106, 2005, 2064, 21, 28, 883, 856, 353, 2117, 29, + /* 2760 */ 487, 2803, 2063, 2821, 2062, 208, 218, 2040, 20, 49, + /* 2770 */ 2619, 891, 2454, 896, 122, 918, 880, 921, 924, 2768, + /* 2780 */ 927, 882, 50, 2802, 16, 2821, 2850, 2032, 30, 31, + /* 2790 */ 435, 2804, 886, 2806, 2807, 881, 82, 355, 869, 2851, + /* 2800 */ 905, 2768, 889, 882, 123, 128, 2821, 91, 897, 361, + /* 2810 */ 2076, 2863, 2862, 904, 80, 2267, 885, 906, 1736, 2266, + /* 2820 */ 910, 521, 2768, 1733, 882, 914, 2802, 912, 917, 2850, + /* 2830 */ 920, 915, 923, 428, 2804, 886, 2806, 2807, 881, 1732, + /* 2840 */ 1729, 869, 2851, 905, 926, 385, 1749, 1723, 2802, 1721, + /* 2850 */ 129, 2850, 130, 92, 1727, 201, 2804, 886, 2806, 2807, + /* 2860 */ 881, 1745, 1726, 869, 2851, 905, 1595, 1635, 1634, 2802, + /* 2870 */ 941, 1725, 2850, 1724, 1633, 955, 434, 2804, 886, 2806, + /* 2880 */ 2807, 881, 2803, 1630, 869, 2851, 905, 817, 2879, 1627, + /* 2890 */ 1626, 1625, 1624, 1622, 1620, 1619, 1618, 883, 1665, 1664, + /* 2900 */ 957, 234, 1616, 1615, 1613, 1614, 1612, 2803, 1611, 1661, + /* 2910 */ 1610, 1659, 1607, 1606, 1603, 1602, 1601, 1600, 3033, 2359, + /* 2920 */ 977, 2357, 883, 981, 979, 978, 2355, 2821, 985, 983, + /* 2930 */ 2352, 989, 987, 991, 2332, 993, 2330, 982, 995, 1537, + /* 2940 */ 986, 2304, 1520, 2768, 990, 882, 999, 1525, 1527, 2803, + /* 2950 */ 391, 1991, 2821, 1003, 2270, 404, 1006, 1007, 2270, 2270, + /* 2960 */ 2270, 2270, 2270, 2270, 883, 2270, 2270, 500, 2768, 2270, + /* 2970 */ 882, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, + /* 2980 */ 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, + /* 2990 */ 2802, 2270, 495, 2850, 2821, 2270, 2270, 435, 2804, 886, + /* 3000 */ 2806, 2807, 881, 2270, 2270, 869, 2851, 905, 2270, 2270, + /* 3010 */ 2768, 2270, 882, 2270, 2803, 2802, 2270, 2270, 2850, 2270, + /* 3020 */ 2270, 2270, 420, 2804, 886, 2806, 2807, 881, 2270, 883, + /* 3030 */ 869, 2851, 905, 2270, 501, 2270, 2270, 2270, 2270, 2270, + /* 3040 */ 2270, 2803, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, + /* 3050 */ 2270, 2270, 2270, 2270, 2270, 2270, 883, 2802, 2270, 2821, + /* 3060 */ 2850, 2270, 2270, 2270, 435, 2804, 886, 2806, 2807, 881, + /* 3070 */ 2270, 2270, 869, 2851, 905, 2768, 2270, 882, 2270, 2803, + /* 3080 */ 2270, 2270, 2270, 2270, 2270, 2270, 2821, 2270, 2270, 2270, + /* 3090 */ 2270, 2270, 2270, 2270, 883, 2270, 2270, 2270, 2270, 503, + /* 3100 */ 2270, 2270, 2768, 2270, 882, 2270, 2270, 2270, 2803, 2270, + /* 3110 */ 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, + /* 3120 */ 2270, 2270, 2802, 883, 2821, 2850, 2270, 2270, 2270, 435, + /* 3130 */ 2804, 886, 2806, 2807, 881, 2270, 2270, 869, 2851, 905, + /* 3140 */ 2768, 2270, 882, 2270, 2270, 2270, 2270, 2803, 2270, 2802, + /* 3150 */ 2270, 2270, 2850, 2821, 2270, 2270, 416, 2804, 886, 2806, + /* 3160 */ 2807, 881, 883, 2270, 869, 2851, 905, 2270, 2270, 2768, + /* 3170 */ 2270, 882, 2270, 2803, 2270, 2270, 2270, 2270, 2270, 2270, + /* 3180 */ 2270, 2270, 2270, 2270, 2270, 2270, 2270, 766, 883, 2270, + /* 3190 */ 2850, 2270, 2821, 2270, 430, 2804, 886, 2806, 2807, 881, + /* 3200 */ 2270, 2270, 869, 2851, 905, 2270, 2270, 2270, 2768, 2270, + /* 3210 */ 882, 2270, 2270, 2270, 2270, 2270, 2802, 2270, 2821, 2850, + /* 3220 */ 2270, 2270, 2270, 412, 2804, 886, 2806, 2807, 881, 2270, + /* 3230 */ 2270, 869, 2851, 905, 2768, 2270, 882, 2270, 2803, 2270, + /* 3240 */ 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, + /* 3250 */ 2270, 2270, 2270, 883, 2270, 2802, 2270, 2270, 2850, 2803, + /* 3260 */ 2270, 2270, 409, 2804, 886, 2806, 2807, 881, 2270, 2270, + /* 3270 */ 869, 2851, 905, 2270, 883, 2270, 2270, 2270, 2270, 2270, + /* 3280 */ 2270, 2802, 2270, 2821, 2850, 2270, 2270, 2270, 413, 2804, + /* 3290 */ 886, 2806, 2807, 881, 2270, 2270, 869, 2851, 905, 2768, + /* 3300 */ 2270, 882, 2270, 2270, 2821, 2270, 2270, 2270, 2270, 2270, + /* 3310 */ 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, + /* 3320 */ 2768, 2270, 882, 2270, 2270, 2270, 2270, 2270, 2270, 2270, + /* 3330 */ 2270, 2270, 2270, 2270, 2270, 2270, 2803, 2270, 2270, 2270, + /* 3340 */ 2270, 2270, 2270, 2270, 2270, 2270, 2802, 2270, 2270, 2850, + /* 3350 */ 2270, 883, 2270, 427, 2804, 886, 2806, 2807, 881, 2270, + /* 3360 */ 2270, 869, 2851, 905, 2270, 2270, 2270, 2802, 2270, 2270, + /* 3370 */ 2850, 2270, 2270, 2270, 414, 2804, 886, 2806, 2807, 881, + /* 3380 */ 2803, 2821, 869, 2851, 905, 2270, 2270, 2270, 2270, 2270, + /* 3390 */ 2270, 2270, 2270, 2270, 2270, 883, 2270, 2768, 2270, 882, + /* 3400 */ 2270, 2803, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, + /* 3410 */ 2270, 2270, 2270, 2270, 2270, 2270, 883, 2270, 2270, 2270, + /* 3420 */ 2270, 2803, 2270, 2270, 2270, 2821, 2270, 2270, 2270, 2270, + /* 3430 */ 2270, 2270, 2270, 2270, 2270, 2270, 883, 2270, 2270, 2270, + /* 3440 */ 2270, 2768, 2270, 882, 2802, 2270, 2821, 2850, 2270, 2270, + /* 3450 */ 2270, 415, 2804, 886, 2806, 2807, 881, 2270, 2270, 869, + /* 3460 */ 2851, 905, 2768, 2270, 882, 2270, 2821, 2270, 2270, 2270, + /* 3470 */ 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, + /* 3480 */ 2270, 2270, 2768, 2270, 882, 2270, 2803, 2270, 2802, 2270, + /* 3490 */ 2270, 2850, 2270, 2270, 2270, 431, 2804, 886, 2806, 2807, + /* 3500 */ 881, 883, 2270, 869, 2851, 905, 2270, 2270, 2270, 2802, + /* 3510 */ 2270, 2270, 2850, 2270, 2270, 2270, 417, 2804, 886, 2806, + /* 3520 */ 2807, 881, 2270, 2270, 869, 2851, 905, 2803, 2270, 2802, + /* 3530 */ 2270, 2821, 2850, 2270, 2270, 2270, 432, 2804, 886, 2806, + /* 3540 */ 2807, 881, 883, 2270, 869, 2851, 905, 2768, 2270, 882, + /* 3550 */ 2270, 2803, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, + /* 3560 */ 2270, 2270, 2270, 2270, 2270, 2270, 883, 2270, 2270, 2270, + /* 3570 */ 2270, 2270, 2821, 2270, 2270, 2270, 2270, 2270, 2270, 2270, + /* 3580 */ 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2768, 2270, + /* 3590 */ 882, 2270, 2270, 2270, 2802, 2270, 2821, 2850, 2270, 2270, + /* 3600 */ 2270, 418, 2804, 886, 2806, 2807, 881, 2270, 2270, 869, + /* 3610 */ 2851, 905, 2768, 2270, 882, 2270, 2270, 2270, 2803, 2270, + /* 3620 */ 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, + /* 3630 */ 2270, 2270, 2270, 883, 2270, 2802, 2270, 2270, 2850, 2270, + /* 3640 */ 2803, 2270, 433, 2804, 886, 2806, 2807, 881, 2270, 2270, + /* 3650 */ 869, 2851, 905, 2270, 2270, 883, 2270, 2270, 2270, 2802, + /* 3660 */ 2270, 2270, 2850, 2821, 2270, 2270, 419, 2804, 886, 2806, + /* 3670 */ 2807, 881, 2270, 2270, 869, 2851, 905, 2270, 2270, 2768, + /* 3680 */ 2270, 882, 2270, 2803, 2270, 2821, 2270, 2270, 2270, 2270, + /* 3690 */ 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 883, 2270, + /* 3700 */ 2270, 2768, 2270, 882, 2270, 2270, 2270, 2803, 2270, 2270, + /* 3710 */ 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, + /* 3720 */ 2270, 2270, 883, 2270, 2270, 2270, 2802, 2270, 2821, 2850, + /* 3730 */ 2270, 2270, 2270, 410, 2804, 886, 2806, 2807, 881, 2270, + /* 3740 */ 2270, 869, 2851, 905, 2768, 2270, 882, 2270, 2802, 2270, + /* 3750 */ 2270, 2850, 2821, 2270, 2270, 421, 2804, 886, 2806, 2807, + /* 3760 */ 881, 2270, 2270, 869, 2851, 905, 2270, 2270, 2768, 2270, + /* 3770 */ 882, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, + /* 3780 */ 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, + /* 3790 */ 2270, 2802, 2270, 2270, 2850, 2270, 2270, 2270, 422, 2804, + /* 3800 */ 886, 2806, 2807, 881, 2270, 2270, 869, 2851, 905, 2270, + /* 3810 */ 2270, 2270, 2270, 2270, 2270, 2802, 2270, 2270, 2850, 2270, + /* 3820 */ 2270, 2270, 423, 2804, 886, 2806, 2807, 881, 2803, 2270, + /* 3830 */ 869, 2851, 905, 2270, 2270, 2270, 2270, 2270, 2270, 2270, + /* 3840 */ 2270, 2270, 2270, 883, 2270, 2270, 2270, 2803, 2270, 2270, + /* 3850 */ 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, + /* 3860 */ 2270, 2270, 883, 2270, 2270, 2270, 2270, 2270, 2270, 2803, + /* 3870 */ 2270, 2270, 2270, 2821, 2270, 2270, 2270, 2270, 2270, 2270, + /* 3880 */ 2270, 2270, 2270, 2270, 883, 2270, 2270, 2270, 2270, 2768, + /* 3890 */ 2270, 882, 2821, 2270, 2270, 2270, 2803, 2270, 2270, 2270, + /* 3900 */ 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2768, 2270, + /* 3910 */ 882, 883, 2270, 2270, 2821, 2270, 2270, 2270, 2270, 2270, + /* 3920 */ 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, + /* 3930 */ 2768, 2270, 882, 2270, 2803, 2270, 2802, 2270, 2270, 2850, + /* 3940 */ 2270, 2821, 2270, 424, 2804, 886, 2806, 2807, 881, 883, + /* 3950 */ 2270, 869, 2851, 905, 2270, 2802, 2270, 2768, 2850, 882, + /* 3960 */ 2270, 2270, 440, 2804, 886, 2806, 2807, 881, 2270, 2270, + /* 3970 */ 869, 2851, 905, 2270, 2270, 2270, 2270, 2802, 2270, 2821, + /* 3980 */ 2850, 2270, 2270, 2803, 441, 2804, 886, 2806, 2807, 881, + /* 3990 */ 2270, 2270, 869, 2851, 905, 2768, 2270, 882, 883, 2270, + /* 4000 */ 2270, 2270, 2270, 2270, 2802, 2270, 2270, 2850, 2270, 2270, + /* 4010 */ 2270, 2815, 2804, 886, 2806, 2807, 881, 2270, 2270, 869, + /* 4020 */ 2851, 905, 2803, 2270, 2270, 2270, 2270, 2270, 2821, 2270, + /* 4030 */ 2270, 2270, 2270, 2270, 2270, 2270, 2270, 883, 2270, 2270, + /* 4040 */ 2270, 2270, 2802, 2270, 2768, 2850, 882, 2270, 2270, 2814, + /* 4050 */ 2804, 886, 2806, 2807, 881, 2270, 2270, 869, 2851, 905, + /* 4060 */ 2270, 2270, 2270, 2270, 2270, 2270, 2803, 2821, 2270, 2270, + /* 4070 */ 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, + /* 4080 */ 2270, 883, 2270, 2768, 2270, 882, 2270, 2270, 2270, 2270, + /* 4090 */ 2803, 2802, 2270, 2270, 2850, 2270, 2270, 2270, 2813, 2804, + /* 4100 */ 886, 2806, 2807, 881, 2270, 883, 869, 2851, 905, 2803, + /* 4110 */ 2270, 2821, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, + /* 4120 */ 2270, 2270, 2270, 2270, 883, 2270, 2270, 2768, 2270, 882, + /* 4130 */ 2802, 2270, 2270, 2850, 2270, 2821, 2270, 457, 2804, 886, + /* 4140 */ 2806, 2807, 881, 2270, 2270, 869, 2851, 905, 2270, 2270, + /* 4150 */ 2270, 2768, 2270, 882, 2821, 2270, 2270, 2270, 2270, 2270, + /* 4160 */ 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, + /* 4170 */ 2768, 2270, 882, 2270, 2802, 2270, 2270, 2850, 2803, 2270, + /* 4180 */ 2270, 458, 2804, 886, 2806, 2807, 881, 2270, 2270, 869, + /* 4190 */ 2851, 905, 2270, 883, 2270, 2270, 2270, 2270, 2802, 2270, + /* 4200 */ 2270, 2850, 2270, 2270, 2270, 454, 2804, 886, 2806, 2807, + /* 4210 */ 881, 2270, 2270, 869, 2851, 905, 2270, 2802, 2270, 2270, + /* 4220 */ 2850, 2270, 2270, 2821, 459, 2804, 886, 2806, 2807, 881, + /* 4230 */ 2270, 2270, 869, 2851, 905, 2270, 2270, 2270, 2270, 2768, + /* 4240 */ 2270, 882, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, + /* 4250 */ 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, + /* 4260 */ 2803, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, + /* 4270 */ 2270, 2270, 2270, 2270, 2270, 883, 2270, 2270, 2270, 2270, + /* 4280 */ 2270, 2270, 2270, 2270, 2270, 2270, 884, 2270, 2270, 2850, + /* 4290 */ 2270, 2270, 2270, 430, 2804, 886, 2806, 2807, 881, 2270, + /* 4300 */ 2270, 869, 2851, 905, 2270, 2821, 2270, 2270, 2270, 2270, + /* 4310 */ 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, + /* 4320 */ 2270, 2768, 2270, 882, 2270, 2270, 2270, 2270, 2270, 2270, + /* 4330 */ 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, + /* 4340 */ 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, + /* 4350 */ 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, + /* 4360 */ 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2270, 2802, 2270, + /* 4370 */ 2270, 2850, 2270, 2270, 2270, 429, 2804, 886, 2806, 2807, + /* 4380 */ 881, 2270, 2270, 869, 2851, 905, }; static const YYCODETYPE yy_lookahead[] = { - /* 0 */ 529, 395, 0, 529, 398, 399, 395, 431, 537, 398, - /* 10 */ 399, 537, 12, 13, 444, 518, 519, 447, 448, 431, - /* 20 */ 20, 0, 22, 448, 20, 433, 555, 556, 436, 20, - /* 30 */ 556, 560, 561, 400, 560, 561, 36, 462, 38, 0, - /* 40 */ 386, 386, 21, 468, 469, 24, 25, 26, 27, 28, - /* 50 */ 29, 30, 31, 32, 21, 20, 401, 8, 9, 400, - /* 60 */ 401, 12, 13, 14, 15, 16, 0, 431, 68, 20, - /* 70 */ 37, 71, 39, 40, 41, 42, 74, 20, 442, 529, - /* 80 */ 400, 401, 82, 450, 451, 430, 453, 537, 496, 456, - /* 90 */ 24, 25, 26, 27, 28, 29, 30, 31, 32, 430, - /* 100 */ 446, 446, 510, 448, 400, 401, 556, 20, 439, 440, - /* 110 */ 560, 561, 112, 400, 401, 115, 77, 78, 79, 80, - /* 120 */ 81, 117, 83, 84, 85, 86, 87, 88, 89, 90, - /* 130 */ 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, - /* 140 */ 101, 102, 103, 104, 105, 106, 107, 108, 493, 4, - /* 150 */ 383, 496, 152, 153, 0, 500, 501, 502, 503, 504, - /* 160 */ 505, 152, 153, 508, 509, 510, 20, 454, 23, 433, - /* 170 */ 515, 429, 517, 68, 8, 9, 521, 522, 12, 13, - /* 180 */ 14, 15, 16, 386, 525, 526, 527, 445, 529, 530, - /* 190 */ 430, 191, 192, 48, 49, 50, 541, 20, 401, 439, - /* 200 */ 440, 201, 202, 20, 549, 525, 526, 527, 3, 529, - /* 210 */ 530, 12, 13, 14, 15, 16, 216, 537, 218, 114, - /* 220 */ 14, 20, 44, 223, 119, 20, 20, 430, 524, 525, - /* 230 */ 526, 527, 496, 529, 530, 555, 556, 155, 20, 472, - /* 240 */ 560, 561, 193, 446, 477, 448, 510, 410, 191, 192, - /* 250 */ 490, 491, 252, 253, 254, 418, 256, 257, 258, 259, - /* 260 */ 260, 261, 262, 263, 264, 265, 266, 400, 401, 269, - /* 270 */ 270, 271, 272, 273, 274, 275, 276, 277, 278, 279, - /* 280 */ 280, 281, 282, 283, 12, 13, 14, 420, 400, 401, - /* 290 */ 493, 186, 20, 496, 22, 428, 529, 500, 501, 502, - /* 300 */ 503, 504, 505, 254, 537, 508, 509, 510, 36, 155, - /* 310 */ 38, 147, 515, 0, 517, 151, 115, 20, 521, 522, - /* 320 */ 20, 116, 555, 556, 170, 409, 386, 560, 561, 152, - /* 330 */ 153, 8, 9, 155, 20, 12, 13, 14, 15, 16, - /* 340 */ 68, 401, 417, 71, 8, 9, 549, 75, 12, 13, - /* 350 */ 14, 15, 16, 437, 82, 21, 33, 433, 24, 25, - /* 360 */ 26, 27, 28, 29, 30, 31, 32, 12, 13, 422, - /* 370 */ 430, 446, 73, 426, 208, 20, 193, 22, 201, 202, - /* 380 */ 298, 299, 300, 531, 112, 533, 446, 115, 448, 225, - /* 390 */ 14, 36, 430, 38, 230, 20, 20, 233, 193, 235, - /* 400 */ 438, 4, 8, 9, 12, 13, 12, 13, 14, 15, - /* 410 */ 16, 449, 115, 525, 526, 527, 155, 529, 530, 430, - /* 420 */ 496, 496, 497, 68, 152, 153, 71, 438, 36, 115, - /* 430 */ 75, 400, 401, 493, 510, 510, 496, 82, 449, 116, - /* 440 */ 500, 501, 502, 503, 504, 505, 400, 401, 508, 509, - /* 450 */ 510, 420, 116, 513, 396, 515, 516, 517, 400, 428, - /* 460 */ 402, 521, 522, 191, 192, 36, 420, 112, 186, 75, - /* 470 */ 115, 401, 254, 201, 202, 297, 298, 299, 300, 301, - /* 480 */ 302, 303, 304, 305, 171, 77, 78, 79, 216, 176, - /* 490 */ 218, 529, 84, 85, 86, 223, 44, 184, 90, 537, - /* 500 */ 430, 335, 220, 95, 96, 97, 98, 152, 153, 101, - /* 510 */ 211, 82, 115, 105, 106, 107, 108, 555, 556, 125, - /* 520 */ 68, 14, 560, 561, 252, 253, 254, 20, 256, 257, - /* 530 */ 258, 259, 260, 261, 262, 263, 264, 265, 266, 240, - /* 540 */ 241, 269, 270, 271, 272, 273, 191, 192, 74, 277, - /* 550 */ 278, 279, 280, 281, 282, 283, 201, 202, 297, 298, - /* 560 */ 299, 300, 301, 302, 303, 304, 305, 191, 430, 2, - /* 570 */ 112, 216, 502, 218, 74, 8, 9, 417, 223, 12, - /* 580 */ 13, 14, 15, 16, 190, 127, 128, 129, 130, 131, - /* 590 */ 132, 133, 134, 135, 136, 457, 138, 139, 140, 141, - /* 600 */ 142, 143, 144, 252, 268, 308, 446, 252, 253, 254, - /* 610 */ 218, 256, 257, 258, 259, 260, 261, 262, 263, 264, - /* 620 */ 265, 266, 308, 91, 269, 270, 271, 272, 273, 400, - /* 630 */ 254, 499, 277, 278, 279, 280, 281, 282, 283, 284, - /* 640 */ 12, 13, 301, 302, 303, 304, 305, 385, 20, 387, - /* 650 */ 22, 126, 36, 386, 41, 42, 496, 497, 498, 396, - /* 660 */ 528, 267, 472, 400, 36, 402, 38, 284, 401, 286, - /* 670 */ 510, 320, 321, 322, 323, 324, 325, 326, 400, 401, - /* 680 */ 448, 287, 288, 289, 290, 291, 292, 293, 294, 295, - /* 690 */ 296, 159, 386, 68, 462, 430, 68, 430, 191, 71, - /* 700 */ 468, 469, 115, 75, 20, 308, 22, 401, 448, 425, - /* 710 */ 82, 482, 483, 446, 430, 448, 184, 185, 400, 529, - /* 720 */ 36, 284, 115, 12, 13, 14, 115, 537, 468, 469, - /* 730 */ 198, 20, 454, 22, 121, 122, 430, 124, 400, 401, - /* 740 */ 112, 457, 58, 115, 119, 555, 556, 36, 472, 38, - /* 750 */ 560, 561, 446, 477, 448, 490, 491, 514, 145, 516, - /* 760 */ 493, 254, 149, 496, 0, 400, 401, 500, 501, 502, - /* 770 */ 503, 504, 505, 386, 54, 508, 509, 510, 3, 68, - /* 780 */ 152, 153, 71, 63, 517, 420, 66, 67, 521, 522, - /* 790 */ 8, 9, 454, 82, 12, 13, 14, 15, 16, 493, - /* 800 */ 482, 483, 496, 431, 432, 529, 500, 501, 502, 503, - /* 810 */ 504, 505, 506, 537, 508, 509, 510, 511, 512, 191, - /* 820 */ 192, 430, 215, 112, 217, 430, 115, 400, 401, 201, - /* 830 */ 202, 555, 556, 446, 218, 440, 560, 561, 400, 401, - /* 840 */ 449, 77, 78, 79, 216, 36, 218, 420, 84, 85, - /* 850 */ 86, 223, 146, 147, 90, 400, 249, 151, 420, 95, - /* 860 */ 96, 97, 98, 152, 153, 101, 250, 251, 400, 105, - /* 870 */ 106, 107, 108, 145, 146, 147, 148, 149, 150, 151, - /* 880 */ 252, 253, 254, 33, 256, 257, 258, 259, 260, 261, - /* 890 */ 262, 263, 264, 265, 266, 308, 196, 269, 270, 271, - /* 900 */ 272, 273, 191, 192, 23, 277, 278, 279, 280, 281, - /* 910 */ 282, 283, 201, 202, 459, 308, 461, 8, 9, 308, - /* 920 */ 112, 12, 13, 14, 15, 16, 0, 216, 82, 218, - /* 930 */ 49, 50, 464, 465, 223, 127, 128, 129, 130, 131, - /* 940 */ 132, 133, 134, 135, 136, 126, 138, 139, 140, 141, - /* 950 */ 142, 143, 144, 8, 9, 13, 47, 12, 13, 14, - /* 960 */ 15, 16, 386, 252, 253, 254, 116, 256, 257, 258, - /* 970 */ 259, 260, 261, 262, 263, 264, 265, 266, 400, 401, - /* 980 */ 269, 270, 271, 272, 273, 190, 4, 36, 277, 278, - /* 990 */ 279, 280, 281, 282, 283, 12, 13, 22, 420, 425, - /* 1000 */ 514, 19, 516, 20, 430, 22, 400, 401, 386, 400, - /* 1010 */ 401, 36, 400, 401, 314, 315, 316, 317, 478, 36, - /* 1020 */ 38, 38, 446, 401, 82, 116, 420, 218, 472, 420, - /* 1030 */ 386, 457, 420, 82, 8, 9, 54, 20, 12, 13, - /* 1040 */ 14, 15, 16, 61, 62, 430, 400, 401, 386, 267, - /* 1050 */ 68, 68, 430, 438, 71, 22, 20, 82, 22, 250, - /* 1060 */ 251, 116, 267, 401, 449, 82, 420, 431, 446, 36, - /* 1070 */ 448, 145, 146, 147, 148, 149, 150, 151, 12, 13, - /* 1080 */ 400, 401, 287, 400, 401, 529, 20, 112, 22, 0, - /* 1090 */ 446, 409, 430, 537, 58, 112, 114, 34, 115, 116, - /* 1100 */ 420, 119, 36, 420, 38, 330, 1, 2, 446, 427, - /* 1110 */ 448, 555, 556, 47, 407, 493, 560, 561, 496, 437, - /* 1120 */ 386, 430, 500, 501, 502, 503, 504, 505, 492, 421, - /* 1130 */ 508, 509, 510, 44, 68, 152, 153, 71, 430, 517, - /* 1140 */ 2, 434, 116, 521, 522, 112, 8, 9, 82, 441, - /* 1150 */ 12, 13, 14, 15, 16, 493, 400, 401, 496, 400, - /* 1160 */ 401, 0, 500, 501, 502, 503, 504, 505, 400, 401, - /* 1170 */ 508, 509, 510, 22, 191, 192, 420, 431, 112, 420, - /* 1180 */ 446, 115, 491, 20, 201, 202, 431, 36, 420, 400, - /* 1190 */ 401, 216, 430, 218, 400, 401, 400, 401, 407, 216, - /* 1200 */ 438, 218, 400, 401, 38, 0, 223, 59, 60, 420, - /* 1210 */ 193, 449, 550, 551, 420, 424, 420, 14, 152, 153, - /* 1220 */ 54, 116, 420, 20, 20, 434, 52, 252, 253, 63, - /* 1230 */ 64, 65, 66, 82, 68, 252, 253, 254, 0, 256, - /* 1240 */ 257, 258, 259, 260, 261, 262, 263, 264, 265, 266, - /* 1250 */ 447, 448, 269, 270, 271, 272, 273, 191, 192, 54, - /* 1260 */ 277, 278, 279, 280, 281, 282, 283, 201, 202, 8, - /* 1270 */ 9, 254, 20, 12, 13, 14, 15, 16, 400, 401, - /* 1280 */ 114, 426, 216, 146, 218, 119, 8, 9, 430, 223, - /* 1290 */ 12, 13, 14, 15, 16, 8, 9, 421, 420, 12, - /* 1300 */ 13, 14, 15, 16, 8, 9, 430, 449, 12, 13, - /* 1310 */ 14, 15, 16, 400, 401, 405, 406, 441, 252, 253, - /* 1320 */ 254, 430, 256, 257, 258, 259, 260, 261, 262, 263, - /* 1330 */ 264, 265, 266, 420, 47, 269, 270, 271, 272, 273, - /* 1340 */ 449, 22, 487, 277, 278, 279, 280, 281, 282, 283, - /* 1350 */ 12, 13, 186, 400, 401, 36, 193, 4, 20, 386, - /* 1360 */ 22, 195, 386, 386, 386, 199, 200, 193, 231, 232, - /* 1370 */ 386, 205, 206, 420, 36, 386, 38, 116, 204, 401, - /* 1380 */ 386, 403, 386, 145, 146, 147, 148, 149, 150, 151, - /* 1390 */ 224, 386, 8, 9, 116, 191, 12, 13, 14, 15, - /* 1400 */ 16, 14, 15, 16, 386, 244, 68, 416, 430, 71, - /* 1410 */ 419, 513, 116, 386, 516, 386, 386, 254, 499, 446, - /* 1420 */ 82, 20, 446, 446, 446, 386, 448, 405, 406, 0, - /* 1430 */ 446, 112, 499, 12, 13, 446, 386, 472, 414, 415, - /* 1440 */ 446, 20, 446, 22, 430, 414, 415, 528, 20, 443, - /* 1450 */ 112, 446, 446, 115, 13, 441, 145, 36, 254, 38, - /* 1460 */ 149, 528, 8, 9, 446, 126, 12, 13, 14, 15, - /* 1470 */ 16, 493, 33, 446, 496, 446, 446, 33, 500, 501, - /* 1480 */ 502, 503, 504, 505, 431, 446, 508, 509, 510, 68, - /* 1490 */ 152, 153, 71, 515, 529, 517, 446, 389, 390, 521, - /* 1500 */ 522, 47, 537, 82, 443, 443, 254, 446, 446, 431, - /* 1510 */ 8, 9, 0, 33, 12, 13, 14, 15, 16, 180, - /* 1520 */ 555, 556, 418, 82, 33, 560, 561, 47, 120, 191, - /* 1530 */ 192, 123, 120, 112, 120, 123, 115, 123, 47, 201, - /* 1540 */ 202, 33, 8, 9, 13, 33, 12, 13, 14, 15, - /* 1550 */ 16, 75, 120, 13, 216, 123, 218, 0, 8, 9, - /* 1560 */ 0, 223, 12, 13, 14, 15, 16, 36, 234, 33, - /* 1570 */ 236, 33, 0, 152, 153, 33, 36, 33, 33, 22, - /* 1580 */ 387, 472, 22, 0, 155, 152, 153, 458, 33, 33, - /* 1590 */ 252, 253, 254, 553, 256, 257, 258, 259, 260, 261, - /* 1600 */ 262, 263, 264, 265, 266, 22, 0, 269, 270, 271, - /* 1610 */ 272, 273, 191, 192, 531, 277, 278, 279, 280, 281, - /* 1620 */ 282, 283, 201, 202, 116, 36, 33, 55, 22, 33, - /* 1630 */ 1, 2, 33, 12, 13, 33, 33, 216, 529, 218, - /* 1640 */ 33, 33, 51, 22, 223, 36, 537, 33, 564, 33, - /* 1650 */ 116, 472, 116, 33, 116, 254, 228, 36, 116, 38, - /* 1660 */ 116, 116, 546, 310, 555, 556, 116, 532, 33, 560, - /* 1670 */ 561, 116, 116, 252, 253, 254, 33, 256, 257, 258, - /* 1680 */ 259, 260, 261, 262, 263, 264, 265, 266, 404, 68, - /* 1690 */ 269, 270, 271, 272, 273, 193, 12, 13, 277, 278, - /* 1700 */ 279, 280, 281, 282, 283, 18, 115, 20, 529, 116, - /* 1710 */ 12, 13, 116, 33, 27, 116, 537, 30, 116, 116, - /* 1720 */ 12, 13, 18, 116, 116, 38, 33, 23, 252, 33, - /* 1730 */ 116, 430, 116, 33, 555, 556, 116, 12, 13, 560, - /* 1740 */ 561, 54, 33, 56, 417, 417, 42, 43, 61, 62, - /* 1750 */ 46, 116, 12, 13, 12, 13, 12, 13, 36, 116, - /* 1760 */ 73, 57, 12, 13, 12, 13, 12, 13, 12, 13, - /* 1770 */ 115, 332, 117, 69, 70, 71, 72, 73, 334, 13, - /* 1780 */ 13, 399, 458, 36, 552, 552, 552, 471, 552, 458, - /* 1790 */ 404, 494, 401, 445, 479, 458, 116, 557, 458, 536, - /* 1800 */ 536, 114, 36, 36, 82, 523, 539, 218, 458, 116, - /* 1810 */ 311, 419, 116, 126, 473, 54, 116, 495, 20, 115, - /* 1820 */ 400, 20, 489, 233, 409, 116, 484, 218, 484, 82, - /* 1830 */ 475, 409, 214, 20, 400, 47, 401, 216, 455, 218, - /* 1840 */ 455, 401, 190, 400, 157, 158, 452, 160, 161, 162, - /* 1850 */ 163, 164, 165, 166, 167, 168, 169, 401, 154, 172, - /* 1860 */ 173, 174, 175, 176, 177, 178, 179, 386, 181, 182, - /* 1870 */ 183, 250, 251, 252, 187, 188, 189, 400, 455, 452, - /* 1880 */ 413, 194, 401, 452, 403, 113, 111, 412, 452, 400, - /* 1890 */ 269, 270, 400, 110, 411, 400, 400, 400, 277, 278, - /* 1900 */ 279, 280, 281, 282, 20, 52, 393, 397, 393, 484, - /* 1910 */ 409, 430, 208, 209, 210, 397, 409, 213, 20, 448, - /* 1920 */ 409, 20, 402, 20, 474, 409, 402, 446, 409, 448, - /* 1930 */ 226, 227, 20, 465, 409, 20, 409, 459, 409, 400, - /* 1940 */ 393, 409, 389, 239, 430, 393, 242, 430, 386, 245, - /* 1950 */ 246, 247, 248, 249, 400, 389, 430, 237, 430, 115, - /* 1960 */ 430, 488, 20, 401, 221, 403, 484, 430, 446, 446, - /* 1970 */ 486, 430, 407, 430, 493, 222, 430, 496, 386, 430, - /* 1980 */ 480, 500, 501, 502, 503, 504, 505, 483, 430, 508, - /* 1990 */ 509, 510, 430, 401, 446, 403, 515, 400, 517, 448, - /* 2000 */ 319, 407, 521, 522, 545, 545, 318, 446, 446, 327, - /* 2010 */ 448, 548, 308, 207, 481, 545, 547, 543, 329, 328, - /* 2020 */ 307, 535, 430, 544, 312, 306, 336, 542, 534, 466, - /* 2030 */ 466, 565, 473, 331, 333, 401, 20, 126, 446, 309, - /* 2040 */ 448, 473, 402, 540, 538, 407, 559, 466, 558, 407, - /* 2050 */ 446, 446, 466, 199, 407, 493, 446, 446, 496, 446, - /* 2060 */ 459, 386, 500, 501, 502, 503, 504, 505, 499, 446, - /* 2070 */ 508, 509, 510, 407, 115, 463, 401, 515, 403, 517, - /* 2080 */ 199, 459, 446, 521, 522, 493, 460, 520, 496, 426, - /* 2090 */ 407, 386, 500, 501, 502, 503, 504, 505, 401, 407, - /* 2100 */ 508, 509, 510, 446, 446, 430, 401, 515, 403, 517, - /* 2110 */ 446, 446, 115, 521, 522, 446, 446, 446, 446, 446, - /* 2120 */ 446, 446, 446, 448, 446, 446, 400, 22, 407, 388, - /* 2130 */ 35, 446, 446, 37, 40, 430, 391, 476, 392, 423, - /* 2140 */ 446, 446, 435, 394, 393, 446, 492, 432, 384, 446, - /* 2150 */ 432, 446, 446, 448, 423, 423, 446, 446, 0, 0, - /* 2160 */ 446, 0, 485, 408, 47, 0, 36, 243, 493, 36, - /* 2170 */ 36, 496, 36, 243, 0, 500, 501, 502, 503, 504, - /* 2180 */ 505, 36, 36, 508, 509, 510, 243, 36, 386, 0, - /* 2190 */ 515, 467, 517, 0, 467, 243, 521, 522, 493, 0, - /* 2200 */ 36, 496, 0, 401, 36, 500, 501, 502, 503, 504, - /* 2210 */ 505, 0, 22, 508, 509, 510, 0, 36, 12, 13, - /* 2220 */ 515, 238, 517, 0, 224, 0, 521, 522, 22, 224, - /* 2230 */ 218, 386, 430, 225, 216, 0, 0, 0, 212, 211, - /* 2240 */ 0, 0, 36, 158, 38, 51, 401, 51, 446, 36, - /* 2250 */ 448, 0, 0, 0, 36, 54, 0, 0, 51, 47, - /* 2260 */ 0, 0, 0, 0, 0, 51, 0, 0, 0, 386, - /* 2270 */ 0, 0, 0, 176, 68, 430, 176, 0, 36, 0, - /* 2280 */ 0, 0, 0, 0, 401, 0, 0, 0, 82, 0, - /* 2290 */ 0, 446, 0, 448, 0, 493, 0, 0, 496, 0, - /* 2300 */ 0, 0, 500, 501, 502, 503, 504, 505, 0, 51, - /* 2310 */ 508, 509, 510, 430, 0, 0, 47, 515, 112, 517, - /* 2320 */ 0, 0, 0, 521, 522, 0, 0, 0, 0, 446, - /* 2330 */ 0, 448, 22, 0, 158, 0, 157, 0, 493, 156, - /* 2340 */ 0, 496, 0, 52, 0, 500, 501, 502, 503, 504, - /* 2350 */ 505, 22, 68, 508, 509, 510, 22, 52, 0, 36, - /* 2360 */ 515, 68, 517, 0, 0, 0, 521, 522, 0, 0, - /* 2370 */ 68, 68, 36, 54, 36, 44, 493, 0, 54, 496, - /* 2380 */ 33, 14, 386, 500, 501, 502, 503, 504, 505, 44, - /* 2390 */ 36, 508, 509, 510, 44, 54, 0, 401, 515, 0, - /* 2400 */ 517, 44, 36, 47, 521, 522, 51, 0, 0, 0, - /* 2410 */ 51, 51, 0, 0, 0, 45, 44, 44, 0, 0, - /* 2420 */ 0, 0, 216, 0, 218, 51, 430, 207, 76, 51, - /* 2430 */ 36, 44, 0, 54, 36, 54, 44, 0, 36, 54, - /* 2440 */ 0, 44, 446, 54, 448, 44, 36, 0, 0, 386, - /* 2450 */ 0, 0, 0, 0, 0, 22, 22, 125, 252, 253, - /* 2460 */ 36, 36, 36, 36, 401, 36, 123, 36, 22, 0, - /* 2470 */ 0, 36, 36, 56, 36, 269, 270, 36, 36, 386, - /* 2480 */ 36, 22, 33, 277, 278, 279, 280, 281, 282, 493, - /* 2490 */ 33, 36, 496, 430, 401, 22, 500, 501, 502, 503, - /* 2500 */ 504, 505, 0, 22, 508, 509, 510, 0, 22, 446, - /* 2510 */ 36, 448, 0, 517, 0, 0, 36, 521, 522, 0, - /* 2520 */ 36, 0, 0, 430, 36, 22, 20, 36, 36, 36, - /* 2530 */ 0, 116, 223, 229, 228, 0, 36, 115, 51, 446, - /* 2540 */ 22, 448, 193, 115, 193, 0, 22, 199, 0, 0, - /* 2550 */ 3, 313, 36, 33, 115, 193, 493, 52, 115, 496, - /* 2560 */ 52, 36, 33, 500, 501, 502, 503, 504, 505, 1, - /* 2570 */ 33, 508, 509, 510, 203, 193, 193, 116, 203, 116, - /* 2580 */ 219, 115, 111, 116, 386, 113, 493, 19, 33, 496, - /* 2590 */ 51, 116, 115, 500, 501, 502, 503, 504, 505, 401, - /* 2600 */ 33, 508, 509, 510, 115, 386, 38, 51, 313, 115, - /* 2610 */ 517, 116, 115, 82, 116, 522, 33, 36, 3, 115, - /* 2620 */ 401, 53, 54, 36, 33, 562, 563, 116, 430, 116, - /* 2630 */ 313, 63, 64, 65, 66, 386, 68, 36, 36, 36, - /* 2640 */ 36, 36, 116, 116, 446, 51, 448, 33, 51, 430, - /* 2650 */ 401, 0, 0, 115, 44, 0, 116, 116, 115, 115, - /* 2660 */ 196, 115, 44, 0, 44, 446, 116, 448, 200, 115, - /* 2670 */ 33, 113, 196, 297, 195, 285, 113, 2, 22, 430, - /* 2680 */ 115, 115, 114, 51, 115, 51, 115, 119, 115, 470, - /* 2690 */ 116, 493, 116, 115, 496, 446, 116, 448, 500, 501, - /* 2700 */ 502, 503, 504, 505, 115, 507, 508, 509, 510, 116, - /* 2710 */ 252, 115, 493, 115, 115, 496, 22, 255, 150, 500, - /* 2720 */ 501, 502, 503, 504, 505, 386, 115, 508, 509, 510, - /* 2730 */ 0, 115, 115, 44, 115, 0, 22, 116, 115, 115, - /* 2740 */ 401, 51, 493, 117, 115, 496, 118, 196, 115, 500, - /* 2750 */ 501, 502, 503, 504, 505, 115, 115, 508, 509, 510, - /* 2760 */ 116, 115, 126, 195, 22, 197, 386, 36, 200, 430, - /* 2770 */ 116, 229, 36, 205, 115, 36, 116, 115, 33, 137, - /* 2780 */ 116, 401, 36, 116, 36, 446, 116, 448, 36, 116, - /* 2790 */ 36, 115, 224, 115, 137, 137, 36, 115, 137, 22, - /* 2800 */ 551, 76, 75, 22, 36, 36, 36, 36, 36, 470, - /* 2810 */ 430, 36, 36, 109, 36, 36, 36, 109, 36, 82, - /* 2820 */ 82, 33, 36, 36, 22, 36, 446, 36, 448, 36, - /* 2830 */ 36, 386, 493, 82, 36, 496, 36, 36, 0, 500, - /* 2840 */ 501, 502, 503, 504, 505, 36, 401, 508, 509, 510, - /* 2850 */ 470, 386, 36, 22, 36, 36, 44, 54, 0, 36, - /* 2860 */ 54, 44, 0, 0, 36, 54, 401, 54, 44, 36, - /* 2870 */ 44, 386, 0, 493, 0, 430, 496, 36, 22, 36, - /* 2880 */ 500, 501, 502, 503, 504, 505, 401, 0, 508, 509, - /* 2890 */ 510, 446, 22, 448, 33, 430, 36, 22, 21, 21, - /* 2900 */ 36, 22, 22, 20, 566, 566, 566, 566, 566, 566, - /* 2910 */ 566, 446, 566, 448, 566, 430, 566, 566, 566, 566, - /* 2920 */ 566, 566, 566, 566, 566, 566, 566, 566, 566, 566, - /* 2930 */ 566, 446, 566, 448, 566, 566, 566, 566, 493, 566, - /* 2940 */ 566, 496, 566, 566, 566, 500, 501, 502, 503, 504, - /* 2950 */ 505, 566, 566, 508, 509, 510, 386, 566, 493, 566, - /* 2960 */ 566, 496, 566, 566, 566, 500, 501, 502, 503, 504, - /* 2970 */ 505, 401, 566, 508, 509, 510, 386, 566, 493, 566, - /* 2980 */ 566, 496, 566, 566, 566, 500, 501, 502, 503, 504, - /* 2990 */ 505, 401, 566, 508, 509, 510, 566, 512, 566, 554, - /* 3000 */ 430, 566, 566, 566, 566, 566, 566, 566, 566, 566, - /* 3010 */ 566, 566, 566, 566, 566, 566, 446, 566, 448, 566, - /* 3020 */ 430, 566, 566, 566, 566, 566, 566, 566, 563, 566, - /* 3030 */ 566, 566, 566, 566, 566, 566, 446, 566, 448, 566, - /* 3040 */ 470, 566, 566, 566, 566, 566, 566, 566, 566, 566, - /* 3050 */ 566, 566, 386, 566, 566, 566, 566, 566, 566, 566, - /* 3060 */ 470, 566, 566, 493, 566, 566, 496, 401, 566, 566, - /* 3070 */ 500, 501, 502, 503, 504, 505, 566, 566, 508, 509, - /* 3080 */ 510, 566, 566, 493, 566, 566, 496, 566, 386, 566, - /* 3090 */ 500, 501, 502, 503, 504, 505, 430, 566, 508, 509, - /* 3100 */ 510, 566, 566, 401, 566, 566, 566, 566, 566, 566, - /* 3110 */ 566, 566, 446, 566, 448, 566, 566, 566, 566, 566, - /* 3120 */ 566, 566, 566, 566, 566, 566, 566, 566, 566, 386, - /* 3130 */ 566, 566, 430, 566, 566, 566, 470, 566, 566, 566, - /* 3140 */ 566, 566, 566, 566, 401, 566, 566, 566, 446, 566, - /* 3150 */ 448, 566, 566, 566, 566, 566, 566, 566, 566, 493, - /* 3160 */ 566, 566, 496, 566, 566, 566, 500, 501, 502, 503, - /* 3170 */ 504, 505, 470, 430, 508, 509, 510, 566, 566, 566, - /* 3180 */ 566, 566, 566, 566, 566, 566, 566, 566, 566, 446, - /* 3190 */ 566, 448, 566, 566, 566, 493, 566, 566, 496, 566, - /* 3200 */ 566, 566, 500, 501, 502, 503, 504, 505, 566, 566, - /* 3210 */ 508, 509, 510, 386, 566, 566, 566, 566, 566, 566, - /* 3220 */ 566, 566, 566, 566, 566, 566, 566, 566, 401, 566, - /* 3230 */ 566, 566, 566, 566, 386, 566, 493, 566, 566, 496, - /* 3240 */ 566, 566, 566, 500, 501, 502, 503, 504, 505, 401, - /* 3250 */ 566, 508, 509, 510, 566, 566, 566, 430, 566, 566, - /* 3260 */ 566, 566, 386, 566, 566, 566, 566, 566, 566, 566, - /* 3270 */ 566, 566, 566, 446, 566, 448, 566, 401, 430, 566, - /* 3280 */ 566, 566, 566, 566, 566, 566, 566, 566, 566, 566, - /* 3290 */ 566, 566, 566, 566, 446, 566, 448, 566, 566, 566, - /* 3300 */ 566, 566, 386, 566, 566, 566, 430, 566, 566, 566, - /* 3310 */ 566, 566, 566, 566, 566, 566, 566, 401, 566, 566, - /* 3320 */ 493, 566, 446, 496, 448, 566, 566, 500, 501, 502, - /* 3330 */ 503, 504, 505, 566, 566, 508, 509, 510, 566, 566, - /* 3340 */ 566, 493, 566, 566, 496, 386, 430, 566, 500, 501, - /* 3350 */ 502, 503, 504, 505, 566, 566, 508, 509, 510, 566, - /* 3360 */ 401, 566, 446, 566, 448, 566, 566, 566, 566, 493, - /* 3370 */ 566, 566, 496, 566, 566, 566, 500, 501, 502, 503, - /* 3380 */ 504, 505, 566, 566, 508, 509, 510, 386, 566, 430, - /* 3390 */ 566, 566, 566, 566, 566, 566, 566, 566, 566, 566, - /* 3400 */ 566, 566, 401, 566, 566, 446, 566, 448, 566, 493, - /* 3410 */ 566, 566, 496, 566, 566, 566, 500, 501, 502, 503, - /* 3420 */ 504, 505, 566, 566, 508, 509, 510, 386, 566, 566, - /* 3430 */ 566, 430, 566, 566, 566, 566, 566, 566, 566, 566, - /* 3440 */ 566, 566, 401, 566, 566, 566, 566, 446, 566, 448, - /* 3450 */ 566, 566, 493, 566, 566, 496, 566, 566, 566, 500, - /* 3460 */ 501, 502, 503, 504, 505, 566, 566, 508, 509, 510, - /* 3470 */ 386, 430, 566, 566, 566, 566, 566, 566, 566, 566, - /* 3480 */ 566, 566, 566, 566, 566, 401, 566, 446, 566, 448, - /* 3490 */ 566, 566, 566, 566, 493, 566, 566, 496, 566, 566, - /* 3500 */ 566, 500, 501, 502, 503, 504, 505, 566, 566, 508, - /* 3510 */ 509, 510, 566, 566, 430, 566, 386, 566, 566, 566, - /* 3520 */ 566, 566, 566, 566, 566, 566, 566, 566, 566, 566, - /* 3530 */ 446, 401, 448, 566, 493, 566, 566, 496, 566, 566, - /* 3540 */ 566, 500, 501, 502, 503, 504, 505, 566, 566, 508, - /* 3550 */ 509, 510, 566, 386, 566, 566, 566, 566, 566, 566, - /* 3560 */ 430, 566, 566, 566, 566, 566, 566, 566, 401, 566, - /* 3570 */ 566, 566, 566, 566, 566, 566, 446, 493, 448, 566, - /* 3580 */ 496, 566, 566, 566, 500, 501, 502, 503, 504, 505, - /* 3590 */ 566, 566, 508, 509, 510, 566, 566, 430, 566, 386, - /* 3600 */ 566, 566, 566, 566, 566, 566, 566, 566, 566, 566, - /* 3610 */ 566, 566, 566, 446, 401, 448, 566, 566, 566, 566, - /* 3620 */ 566, 386, 566, 493, 566, 566, 496, 566, 566, 566, - /* 3630 */ 500, 501, 502, 503, 504, 505, 401, 566, 508, 509, - /* 3640 */ 510, 566, 566, 430, 566, 566, 566, 566, 566, 566, - /* 3650 */ 566, 566, 566, 566, 566, 566, 566, 566, 566, 446, - /* 3660 */ 493, 448, 566, 496, 386, 430, 566, 500, 501, 502, - /* 3670 */ 503, 504, 505, 566, 566, 508, 509, 510, 566, 401, - /* 3680 */ 566, 446, 566, 448, 566, 566, 566, 566, 566, 386, - /* 3690 */ 566, 566, 566, 566, 566, 566, 566, 566, 566, 566, - /* 3700 */ 566, 566, 566, 566, 401, 566, 493, 566, 430, 496, - /* 3710 */ 386, 566, 566, 500, 501, 502, 503, 504, 505, 566, - /* 3720 */ 566, 508, 509, 510, 446, 401, 448, 566, 493, 566, - /* 3730 */ 566, 496, 386, 430, 566, 500, 501, 502, 503, 504, - /* 3740 */ 505, 566, 566, 508, 509, 510, 566, 401, 566, 446, - /* 3750 */ 566, 448, 566, 566, 430, 566, 566, 566, 566, 566, - /* 3760 */ 566, 566, 566, 566, 566, 566, 566, 566, 566, 566, - /* 3770 */ 446, 493, 448, 566, 496, 566, 430, 566, 500, 501, - /* 3780 */ 502, 503, 504, 505, 566, 566, 508, 509, 510, 566, - /* 3790 */ 566, 566, 446, 566, 448, 566, 493, 566, 566, 496, - /* 3800 */ 566, 566, 566, 500, 501, 502, 503, 504, 505, 566, - /* 3810 */ 566, 508, 509, 510, 566, 566, 566, 493, 566, 566, - /* 3820 */ 496, 566, 566, 566, 500, 501, 502, 503, 504, 505, - /* 3830 */ 566, 566, 508, 509, 510, 566, 566, 566, 566, 493, - /* 3840 */ 566, 566, 496, 566, 566, 566, 500, 501, 502, 503, - /* 3850 */ 504, 505, 566, 566, 508, 509, 510, 386, 566, 566, - /* 3860 */ 566, 566, 566, 566, 566, 566, 566, 566, 566, 566, - /* 3870 */ 566, 566, 401, 566, 566, 566, 386, 566, 566, 566, - /* 3880 */ 566, 566, 566, 566, 566, 566, 566, 566, 566, 566, - /* 3890 */ 566, 401, 566, 566, 566, 566, 386, 566, 566, 566, - /* 3900 */ 566, 430, 566, 566, 566, 566, 566, 566, 566, 566, - /* 3910 */ 566, 401, 566, 566, 566, 566, 566, 446, 566, 448, - /* 3920 */ 430, 566, 566, 566, 566, 566, 566, 566, 566, 566, - /* 3930 */ 566, 566, 566, 566, 566, 566, 446, 566, 448, 566, - /* 3940 */ 430, 566, 566, 566, 566, 566, 566, 566, 566, 566, - /* 3950 */ 566, 566, 566, 566, 566, 566, 446, 566, 448, 566, - /* 3960 */ 566, 566, 566, 386, 493, 566, 566, 496, 566, 566, - /* 3970 */ 566, 500, 501, 502, 503, 504, 505, 566, 401, 508, - /* 3980 */ 509, 510, 566, 493, 566, 566, 496, 566, 566, 566, - /* 3990 */ 500, 501, 502, 503, 504, 505, 566, 566, 508, 509, - /* 4000 */ 510, 386, 566, 493, 566, 566, 496, 430, 566, 566, - /* 4010 */ 500, 501, 502, 503, 504, 505, 401, 566, 508, 509, - /* 4020 */ 510, 566, 566, 446, 566, 448, 566, 566, 566, 566, - /* 4030 */ 566, 566, 566, 566, 566, 566, 566, 566, 566, 566, - /* 4040 */ 566, 566, 566, 566, 566, 430, 566, 386, 566, 566, - /* 4050 */ 566, 566, 566, 566, 566, 566, 566, 566, 566, 566, - /* 4060 */ 566, 446, 401, 448, 566, 566, 566, 566, 386, 566, - /* 4070 */ 493, 566, 566, 496, 566, 566, 566, 500, 501, 502, - /* 4080 */ 503, 504, 505, 401, 566, 508, 509, 510, 566, 566, - /* 4090 */ 566, 430, 566, 566, 566, 566, 566, 566, 566, 566, - /* 4100 */ 566, 566, 566, 566, 566, 566, 566, 446, 493, 448, - /* 4110 */ 566, 496, 430, 566, 566, 500, 501, 502, 503, 504, - /* 4120 */ 505, 566, 566, 508, 509, 510, 566, 566, 446, 566, - /* 4130 */ 448, 566, 566, 566, 566, 566, 386, 566, 566, 566, - /* 4140 */ 566, 566, 566, 566, 566, 566, 566, 566, 566, 566, - /* 4150 */ 566, 401, 566, 566, 493, 566, 566, 496, 386, 566, - /* 4160 */ 566, 500, 501, 502, 503, 504, 505, 566, 566, 508, - /* 4170 */ 509, 510, 566, 401, 566, 493, 566, 566, 496, 386, - /* 4180 */ 430, 566, 500, 501, 502, 503, 504, 505, 566, 566, - /* 4190 */ 508, 509, 510, 566, 401, 566, 446, 566, 448, 566, - /* 4200 */ 566, 566, 430, 566, 386, 566, 566, 566, 566, 566, - /* 4210 */ 566, 566, 566, 566, 566, 566, 566, 566, 446, 401, - /* 4220 */ 448, 566, 566, 430, 566, 566, 566, 566, 566, 566, - /* 4230 */ 566, 566, 566, 566, 566, 566, 566, 566, 566, 446, - /* 4240 */ 566, 448, 566, 493, 566, 566, 496, 566, 430, 566, - /* 4250 */ 500, 501, 502, 503, 504, 505, 566, 566, 508, 509, - /* 4260 */ 510, 566, 566, 566, 446, 493, 448, 566, 496, 566, - /* 4270 */ 566, 566, 500, 501, 502, 503, 504, 505, 566, 566, - /* 4280 */ 508, 509, 510, 566, 566, 566, 493, 566, 566, 496, - /* 4290 */ 566, 566, 566, 500, 501, 502, 503, 504, 505, 566, - /* 4300 */ 566, 508, 509, 510, 566, 566, 566, 566, 566, 566, - /* 4310 */ 566, 493, 566, 566, 496, 566, 566, 566, 500, 501, - /* 4320 */ 502, 503, 504, 505, 566, 386, 508, 509, 510, 566, - /* 4330 */ 566, 566, 566, 566, 566, 566, 566, 566, 566, 566, - /* 4340 */ 401, 566, 566, 566, 566, 386, 566, 566, 566, 566, - /* 4350 */ 566, 566, 566, 566, 566, 566, 566, 566, 566, 566, - /* 4360 */ 401, 566, 566, 566, 566, 566, 566, 566, 566, 430, - /* 4370 */ 566, 566, 566, 566, 566, 566, 566, 566, 566, 566, - /* 4380 */ 566, 566, 566, 566, 566, 446, 566, 448, 566, 430, - /* 4390 */ 566, 566, 566, 566, 566, 566, 566, 566, 566, 566, - /* 4400 */ 566, 566, 566, 566, 566, 446, 566, 448, 566, 566, - /* 4410 */ 566, 566, 566, 566, 566, 566, 566, 566, 566, 566, - /* 4420 */ 566, 566, 566, 566, 566, 566, 566, 566, 566, 566, - /* 4430 */ 566, 566, 493, 566, 566, 496, 566, 566, 566, 500, - /* 4440 */ 501, 502, 503, 504, 505, 566, 566, 508, 509, 510, - /* 4450 */ 566, 566, 493, 566, 566, 496, 566, 566, 566, 500, - /* 4460 */ 501, 502, 503, 504, 505, 566, 566, 508, 509, 510, - /* 4470 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, - /* 4480 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, - /* 4490 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, - /* 4500 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, - /* 4510 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, - /* 4520 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, - /* 4530 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, - /* 4540 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, - /* 4550 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, - /* 4560 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, - /* 4570 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, - /* 4580 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, - /* 4590 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, - /* 4600 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, - /* 4610 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, - /* 4620 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, - /* 4630 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, - /* 4640 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, - /* 4650 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, - /* 4660 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, - /* 4670 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, - /* 4680 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, - /* 4690 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, - /* 4700 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, - /* 4710 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, - /* 4720 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, - /* 4730 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, - /* 4740 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, - /* 4750 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, - /* 4760 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, - /* 4770 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, - /* 4780 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, - /* 4790 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, - /* 4800 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, - /* 4810 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, - /* 4820 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, - /* 4830 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, - /* 4840 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, - /* 4850 */ 383, 383, 383, + /* 0 */ 519, 520, 425, 0, 473, 400, 401, 383, 431, 478, + /* 10 */ 426, 425, 12, 13, 431, 395, 473, 431, 398, 399, + /* 20 */ 20, 0, 22, 440, 441, 8, 9, 20, 14, 12, + /* 30 */ 13, 14, 15, 16, 20, 458, 36, 0, 38, 0, + /* 40 */ 386, 0, 21, 432, 458, 24, 25, 26, 27, 28, + /* 50 */ 29, 30, 31, 32, 443, 401, 449, 54, 8, 9, + /* 60 */ 455, 530, 12, 13, 14, 15, 16, 4, 68, 538, + /* 70 */ 463, 71, 488, 530, 491, 492, 469, 470, 410, 400, + /* 80 */ 401, 538, 82, 33, 22, 431, 418, 556, 557, 12, + /* 90 */ 13, 395, 561, 562, 398, 399, 55, 473, 36, 556, + /* 100 */ 557, 447, 478, 449, 561, 562, 434, 41, 42, 437, + /* 110 */ 473, 20, 112, 36, 20, 115, 77, 78, 79, 80, + /* 120 */ 81, 500, 83, 84, 85, 86, 87, 88, 89, 90, + /* 130 */ 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, + /* 140 */ 101, 102, 103, 104, 105, 106, 107, 108, 494, 401, + /* 150 */ 529, 497, 152, 153, 530, 501, 502, 503, 504, 505, + /* 160 */ 506, 407, 538, 509, 510, 511, 116, 530, 430, 497, + /* 170 */ 516, 20, 518, 68, 112, 538, 522, 523, 115, 431, + /* 180 */ 556, 557, 386, 511, 446, 561, 562, 121, 122, 435, + /* 190 */ 124, 191, 192, 556, 557, 431, 542, 401, 561, 562, + /* 200 */ 44, 201, 202, 439, 550, 526, 527, 528, 171, 530, + /* 210 */ 531, 145, 20, 176, 450, 149, 216, 538, 218, 114, + /* 220 */ 20, 184, 407, 223, 119, 8, 9, 431, 21, 12, + /* 230 */ 13, 14, 15, 16, 422, 556, 557, 20, 426, 424, + /* 240 */ 561, 562, 400, 447, 37, 449, 39, 40, 41, 42, + /* 250 */ 435, 503, 252, 253, 254, 4, 256, 257, 258, 259, + /* 260 */ 260, 261, 262, 263, 264, 265, 266, 400, 401, 269, + /* 270 */ 270, 271, 272, 273, 274, 275, 276, 277, 278, 279, + /* 280 */ 280, 281, 282, 283, 12, 13, 14, 420, 386, 20, + /* 290 */ 494, 186, 20, 497, 22, 218, 429, 501, 502, 503, + /* 300 */ 504, 505, 506, 401, 36, 509, 510, 511, 36, 449, + /* 310 */ 38, 155, 516, 432, 518, 115, 8, 9, 522, 523, + /* 320 */ 12, 13, 14, 15, 16, 483, 484, 386, 400, 469, + /* 330 */ 470, 8, 9, 431, 115, 12, 13, 14, 15, 16, + /* 340 */ 68, 20, 401, 71, 152, 153, 550, 75, 254, 447, + /* 350 */ 82, 449, 400, 401, 82, 21, 400, 401, 24, 25, + /* 360 */ 26, 27, 28, 29, 30, 31, 32, 12, 13, 20, + /* 370 */ 530, 308, 431, 155, 493, 20, 420, 22, 538, 451, + /* 380 */ 452, 431, 454, 75, 112, 457, 117, 115, 447, 439, + /* 390 */ 449, 36, 190, 38, 432, 433, 494, 557, 20, 497, + /* 400 */ 450, 561, 562, 501, 502, 503, 504, 505, 506, 507, + /* 410 */ 193, 509, 510, 511, 512, 513, 145, 146, 147, 148, + /* 420 */ 149, 150, 151, 68, 152, 153, 71, 20, 434, 22, + /* 430 */ 75, 400, 401, 125, 215, 494, 217, 82, 497, 116, + /* 440 */ 448, 449, 501, 502, 503, 504, 505, 506, 36, 155, + /* 450 */ 509, 510, 511, 297, 298, 299, 300, 301, 302, 303, + /* 460 */ 304, 305, 115, 191, 192, 58, 0, 112, 249, 267, + /* 470 */ 115, 254, 44, 201, 202, 14, 74, 525, 526, 527, + /* 480 */ 528, 20, 530, 531, 400, 401, 455, 36, 216, 287, + /* 490 */ 218, 497, 551, 552, 252, 223, 68, 54, 190, 301, + /* 500 */ 302, 303, 304, 305, 420, 511, 63, 152, 153, 66, + /* 510 */ 67, 20, 532, 429, 534, 297, 298, 299, 300, 301, + /* 520 */ 302, 303, 304, 305, 252, 253, 254, 308, 256, 257, + /* 530 */ 258, 259, 260, 261, 262, 263, 264, 265, 266, 196, + /* 540 */ 74, 269, 270, 271, 272, 273, 191, 192, 74, 277, + /* 550 */ 278, 279, 280, 281, 282, 283, 201, 202, 0, 20, + /* 560 */ 449, 310, 320, 321, 322, 323, 324, 325, 326, 191, + /* 570 */ 192, 216, 115, 218, 463, 267, 59, 60, 223, 431, + /* 580 */ 469, 470, 24, 25, 26, 27, 28, 29, 30, 31, + /* 590 */ 32, 268, 298, 299, 300, 287, 288, 289, 290, 291, + /* 600 */ 292, 293, 294, 295, 296, 3, 458, 252, 253, 254, + /* 610 */ 126, 256, 257, 258, 259, 260, 261, 262, 263, 264, + /* 620 */ 265, 266, 20, 20, 269, 270, 271, 272, 273, 20, + /* 630 */ 218, 22, 277, 278, 279, 280, 281, 282, 283, 284, + /* 640 */ 12, 13, 145, 152, 153, 36, 149, 400, 20, 73, + /* 650 */ 22, 284, 191, 386, 115, 308, 112, 314, 315, 316, + /* 660 */ 317, 417, 250, 251, 36, 20, 38, 58, 401, 218, + /* 670 */ 403, 127, 128, 129, 130, 131, 132, 133, 134, 135, + /* 680 */ 136, 431, 138, 139, 140, 141, 142, 143, 144, 386, + /* 690 */ 82, 447, 201, 202, 20, 385, 68, 387, 431, 71, + /* 700 */ 450, 250, 251, 75, 401, 12, 13, 14, 15, 16, + /* 710 */ 82, 431, 465, 466, 447, 254, 449, 34, 116, 439, + /* 720 */ 284, 417, 286, 12, 13, 14, 400, 530, 400, 401, + /* 730 */ 450, 20, 396, 22, 431, 538, 400, 431, 402, 14, + /* 740 */ 112, 497, 498, 115, 515, 20, 517, 36, 420, 38, + /* 750 */ 447, 447, 449, 556, 557, 511, 450, 126, 561, 562, + /* 760 */ 115, 494, 147, 431, 497, 308, 151, 530, 501, 502, + /* 770 */ 503, 504, 505, 506, 442, 538, 509, 510, 511, 68, + /* 780 */ 152, 153, 71, 516, 33, 518, 460, 211, 462, 522, + /* 790 */ 523, 400, 401, 82, 557, 193, 193, 494, 561, 562, + /* 800 */ 497, 497, 498, 499, 501, 502, 503, 504, 505, 506, + /* 810 */ 530, 420, 509, 510, 511, 511, 240, 241, 538, 191, + /* 820 */ 192, 445, 0, 112, 448, 449, 115, 8, 9, 201, + /* 830 */ 202, 12, 13, 14, 15, 16, 556, 557, 146, 147, + /* 840 */ 225, 561, 562, 151, 216, 230, 218, 308, 233, 400, + /* 850 */ 235, 223, 421, 8, 9, 33, 386, 12, 13, 14, + /* 860 */ 15, 16, 431, 152, 153, 191, 563, 564, 434, 22, + /* 870 */ 8, 9, 52, 442, 12, 13, 14, 15, 16, 432, + /* 880 */ 252, 253, 254, 36, 256, 257, 258, 259, 260, 261, + /* 890 */ 262, 263, 264, 265, 266, 400, 401, 269, 270, 271, + /* 900 */ 272, 273, 191, 192, 432, 277, 278, 279, 280, 281, + /* 910 */ 282, 283, 201, 202, 0, 420, 191, 447, 8, 9, + /* 920 */ 112, 20, 12, 13, 14, 15, 16, 216, 254, 218, + /* 930 */ 146, 497, 483, 484, 223, 127, 128, 129, 130, 131, + /* 940 */ 132, 133, 134, 135, 136, 511, 138, 139, 140, 141, + /* 950 */ 142, 143, 144, 308, 400, 401, 396, 47, 44, 112, + /* 960 */ 400, 116, 402, 252, 253, 254, 4, 256, 257, 258, + /* 970 */ 259, 260, 261, 262, 263, 264, 265, 266, 116, 254, + /* 980 */ 269, 270, 271, 272, 273, 23, 400, 401, 277, 278, + /* 990 */ 279, 280, 281, 282, 283, 12, 13, 515, 91, 517, + /* 1000 */ 22, 431, 386, 20, 68, 22, 420, 23, 386, 386, + /* 1010 */ 48, 49, 50, 193, 36, 231, 232, 400, 401, 36, + /* 1020 */ 432, 38, 431, 401, 204, 403, 116, 208, 77, 78, + /* 1030 */ 79, 440, 441, 49, 50, 84, 85, 86, 14, 15, + /* 1040 */ 16, 90, 0, 3, 400, 401, 95, 96, 97, 98, + /* 1050 */ 386, 68, 101, 431, 71, 119, 105, 106, 107, 108, + /* 1060 */ 82, 491, 492, 447, 420, 82, 159, 400, 401, 447, + /* 1070 */ 447, 449, 455, 400, 401, 432, 400, 401, 12, 13, + /* 1080 */ 526, 527, 528, 332, 530, 531, 20, 420, 22, 409, + /* 1090 */ 112, 184, 185, 420, 193, 112, 420, 431, 115, 116, + /* 1100 */ 400, 401, 36, 22, 38, 198, 386, 4, 428, 400, + /* 1110 */ 401, 447, 386, 47, 13, 479, 494, 36, 438, 497, + /* 1120 */ 420, 386, 19, 501, 502, 503, 504, 505, 506, 420, + /* 1130 */ 432, 509, 510, 511, 68, 152, 153, 71, 516, 20, + /* 1140 */ 518, 38, 400, 401, 522, 523, 400, 401, 82, 400, + /* 1150 */ 401, 0, 400, 401, 335, 254, 432, 54, 492, 400, + /* 1160 */ 401, 0, 420, 82, 61, 62, 420, 447, 386, 420, + /* 1170 */ 431, 68, 420, 447, 191, 192, 421, 386, 112, 420, + /* 1180 */ 441, 115, 447, 82, 201, 202, 431, 145, 146, 147, + /* 1190 */ 148, 149, 150, 151, 216, 416, 218, 442, 419, 216, + /* 1200 */ 13, 218, 0, 8, 9, 20, 223, 12, 13, 14, + /* 1210 */ 15, 16, 400, 401, 400, 401, 0, 114, 152, 153, + /* 1220 */ 8, 9, 119, 36, 12, 13, 14, 15, 16, 447, + /* 1230 */ 252, 253, 420, 418, 420, 252, 253, 254, 447, 256, + /* 1240 */ 257, 258, 259, 260, 261, 262, 263, 264, 265, 266, + /* 1250 */ 1, 2, 269, 270, 271, 272, 273, 191, 192, 47, + /* 1260 */ 277, 278, 279, 280, 281, 282, 283, 201, 202, 8, + /* 1270 */ 9, 400, 401, 12, 13, 14, 15, 16, 387, 77, + /* 1280 */ 78, 79, 216, 20, 218, 409, 84, 85, 86, 223, + /* 1290 */ 33, 420, 90, 400, 401, 400, 401, 95, 96, 97, + /* 1300 */ 98, 405, 406, 101, 47, 386, 155, 105, 106, 107, + /* 1310 */ 108, 116, 193, 420, 438, 420, 405, 406, 252, 253, + /* 1320 */ 254, 170, 256, 257, 258, 259, 260, 261, 262, 263, + /* 1330 */ 264, 265, 266, 431, 459, 269, 270, 271, 272, 273, + /* 1340 */ 500, 439, 386, 277, 278, 279, 280, 281, 282, 283, + /* 1350 */ 12, 13, 450, 414, 415, 414, 415, 186, 20, 38, + /* 1360 */ 22, 444, 532, 386, 447, 116, 447, 386, 500, 529, + /* 1370 */ 330, 155, 473, 254, 36, 54, 38, 116, 401, 514, + /* 1380 */ 403, 386, 517, 386, 63, 64, 65, 66, 2, 68, + /* 1390 */ 386, 220, 36, 386, 8, 9, 13, 529, 12, 13, + /* 1400 */ 14, 15, 16, 447, 2, 244, 68, 33, 431, 71, + /* 1410 */ 8, 9, 386, 431, 12, 13, 14, 15, 16, 14, + /* 1420 */ 82, 47, 400, 401, 447, 20, 449, 20, 447, 530, + /* 1430 */ 389, 390, 450, 12, 13, 114, 386, 538, 82, 254, + /* 1440 */ 119, 20, 447, 22, 447, 386, 444, 565, 33, 447, + /* 1450 */ 112, 447, 33, 115, 447, 556, 557, 36, 473, 38, + /* 1460 */ 561, 562, 8, 9, 75, 82, 12, 13, 14, 15, + /* 1470 */ 16, 494, 444, 447, 497, 447, 33, 33, 501, 502, + /* 1480 */ 503, 504, 505, 506, 126, 33, 509, 510, 511, 68, + /* 1490 */ 152, 153, 71, 516, 234, 518, 236, 447, 120, 522, + /* 1500 */ 523, 123, 13, 82, 8, 9, 447, 186, 12, 13, + /* 1510 */ 14, 15, 16, 152, 153, 530, 195, 254, 36, 120, + /* 1520 */ 199, 200, 123, 538, 554, 36, 205, 206, 404, 191, + /* 1530 */ 192, 116, 120, 112, 120, 123, 115, 123, 180, 201, + /* 1540 */ 202, 556, 557, 47, 0, 224, 561, 562, 526, 527, + /* 1550 */ 528, 33, 530, 531, 216, 33, 218, 33, 13, 116, + /* 1560 */ 116, 223, 1, 2, 82, 33, 22, 0, 116, 533, + /* 1570 */ 116, 431, 33, 152, 153, 33, 33, 36, 51, 8, + /* 1580 */ 9, 36, 33, 12, 13, 14, 15, 16, 0, 22, + /* 1590 */ 252, 253, 254, 33, 256, 257, 258, 259, 260, 261, + /* 1600 */ 262, 263, 264, 265, 266, 0, 33, 269, 270, 271, + /* 1610 */ 272, 273, 191, 192, 0, 277, 278, 279, 280, 281, + /* 1620 */ 282, 283, 201, 202, 8, 9, 36, 22, 12, 13, + /* 1630 */ 14, 15, 16, 33, 116, 228, 22, 216, 116, 218, + /* 1640 */ 116, 252, 115, 33, 223, 33, 8, 9, 116, 547, + /* 1650 */ 12, 13, 14, 15, 16, 116, 8, 9, 116, 116, + /* 1660 */ 12, 13, 14, 15, 16, 116, 12, 13, 417, 33, + /* 1670 */ 12, 13, 33, 252, 253, 254, 116, 256, 257, 258, + /* 1680 */ 259, 260, 261, 262, 263, 264, 265, 266, 33, 116, + /* 1690 */ 269, 270, 271, 272, 273, 12, 13, 13, 277, 278, + /* 1700 */ 279, 280, 281, 282, 283, 18, 386, 20, 12, 13, + /* 1710 */ 33, 12, 13, 33, 27, 473, 116, 30, 12, 13, + /* 1720 */ 36, 401, 18, 33, 33, 38, 116, 23, 116, 12, + /* 1730 */ 13, 417, 116, 145, 146, 147, 148, 149, 150, 151, + /* 1740 */ 115, 54, 117, 56, 33, 33, 42, 43, 61, 62, + /* 1750 */ 46, 431, 116, 334, 116, 116, 12, 13, 399, 218, + /* 1760 */ 73, 57, 12, 13, 193, 12, 13, 447, 459, 449, + /* 1770 */ 36, 116, 530, 69, 70, 71, 72, 73, 12, 13, + /* 1780 */ 538, 553, 553, 553, 472, 553, 459, 495, 404, 401, + /* 1790 */ 446, 480, 459, 116, 459, 537, 116, 558, 556, 557, + /* 1800 */ 524, 114, 537, 561, 562, 459, 116, 116, 218, 540, + /* 1810 */ 419, 311, 54, 126, 494, 474, 82, 497, 496, 115, + /* 1820 */ 20, 501, 502, 503, 504, 505, 506, 116, 116, 509, + /* 1830 */ 510, 511, 400, 20, 514, 485, 516, 517, 518, 233, + /* 1840 */ 409, 490, 522, 523, 157, 158, 409, 160, 161, 162, + /* 1850 */ 163, 164, 165, 166, 167, 168, 169, 485, 154, 172, + /* 1860 */ 173, 174, 175, 176, 177, 178, 179, 214, 181, 182, + /* 1870 */ 183, 476, 400, 386, 187, 188, 189, 20, 401, 47, + /* 1880 */ 456, 194, 401, 456, 190, 400, 453, 401, 401, 113, + /* 1890 */ 403, 400, 456, 453, 453, 453, 413, 111, 400, 400, + /* 1900 */ 412, 110, 400, 411, 400, 400, 20, 393, 52, 397, + /* 1910 */ 393, 485, 208, 209, 210, 267, 397, 213, 431, 409, + /* 1920 */ 409, 20, 449, 20, 409, 402, 20, 402, 475, 409, + /* 1930 */ 226, 227, 20, 466, 447, 409, 449, 409, 20, 460, + /* 1940 */ 409, 386, 409, 239, 52, 409, 242, 400, 427, 245, + /* 1950 */ 246, 247, 248, 249, 389, 393, 401, 427, 403, 400, + /* 1960 */ 431, 389, 393, 447, 237, 431, 431, 489, 431, 431, + /* 1970 */ 115, 431, 20, 407, 222, 485, 221, 431, 484, 386, + /* 1980 */ 487, 494, 431, 431, 497, 431, 431, 431, 501, 502, + /* 1990 */ 503, 504, 505, 506, 401, 447, 509, 510, 511, 407, + /* 2000 */ 447, 400, 447, 516, 449, 518, 386, 449, 319, 522, + /* 2010 */ 523, 447, 308, 318, 546, 546, 207, 312, 548, 327, + /* 2020 */ 549, 401, 546, 403, 431, 545, 329, 543, 328, 307, + /* 2030 */ 306, 566, 482, 536, 336, 467, 535, 474, 481, 544, + /* 2040 */ 447, 467, 449, 333, 474, 331, 401, 20, 126, 494, + /* 2050 */ 541, 431, 497, 402, 309, 447, 501, 502, 503, 504, + /* 2060 */ 505, 506, 12, 13, 509, 510, 511, 447, 560, 449, + /* 2070 */ 407, 516, 22, 518, 386, 407, 500, 522, 523, 447, + /* 2080 */ 467, 447, 447, 199, 467, 464, 36, 494, 38, 401, + /* 2090 */ 497, 447, 407, 447, 501, 502, 503, 504, 505, 506, + /* 2100 */ 460, 115, 509, 510, 511, 521, 447, 199, 407, 516, + /* 2110 */ 461, 518, 386, 447, 494, 522, 523, 497, 68, 431, + /* 2120 */ 539, 501, 502, 503, 504, 505, 506, 401, 407, 509, + /* 2130 */ 510, 511, 82, 460, 559, 447, 516, 449, 518, 12, + /* 2140 */ 13, 426, 522, 523, 407, 115, 22, 401, 400, 22, + /* 2150 */ 447, 388, 436, 35, 447, 447, 386, 431, 407, 391, + /* 2160 */ 447, 392, 112, 36, 393, 38, 447, 447, 37, 40, + /* 2170 */ 447, 401, 447, 447, 394, 449, 447, 447, 447, 447, + /* 2180 */ 447, 408, 494, 447, 0, 497, 447, 447, 447, 501, + /* 2190 */ 502, 503, 504, 505, 506, 68, 447, 509, 510, 511, + /* 2200 */ 433, 431, 493, 447, 516, 477, 518, 447, 447, 447, + /* 2210 */ 522, 523, 423, 423, 433, 468, 423, 447, 384, 449, + /* 2220 */ 494, 486, 468, 497, 0, 0, 47, 501, 502, 503, + /* 2230 */ 504, 505, 506, 0, 36, 509, 510, 511, 386, 243, + /* 2240 */ 36, 36, 516, 36, 518, 243, 0, 36, 522, 523, + /* 2250 */ 36, 243, 36, 401, 0, 0, 243, 0, 36, 0, + /* 2260 */ 0, 22, 36, 0, 494, 36, 216, 497, 218, 238, + /* 2270 */ 0, 501, 502, 503, 504, 505, 506, 224, 0, 509, + /* 2280 */ 510, 511, 224, 431, 225, 218, 216, 0, 518, 212, + /* 2290 */ 211, 0, 522, 523, 0, 0, 0, 158, 51, 447, + /* 2300 */ 51, 449, 252, 253, 0, 36, 0, 0, 36, 0, + /* 2310 */ 54, 0, 51, 47, 0, 0, 0, 0, 51, 269, + /* 2320 */ 270, 386, 0, 0, 0, 0, 0, 277, 278, 279, + /* 2330 */ 280, 281, 282, 176, 36, 0, 401, 176, 0, 0, + /* 2340 */ 0, 0, 0, 216, 0, 218, 494, 0, 0, 497, + /* 2350 */ 0, 0, 0, 501, 502, 503, 504, 505, 506, 0, + /* 2360 */ 0, 509, 510, 511, 0, 0, 431, 0, 0, 0, + /* 2370 */ 518, 0, 0, 0, 522, 523, 0, 250, 251, 252, + /* 2380 */ 51, 47, 447, 0, 449, 0, 0, 0, 0, 0, + /* 2390 */ 0, 0, 22, 0, 158, 0, 269, 270, 157, 0, + /* 2400 */ 156, 0, 0, 22, 277, 278, 279, 280, 281, 282, + /* 2410 */ 386, 0, 0, 52, 22, 52, 36, 68, 0, 0, + /* 2420 */ 0, 68, 0, 68, 68, 401, 44, 0, 54, 494, + /* 2430 */ 36, 1, 497, 36, 0, 0, 501, 502, 503, 504, + /* 2440 */ 505, 506, 44, 36, 509, 510, 511, 386, 44, 19, + /* 2450 */ 54, 36, 0, 518, 54, 431, 47, 522, 523, 33, + /* 2460 */ 44, 51, 401, 14, 51, 51, 0, 44, 38, 45, + /* 2470 */ 0, 447, 0, 449, 0, 386, 0, 44, 207, 0, + /* 2480 */ 51, 0, 51, 53, 54, 0, 0, 0, 0, 36, + /* 2490 */ 401, 54, 431, 63, 64, 65, 66, 76, 68, 44, + /* 2500 */ 0, 36, 54, 44, 0, 36, 44, 0, 447, 36, + /* 2510 */ 449, 54, 54, 0, 0, 44, 0, 0, 494, 0, + /* 2520 */ 431, 497, 0, 0, 22, 501, 502, 503, 504, 505, + /* 2530 */ 506, 125, 22, 509, 510, 511, 447, 36, 449, 36, + /* 2540 */ 123, 36, 518, 0, 114, 36, 0, 523, 36, 119, + /* 2550 */ 22, 36, 22, 22, 36, 494, 36, 33, 497, 33, + /* 2560 */ 471, 36, 501, 502, 503, 504, 505, 506, 36, 508, + /* 2570 */ 509, 510, 511, 36, 36, 36, 0, 22, 0, 22, + /* 2580 */ 150, 386, 0, 494, 36, 56, 497, 0, 0, 36, + /* 2590 */ 501, 502, 503, 504, 505, 506, 401, 0, 509, 510, + /* 2600 */ 511, 36, 0, 36, 0, 22, 386, 36, 36, 20, + /* 2610 */ 36, 116, 115, 0, 115, 51, 0, 36, 193, 0, + /* 2620 */ 22, 401, 22, 0, 0, 195, 431, 197, 3, 193, + /* 2630 */ 200, 223, 229, 228, 193, 205, 193, 199, 193, 33, + /* 2640 */ 313, 36, 447, 203, 449, 203, 36, 219, 115, 313, + /* 2650 */ 116, 431, 116, 52, 224, 115, 115, 113, 111, 52, + /* 2660 */ 33, 116, 33, 33, 33, 116, 115, 447, 116, 449, + /* 2670 */ 116, 115, 51, 115, 115, 386, 82, 51, 33, 36, + /* 2680 */ 3, 115, 33, 36, 116, 116, 36, 36, 36, 494, + /* 2690 */ 401, 471, 497, 36, 36, 116, 501, 502, 503, 504, + /* 2700 */ 505, 506, 116, 33, 509, 510, 511, 51, 0, 0, + /* 2710 */ 51, 115, 44, 0, 494, 116, 44, 497, 386, 116, + /* 2720 */ 431, 501, 502, 503, 504, 505, 506, 115, 0, 509, + /* 2730 */ 510, 511, 115, 401, 116, 115, 447, 115, 449, 44, + /* 2740 */ 386, 297, 200, 33, 2, 313, 196, 552, 113, 285, + /* 2750 */ 113, 22, 116, 115, 115, 401, 196, 195, 252, 115, + /* 2760 */ 471, 386, 116, 431, 116, 51, 51, 22, 115, 115, + /* 2770 */ 0, 196, 0, 22, 44, 115, 401, 115, 115, 447, + /* 2780 */ 115, 449, 115, 494, 115, 431, 497, 116, 115, 115, + /* 2790 */ 501, 502, 503, 504, 505, 506, 115, 115, 509, 510, + /* 2800 */ 511, 447, 116, 449, 115, 117, 431, 115, 118, 51, + /* 2810 */ 116, 115, 115, 115, 115, 22, 255, 126, 116, 229, + /* 2820 */ 36, 36, 447, 116, 449, 36, 494, 115, 36, 497, + /* 2830 */ 36, 115, 36, 501, 502, 503, 504, 505, 506, 116, + /* 2840 */ 116, 509, 510, 511, 36, 33, 36, 116, 494, 116, + /* 2850 */ 115, 497, 115, 115, 137, 501, 502, 503, 504, 505, + /* 2860 */ 506, 22, 137, 509, 510, 511, 76, 22, 36, 494, + /* 2870 */ 75, 137, 497, 137, 36, 109, 501, 502, 503, 504, + /* 2880 */ 505, 506, 386, 36, 509, 510, 511, 555, 513, 36, + /* 2890 */ 36, 36, 36, 36, 36, 36, 36, 401, 82, 82, + /* 2900 */ 109, 33, 36, 36, 22, 36, 36, 386, 36, 82, + /* 2910 */ 36, 36, 36, 36, 36, 36, 22, 36, 564, 0, + /* 2920 */ 36, 0, 401, 36, 44, 54, 0, 431, 36, 44, + /* 2930 */ 0, 36, 44, 44, 0, 36, 0, 54, 22, 36, + /* 2940 */ 54, 0, 22, 447, 54, 449, 33, 36, 36, 386, + /* 2950 */ 22, 22, 431, 21, 567, 22, 21, 20, 567, 567, + /* 2960 */ 567, 567, 567, 567, 401, 567, 567, 471, 447, 567, + /* 2970 */ 449, 567, 567, 567, 567, 567, 567, 567, 567, 567, + /* 2980 */ 567, 567, 567, 567, 567, 567, 567, 567, 567, 567, + /* 2990 */ 494, 567, 471, 497, 431, 567, 567, 501, 502, 503, + /* 3000 */ 504, 505, 506, 567, 567, 509, 510, 511, 567, 567, + /* 3010 */ 447, 567, 449, 567, 386, 494, 567, 567, 497, 567, + /* 3020 */ 567, 567, 501, 502, 503, 504, 505, 506, 567, 401, + /* 3030 */ 509, 510, 511, 567, 471, 567, 567, 567, 567, 567, + /* 3040 */ 567, 386, 567, 567, 567, 567, 567, 567, 567, 567, + /* 3050 */ 567, 567, 567, 567, 567, 567, 401, 494, 567, 431, + /* 3060 */ 497, 567, 567, 567, 501, 502, 503, 504, 505, 506, + /* 3070 */ 567, 567, 509, 510, 511, 447, 567, 449, 567, 386, + /* 3080 */ 567, 567, 567, 567, 567, 567, 431, 567, 567, 567, + /* 3090 */ 567, 567, 567, 567, 401, 567, 567, 567, 567, 471, + /* 3100 */ 567, 567, 447, 567, 449, 567, 567, 567, 386, 567, + /* 3110 */ 567, 567, 567, 567, 567, 567, 567, 567, 567, 567, + /* 3120 */ 567, 567, 494, 401, 431, 497, 567, 567, 567, 501, + /* 3130 */ 502, 503, 504, 505, 506, 567, 567, 509, 510, 511, + /* 3140 */ 447, 567, 449, 567, 567, 567, 567, 386, 567, 494, + /* 3150 */ 567, 567, 497, 431, 567, 567, 501, 502, 503, 504, + /* 3160 */ 505, 506, 401, 567, 509, 510, 511, 567, 567, 447, + /* 3170 */ 567, 449, 567, 386, 567, 567, 567, 567, 567, 567, + /* 3180 */ 567, 567, 567, 567, 567, 567, 567, 494, 401, 567, + /* 3190 */ 497, 567, 431, 567, 501, 502, 503, 504, 505, 506, + /* 3200 */ 567, 567, 509, 510, 511, 567, 567, 567, 447, 567, + /* 3210 */ 449, 567, 567, 567, 567, 567, 494, 567, 431, 497, + /* 3220 */ 567, 567, 567, 501, 502, 503, 504, 505, 506, 567, + /* 3230 */ 567, 509, 510, 511, 447, 567, 449, 567, 386, 567, + /* 3240 */ 567, 567, 567, 567, 567, 567, 567, 567, 567, 567, + /* 3250 */ 567, 567, 567, 401, 567, 494, 567, 567, 497, 386, + /* 3260 */ 567, 567, 501, 502, 503, 504, 505, 506, 567, 567, + /* 3270 */ 509, 510, 511, 567, 401, 567, 567, 567, 567, 567, + /* 3280 */ 567, 494, 567, 431, 497, 567, 567, 567, 501, 502, + /* 3290 */ 503, 504, 505, 506, 567, 567, 509, 510, 511, 447, + /* 3300 */ 567, 449, 567, 567, 431, 567, 567, 567, 567, 567, + /* 3310 */ 567, 567, 567, 567, 567, 567, 567, 567, 567, 567, + /* 3320 */ 447, 567, 449, 567, 567, 567, 567, 567, 567, 567, + /* 3330 */ 567, 567, 567, 567, 567, 567, 386, 567, 567, 567, + /* 3340 */ 567, 567, 567, 567, 567, 567, 494, 567, 567, 497, + /* 3350 */ 567, 401, 567, 501, 502, 503, 504, 505, 506, 567, + /* 3360 */ 567, 509, 510, 511, 567, 567, 567, 494, 567, 567, + /* 3370 */ 497, 567, 567, 567, 501, 502, 503, 504, 505, 506, + /* 3380 */ 386, 431, 509, 510, 511, 567, 567, 567, 567, 567, + /* 3390 */ 567, 567, 567, 567, 567, 401, 567, 447, 567, 449, + /* 3400 */ 567, 386, 567, 567, 567, 567, 567, 567, 567, 567, + /* 3410 */ 567, 567, 567, 567, 567, 567, 401, 567, 567, 567, + /* 3420 */ 567, 386, 567, 567, 567, 431, 567, 567, 567, 567, + /* 3430 */ 567, 567, 567, 567, 567, 567, 401, 567, 567, 567, + /* 3440 */ 567, 447, 567, 449, 494, 567, 431, 497, 567, 567, + /* 3450 */ 567, 501, 502, 503, 504, 505, 506, 567, 567, 509, + /* 3460 */ 510, 511, 447, 567, 449, 567, 431, 567, 567, 567, + /* 3470 */ 567, 567, 567, 567, 567, 567, 567, 567, 567, 567, + /* 3480 */ 567, 567, 447, 567, 449, 567, 386, 567, 494, 567, + /* 3490 */ 567, 497, 567, 567, 567, 501, 502, 503, 504, 505, + /* 3500 */ 506, 401, 567, 509, 510, 511, 567, 567, 567, 494, + /* 3510 */ 567, 567, 497, 567, 567, 567, 501, 502, 503, 504, + /* 3520 */ 505, 506, 567, 567, 509, 510, 511, 386, 567, 494, + /* 3530 */ 567, 431, 497, 567, 567, 567, 501, 502, 503, 504, + /* 3540 */ 505, 506, 401, 567, 509, 510, 511, 447, 567, 449, + /* 3550 */ 567, 386, 567, 567, 567, 567, 567, 567, 567, 567, + /* 3560 */ 567, 567, 567, 567, 567, 567, 401, 567, 567, 567, + /* 3570 */ 567, 567, 431, 567, 567, 567, 567, 567, 567, 567, + /* 3580 */ 567, 567, 567, 567, 567, 567, 567, 567, 447, 567, + /* 3590 */ 449, 567, 567, 567, 494, 567, 431, 497, 567, 567, + /* 3600 */ 567, 501, 502, 503, 504, 505, 506, 567, 567, 509, + /* 3610 */ 510, 511, 447, 567, 449, 567, 567, 567, 386, 567, + /* 3620 */ 567, 567, 567, 567, 567, 567, 567, 567, 567, 567, + /* 3630 */ 567, 567, 567, 401, 567, 494, 567, 567, 497, 567, + /* 3640 */ 386, 567, 501, 502, 503, 504, 505, 506, 567, 567, + /* 3650 */ 509, 510, 511, 567, 567, 401, 567, 567, 567, 494, + /* 3660 */ 567, 567, 497, 431, 567, 567, 501, 502, 503, 504, + /* 3670 */ 505, 506, 567, 567, 509, 510, 511, 567, 567, 447, + /* 3680 */ 567, 449, 567, 386, 567, 431, 567, 567, 567, 567, + /* 3690 */ 567, 567, 567, 567, 567, 567, 567, 567, 401, 567, + /* 3700 */ 567, 447, 567, 449, 567, 567, 567, 386, 567, 567, + /* 3710 */ 567, 567, 567, 567, 567, 567, 567, 567, 567, 567, + /* 3720 */ 567, 567, 401, 567, 567, 567, 494, 567, 431, 497, + /* 3730 */ 567, 567, 567, 501, 502, 503, 504, 505, 506, 567, + /* 3740 */ 567, 509, 510, 511, 447, 567, 449, 567, 494, 567, + /* 3750 */ 567, 497, 431, 567, 567, 501, 502, 503, 504, 505, + /* 3760 */ 506, 567, 567, 509, 510, 511, 567, 567, 447, 567, + /* 3770 */ 449, 567, 567, 567, 567, 567, 567, 567, 567, 567, + /* 3780 */ 567, 567, 567, 567, 567, 567, 567, 567, 567, 567, + /* 3790 */ 567, 494, 567, 567, 497, 567, 567, 567, 501, 502, + /* 3800 */ 503, 504, 505, 506, 567, 567, 509, 510, 511, 567, + /* 3810 */ 567, 567, 567, 567, 567, 494, 567, 567, 497, 567, + /* 3820 */ 567, 567, 501, 502, 503, 504, 505, 506, 386, 567, + /* 3830 */ 509, 510, 511, 567, 567, 567, 567, 567, 567, 567, + /* 3840 */ 567, 567, 567, 401, 567, 567, 567, 386, 567, 567, + /* 3850 */ 567, 567, 567, 567, 567, 567, 567, 567, 567, 567, + /* 3860 */ 567, 567, 401, 567, 567, 567, 567, 567, 567, 386, + /* 3870 */ 567, 567, 567, 431, 567, 567, 567, 567, 567, 567, + /* 3880 */ 567, 567, 567, 567, 401, 567, 567, 567, 567, 447, + /* 3890 */ 567, 449, 431, 567, 567, 567, 386, 567, 567, 567, + /* 3900 */ 567, 567, 567, 567, 567, 567, 567, 567, 447, 567, + /* 3910 */ 449, 401, 567, 567, 431, 567, 567, 567, 567, 567, + /* 3920 */ 567, 567, 567, 567, 567, 567, 567, 567, 567, 567, + /* 3930 */ 447, 567, 449, 567, 386, 567, 494, 567, 567, 497, + /* 3940 */ 567, 431, 567, 501, 502, 503, 504, 505, 506, 401, + /* 3950 */ 567, 509, 510, 511, 567, 494, 567, 447, 497, 449, + /* 3960 */ 567, 567, 501, 502, 503, 504, 505, 506, 567, 567, + /* 3970 */ 509, 510, 511, 567, 567, 567, 567, 494, 567, 431, + /* 3980 */ 497, 567, 567, 386, 501, 502, 503, 504, 505, 506, + /* 3990 */ 567, 567, 509, 510, 511, 447, 567, 449, 401, 567, + /* 4000 */ 567, 567, 567, 567, 494, 567, 567, 497, 567, 567, + /* 4010 */ 567, 501, 502, 503, 504, 505, 506, 567, 567, 509, + /* 4020 */ 510, 511, 386, 567, 567, 567, 567, 567, 431, 567, + /* 4030 */ 567, 567, 567, 567, 567, 567, 567, 401, 567, 567, + /* 4040 */ 567, 567, 494, 567, 447, 497, 449, 567, 567, 501, + /* 4050 */ 502, 503, 504, 505, 506, 567, 567, 509, 510, 511, + /* 4060 */ 567, 567, 567, 567, 567, 567, 386, 431, 567, 567, + /* 4070 */ 567, 567, 567, 567, 567, 567, 567, 567, 567, 567, + /* 4080 */ 567, 401, 567, 447, 567, 449, 567, 567, 567, 567, + /* 4090 */ 386, 494, 567, 567, 497, 567, 567, 567, 501, 502, + /* 4100 */ 503, 504, 505, 506, 567, 401, 509, 510, 511, 386, + /* 4110 */ 567, 431, 567, 567, 567, 567, 567, 567, 567, 567, + /* 4120 */ 567, 567, 567, 567, 401, 567, 567, 447, 567, 449, + /* 4130 */ 494, 567, 567, 497, 567, 431, 567, 501, 502, 503, + /* 4140 */ 504, 505, 506, 567, 567, 509, 510, 511, 567, 567, + /* 4150 */ 567, 447, 567, 449, 431, 567, 567, 567, 567, 567, + /* 4160 */ 567, 567, 567, 567, 567, 567, 567, 567, 567, 567, + /* 4170 */ 447, 567, 449, 567, 494, 567, 567, 497, 386, 567, + /* 4180 */ 567, 501, 502, 503, 504, 505, 506, 567, 567, 509, + /* 4190 */ 510, 511, 567, 401, 567, 567, 567, 567, 494, 567, + /* 4200 */ 567, 497, 567, 567, 567, 501, 502, 503, 504, 505, + /* 4210 */ 506, 567, 567, 509, 510, 511, 567, 494, 567, 567, + /* 4220 */ 497, 567, 567, 431, 501, 502, 503, 504, 505, 506, + /* 4230 */ 567, 567, 509, 510, 511, 567, 567, 567, 567, 447, + /* 4240 */ 567, 449, 567, 567, 567, 567, 567, 567, 567, 567, + /* 4250 */ 567, 567, 567, 567, 567, 567, 567, 567, 567, 567, + /* 4260 */ 386, 567, 567, 567, 567, 567, 567, 567, 567, 567, + /* 4270 */ 567, 567, 567, 567, 567, 401, 567, 567, 567, 567, + /* 4280 */ 567, 567, 567, 567, 567, 567, 494, 567, 567, 497, + /* 4290 */ 567, 567, 567, 501, 502, 503, 504, 505, 506, 567, + /* 4300 */ 567, 509, 510, 511, 567, 431, 567, 567, 567, 567, + /* 4310 */ 567, 567, 567, 567, 567, 567, 567, 567, 567, 567, + /* 4320 */ 567, 447, 567, 449, 567, 567, 567, 567, 567, 567, + /* 4330 */ 567, 567, 567, 567, 567, 567, 567, 567, 567, 567, + /* 4340 */ 567, 567, 567, 567, 567, 567, 567, 567, 567, 567, + /* 4350 */ 567, 567, 567, 567, 567, 567, 567, 567, 567, 567, + /* 4360 */ 567, 567, 567, 567, 567, 567, 567, 567, 494, 567, + /* 4370 */ 567, 497, 567, 567, 567, 501, 502, 503, 504, 505, + /* 4380 */ 506, 567, 567, 509, 510, 511, 383, 383, 383, 383, + /* 4390 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, + /* 4400 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, + /* 4410 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, + /* 4420 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, + /* 4430 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, + /* 4440 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, + /* 4450 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, + /* 4460 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, + /* 4470 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, + /* 4480 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, + /* 4490 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, + /* 4500 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, + /* 4510 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, + /* 4520 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, + /* 4530 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, + /* 4540 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, + /* 4550 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, + /* 4560 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, + /* 4570 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, + /* 4580 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, + /* 4590 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, + /* 4600 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, + /* 4610 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, + /* 4620 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, + /* 4630 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, + /* 4640 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, + /* 4650 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, + /* 4660 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, + /* 4670 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, + /* 4680 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, + /* 4690 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, + /* 4700 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, + /* 4710 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, + /* 4720 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, + /* 4730 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, + /* 4740 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, + /* 4750 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, 383, + /* 4760 */ 383, 383, 383, 383, 383, 383, 383, 383, 383, }; -#define YY_SHIFT_COUNT (1006) +#define YY_SHIFT_COUNT (1008) #define YY_SHIFT_MIN (0) -#define YY_SHIFT_MAX (2887) +#define YY_SHIFT_MAX (2941) static const unsigned short int yy_shift_ofst[] = { - /* 0 */ 1704, 272, 355, 272, 628, 628, 628, 628, 628, 628, - /* 10 */ 628, 628, 628, 628, 628, 628, 711, 1338, 1338, 1421, - /* 20 */ 0, 983, 1338, 1338, 1338, 1338, 1338, 1338, 1338, 1338, - /* 30 */ 1338, 1338, 1066, 1338, 1338, 1338, 1338, 1338, 1338, 1338, - /* 40 */ 1338, 1338, 1338, 1338, 1338, 1338, 1338, 1338, 1338, 1338, - /* 50 */ 1338, 1338, 1338, 1338, 1338, 1338, 1338, 1338, 1338, 1338, - /* 60 */ 1338, 1338, 297, 314, 607, 201, 587, 611, 587, 587, - /* 70 */ 201, 201, 587, 2206, 587, 1687, 2206, 397, 587, 35, - /* 80 */ 1621, 177, 177, 87, 87, 1621, 1621, 145, 145, 177, - /* 90 */ 57, 57, 9, 206, 206, 218, 4, 87, 87, 87, - /* 100 */ 87, 87, 87, 87, 87, 87, 87, 87, 146, 300, - /* 110 */ 375, 87, 87, 474, 35, 87, 146, 87, 35, 87, - /* 120 */ 87, 87, 87, 35, 87, 87, 87, 35, 87, 35, - /* 130 */ 35, 35, 500, 394, 394, 458, 458, 808, 408, 178, - /* 140 */ 334, 975, 975, 975, 975, 975, 975, 975, 975, 975, - /* 150 */ 975, 975, 975, 975, 975, 975, 975, 975, 975, 975, - /* 160 */ 613, 205, 57, 9, 1148, 1148, 429, 183, 183, 183, - /* 170 */ 383, 383, 2, 942, 429, 474, 35, 525, 35, 35, - /* 180 */ 437, 35, 35, 846, 35, 846, 846, 819, 1063, 458, - /* 190 */ 458, 458, 458, 458, 458, 2568, 764, 21, 49, 261, - /* 200 */ 261, 166, 351, 700, 341, 684, 82, 376, 507, 392, - /* 210 */ 392, 881, 1017, 1151, 1151, 1151, 1174, 1151, 1204, 1163, - /* 220 */ 1036, 452, 1203, 1311, 282, 1252, 1252, 1401, 1441, 1441, - /* 230 */ 775, 1480, 1353, 1252, 942, 1499, 1761, 1798, 1801, 1590, - /* 240 */ 474, 1801, 474, 1618, 1798, 1813, 1788, 1813, 1788, 1652, - /* 250 */ 1798, 1813, 1798, 1788, 1652, 1652, 1652, 1772, 1775, 1798, - /* 260 */ 1798, 1783, 1798, 1798, 1798, 1884, 1853, 1884, 1853, 1801, - /* 270 */ 474, 474, 1898, 474, 1901, 1903, 474, 1901, 474, 1912, - /* 280 */ 474, 1915, 474, 474, 1798, 474, 1884, 35, 35, 35, - /* 290 */ 35, 35, 35, 35, 35, 35, 35, 35, 1798, 1063, - /* 300 */ 1063, 1884, 846, 846, 846, 1720, 1844, 1801, 500, 1942, - /* 310 */ 1753, 1743, 1898, 500, 1499, 1798, 846, 1681, 1688, 1681, - /* 320 */ 1688, 1682, 1806, 1681, 1689, 1691, 1712, 1499, 1713, 1719, - /* 330 */ 1690, 1701, 1702, 1813, 2016, 1911, 1730, 1901, 500, 500, - /* 340 */ 1688, 846, 846, 846, 846, 1688, 846, 1854, 500, 846, - /* 350 */ 1915, 500, 1959, 846, 1881, 1915, 500, 819, 500, 1813, - /* 360 */ 846, 846, 846, 846, 846, 846, 846, 846, 846, 846, - /* 370 */ 846, 846, 846, 846, 846, 846, 846, 846, 846, 846, - /* 380 */ 846, 846, 1997, 846, 1798, 500, 2105, 2095, 2096, 2094, - /* 390 */ 1884, 4470, 4470, 4470, 4470, 4470, 4470, 4470, 4470, 4470, - /* 400 */ 4470, 4470, 4470, 39, 1166, 66, 982, 323, 336, 909, - /* 410 */ 945, 1026, 1261, 1278, 1287, 567, 1138, 1296, 1454, 1534, - /* 420 */ 1550, 782, 1502, 926, 1238, 1384, 1384, 1384, 1384, 1384, - /* 430 */ 1384, 1384, 1384, 1384, 728, 33, 164, 532, 199, 199, - /* 440 */ 299, 105, 313, 720, 616, 809, 154, 1033, 1319, 1137, - /* 450 */ 706, 706, 1387, 1105, 795, 1387, 1387, 1387, 1205, 1161, - /* 460 */ 850, 1089, 1491, 1339, 1429, 1512, 1408, 1428, 1412, 1414, - /* 470 */ 1428, 1432, 951, 1531, 1540, 1557, 1560, 1583, 1606, 1334, - /* 480 */ 1508, 1536, 625, 1538, 1542, 1544, 1545, 1433, 1439, 1444, - /* 490 */ 1555, 1556, 1593, 1596, 1629, 1599, 1476, 1602, 1603, 1607, - /* 500 */ 1591, 1608, 1614, 1616, 1620, 1635, 1684, 1698, 1708, 1725, - /* 510 */ 1740, 1742, 1744, 1750, 1752, 1754, 1756, 1643, 1428, 1680, - /* 520 */ 1693, 1696, 1700, 1709, 1655, 1722, 1589, 1609, 1766, 1767, - /* 530 */ 1747, 1572, 2158, 2159, 2161, 2117, 2165, 2130, 1924, 2133, - /* 540 */ 2134, 2136, 1930, 2174, 2145, 2146, 1943, 2151, 2189, 2193, - /* 550 */ 1952, 2199, 2164, 2202, 2168, 2211, 2190, 2216, 2181, 1983, - /* 560 */ 2223, 2000, 2225, 2005, 2008, 2012, 2018, 2235, 2236, 2237, - /* 570 */ 2026, 2028, 2240, 2241, 2085, 2194, 2196, 2251, 2213, 2252, - /* 580 */ 2253, 2218, 2201, 2256, 2207, 2257, 2212, 2260, 2261, 2262, - /* 590 */ 2214, 2263, 2264, 2266, 2267, 2268, 2270, 2097, 2242, 2271, - /* 600 */ 2100, 2272, 2277, 2279, 2280, 2281, 2282, 2283, 2285, 2286, - /* 610 */ 2287, 2289, 2290, 2292, 2294, 2296, 2297, 2299, 2300, 2301, - /* 620 */ 2308, 2258, 2314, 2269, 2315, 2320, 2321, 2322, 2325, 2326, - /* 630 */ 2327, 2328, 2330, 2310, 2333, 2176, 2335, 2179, 2337, 2183, - /* 640 */ 2340, 2342, 2329, 2291, 2334, 2305, 2344, 2284, 2358, 2293, - /* 650 */ 2323, 2363, 2302, 2364, 2303, 2365, 2368, 2336, 2319, 2331, - /* 660 */ 2369, 2338, 2324, 2345, 2377, 2354, 2341, 2350, 2396, 2366, - /* 670 */ 2399, 2356, 2357, 2347, 2355, 2359, 2367, 2360, 2407, 2370, - /* 680 */ 2372, 2408, 2409, 2412, 2413, 2373, 2220, 2414, 2355, 2374, - /* 690 */ 2418, 2355, 2378, 2419, 2420, 2352, 2421, 2423, 2394, 2379, - /* 700 */ 2387, 2432, 2398, 2381, 2392, 2437, 2402, 2385, 2397, 2440, - /* 710 */ 2410, 2389, 2401, 2447, 2448, 2450, 2451, 2452, 2453, 2332, - /* 720 */ 2343, 2424, 2433, 2454, 2434, 2425, 2426, 2427, 2429, 2431, - /* 730 */ 2435, 2436, 2438, 2441, 2449, 2457, 2442, 2444, 2446, 2455, - /* 740 */ 2469, 2459, 2470, 2473, 2502, 2481, 2417, 2507, 2486, 2474, - /* 750 */ 2512, 2514, 2515, 2480, 2519, 2484, 2521, 2488, 2522, 2503, - /* 760 */ 2506, 2491, 2492, 2493, 2415, 2422, 2530, 2349, 2304, 2306, - /* 770 */ 2428, 2309, 2355, 2487, 2535, 2351, 2500, 2518, 2545, 2361, - /* 780 */ 2524, 2362, 2348, 2548, 2549, 2382, 2371, 2383, 2375, 2547, - /* 790 */ 2520, 2238, 2439, 2461, 2443, 2463, 2516, 2525, 2466, 2505, - /* 800 */ 2472, 2508, 2471, 2467, 2529, 2537, 2475, 2477, 2489, 2494, - /* 810 */ 2495, 2555, 2539, 2556, 2497, 2567, 2295, 2531, 2498, 2583, - /* 820 */ 2504, 2581, 2511, 2513, 2615, 2591, 2317, 2587, 2601, 2602, - /* 830 */ 2603, 2604, 2605, 2526, 2527, 2594, 2376, 2614, 2597, 2651, - /* 840 */ 2652, 2538, 2610, 2540, 2541, 2543, 2544, 2464, 2546, 2655, - /* 850 */ 2618, 2468, 2663, 2550, 2554, 2476, 2620, 2479, 2637, 2558, - /* 860 */ 2390, 2563, 2675, 2656, 2458, 2565, 2566, 2569, 2571, 2573, - /* 870 */ 2574, 2576, 2578, 2589, 2596, 2598, 2599, 2580, 2632, 2611, - /* 880 */ 2616, 2634, 2593, 2694, 2462, 2617, 2619, 2730, 2621, 2623, - /* 890 */ 2551, 2689, 2624, 2626, 2735, 2714, 2628, 2629, 2355, 2690, - /* 900 */ 2633, 2640, 2644, 2641, 2646, 2636, 2742, 2542, 2654, 2731, - /* 910 */ 2736, 2659, 2660, 2739, 2662, 2664, 2746, 2578, 2667, 2748, - /* 920 */ 2589, 2670, 2752, 2596, 2673, 2754, 2598, 2642, 2657, 2658, - /* 930 */ 2661, 2676, 2745, 2678, 2760, 2682, 2745, 2745, 2777, 2725, - /* 940 */ 2727, 2781, 2768, 2769, 2770, 2771, 2772, 2775, 2776, 2778, - /* 950 */ 2779, 2780, 2782, 2737, 2704, 2738, 2708, 2788, 2786, 2787, - /* 960 */ 2789, 2802, 2791, 2793, 2794, 2751, 2449, 2798, 2457, 2800, - /* 970 */ 2801, 2809, 2816, 2831, 2818, 2838, 2819, 2803, 2812, 2858, - /* 980 */ 2823, 2806, 2817, 2862, 2828, 2811, 2824, 2863, 2833, 2813, - /* 990 */ 2826, 2872, 2841, 2874, 2856, 2843, 2887, 2870, 2861, 2860, - /* 1000 */ 2864, 2875, 2877, 2879, 2880, 2878, 2883, + /* 0 */ 1704, 272, 355, 272, 628, 628, 628, 628, 628, 628, + /* 10 */ 628, 628, 628, 628, 628, 628, 711, 1338, 1338, 1421, + /* 20 */ 0, 983, 1338, 1338, 1338, 1338, 1338, 1338, 1338, 1338, + /* 30 */ 1338, 1338, 1066, 1338, 1338, 1338, 1338, 1338, 1338, 1338, + /* 40 */ 1338, 1338, 1338, 1338, 1338, 1338, 1338, 1338, 1338, 1338, + /* 50 */ 1338, 1338, 1338, 1338, 1338, 1338, 1338, 1338, 1338, 1338, + /* 60 */ 1338, 1338, 539, 645, 219, 200, 347, 457, 347, 347, + /* 70 */ 200, 200, 347, 2050, 347, 1687, 2050, 63, 347, 7, + /* 80 */ 2127, 491, 491, 91, 91, 2127, 2127, 962, 962, 491, + /* 90 */ 378, 378, 192, 14, 14, 94, 269, 91, 91, 91, + /* 100 */ 91, 91, 91, 91, 91, 91, 91, 91, 151, 321, + /* 110 */ 349, 91, 91, 402, 7, 91, 151, 91, 7, 91, + /* 120 */ 91, 91, 91, 7, 91, 91, 91, 7, 91, 7, + /* 130 */ 7, 7, 474, 308, 308, 544, 544, 808, 951, 156, + /* 140 */ 334, 978, 978, 978, 978, 978, 978, 978, 978, 978, + /* 150 */ 978, 978, 978, 978, 978, 978, 978, 978, 978, 978, + /* 160 */ 66, 602, 378, 192, 517, 517, 268, 603, 603, 603, + /* 170 */ 436, 436, 466, 1101, 268, 402, 7, 484, 7, 7, + /* 180 */ 367, 7, 7, 608, 7, 608, 608, 631, 683, 544, + /* 190 */ 544, 544, 544, 544, 544, 2430, 1202, 21, 217, 218, + /* 200 */ 218, 819, 242, 343, 198, 609, 294, 461, 725, 77, + /* 210 */ 77, 984, 901, 1081, 1081, 1081, 820, 1081, 674, 1119, + /* 220 */ 407, 428, 1405, 497, 1171, 1185, 1185, 1263, 1383, 1383, + /* 230 */ 1040, 1257, 251, 1185, 1101, 1500, 1758, 1800, 1813, 1606, + /* 240 */ 402, 1813, 402, 1653, 1800, 1857, 1832, 1857, 1832, 1694, + /* 250 */ 1800, 1857, 1800, 1832, 1694, 1694, 1694, 1776, 1786, 1800, + /* 260 */ 1800, 1791, 1800, 1800, 1800, 1886, 1856, 1886, 1856, 1813, + /* 270 */ 402, 402, 1901, 402, 1903, 1906, 402, 1903, 402, 1912, + /* 280 */ 402, 1918, 402, 402, 1892, 1892, 1800, 402, 1886, 7, + /* 290 */ 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, + /* 300 */ 1800, 683, 683, 1886, 608, 608, 608, 1727, 1855, 1813, + /* 310 */ 474, 1952, 1752, 1755, 1901, 474, 1500, 1800, 608, 1689, + /* 320 */ 1695, 1689, 1695, 1692, 1809, 1689, 1697, 1700, 1705, 1500, + /* 330 */ 1722, 1724, 1698, 1710, 1714, 1857, 2027, 1922, 1745, 1903, + /* 340 */ 474, 474, 1695, 608, 608, 608, 608, 1695, 608, 1884, + /* 350 */ 474, 608, 1918, 474, 1986, 608, 1908, 1918, 474, 631, + /* 360 */ 474, 1857, 608, 608, 608, 608, 608, 608, 608, 608, + /* 370 */ 608, 608, 608, 608, 608, 608, 608, 608, 608, 608, + /* 380 */ 608, 608, 608, 608, 2030, 608, 1800, 474, 2124, 2118, + /* 390 */ 2131, 2129, 1886, 4386, 4386, 4386, 4386, 4386, 4386, 4386, + /* 400 */ 4386, 4386, 4386, 4386, 4386, 39, 1321, 558, 1103, 50, + /* 410 */ 323, 910, 845, 862, 1195, 1261, 1212, 1386, 1402, 1454, + /* 420 */ 1496, 1616, 1638, 1648, 1571, 1042, 1588, 17, 17, 17, + /* 430 */ 17, 17, 17, 17, 17, 17, 271, 207, 615, 907, + /* 440 */ 693, 693, 576, 105, 37, 443, 412, 451, 1151, 62, + /* 450 */ 847, 784, 692, 692, 1024, 1249, 202, 1024, 1024, 1024, + /* 460 */ 3, 1161, 1415, 914, 1374, 1358, 1216, 822, 1378, 1407, + /* 470 */ 1399, 1412, 1407, 1414, 1356, 1187, 1489, 1544, 1567, 1605, + /* 480 */ 1614, 1260, 1443, 1444, 936, 1452, 1518, 1522, 1524, 1361, + /* 490 */ 751, 1419, 1532, 1539, 1542, 1543, 1561, 1549, 1389, 1560, + /* 500 */ 1573, 1600, 1527, 1610, 1612, 1636, 1639, 1655, 1654, 1658, + /* 510 */ 1683, 1696, 1699, 1706, 1717, 1744, 1750, 1753, 1766, 1677, + /* 520 */ 1407, 1680, 1690, 1691, 1711, 1712, 1625, 1482, 1541, 1590, + /* 530 */ 1545, 1684, 1734, 41, 2184, 2224, 2225, 2179, 2233, 2198, + /* 540 */ 1996, 2204, 2205, 2207, 2002, 2246, 2211, 2214, 2008, 2216, + /* 550 */ 2254, 2255, 2013, 2257, 2222, 2259, 2226, 2260, 2239, 2263, + /* 560 */ 2229, 2031, 2270, 2053, 2278, 2058, 2059, 2067, 2070, 2287, + /* 570 */ 2294, 2295, 2077, 2079, 2291, 2296, 2139, 2247, 2249, 2304, + /* 580 */ 2269, 2306, 2307, 2272, 2256, 2309, 2261, 2311, 2266, 2314, + /* 590 */ 2315, 2316, 2267, 2317, 2322, 2323, 2324, 2325, 2326, 2157, + /* 600 */ 2298, 2335, 2161, 2338, 2339, 2340, 2341, 2342, 2344, 2347, + /* 610 */ 2348, 2350, 2351, 2352, 2359, 2360, 2364, 2365, 2367, 2368, + /* 620 */ 2369, 2371, 2372, 2329, 2373, 2334, 2376, 2383, 2385, 2386, + /* 630 */ 2387, 2388, 2389, 2390, 2391, 2370, 2393, 2236, 2395, 2241, + /* 640 */ 2399, 2244, 2401, 2402, 2381, 2361, 2392, 2363, 2411, 2349, + /* 650 */ 2412, 2353, 2380, 2418, 2355, 2419, 2356, 2420, 2422, 2394, + /* 660 */ 2374, 2382, 2427, 2397, 2396, 2398, 2434, 2407, 2400, 2404, + /* 670 */ 2435, 2415, 2452, 2409, 2416, 2426, 2410, 2413, 2449, 2414, + /* 680 */ 2466, 2424, 2423, 2470, 2472, 2474, 2476, 2433, 2271, 2479, + /* 690 */ 2410, 2429, 2481, 2410, 2431, 2485, 2486, 2421, 2487, 2488, + /* 700 */ 2453, 2437, 2455, 2500, 2465, 2448, 2459, 2504, 2469, 2457, + /* 710 */ 2462, 2507, 2473, 2458, 2471, 2513, 2514, 2516, 2517, 2519, + /* 720 */ 2522, 2406, 2417, 2501, 2502, 2523, 2510, 2503, 2505, 2509, + /* 730 */ 2512, 2515, 2518, 2520, 2525, 2532, 2524, 2526, 2537, 2538, + /* 740 */ 2528, 2539, 2543, 2530, 2546, 2531, 2576, 2555, 2529, 2578, + /* 750 */ 2557, 2548, 2582, 2587, 2588, 2553, 2597, 2565, 2602, 2567, + /* 760 */ 2604, 2583, 2589, 2571, 2572, 2574, 2495, 2497, 2613, 2425, + /* 770 */ 2403, 2405, 2499, 2408, 2410, 2564, 2616, 2436, 2581, 2598, + /* 780 */ 2619, 2428, 2600, 2441, 2438, 2623, 2624, 2443, 2440, 2445, + /* 790 */ 2442, 2625, 2606, 2327, 2533, 2534, 2540, 2536, 2605, 2610, + /* 800 */ 2541, 2601, 2544, 2607, 2547, 2545, 2627, 2629, 2549, 2551, + /* 810 */ 2556, 2558, 2552, 2630, 2621, 2626, 2559, 2631, 2336, 2594, + /* 820 */ 2554, 2645, 2566, 2643, 2568, 2569, 2677, 2649, 2432, 2647, + /* 830 */ 2650, 2651, 2652, 2657, 2658, 2579, 2586, 2656, 2444, 2670, + /* 840 */ 2659, 2708, 2709, 2596, 2668, 2599, 2603, 2612, 2617, 2550, + /* 850 */ 2620, 2713, 2672, 2542, 2728, 2618, 2622, 2560, 2695, 2562, + /* 860 */ 2710, 2635, 2464, 2637, 2742, 2729, 2506, 2638, 2639, 2644, + /* 870 */ 2653, 2654, 2636, 2646, 2660, 2662, 2663, 2665, 2667, 2648, + /* 880 */ 2714, 2669, 2673, 2715, 2671, 2745, 2561, 2674, 2681, 2770, + /* 890 */ 2686, 2682, 2575, 2730, 2689, 2688, 2772, 2751, 2690, 2692, + /* 900 */ 2410, 2758, 2696, 2697, 2694, 2698, 2699, 2691, 2793, 2590, + /* 910 */ 2702, 2784, 2785, 2712, 2707, 2789, 2716, 2723, 2792, 2660, + /* 920 */ 2724, 2794, 2662, 2731, 2796, 2663, 2733, 2808, 2665, 2717, + /* 930 */ 2725, 2734, 2736, 2735, 2812, 2737, 2810, 2738, 2812, 2812, + /* 940 */ 2839, 2790, 2795, 2845, 2832, 2838, 2847, 2853, 2854, 2855, + /* 950 */ 2856, 2857, 2858, 2859, 2860, 2816, 2766, 2817, 2791, 2868, + /* 960 */ 2866, 2867, 2869, 2882, 2870, 2872, 2874, 2827, 2524, 2875, + /* 970 */ 2526, 2876, 2877, 2878, 2879, 2894, 2881, 2919, 2884, 2871, + /* 980 */ 2880, 2921, 2887, 2883, 2885, 2926, 2892, 2886, 2888, 2930, + /* 990 */ 2895, 2890, 2889, 2934, 2899, 2936, 2916, 2903, 2941, 2920, + /* 1000 */ 2913, 2911, 2912, 2928, 2932, 2929, 2933, 2935, 2937, }; -#define YY_REDUCE_COUNT (402) -#define YY_REDUCE_MIN (-529) -#define YY_REDUCE_MAX (3959) +#define YY_REDUCE_COUNT (404) +#define YY_REDUCE_MIN (-519) +#define YY_REDUCE_MAX (3874) static const short yy_reduce_ofst[] = { - /* 0 */ -233, -345, -60, -203, 978, 1481, 1562, 1592, 1675, 1705, - /* 10 */ 1802, 1845, 1883, 267, 622, 1996, 306, 662, 2063, 2093, - /* 20 */ 2198, 2219, 2249, 2339, 2380, 2445, 2465, 2485, 2570, 2590, - /* 30 */ 2666, 2702, 2743, 2827, 2848, 2876, 2916, 2959, 3001, 3041, - /* 40 */ 3084, 3130, 3167, 3213, 3235, 3278, 3303, 3324, 3346, 3471, - /* 50 */ 3490, 3510, 3577, 3615, 3661, 3682, 3750, 3772, 3793, 3818, - /* 60 */ 3939, 3959, -320, -38, 276, -296, 556, 965, 1109, 1179, - /* 70 */ -341, -112, 190, 160, -529, -367, -75, -526, -450, -240, - /* 80 */ -408, -425, 232, -133, 31, -264, -76, -394, -389, 260, - /* 90 */ 284, 574, -430, 58, 263, 70, 46, 365, 427, 438, - /* 100 */ 578, -287, 278, 606, 609, 612, 646, 338, 229, 468, - /* 110 */ 455, 680, 683, 682, 265, 756, 318, 759, -11, 768, - /* 120 */ 789, 794, 796, 708, 802, 878, 913, 615, 953, -331, - /* 130 */ 762, 876, 791, -503, -503, 372, 636, -364, -163, -148, - /* 140 */ 262, -346, 387, 576, 644, 734, 973, 976, 977, 984, - /* 150 */ 989, 994, 996, 1005, 1018, 1027, 1029, 1030, 1039, 1050, - /* 160 */ -258, 132, 138, 803, 910, 1022, 1024, 132, 919, 933, - /* 170 */ 243, 486, 707, 991, 1031, -84, 691, 855, 391, 858, - /* 180 */ 898, 1014, 395, 1006, 891, 1061, 1062, -53, 1108, -424, - /* 190 */ -412, 746, 755, 1053, 1078, 540, 1104, 1193, 1129, 1083, - /* 200 */ 1083, 1084, 1040, 1116, 1135, 1284, 1083, 1301, 1301, 1327, - /* 210 */ 1328, 1382, 1324, 1232, 1233, 1234, 1316, 1236, 1301, 1331, - /* 220 */ 1386, 1297, 1391, 1348, 1315, 1337, 1340, 1301, 1263, 1264, - /* 230 */ 1240, 1282, 1267, 1350, 1392, 1341, 1322, 1420, 1342, 1333, - /* 240 */ 1415, 1344, 1422, 1355, 1434, 1435, 1383, 1440, 1385, 1394, - /* 250 */ 1443, 1456, 1477, 1423, 1427, 1431, 1436, 1467, 1475, 1489, - /* 260 */ 1492, 1483, 1495, 1496, 1497, 1513, 1510, 1515, 1518, 1425, - /* 270 */ 1501, 1507, 1471, 1511, 1520, 1450, 1516, 1524, 1519, 1468, - /* 280 */ 1525, 1478, 1527, 1529, 1539, 1532, 1547, 1514, 1517, 1526, - /* 290 */ 1528, 1530, 1537, 1541, 1543, 1546, 1549, 1558, 1554, 1553, - /* 300 */ 1566, 1552, 1522, 1523, 1548, 1473, 1484, 1482, 1565, 1504, - /* 310 */ 1533, 1500, 1551, 1594, 1559, 1597, 1561, 1459, 1563, 1460, - /* 320 */ 1564, 1463, 1469, 1470, 1479, 1474, 1485, 1568, 1486, 1494, - /* 330 */ 1466, 1487, 1490, 1634, 1569, 1503, 1506, 1640, 1638, 1642, - /* 340 */ 1581, 1604, 1605, 1610, 1611, 1586, 1613, 1612, 1647, 1623, - /* 350 */ 1601, 1666, 1567, 1636, 1626, 1622, 1683, 1663, 1692, 1697, - /* 360 */ 1657, 1658, 1664, 1665, 1669, 1670, 1671, 1672, 1673, 1674, - /* 370 */ 1676, 1678, 1679, 1685, 1686, 1694, 1695, 1699, 1703, 1706, - /* 380 */ 1710, 1711, 1707, 1714, 1726, 1721, 1741, 1745, 1746, 1749, - /* 390 */ 1751, 1661, 1715, 1654, 1677, 1724, 1727, 1716, 1731, 1718, - /* 400 */ 1732, 1755, 1764, + /* 0 */ -376, -346, 1320, -204, 267, 622, 977, 1487, 1555, 1620, + /* 10 */ 1593, 1688, 1726, 1770, 1852, 1935, -98, -59, 303, 2024, + /* 20 */ 2061, 2089, 2195, 2220, 2289, 2332, 2354, 2375, 2496, 2521, + /* 30 */ 2563, 2628, 2655, 2693, 2722, 2761, 2787, 2852, 2873, 2950, + /* 40 */ 2994, 3015, 3035, 3100, 3141, 3165, 3232, 3254, 3297, 3321, + /* 50 */ 3442, 3461, 3483, 3510, 3548, 3597, 3636, 3680, 3704, 3723, + /* 60 */ 3792, 3874, -321, 280, -469, -48, -457, -363, 899, 985, + /* 70 */ 554, 1022, 1242, 304, 197, -72, 244, -160, 237, -417, + /* 80 */ -328, -393, 111, -133, 84, -6, 434, -380, -304, -140, + /* 90 */ -423, -414, 376, 336, 560, -252, -44, 328, 391, 495, + /* 100 */ 586, -395, 31, 644, 667, 673, 676, 617, -158, 247, + /* 110 */ 326, 700, 709, 680, 570, 742, 449, 746, -236, 749, + /* 120 */ 752, 759, 812, 431, 814, 871, 893, -50, 895, 591, + /* 130 */ 902, 755, -185, -519, -519, -38, -119, -389, -332, -20, + /* 140 */ 310, 470, 616, 623, 664, 720, 726, 735, 782, 791, + /* 150 */ 919, 956, 981, 995, 997, 1004, 1007, 1026, 1050, 1059, + /* 160 */ -262, -379, 148, -8, 896, 911, 939, -379, 840, 868, + /* 170 */ 229, 482, -246, 779, 941, 876, 666, -416, 250, 306, + /* 180 */ 865, 332, 739, 917, 982, 1002, 1028, -188, 1041, 447, + /* 190 */ 472, 588, 643, 698, 724, 636, 815, 891, 875, 830, + /* 200 */ 830, 882, 970, 1102, 1036, 1124, 830, 1140, 1140, 1251, + /* 210 */ 1314, 1359, 1309, 1228, 1229, 1230, 1312, 1232, 1140, 1327, + /* 220 */ 1384, 1292, 1388, 1344, 1311, 1333, 1335, 1140, 1258, 1265, + /* 230 */ 1239, 1276, 1269, 1346, 1391, 1341, 1322, 1432, 1350, 1351, + /* 240 */ 1431, 1372, 1437, 1395, 1472, 1477, 1424, 1481, 1427, 1433, + /* 250 */ 1485, 1486, 1491, 1436, 1440, 1441, 1442, 1483, 1488, 1498, + /* 260 */ 1499, 1492, 1502, 1504, 1505, 1514, 1512, 1517, 1519, 1426, + /* 270 */ 1510, 1511, 1473, 1515, 1523, 1453, 1520, 1525, 1526, 1467, + /* 280 */ 1528, 1479, 1531, 1533, 1521, 1530, 1547, 1536, 1562, 1529, + /* 290 */ 1534, 1535, 1537, 1538, 1540, 1546, 1551, 1552, 1554, 1556, + /* 300 */ 1559, 1565, 1572, 1569, 1516, 1548, 1553, 1478, 1493, 1490, + /* 310 */ 1566, 1494, 1550, 1557, 1558, 1592, 1563, 1601, 1564, 1468, + /* 320 */ 1568, 1469, 1574, 1471, 1470, 1476, 1480, 1495, 1484, 1570, + /* 330 */ 1497, 1501, 1465, 1508, 1575, 1645, 1576, 1509, 1581, 1651, + /* 340 */ 1663, 1668, 1613, 1608, 1632, 1634, 1635, 1617, 1644, 1621, + /* 350 */ 1685, 1646, 1640, 1701, 1584, 1659, 1649, 1673, 1721, 1715, + /* 360 */ 1737, 1746, 1666, 1703, 1707, 1708, 1713, 1719, 1720, 1723, + /* 370 */ 1725, 1729, 1730, 1731, 1732, 1733, 1736, 1739, 1740, 1741, + /* 380 */ 1749, 1756, 1760, 1761, 1716, 1762, 1748, 1751, 1763, 1768, + /* 390 */ 1769, 1780, 1771, 1728, 1767, 1709, 1735, 1747, 1754, 1789, + /* 400 */ 1790, 1781, 1793, 1773, 1834, }; static const YYACTIONTYPE yy_default[] = { - /* 0 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 10 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 20 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 30 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 40 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 50 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 60 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 70 */ 2263, 2263, 2638, 2263, 2263, 2594, 2263, 2263, 2263, 2263, - /* 80 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 90 */ 2601, 2601, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 100 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 110 */ 2263, 2263, 2263, 2369, 2263, 2263, 2263, 2263, 2263, 2263, - /* 120 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 130 */ 2263, 2263, 2367, 2908, 2263, 3034, 2679, 2263, 2263, 2937, - /* 140 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 150 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 160 */ 2263, 2920, 2263, 2263, 2340, 2340, 2263, 2920, 2920, 2920, - /* 170 */ 2880, 2880, 2367, 2263, 2263, 2369, 2263, 2681, 2263, 2263, - /* 180 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2510, 2293, 2263, - /* 190 */ 2263, 2263, 2263, 2263, 2263, 2664, 2263, 2263, 2966, 2912, - /* 200 */ 2913, 3028, 2263, 2969, 2931, 2263, 2926, 2263, 2263, 2263, - /* 210 */ 2263, 2263, 2956, 2263, 2263, 2263, 2263, 2263, 2263, 2606, - /* 220 */ 2263, 2707, 2263, 2455, 2658, 2263, 2263, 2263, 2263, 2263, - /* 230 */ 3012, 2910, 2950, 2263, 2263, 2960, 2263, 2263, 2263, 2695, - /* 240 */ 2369, 2263, 2369, 2651, 2589, 2263, 2599, 2263, 2599, 2596, - /* 250 */ 2263, 2263, 2263, 2599, 2596, 2596, 2596, 2443, 2439, 2263, - /* 260 */ 2263, 2437, 2263, 2263, 2263, 2263, 2323, 2263, 2323, 2263, - /* 270 */ 2369, 2369, 2263, 2369, 2263, 2263, 2369, 2263, 2369, 2263, - /* 280 */ 2369, 2263, 2369, 2369, 2263, 2369, 2263, 2263, 2263, 2263, - /* 290 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 300 */ 2263, 2263, 2263, 2263, 2263, 2693, 2674, 2263, 2367, 2263, - /* 310 */ 2662, 2660, 2263, 2367, 2960, 2263, 2263, 2982, 2977, 2982, - /* 320 */ 2977, 2996, 2992, 2982, 3001, 2998, 2962, 2960, 2943, 2939, - /* 330 */ 3031, 3018, 3014, 2263, 2263, 2948, 2946, 2263, 2367, 2367, - /* 340 */ 2977, 2263, 2263, 2263, 2263, 2977, 2263, 2263, 2367, 2263, - /* 350 */ 2263, 2367, 2263, 2263, 2263, 2263, 2367, 2263, 2367, 2263, - /* 360 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 370 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 380 */ 2263, 2263, 2472, 2263, 2263, 2367, 2263, 2295, 2297, 2307, - /* 390 */ 2263, 2653, 3034, 2679, 2684, 2634, 2634, 2513, 2513, 3034, - /* 400 */ 2513, 2370, 2268, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 410 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2812, 2263, - /* 420 */ 2263, 2263, 2263, 2263, 2263, 2995, 2994, 2813, 2263, 2884, - /* 430 */ 2883, 2882, 2873, 2812, 2468, 2263, 2263, 2263, 2811, 2810, - /* 440 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 450 */ 2625, 2624, 2804, 2263, 2263, 2805, 2803, 2802, 2263, 2263, - /* 460 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2459, 2263, 2263, - /* 470 */ 2456, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 480 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 3015, 3019, - /* 490 */ 2263, 2263, 2263, 2263, 2909, 2263, 2263, 2263, 2263, 2263, - /* 500 */ 2783, 2263, 2263, 2263, 2263, 2263, 2751, 2746, 2737, 2728, - /* 510 */ 2743, 2734, 2722, 2740, 2731, 2719, 2716, 2263, 2481, 2263, - /* 520 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 530 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 540 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 550 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 560 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 570 */ 2263, 2263, 2263, 2263, 2595, 2263, 2263, 2263, 2263, 2263, - /* 580 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 590 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 600 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 610 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 620 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 630 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2610, - /* 640 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 650 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 660 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 670 */ 2263, 2263, 2263, 2312, 2790, 2263, 2263, 2263, 2263, 2263, - /* 680 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2793, 2263, - /* 690 */ 2263, 2794, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 700 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 710 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 720 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 730 */ 2263, 2263, 2263, 2263, 2414, 2413, 2263, 2263, 2263, 2263, - /* 740 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 750 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 760 */ 2263, 2263, 2263, 2263, 2795, 2263, 2263, 2263, 2263, 2678, - /* 770 */ 2263, 2263, 2785, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 780 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 3011, - /* 790 */ 2963, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 800 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 810 */ 2263, 2263, 2263, 2783, 2263, 2993, 2263, 2263, 2263, 2263, - /* 820 */ 2263, 2263, 2263, 3009, 2263, 3013, 2263, 2263, 2263, 2263, - /* 830 */ 2263, 2263, 2263, 2919, 2915, 2263, 2263, 2911, 2263, 2263, - /* 840 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 850 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2870, 2263, - /* 860 */ 2263, 2263, 2904, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 870 */ 2263, 2263, 2509, 2508, 2507, 2506, 2263, 2263, 2263, 2263, - /* 880 */ 2263, 2263, 2795, 2263, 2798, 2263, 2263, 2263, 2263, 2263, - /* 890 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2782, 2263, - /* 900 */ 2847, 2846, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 910 */ 2263, 2503, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 920 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2487, 2485, 2484, - /* 930 */ 2483, 2263, 2520, 2263, 2263, 2263, 2516, 2515, 2263, 2263, - /* 940 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 950 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2388, 2263, 2263, - /* 960 */ 2263, 2263, 2263, 2263, 2263, 2263, 2380, 2263, 2379, 2263, - /* 970 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 980 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, - /* 990 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2263, 2292, 2263, - /* 1000 */ 2263, 2263, 2263, 2263, 2263, 2263, 2263, + /* 0 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 10 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 20 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 30 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 40 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 50 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 60 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 70 */ 2268, 2268, 2645, 2268, 2268, 2601, 2268, 2268, 2268, 2268, + /* 80 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 90 */ 2608, 2608, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 100 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 110 */ 2268, 2268, 2268, 2374, 2268, 2268, 2268, 2268, 2268, 2268, + /* 120 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 130 */ 2268, 2268, 2372, 2915, 2268, 3041, 2686, 2268, 2268, 2944, + /* 140 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 150 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 160 */ 2268, 2927, 2268, 2268, 2345, 2345, 2268, 2927, 2927, 2927, + /* 170 */ 2887, 2887, 2372, 2268, 2268, 2374, 2268, 2688, 2268, 2268, + /* 180 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2517, 2298, 2268, + /* 190 */ 2268, 2268, 2268, 2268, 2268, 2671, 2268, 2268, 2973, 2919, + /* 200 */ 2920, 3035, 2268, 2976, 2938, 2268, 2933, 2268, 2268, 2268, + /* 210 */ 2268, 2268, 2963, 2268, 2268, 2268, 2268, 2268, 2268, 2613, + /* 220 */ 2268, 2714, 2268, 2460, 2665, 2268, 2268, 2268, 2268, 2268, + /* 230 */ 3019, 2917, 2957, 2268, 2268, 2967, 2268, 2268, 2268, 2702, + /* 240 */ 2374, 2268, 2374, 2658, 2596, 2268, 2606, 2268, 2606, 2603, + /* 250 */ 2268, 2268, 2268, 2606, 2603, 2603, 2603, 2448, 2444, 2268, + /* 260 */ 2268, 2442, 2268, 2268, 2268, 2268, 2328, 2268, 2328, 2268, + /* 270 */ 2374, 2374, 2268, 2374, 2268, 2268, 2374, 2268, 2374, 2268, + /* 280 */ 2374, 2268, 2374, 2374, 2477, 2477, 2268, 2374, 2268, 2268, + /* 290 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 300 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2700, 2681, 2268, + /* 310 */ 2372, 2268, 2669, 2667, 2268, 2372, 2967, 2268, 2268, 2989, + /* 320 */ 2984, 2989, 2984, 3003, 2999, 2989, 3008, 3005, 2969, 2967, + /* 330 */ 2950, 2946, 3038, 3025, 3021, 2268, 2268, 2955, 2953, 2268, + /* 340 */ 2372, 2372, 2984, 2268, 2268, 2268, 2268, 2984, 2268, 2268, + /* 350 */ 2372, 2268, 2268, 2372, 2268, 2268, 2268, 2268, 2372, 2268, + /* 360 */ 2372, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 370 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 380 */ 2268, 2268, 2268, 2268, 2479, 2268, 2268, 2372, 2268, 2300, + /* 390 */ 2302, 2312, 2268, 2660, 3041, 2686, 2691, 2641, 2641, 2520, + /* 400 */ 2520, 3041, 2520, 2375, 2273, 2268, 2268, 2268, 2268, 2268, + /* 410 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 420 */ 2819, 2268, 2268, 2268, 2268, 2268, 2268, 3002, 3001, 2820, + /* 430 */ 2268, 2891, 2890, 2889, 2880, 2819, 2473, 2268, 2268, 2268, + /* 440 */ 2818, 2817, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 450 */ 2268, 2268, 2632, 2631, 2811, 2268, 2268, 2812, 2810, 2809, + /* 460 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2464, + /* 470 */ 2268, 2268, 2461, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 480 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 490 */ 3022, 3026, 2268, 2268, 2268, 2268, 2916, 2268, 2268, 2268, + /* 500 */ 2268, 2268, 2790, 2268, 2268, 2268, 2268, 2268, 2758, 2753, + /* 510 */ 2744, 2735, 2750, 2741, 2729, 2747, 2738, 2726, 2723, 2268, + /* 520 */ 2488, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 530 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 540 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 550 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 560 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 570 */ 2268, 2268, 2268, 2268, 2268, 2268, 2602, 2268, 2268, 2268, + /* 580 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 590 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 600 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 610 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 620 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 630 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 640 */ 2268, 2617, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 650 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 660 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 670 */ 2268, 2268, 2268, 2268, 2268, 2317, 2797, 2268, 2268, 2268, + /* 680 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 690 */ 2800, 2268, 2268, 2801, 2268, 2268, 2268, 2268, 2268, 2268, + /* 700 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 710 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 720 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 730 */ 2268, 2268, 2268, 2268, 2268, 2268, 2419, 2418, 2268, 2268, + /* 740 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 750 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 760 */ 2268, 2268, 2268, 2268, 2268, 2268, 2802, 2268, 2268, 2268, + /* 770 */ 2268, 2685, 2268, 2268, 2792, 2268, 2268, 2268, 2268, 2268, + /* 780 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 790 */ 2268, 3018, 2970, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 800 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 810 */ 2268, 2268, 2268, 2268, 2268, 2790, 2268, 3000, 2268, 2268, + /* 820 */ 2268, 2268, 2268, 2268, 2268, 3016, 2268, 3020, 2268, 2268, + /* 830 */ 2268, 2268, 2268, 2268, 2268, 2926, 2922, 2268, 2268, 2918, + /* 840 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 850 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 860 */ 2877, 2268, 2268, 2268, 2911, 2268, 2268, 2268, 2268, 2268, + /* 870 */ 2268, 2268, 2268, 2268, 2516, 2515, 2514, 2513, 2268, 2268, + /* 880 */ 2268, 2268, 2268, 2268, 2802, 2268, 2805, 2268, 2268, 2268, + /* 890 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 900 */ 2789, 2268, 2854, 2853, 2268, 2268, 2268, 2268, 2268, 2268, + /* 910 */ 2268, 2268, 2268, 2510, 2268, 2268, 2268, 2268, 2268, 2268, + /* 920 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2494, + /* 930 */ 2492, 2491, 2490, 2268, 2527, 2268, 2268, 2268, 2523, 2522, + /* 940 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 950 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2393, + /* 960 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2385, 2268, + /* 970 */ 2384, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 980 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 990 */ 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, + /* 1000 */ 2297, 2268, 2268, 2268, 2268, 2268, 2268, 2268, 2268, }; /********** End of lemon-generated parsing tables *****************************/ -/* The next table maps tokens (terminal symbols) into fallback tokens. +/* The next table maps tokens (terminal symbols) into fallback tokens. ** If a construct like the following: -** +** ** %fallback ID X Y Z. ** ** appears in the grammar, then ID becomes a fallback token for X, Y, @@ -1954,12 +1529,12 @@ static const YYCODETYPE yyFallback[] = { 0, /* BWLIMIT => nothing */ 0, /* START => nothing */ 0, /* TIMESTAMP => nothing */ - 337, /* END => ABORT */ + 337, /* END => ABORT */ 0, /* TABLE => nothing */ 0, /* NK_LP => nothing */ 0, /* NK_RP => nothing */ 0, /* USING => nothing */ - 337, /* FILE => ABORT */ + 337, /* FILE => ABORT */ 0, /* STABLE => nothing */ 0, /* COLUMN => nothing */ 0, /* MODIFY => nothing */ @@ -2027,7 +1602,7 @@ static const YYCODETYPE yyFallback[] = { 0, /* VNODES => nothing */ 0, /* ALIVE => nothing */ 0, /* VIEWS => nothing */ - 337, /* VIEW => ABORT */ + 337, /* VIEW => ABORT */ 0, /* COMPACTS => nothing */ 0, /* NORMAL => nothing */ 0, /* CHILD => nothing */ @@ -2070,7 +1645,7 @@ static const YYCODETYPE yyFallback[] = { 0, /* PAUSE => nothing */ 0, /* RESUME => nothing */ 0, /* PRIMARY => nothing */ - 337, /* KEY => ABORT */ + 337, /* KEY => ABORT */ 0, /* TRIGGER => nothing */ 0, /* AT_ONCE => nothing */ 0, /* WINDOW_CLOSE => nothing */ @@ -2109,7 +1684,7 @@ static const YYCODETYPE yyFallback[] = { 0, /* CAST => nothing */ 0, /* POSITION => nothing */ 0, /* IN => nothing */ - 337, /* FOR => ABORT */ + 337, /* FOR => ABORT */ 0, /* NOW => nothing */ 0, /* TODAY => nothing */ 0, /* RAND => nothing */ @@ -2143,7 +1718,7 @@ static const YYCODETYPE yyFallback[] = { 0, /* LEFT => nothing */ 0, /* RIGHT => nothing */ 0, /* OUTER => nothing */ - 337, /* SEMI => ABORT */ + 337, /* SEMI => ABORT */ 0, /* ANTI => nothing */ 0, /* ASOF => nothing */ 0, /* WINDOW => nothing */ @@ -2179,51 +1754,51 @@ static const YYCODETYPE yyFallback[] = { 0, /* ASC => nothing */ 0, /* NULLS => nothing */ 0, /* ABORT => nothing */ - 337, /* AFTER => ABORT */ - 337, /* ATTACH => ABORT */ - 337, /* BEFORE => ABORT */ - 337, /* BEGIN => ABORT */ - 337, /* BITAND => ABORT */ - 337, /* BITNOT => ABORT */ - 337, /* BITOR => ABORT */ - 337, /* BLOCKS => ABORT */ - 337, /* CHANGE => ABORT */ - 337, /* COMMA => ABORT */ - 337, /* CONCAT => ABORT */ - 337, /* CONFLICT => ABORT */ - 337, /* COPY => ABORT */ - 337, /* DEFERRED => ABORT */ - 337, /* DELIMITERS => ABORT */ - 337, /* DETACH => ABORT */ - 337, /* DIVIDE => ABORT */ - 337, /* DOT => ABORT */ - 337, /* EACH => ABORT */ - 337, /* FAIL => ABORT */ - 337, /* GLOB => ABORT */ - 337, /* ID => ABORT */ - 337, /* IMMEDIATE => ABORT */ - 337, /* IMPORT => ABORT */ - 337, /* INITIALLY => ABORT */ - 337, /* INSTEAD => ABORT */ - 337, /* ISNULL => ABORT */ - 337, /* MODULES => ABORT */ - 337, /* NK_BITNOT => ABORT */ - 337, /* NK_SEMI => ABORT */ - 337, /* NOTNULL => ABORT */ - 337, /* OF => ABORT */ - 337, /* PLUS => ABORT */ - 337, /* PRIVILEGE => ABORT */ - 337, /* RAISE => ABORT */ - 337, /* RESTRICT => ABORT */ - 337, /* ROW => ABORT */ - 337, /* STAR => ABORT */ - 337, /* STATEMENT => ABORT */ - 337, /* STRICT => ABORT */ - 337, /* STRING => ABORT */ - 337, /* TIMES => ABORT */ - 337, /* VALUES => ABORT */ - 337, /* VARIABLE => ABORT */ - 337, /* WAL => ABORT */ + 337, /* AFTER => ABORT */ + 337, /* ATTACH => ABORT */ + 337, /* BEFORE => ABORT */ + 337, /* BEGIN => ABORT */ + 337, /* BITAND => ABORT */ + 337, /* BITNOT => ABORT */ + 337, /* BITOR => ABORT */ + 337, /* BLOCKS => ABORT */ + 337, /* CHANGE => ABORT */ + 337, /* COMMA => ABORT */ + 337, /* CONCAT => ABORT */ + 337, /* CONFLICT => ABORT */ + 337, /* COPY => ABORT */ + 337, /* DEFERRED => ABORT */ + 337, /* DELIMITERS => ABORT */ + 337, /* DETACH => ABORT */ + 337, /* DIVIDE => ABORT */ + 337, /* DOT => ABORT */ + 337, /* EACH => ABORT */ + 337, /* FAIL => ABORT */ + 337, /* GLOB => ABORT */ + 337, /* ID => ABORT */ + 337, /* IMMEDIATE => ABORT */ + 337, /* IMPORT => ABORT */ + 337, /* INITIALLY => ABORT */ + 337, /* INSTEAD => ABORT */ + 337, /* ISNULL => ABORT */ + 337, /* MODULES => ABORT */ + 337, /* NK_BITNOT => ABORT */ + 337, /* NK_SEMI => ABORT */ + 337, /* NOTNULL => ABORT */ + 337, /* OF => ABORT */ + 337, /* PLUS => ABORT */ + 337, /* PRIVILEGE => ABORT */ + 337, /* RAISE => ABORT */ + 337, /* RESTRICT => ABORT */ + 337, /* ROW => ABORT */ + 337, /* STAR => ABORT */ + 337, /* STATEMENT => ABORT */ + 337, /* STRICT => ABORT */ + 337, /* STRING => ABORT */ + 337, /* TIMES => ABORT */ + 337, /* VALUES => ABORT */ + 337, /* VARIABLE => ABORT */ + 337, /* WAL => ABORT */ }; #endif /* YYFALLBACK */ @@ -2263,14 +1838,18 @@ struct yyParser { int yyerrcnt; /* Shifts left before out of the error */ #endif ParseARG_SDECL /* A place to hold %extra_argument */ - ParseCTX_SDECL /* A place to hold %extra_context */ - yyStackEntry *yystackEnd; /* Last entry in the stack */ - yyStackEntry *yystack; /* The parser stack */ - yyStackEntry yystk0[YYSTACKDEPTH]; /* Initial stack space */ + ParseCTX_SDECL /* A place to hold %extra_context */ +#if YYSTACKDEPTH<=0 + int yystksz; /* Current side of the stack */ + yyStackEntry *yystack; /* The parser's stack */ + yyStackEntry yystk0; /* First stack entry */ +#else + yyStackEntry yystack[YYSTACKDEPTH]; /* The parser's stack */ + yyStackEntry *yystackEnd; /* Last entry in the stack */ +#endif }; typedef struct yyParser yyParser; -#include #ifndef NDEBUG #include static FILE *yyTraceFILE = 0; @@ -2278,10 +1857,10 @@ static char *yyTracePrompt = 0; #endif /* NDEBUG */ #ifndef NDEBUG -/* +/* ** Turn parser tracing on by giving a stream to which to write the trace ** and a prompt to preface each trace message. Tracing is turned off -** by making either argument NULL +** by making either argument NULL ** ** Inputs: **
    @@ -2306,1394 +1885,1389 @@ void ParseTrace(FILE *TraceFILE, char *zTracePrompt){ #if defined(YYCOVERAGE) || !defined(NDEBUG) /* For tracing shifts, the names of all terminals and nonterminals ** are required. The following table supplies these names */ -static const char *const yyTokenName[] = { - /* 0 */ "$", - /* 1 */ "OR", - /* 2 */ "AND", - /* 3 */ "UNION", - /* 4 */ "ALL", - /* 5 */ "MINUS", - /* 6 */ "EXCEPT", - /* 7 */ "INTERSECT", - /* 8 */ "NK_BITAND", - /* 9 */ "NK_BITOR", - /* 10 */ "NK_LSHIFT", - /* 11 */ "NK_RSHIFT", - /* 12 */ "NK_PLUS", - /* 13 */ "NK_MINUS", - /* 14 */ "NK_STAR", - /* 15 */ "NK_SLASH", - /* 16 */ "NK_REM", - /* 17 */ "NK_CONCAT", - /* 18 */ "CREATE", - /* 19 */ "ACCOUNT", - /* 20 */ "NK_ID", - /* 21 */ "PASS", - /* 22 */ "NK_STRING", - /* 23 */ "ALTER", - /* 24 */ "PPS", - /* 25 */ "TSERIES", - /* 26 */ "STORAGE", - /* 27 */ "STREAMS", - /* 28 */ "QTIME", - /* 29 */ "DBS", - /* 30 */ "USERS", - /* 31 */ "CONNS", - /* 32 */ "STATE", - /* 33 */ "NK_COMMA", - /* 34 */ "HOST", - /* 35 */ "IS_IMPORT", - /* 36 */ "NK_INTEGER", - /* 37 */ "CREATEDB", - /* 38 */ "USER", - /* 39 */ "ENABLE", - /* 40 */ "SYSINFO", - /* 41 */ "ADD", - /* 42 */ "DROP", - /* 43 */ "GRANT", - /* 44 */ "ON", - /* 45 */ "TO", - /* 46 */ "REVOKE", - /* 47 */ "FROM", - /* 48 */ "SUBSCRIBE", - /* 49 */ "READ", - /* 50 */ "WRITE", - /* 51 */ "NK_DOT", - /* 52 */ "WITH", - /* 53 */ "ENCRYPT_KEY", - /* 54 */ "DNODE", - /* 55 */ "PORT", - /* 56 */ "DNODES", - /* 57 */ "RESTORE", - /* 58 */ "NK_IPTOKEN", - /* 59 */ "FORCE", - /* 60 */ "UNSAFE", - /* 61 */ "CLUSTER", - /* 62 */ "LOCAL", - /* 63 */ "QNODE", - /* 64 */ "BNODE", - /* 65 */ "SNODE", - /* 66 */ "MNODE", - /* 67 */ "VNODE", - /* 68 */ "DATABASE", - /* 69 */ "USE", - /* 70 */ "FLUSH", - /* 71 */ "TRIM", - /* 72 */ "S3MIGRATE", - /* 73 */ "COMPACT", - /* 74 */ "IF", - /* 75 */ "NOT", - /* 76 */ "EXISTS", - /* 77 */ "BUFFER", - /* 78 */ "CACHEMODEL", - /* 79 */ "CACHESIZE", - /* 80 */ "COMP", - /* 81 */ "DURATION", - /* 82 */ "NK_VARIABLE", - /* 83 */ "MAXROWS", - /* 84 */ "MINROWS", - /* 85 */ "KEEP", - /* 86 */ "PAGES", - /* 87 */ "PAGESIZE", - /* 88 */ "TSDB_PAGESIZE", - /* 89 */ "PRECISION", - /* 90 */ "REPLICA", - /* 91 */ "VGROUPS", - /* 92 */ "SINGLE_STABLE", - /* 93 */ "RETENTIONS", - /* 94 */ "SCHEMALESS", - /* 95 */ "WAL_LEVEL", - /* 96 */ "WAL_FSYNC_PERIOD", - /* 97 */ "WAL_RETENTION_PERIOD", - /* 98 */ "WAL_RETENTION_SIZE", - /* 99 */ "WAL_ROLL_PERIOD", - /* 100 */ "WAL_SEGMENT_SIZE", - /* 101 */ "STT_TRIGGER", - /* 102 */ "TABLE_PREFIX", - /* 103 */ "TABLE_SUFFIX", - /* 104 */ "S3_CHUNKSIZE", - /* 105 */ "S3_KEEPLOCAL", - /* 106 */ "S3_COMPACT", - /* 107 */ "KEEP_TIME_OFFSET", - /* 108 */ "ENCRYPT_ALGORITHM", - /* 109 */ "NK_COLON", - /* 110 */ "BWLIMIT", - /* 111 */ "START", - /* 112 */ "TIMESTAMP", - /* 113 */ "END", - /* 114 */ "TABLE", - /* 115 */ "NK_LP", - /* 116 */ "NK_RP", - /* 117 */ "USING", - /* 118 */ "FILE", - /* 119 */ "STABLE", - /* 120 */ "COLUMN", - /* 121 */ "MODIFY", - /* 122 */ "RENAME", - /* 123 */ "TAG", - /* 124 */ "SET", - /* 125 */ "NK_EQ", - /* 126 */ "TAGS", - /* 127 */ "BOOL", - /* 128 */ "TINYINT", - /* 129 */ "SMALLINT", - /* 130 */ "INT", - /* 131 */ "INTEGER", - /* 132 */ "BIGINT", - /* 133 */ "FLOAT", - /* 134 */ "DOUBLE", - /* 135 */ "BINARY", - /* 136 */ "NCHAR", - /* 137 */ "UNSIGNED", - /* 138 */ "JSON", - /* 139 */ "VARCHAR", - /* 140 */ "MEDIUMBLOB", - /* 141 */ "BLOB", - /* 142 */ "VARBINARY", - /* 143 */ "GEOMETRY", - /* 144 */ "DECIMAL", - /* 145 */ "COMMENT", - /* 146 */ "MAX_DELAY", - /* 147 */ "WATERMARK", - /* 148 */ "ROLLUP", - /* 149 */ "TTL", - /* 150 */ "SMA", - /* 151 */ "DELETE_MARK", - /* 152 */ "FIRST", - /* 153 */ "LAST", - /* 154 */ "SHOW", - /* 155 */ "FULL", - /* 156 */ "PRIVILEGES", - /* 157 */ "DATABASES", - /* 158 */ "TABLES", - /* 159 */ "STABLES", - /* 160 */ "MNODES", - /* 161 */ "QNODES", - /* 162 */ "ARBGROUPS", - /* 163 */ "FUNCTIONS", - /* 164 */ "INDEXES", - /* 165 */ "ACCOUNTS", - /* 166 */ "APPS", - /* 167 */ "CONNECTIONS", - /* 168 */ "LICENCES", - /* 169 */ "GRANTS", - /* 170 */ "LOGS", - /* 171 */ "MACHINES", - /* 172 */ "ENCRYPTIONS", - /* 173 */ "QUERIES", - /* 174 */ "SCORES", - /* 175 */ "TOPICS", - /* 176 */ "VARIABLES", - /* 177 */ "BNODES", - /* 178 */ "SNODES", - /* 179 */ "TRANSACTIONS", - /* 180 */ "DISTRIBUTED", - /* 181 */ "CONSUMERS", - /* 182 */ "SUBSCRIPTIONS", - /* 183 */ "VNODES", - /* 184 */ "ALIVE", - /* 185 */ "VIEWS", - /* 186 */ "VIEW", - /* 187 */ "COMPACTS", - /* 188 */ "NORMAL", - /* 189 */ "CHILD", - /* 190 */ "LIKE", - /* 191 */ "TBNAME", - /* 192 */ "QTAGS", - /* 193 */ "AS", - /* 194 */ "SYSTEM", - /* 195 */ "TSMA", - /* 196 */ "INTERVAL", - /* 197 */ "RECURSIVE", - /* 198 */ "TSMAS", - /* 199 */ "FUNCTION", - /* 200 */ "INDEX", - /* 201 */ "COUNT", - /* 202 */ "LAST_ROW", - /* 203 */ "META", - /* 204 */ "ONLY", - /* 205 */ "TOPIC", - /* 206 */ "CONSUMER", - /* 207 */ "GROUP", - /* 208 */ "DESC", - /* 209 */ "DESCRIBE", - /* 210 */ "RESET", - /* 211 */ "QUERY", - /* 212 */ "CACHE", - /* 213 */ "EXPLAIN", - /* 214 */ "ANALYZE", - /* 215 */ "VERBOSE", - /* 216 */ "NK_BOOL", - /* 217 */ "RATIO", - /* 218 */ "NK_FLOAT", - /* 219 */ "OUTPUTTYPE", - /* 220 */ "AGGREGATE", - /* 221 */ "BUFSIZE", - /* 222 */ "LANGUAGE", - /* 223 */ "REPLACE", - /* 224 */ "STREAM", - /* 225 */ "INTO", - /* 226 */ "PAUSE", - /* 227 */ "RESUME", - /* 228 */ "PRIMARY", - /* 229 */ "KEY", - /* 230 */ "TRIGGER", - /* 231 */ "AT_ONCE", - /* 232 */ "WINDOW_CLOSE", - /* 233 */ "IGNORE", - /* 234 */ "EXPIRED", - /* 235 */ "FILL_HISTORY", - /* 236 */ "UPDATE", - /* 237 */ "SUBTABLE", - /* 238 */ "UNTREATED", - /* 239 */ "KILL", - /* 240 */ "CONNECTION", - /* 241 */ "TRANSACTION", - /* 242 */ "BALANCE", - /* 243 */ "VGROUP", - /* 244 */ "LEADER", - /* 245 */ "MERGE", - /* 246 */ "REDISTRIBUTE", - /* 247 */ "SPLIT", - /* 248 */ "DELETE", - /* 249 */ "INSERT", - /* 250 */ "NK_BIN", - /* 251 */ "NK_HEX", - /* 252 */ "NULL", - /* 253 */ "NK_QUESTION", - /* 254 */ "NK_ALIAS", - /* 255 */ "NK_ARROW", - /* 256 */ "ROWTS", - /* 257 */ "QSTART", - /* 258 */ "QEND", - /* 259 */ "QDURATION", - /* 260 */ "WSTART", - /* 261 */ "WEND", - /* 262 */ "WDURATION", - /* 263 */ "IROWTS", - /* 264 */ "ISFILLED", - /* 265 */ "CAST", - /* 266 */ "POSITION", - /* 267 */ "IN", - /* 268 */ "FOR", - /* 269 */ "NOW", - /* 270 */ "TODAY", - /* 271 */ "RAND", - /* 272 */ "SUBSTR", - /* 273 */ "SUBSTRING", - /* 274 */ "BOTH", - /* 275 */ "TRAILING", - /* 276 */ "LEADING", - /* 277 */ "TIMEZONE", - /* 278 */ "CLIENT_VERSION", - /* 279 */ "SERVER_VERSION", - /* 280 */ "SERVER_STATUS", - /* 281 */ "CURRENT_USER", - /* 282 */ "PI", - /* 283 */ "CASE", - /* 284 */ "WHEN", - /* 285 */ "THEN", - /* 286 */ "ELSE", - /* 287 */ "BETWEEN", - /* 288 */ "IS", - /* 289 */ "NK_LT", - /* 290 */ "NK_GT", - /* 291 */ "NK_LE", - /* 292 */ "NK_GE", - /* 293 */ "NK_NE", - /* 294 */ "MATCH", - /* 295 */ "NMATCH", - /* 296 */ "CONTAINS", - /* 297 */ "JOIN", - /* 298 */ "INNER", - /* 299 */ "LEFT", - /* 300 */ "RIGHT", - /* 301 */ "OUTER", - /* 302 */ "SEMI", - /* 303 */ "ANTI", - /* 304 */ "ASOF", - /* 305 */ "WINDOW", - /* 306 */ "WINDOW_OFFSET", - /* 307 */ "JLIMIT", - /* 308 */ "SELECT", - /* 309 */ "NK_HINT", - /* 310 */ "DISTINCT", - /* 311 */ "WHERE", - /* 312 */ "PARTITION", - /* 313 */ "BY", - /* 314 */ "SESSION", - /* 315 */ "STATE_WINDOW", - /* 316 */ "EVENT_WINDOW", - /* 317 */ "COUNT_WINDOW", - /* 318 */ "SLIDING", - /* 319 */ "FILL", - /* 320 */ "VALUE", - /* 321 */ "VALUE_F", - /* 322 */ "NONE", - /* 323 */ "PREV", - /* 324 */ "NULL_F", - /* 325 */ "LINEAR", - /* 326 */ "NEXT", - /* 327 */ "HAVING", - /* 328 */ "RANGE", - /* 329 */ "EVERY", - /* 330 */ "ORDER", - /* 331 */ "SLIMIT", - /* 332 */ "SOFFSET", - /* 333 */ "LIMIT", - /* 334 */ "OFFSET", - /* 335 */ "ASC", - /* 336 */ "NULLS", - /* 337 */ "ABORT", - /* 338 */ "AFTER", - /* 339 */ "ATTACH", - /* 340 */ "BEFORE", - /* 341 */ "BEGIN", - /* 342 */ "BITAND", - /* 343 */ "BITNOT", - /* 344 */ "BITOR", - /* 345 */ "BLOCKS", - /* 346 */ "CHANGE", - /* 347 */ "COMMA", - /* 348 */ "CONCAT", - /* 349 */ "CONFLICT", - /* 350 */ "COPY", - /* 351 */ "DEFERRED", - /* 352 */ "DELIMITERS", - /* 353 */ "DETACH", - /* 354 */ "DIVIDE", - /* 355 */ "DOT", - /* 356 */ "EACH", - /* 357 */ "FAIL", - /* 358 */ "GLOB", - /* 359 */ "ID", - /* 360 */ "IMMEDIATE", - /* 361 */ "IMPORT", - /* 362 */ "INITIALLY", - /* 363 */ "INSTEAD", - /* 364 */ "ISNULL", - /* 365 */ "MODULES", - /* 366 */ "NK_BITNOT", - /* 367 */ "NK_SEMI", - /* 368 */ "NOTNULL", - /* 369 */ "OF", - /* 370 */ "PLUS", - /* 371 */ "PRIVILEGE", - /* 372 */ "RAISE", - /* 373 */ "RESTRICT", - /* 374 */ "ROW", - /* 375 */ "STAR", - /* 376 */ "STATEMENT", - /* 377 */ "STRICT", - /* 378 */ "STRING", - /* 379 */ "TIMES", - /* 380 */ "VALUES", - /* 381 */ "VARIABLE", - /* 382 */ "WAL", - /* 383 */ "cmd", - /* 384 */ "account_options", - /* 385 */ "alter_account_options", - /* 386 */ "literal", - /* 387 */ "alter_account_option", - /* 388 */ "ip_range_list", - /* 389 */ "white_list", - /* 390 */ "white_list_opt", - /* 391 */ "is_import_opt", - /* 392 */ "is_createdb_opt", - /* 393 */ "user_name", - /* 394 */ "sysinfo_opt", - /* 395 */ "privileges", - /* 396 */ "priv_level", - /* 397 */ "with_opt", - /* 398 */ "priv_type_list", - /* 399 */ "priv_type", - /* 400 */ "db_name", - /* 401 */ "table_name", - /* 402 */ "topic_name", - /* 403 */ "search_condition", - /* 404 */ "dnode_endpoint", - /* 405 */ "force_opt", - /* 406 */ "unsafe_opt", - /* 407 */ "not_exists_opt", - /* 408 */ "db_options", - /* 409 */ "exists_opt", - /* 410 */ "alter_db_options", - /* 411 */ "speed_opt", - /* 412 */ "start_opt", - /* 413 */ "end_opt", - /* 414 */ "integer_list", - /* 415 */ "variable_list", - /* 416 */ "retention_list", - /* 417 */ "signed", - /* 418 */ "alter_db_option", - /* 419 */ "retention", - /* 420 */ "full_table_name", - /* 421 */ "column_def_list", - /* 422 */ "tags_def_opt", - /* 423 */ "table_options", - /* 424 */ "multi_create_clause", - /* 425 */ "tag_list_opt", - /* 426 */ "tags_def", - /* 427 */ "multi_drop_clause", - /* 428 */ "alter_table_clause", - /* 429 */ "alter_table_options", - /* 430 */ "column_name", - /* 431 */ "type_name", - /* 432 */ "column_options", - /* 433 */ "tags_literal", - /* 434 */ "create_subtable_clause", - /* 435 */ "specific_cols_opt", - /* 436 */ "tags_literal_list", - /* 437 */ "drop_table_clause", - /* 438 */ "col_name_list", - /* 439 */ "tag_def_list", - /* 440 */ "tag_def", - /* 441 */ "column_def", - /* 442 */ "type_name_default_len", - /* 443 */ "duration_list", - /* 444 */ "rollup_func_list", - /* 445 */ "alter_table_option", - /* 446 */ "duration_literal", - /* 447 */ "rollup_func_name", - /* 448 */ "function_name", - /* 449 */ "col_name", - /* 450 */ "db_kind_opt", - /* 451 */ "table_kind_db_name_cond_opt", - /* 452 */ "like_pattern_opt", - /* 453 */ "db_name_cond_opt", - /* 454 */ "table_name_cond", - /* 455 */ "from_db_opt", - /* 456 */ "table_kind", - /* 457 */ "tag_item", - /* 458 */ "column_alias", - /* 459 */ "tsma_name", - /* 460 */ "tsma_func_list", - /* 461 */ "full_tsma_name", - /* 462 */ "func_list", - /* 463 */ "index_options", - /* 464 */ "full_index_name", - /* 465 */ "index_name", - /* 466 */ "sliding_opt", - /* 467 */ "sma_stream_opt", - /* 468 */ "func", - /* 469 */ "sma_func_name", - /* 470 */ "expression_list", - /* 471 */ "with_meta", - /* 472 */ "query_or_subquery", - /* 473 */ "where_clause_opt", - /* 474 */ "cgroup_name", - /* 475 */ "analyze_opt", - /* 476 */ "explain_options", - /* 477 */ "insert_query", - /* 478 */ "or_replace_opt", - /* 479 */ "agg_func_opt", - /* 480 */ "bufsize_opt", - /* 481 */ "language_opt", - /* 482 */ "full_view_name", - /* 483 */ "view_name", - /* 484 */ "stream_name", - /* 485 */ "stream_options", - /* 486 */ "col_list_opt", - /* 487 */ "tag_def_or_ref_opt", - /* 488 */ "subtable_opt", - /* 489 */ "ignore_opt", - /* 490 */ "column_stream_def_list", - /* 491 */ "column_stream_def", - /* 492 */ "stream_col_options", - /* 493 */ "expression", - /* 494 */ "on_vgroup_id", - /* 495 */ "dnode_list", - /* 496 */ "literal_func", - /* 497 */ "signed_literal", - /* 498 */ "literal_list", - /* 499 */ "table_alias", - /* 500 */ "expr_or_subquery", - /* 501 */ "pseudo_column", - /* 502 */ "column_reference", - /* 503 */ "function_expression", - /* 504 */ "case_when_expression", - /* 505 */ "star_func", - /* 506 */ "star_func_para_list", - /* 507 */ "trim_specification_type", - /* 508 */ "substr_func", - /* 509 */ "rand_func", - /* 510 */ "noarg_func", - /* 511 */ "other_para_list", - /* 512 */ "star_func_para", - /* 513 */ "when_then_list", - /* 514 */ "case_when_else_opt", - /* 515 */ "common_expression", - /* 516 */ "when_then_expr", - /* 517 */ "predicate", - /* 518 */ "compare_op", - /* 519 */ "in_op", - /* 520 */ "in_predicate_value", - /* 521 */ "boolean_value_expression", - /* 522 */ "boolean_primary", - /* 523 */ "from_clause_opt", - /* 524 */ "table_reference_list", - /* 525 */ "table_reference", - /* 526 */ "table_primary", - /* 527 */ "joined_table", - /* 528 */ "alias_opt", - /* 529 */ "subquery", - /* 530 */ "parenthesized_joined_table", - /* 531 */ "join_type", - /* 532 */ "join_subtype", - /* 533 */ "join_on_clause_opt", - /* 534 */ "window_offset_clause_opt", - /* 535 */ "jlimit_clause_opt", - /* 536 */ "window_offset_literal", - /* 537 */ "query_specification", - /* 538 */ "hint_list", - /* 539 */ "set_quantifier_opt", - /* 540 */ "tag_mode_opt", - /* 541 */ "select_list", - /* 542 */ "partition_by_clause_opt", - /* 543 */ "range_opt", - /* 544 */ "every_opt", - /* 545 */ "fill_opt", - /* 546 */ "twindow_clause_opt", - /* 547 */ "group_by_clause_opt", - /* 548 */ "having_clause_opt", - /* 549 */ "select_item", - /* 550 */ "partition_list", - /* 551 */ "partition_item", - /* 552 */ "interval_sliding_duration_literal", - /* 553 */ "fill_mode", - /* 554 */ "group_by_list", - /* 555 */ "query_expression", - /* 556 */ "query_simple", - /* 557 */ "order_by_clause_opt", - /* 558 */ "slimit_clause_opt", - /* 559 */ "limit_clause_opt", - /* 560 */ "union_query_expression", - /* 561 */ "query_simple_or_subquery", - /* 562 */ "sort_specification_list", - /* 563 */ "sort_specification", - /* 564 */ "ordering_specification_opt", - /* 565 */ "null_ordering_opt", +static const char *const yyTokenName[] = { + /* 0 */ "$", + /* 1 */ "OR", + /* 2 */ "AND", + /* 3 */ "UNION", + /* 4 */ "ALL", + /* 5 */ "MINUS", + /* 6 */ "EXCEPT", + /* 7 */ "INTERSECT", + /* 8 */ "NK_BITAND", + /* 9 */ "NK_BITOR", + /* 10 */ "NK_LSHIFT", + /* 11 */ "NK_RSHIFT", + /* 12 */ "NK_PLUS", + /* 13 */ "NK_MINUS", + /* 14 */ "NK_STAR", + /* 15 */ "NK_SLASH", + /* 16 */ "NK_REM", + /* 17 */ "NK_CONCAT", + /* 18 */ "CREATE", + /* 19 */ "ACCOUNT", + /* 20 */ "NK_ID", + /* 21 */ "PASS", + /* 22 */ "NK_STRING", + /* 23 */ "ALTER", + /* 24 */ "PPS", + /* 25 */ "TSERIES", + /* 26 */ "STORAGE", + /* 27 */ "STREAMS", + /* 28 */ "QTIME", + /* 29 */ "DBS", + /* 30 */ "USERS", + /* 31 */ "CONNS", + /* 32 */ "STATE", + /* 33 */ "NK_COMMA", + /* 34 */ "HOST", + /* 35 */ "IS_IMPORT", + /* 36 */ "NK_INTEGER", + /* 37 */ "CREATEDB", + /* 38 */ "USER", + /* 39 */ "ENABLE", + /* 40 */ "SYSINFO", + /* 41 */ "ADD", + /* 42 */ "DROP", + /* 43 */ "GRANT", + /* 44 */ "ON", + /* 45 */ "TO", + /* 46 */ "REVOKE", + /* 47 */ "FROM", + /* 48 */ "SUBSCRIBE", + /* 49 */ "READ", + /* 50 */ "WRITE", + /* 51 */ "NK_DOT", + /* 52 */ "WITH", + /* 53 */ "ENCRYPT_KEY", + /* 54 */ "DNODE", + /* 55 */ "PORT", + /* 56 */ "DNODES", + /* 57 */ "RESTORE", + /* 58 */ "NK_IPTOKEN", + /* 59 */ "FORCE", + /* 60 */ "UNSAFE", + /* 61 */ "CLUSTER", + /* 62 */ "LOCAL", + /* 63 */ "QNODE", + /* 64 */ "BNODE", + /* 65 */ "SNODE", + /* 66 */ "MNODE", + /* 67 */ "VNODE", + /* 68 */ "DATABASE", + /* 69 */ "USE", + /* 70 */ "FLUSH", + /* 71 */ "TRIM", + /* 72 */ "S3MIGRATE", + /* 73 */ "COMPACT", + /* 74 */ "IF", + /* 75 */ "NOT", + /* 76 */ "EXISTS", + /* 77 */ "BUFFER", + /* 78 */ "CACHEMODEL", + /* 79 */ "CACHESIZE", + /* 80 */ "COMP", + /* 81 */ "DURATION", + /* 82 */ "NK_VARIABLE", + /* 83 */ "MAXROWS", + /* 84 */ "MINROWS", + /* 85 */ "KEEP", + /* 86 */ "PAGES", + /* 87 */ "PAGESIZE", + /* 88 */ "TSDB_PAGESIZE", + /* 89 */ "PRECISION", + /* 90 */ "REPLICA", + /* 91 */ "VGROUPS", + /* 92 */ "SINGLE_STABLE", + /* 93 */ "RETENTIONS", + /* 94 */ "SCHEMALESS", + /* 95 */ "WAL_LEVEL", + /* 96 */ "WAL_FSYNC_PERIOD", + /* 97 */ "WAL_RETENTION_PERIOD", + /* 98 */ "WAL_RETENTION_SIZE", + /* 99 */ "WAL_ROLL_PERIOD", + /* 100 */ "WAL_SEGMENT_SIZE", + /* 101 */ "STT_TRIGGER", + /* 102 */ "TABLE_PREFIX", + /* 103 */ "TABLE_SUFFIX", + /* 104 */ "S3_CHUNKSIZE", + /* 105 */ "S3_KEEPLOCAL", + /* 106 */ "S3_COMPACT", + /* 107 */ "KEEP_TIME_OFFSET", + /* 108 */ "ENCRYPT_ALGORITHM", + /* 109 */ "NK_COLON", + /* 110 */ "BWLIMIT", + /* 111 */ "START", + /* 112 */ "TIMESTAMP", + /* 113 */ "END", + /* 114 */ "TABLE", + /* 115 */ "NK_LP", + /* 116 */ "NK_RP", + /* 117 */ "USING", + /* 118 */ "FILE", + /* 119 */ "STABLE", + /* 120 */ "COLUMN", + /* 121 */ "MODIFY", + /* 122 */ "RENAME", + /* 123 */ "TAG", + /* 124 */ "SET", + /* 125 */ "NK_EQ", + /* 126 */ "TAGS", + /* 127 */ "BOOL", + /* 128 */ "TINYINT", + /* 129 */ "SMALLINT", + /* 130 */ "INT", + /* 131 */ "INTEGER", + /* 132 */ "BIGINT", + /* 133 */ "FLOAT", + /* 134 */ "DOUBLE", + /* 135 */ "BINARY", + /* 136 */ "NCHAR", + /* 137 */ "UNSIGNED", + /* 138 */ "JSON", + /* 139 */ "VARCHAR", + /* 140 */ "MEDIUMBLOB", + /* 141 */ "BLOB", + /* 142 */ "VARBINARY", + /* 143 */ "GEOMETRY", + /* 144 */ "DECIMAL", + /* 145 */ "COMMENT", + /* 146 */ "MAX_DELAY", + /* 147 */ "WATERMARK", + /* 148 */ "ROLLUP", + /* 149 */ "TTL", + /* 150 */ "SMA", + /* 151 */ "DELETE_MARK", + /* 152 */ "FIRST", + /* 153 */ "LAST", + /* 154 */ "SHOW", + /* 155 */ "FULL", + /* 156 */ "PRIVILEGES", + /* 157 */ "DATABASES", + /* 158 */ "TABLES", + /* 159 */ "STABLES", + /* 160 */ "MNODES", + /* 161 */ "QNODES", + /* 162 */ "ARBGROUPS", + /* 163 */ "FUNCTIONS", + /* 164 */ "INDEXES", + /* 165 */ "ACCOUNTS", + /* 166 */ "APPS", + /* 167 */ "CONNECTIONS", + /* 168 */ "LICENCES", + /* 169 */ "GRANTS", + /* 170 */ "LOGS", + /* 171 */ "MACHINES", + /* 172 */ "ENCRYPTIONS", + /* 173 */ "QUERIES", + /* 174 */ "SCORES", + /* 175 */ "TOPICS", + /* 176 */ "VARIABLES", + /* 177 */ "BNODES", + /* 178 */ "SNODES", + /* 179 */ "TRANSACTIONS", + /* 180 */ "DISTRIBUTED", + /* 181 */ "CONSUMERS", + /* 182 */ "SUBSCRIPTIONS", + /* 183 */ "VNODES", + /* 184 */ "ALIVE", + /* 185 */ "VIEWS", + /* 186 */ "VIEW", + /* 187 */ "COMPACTS", + /* 188 */ "NORMAL", + /* 189 */ "CHILD", + /* 190 */ "LIKE", + /* 191 */ "TBNAME", + /* 192 */ "QTAGS", + /* 193 */ "AS", + /* 194 */ "SYSTEM", + /* 195 */ "TSMA", + /* 196 */ "INTERVAL", + /* 197 */ "RECURSIVE", + /* 198 */ "TSMAS", + /* 199 */ "FUNCTION", + /* 200 */ "INDEX", + /* 201 */ "COUNT", + /* 202 */ "LAST_ROW", + /* 203 */ "META", + /* 204 */ "ONLY", + /* 205 */ "TOPIC", + /* 206 */ "CONSUMER", + /* 207 */ "GROUP", + /* 208 */ "DESC", + /* 209 */ "DESCRIBE", + /* 210 */ "RESET", + /* 211 */ "QUERY", + /* 212 */ "CACHE", + /* 213 */ "EXPLAIN", + /* 214 */ "ANALYZE", + /* 215 */ "VERBOSE", + /* 216 */ "NK_BOOL", + /* 217 */ "RATIO", + /* 218 */ "NK_FLOAT", + /* 219 */ "OUTPUTTYPE", + /* 220 */ "AGGREGATE", + /* 221 */ "BUFSIZE", + /* 222 */ "LANGUAGE", + /* 223 */ "REPLACE", + /* 224 */ "STREAM", + /* 225 */ "INTO", + /* 226 */ "PAUSE", + /* 227 */ "RESUME", + /* 228 */ "PRIMARY", + /* 229 */ "KEY", + /* 230 */ "TRIGGER", + /* 231 */ "AT_ONCE", + /* 232 */ "WINDOW_CLOSE", + /* 233 */ "IGNORE", + /* 234 */ "EXPIRED", + /* 235 */ "FILL_HISTORY", + /* 236 */ "UPDATE", + /* 237 */ "SUBTABLE", + /* 238 */ "UNTREATED", + /* 239 */ "KILL", + /* 240 */ "CONNECTION", + /* 241 */ "TRANSACTION", + /* 242 */ "BALANCE", + /* 243 */ "VGROUP", + /* 244 */ "LEADER", + /* 245 */ "MERGE", + /* 246 */ "REDISTRIBUTE", + /* 247 */ "SPLIT", + /* 248 */ "DELETE", + /* 249 */ "INSERT", + /* 250 */ "NK_BIN", + /* 251 */ "NK_HEX", + /* 252 */ "NULL", + /* 253 */ "NK_QUESTION", + /* 254 */ "NK_ALIAS", + /* 255 */ "NK_ARROW", + /* 256 */ "ROWTS", + /* 257 */ "QSTART", + /* 258 */ "QEND", + /* 259 */ "QDURATION", + /* 260 */ "WSTART", + /* 261 */ "WEND", + /* 262 */ "WDURATION", + /* 263 */ "IROWTS", + /* 264 */ "ISFILLED", + /* 265 */ "CAST", + /* 266 */ "POSITION", + /* 267 */ "IN", + /* 268 */ "FOR", + /* 269 */ "NOW", + /* 270 */ "TODAY", + /* 271 */ "RAND", + /* 272 */ "SUBSTR", + /* 273 */ "SUBSTRING", + /* 274 */ "BOTH", + /* 275 */ "TRAILING", + /* 276 */ "LEADING", + /* 277 */ "TIMEZONE", + /* 278 */ "CLIENT_VERSION", + /* 279 */ "SERVER_VERSION", + /* 280 */ "SERVER_STATUS", + /* 281 */ "CURRENT_USER", + /* 282 */ "PI", + /* 283 */ "CASE", + /* 284 */ "WHEN", + /* 285 */ "THEN", + /* 286 */ "ELSE", + /* 287 */ "BETWEEN", + /* 288 */ "IS", + /* 289 */ "NK_LT", + /* 290 */ "NK_GT", + /* 291 */ "NK_LE", + /* 292 */ "NK_GE", + /* 293 */ "NK_NE", + /* 294 */ "MATCH", + /* 295 */ "NMATCH", + /* 296 */ "CONTAINS", + /* 297 */ "JOIN", + /* 298 */ "INNER", + /* 299 */ "LEFT", + /* 300 */ "RIGHT", + /* 301 */ "OUTER", + /* 302 */ "SEMI", + /* 303 */ "ANTI", + /* 304 */ "ASOF", + /* 305 */ "WINDOW", + /* 306 */ "WINDOW_OFFSET", + /* 307 */ "JLIMIT", + /* 308 */ "SELECT", + /* 309 */ "NK_HINT", + /* 310 */ "DISTINCT", + /* 311 */ "WHERE", + /* 312 */ "PARTITION", + /* 313 */ "BY", + /* 314 */ "SESSION", + /* 315 */ "STATE_WINDOW", + /* 316 */ "EVENT_WINDOW", + /* 317 */ "COUNT_WINDOW", + /* 318 */ "SLIDING", + /* 319 */ "FILL", + /* 320 */ "VALUE", + /* 321 */ "VALUE_F", + /* 322 */ "NONE", + /* 323 */ "PREV", + /* 324 */ "NULL_F", + /* 325 */ "LINEAR", + /* 326 */ "NEXT", + /* 327 */ "HAVING", + /* 328 */ "RANGE", + /* 329 */ "EVERY", + /* 330 */ "ORDER", + /* 331 */ "SLIMIT", + /* 332 */ "SOFFSET", + /* 333 */ "LIMIT", + /* 334 */ "OFFSET", + /* 335 */ "ASC", + /* 336 */ "NULLS", + /* 337 */ "ABORT", + /* 338 */ "AFTER", + /* 339 */ "ATTACH", + /* 340 */ "BEFORE", + /* 341 */ "BEGIN", + /* 342 */ "BITAND", + /* 343 */ "BITNOT", + /* 344 */ "BITOR", + /* 345 */ "BLOCKS", + /* 346 */ "CHANGE", + /* 347 */ "COMMA", + /* 348 */ "CONCAT", + /* 349 */ "CONFLICT", + /* 350 */ "COPY", + /* 351 */ "DEFERRED", + /* 352 */ "DELIMITERS", + /* 353 */ "DETACH", + /* 354 */ "DIVIDE", + /* 355 */ "DOT", + /* 356 */ "EACH", + /* 357 */ "FAIL", + /* 358 */ "GLOB", + /* 359 */ "ID", + /* 360 */ "IMMEDIATE", + /* 361 */ "IMPORT", + /* 362 */ "INITIALLY", + /* 363 */ "INSTEAD", + /* 364 */ "ISNULL", + /* 365 */ "MODULES", + /* 366 */ "NK_BITNOT", + /* 367 */ "NK_SEMI", + /* 368 */ "NOTNULL", + /* 369 */ "OF", + /* 370 */ "PLUS", + /* 371 */ "PRIVILEGE", + /* 372 */ "RAISE", + /* 373 */ "RESTRICT", + /* 374 */ "ROW", + /* 375 */ "STAR", + /* 376 */ "STATEMENT", + /* 377 */ "STRICT", + /* 378 */ "STRING", + /* 379 */ "TIMES", + /* 380 */ "VALUES", + /* 381 */ "VARIABLE", + /* 382 */ "WAL", + /* 383 */ "cmd", + /* 384 */ "account_options", + /* 385 */ "alter_account_options", + /* 386 */ "literal", + /* 387 */ "alter_account_option", + /* 388 */ "ip_range_list", + /* 389 */ "white_list", + /* 390 */ "white_list_opt", + /* 391 */ "is_import_opt", + /* 392 */ "is_createdb_opt", + /* 393 */ "user_name", + /* 394 */ "sysinfo_opt", + /* 395 */ "privileges", + /* 396 */ "priv_level", + /* 397 */ "with_clause_opt", + /* 398 */ "priv_type_list", + /* 399 */ "priv_type", + /* 400 */ "db_name", + /* 401 */ "table_name", + /* 402 */ "topic_name", + /* 403 */ "search_condition", + /* 404 */ "dnode_endpoint", + /* 405 */ "force_opt", + /* 406 */ "unsafe_opt", + /* 407 */ "not_exists_opt", + /* 408 */ "db_options", + /* 409 */ "exists_opt", + /* 410 */ "alter_db_options", + /* 411 */ "speed_opt", + /* 412 */ "start_opt", + /* 413 */ "end_opt", + /* 414 */ "integer_list", + /* 415 */ "variable_list", + /* 416 */ "retention_list", + /* 417 */ "signed", + /* 418 */ "alter_db_option", + /* 419 */ "retention", + /* 420 */ "full_table_name", + /* 421 */ "column_def_list", + /* 422 */ "tags_def_opt", + /* 423 */ "table_options", + /* 424 */ "multi_create_clause", + /* 425 */ "tag_list_opt", + /* 426 */ "tags_def", + /* 427 */ "with_opt", + /* 428 */ "multi_drop_clause", + /* 429 */ "alter_table_clause", + /* 430 */ "alter_table_options", + /* 431 */ "column_name", + /* 432 */ "type_name", + /* 433 */ "column_options", + /* 434 */ "tags_literal", + /* 435 */ "create_subtable_clause", + /* 436 */ "specific_cols_opt", + /* 437 */ "tags_literal_list", + /* 438 */ "drop_table_clause", + /* 439 */ "col_name_list", + /* 440 */ "tag_def_list", + /* 441 */ "tag_def", + /* 442 */ "column_def", + /* 443 */ "type_name_default_len", + /* 444 */ "duration_list", + /* 445 */ "rollup_func_list", + /* 446 */ "alter_table_option", + /* 447 */ "duration_literal", + /* 448 */ "rollup_func_name", + /* 449 */ "function_name", + /* 450 */ "col_name", + /* 451 */ "db_kind_opt", + /* 452 */ "table_kind_db_name_cond_opt", + /* 453 */ "like_pattern_opt", + /* 454 */ "db_name_cond_opt", + /* 455 */ "table_name_cond", + /* 456 */ "from_db_opt", + /* 457 */ "table_kind", + /* 458 */ "tag_item", + /* 459 */ "column_alias", + /* 460 */ "tsma_name", + /* 461 */ "tsma_func_list", + /* 462 */ "full_tsma_name", + /* 463 */ "func_list", + /* 464 */ "index_options", + /* 465 */ "full_index_name", + /* 466 */ "index_name", + /* 467 */ "sliding_opt", + /* 468 */ "sma_stream_opt", + /* 469 */ "func", + /* 470 */ "sma_func_name", + /* 471 */ "expression_list", + /* 472 */ "with_meta", + /* 473 */ "query_or_subquery", + /* 474 */ "where_clause_opt", + /* 475 */ "cgroup_name", + /* 476 */ "analyze_opt", + /* 477 */ "explain_options", + /* 478 */ "insert_query", + /* 479 */ "or_replace_opt", + /* 480 */ "agg_func_opt", + /* 481 */ "bufsize_opt", + /* 482 */ "language_opt", + /* 483 */ "full_view_name", + /* 484 */ "view_name", + /* 485 */ "stream_name", + /* 486 */ "stream_options", + /* 487 */ "col_list_opt", + /* 488 */ "tag_def_or_ref_opt", + /* 489 */ "subtable_opt", + /* 490 */ "ignore_opt", + /* 491 */ "column_stream_def_list", + /* 492 */ "column_stream_def", + /* 493 */ "stream_col_options", + /* 494 */ "expression", + /* 495 */ "on_vgroup_id", + /* 496 */ "dnode_list", + /* 497 */ "literal_func", + /* 498 */ "signed_literal", + /* 499 */ "literal_list", + /* 500 */ "table_alias", + /* 501 */ "expr_or_subquery", + /* 502 */ "pseudo_column", + /* 503 */ "column_reference", + /* 504 */ "function_expression", + /* 505 */ "case_when_expression", + /* 506 */ "star_func", + /* 507 */ "star_func_para_list", + /* 508 */ "trim_specification_type", + /* 509 */ "substr_func", + /* 510 */ "rand_func", + /* 511 */ "noarg_func", + /* 512 */ "other_para_list", + /* 513 */ "star_func_para", + /* 514 */ "when_then_list", + /* 515 */ "case_when_else_opt", + /* 516 */ "common_expression", + /* 517 */ "when_then_expr", + /* 518 */ "predicate", + /* 519 */ "compare_op", + /* 520 */ "in_op", + /* 521 */ "in_predicate_value", + /* 522 */ "boolean_value_expression", + /* 523 */ "boolean_primary", + /* 524 */ "from_clause_opt", + /* 525 */ "table_reference_list", + /* 526 */ "table_reference", + /* 527 */ "table_primary", + /* 528 */ "joined_table", + /* 529 */ "alias_opt", + /* 530 */ "subquery", + /* 531 */ "parenthesized_joined_table", + /* 532 */ "join_type", + /* 533 */ "join_subtype", + /* 534 */ "join_on_clause_opt", + /* 535 */ "window_offset_clause_opt", + /* 536 */ "jlimit_clause_opt", + /* 537 */ "window_offset_literal", + /* 538 */ "query_specification", + /* 539 */ "hint_list", + /* 540 */ "set_quantifier_opt", + /* 541 */ "tag_mode_opt", + /* 542 */ "select_list", + /* 543 */ "partition_by_clause_opt", + /* 544 */ "range_opt", + /* 545 */ "every_opt", + /* 546 */ "fill_opt", + /* 547 */ "twindow_clause_opt", + /* 548 */ "group_by_clause_opt", + /* 549 */ "having_clause_opt", + /* 550 */ "select_item", + /* 551 */ "partition_list", + /* 552 */ "partition_item", + /* 553 */ "interval_sliding_duration_literal", + /* 554 */ "fill_mode", + /* 555 */ "group_by_list", + /* 556 */ "query_expression", + /* 557 */ "query_simple", + /* 558 */ "order_by_clause_opt", + /* 559 */ "slimit_clause_opt", + /* 560 */ "limit_clause_opt", + /* 561 */ "union_query_expression", + /* 562 */ "query_simple_or_subquery", + /* 563 */ "sort_specification_list", + /* 564 */ "sort_specification", + /* 565 */ "ordering_specification_opt", + /* 566 */ "null_ordering_opt", }; #endif /* defined(YYCOVERAGE) || !defined(NDEBUG) */ #ifndef NDEBUG /* For tracing reduce actions, the names of all rules are required. - */ +*/ static const char *const yyRuleName[] = { - /* 0 */ "cmd ::= CREATE ACCOUNT NK_ID PASS NK_STRING account_options", - /* 1 */ "cmd ::= ALTER ACCOUNT NK_ID alter_account_options", - /* 2 */ "account_options ::=", - /* 3 */ "account_options ::= account_options PPS literal", - /* 4 */ "account_options ::= account_options TSERIES literal", - /* 5 */ "account_options ::= account_options STORAGE literal", - /* 6 */ "account_options ::= account_options STREAMS literal", - /* 7 */ "account_options ::= account_options QTIME literal", - /* 8 */ "account_options ::= account_options DBS literal", - /* 9 */ "account_options ::= account_options USERS literal", - /* 10 */ "account_options ::= account_options CONNS literal", - /* 11 */ "account_options ::= account_options STATE literal", - /* 12 */ "alter_account_options ::= alter_account_option", - /* 13 */ "alter_account_options ::= alter_account_options alter_account_option", - /* 14 */ "alter_account_option ::= PASS literal", - /* 15 */ "alter_account_option ::= PPS literal", - /* 16 */ "alter_account_option ::= TSERIES literal", - /* 17 */ "alter_account_option ::= STORAGE literal", - /* 18 */ "alter_account_option ::= STREAMS literal", - /* 19 */ "alter_account_option ::= QTIME literal", - /* 20 */ "alter_account_option ::= DBS literal", - /* 21 */ "alter_account_option ::= USERS literal", - /* 22 */ "alter_account_option ::= CONNS literal", - /* 23 */ "alter_account_option ::= STATE literal", - /* 24 */ "ip_range_list ::= NK_STRING", - /* 25 */ "ip_range_list ::= ip_range_list NK_COMMA NK_STRING", - /* 26 */ "white_list ::= HOST ip_range_list", - /* 27 */ "white_list_opt ::=", - /* 28 */ "white_list_opt ::= white_list", - /* 29 */ "is_import_opt ::=", - /* 30 */ "is_import_opt ::= IS_IMPORT NK_INTEGER", - /* 31 */ "is_createdb_opt ::=", - /* 32 */ "is_createdb_opt ::= CREATEDB NK_INTEGER", - /* 33 */ "cmd ::= CREATE USER user_name PASS NK_STRING sysinfo_opt is_createdb_opt is_import_opt white_list_opt", - /* 34 */ "cmd ::= ALTER USER user_name PASS NK_STRING", - /* 35 */ "cmd ::= ALTER USER user_name ENABLE NK_INTEGER", - /* 36 */ "cmd ::= ALTER USER user_name SYSINFO NK_INTEGER", - /* 37 */ "cmd ::= ALTER USER user_name CREATEDB NK_INTEGER", - /* 38 */ "cmd ::= ALTER USER user_name ADD white_list", - /* 39 */ "cmd ::= ALTER USER user_name DROP white_list", - /* 40 */ "cmd ::= DROP USER user_name", - /* 41 */ "sysinfo_opt ::=", - /* 42 */ "sysinfo_opt ::= SYSINFO NK_INTEGER", - /* 43 */ "cmd ::= GRANT privileges ON priv_level with_opt TO user_name", - /* 44 */ "cmd ::= REVOKE privileges ON priv_level with_opt FROM user_name", - /* 45 */ "privileges ::= ALL", - /* 46 */ "privileges ::= priv_type_list", - /* 47 */ "privileges ::= SUBSCRIBE", - /* 48 */ "priv_type_list ::= priv_type", - /* 49 */ "priv_type_list ::= priv_type_list NK_COMMA priv_type", - /* 50 */ "priv_type ::= READ", - /* 51 */ "priv_type ::= WRITE", - /* 52 */ "priv_type ::= ALTER", - /* 53 */ "priv_level ::= NK_STAR NK_DOT NK_STAR", - /* 54 */ "priv_level ::= db_name NK_DOT NK_STAR", - /* 55 */ "priv_level ::= db_name NK_DOT table_name", - /* 56 */ "priv_level ::= topic_name", - /* 57 */ "with_opt ::=", - /* 58 */ "with_opt ::= WITH search_condition", - /* 59 */ "cmd ::= CREATE ENCRYPT_KEY NK_STRING", - /* 60 */ "cmd ::= CREATE DNODE dnode_endpoint", - /* 61 */ "cmd ::= CREATE DNODE dnode_endpoint PORT NK_INTEGER", - /* 62 */ "cmd ::= DROP DNODE NK_INTEGER force_opt", - /* 63 */ "cmd ::= DROP DNODE dnode_endpoint force_opt", - /* 64 */ "cmd ::= DROP DNODE NK_INTEGER unsafe_opt", - /* 65 */ "cmd ::= DROP DNODE dnode_endpoint unsafe_opt", - /* 66 */ "cmd ::= ALTER DNODE NK_INTEGER NK_STRING", - /* 67 */ "cmd ::= ALTER DNODE NK_INTEGER NK_STRING NK_STRING", - /* 68 */ "cmd ::= ALTER ALL DNODES NK_STRING", - /* 69 */ "cmd ::= ALTER ALL DNODES NK_STRING NK_STRING", - /* 70 */ "cmd ::= RESTORE DNODE NK_INTEGER", - /* 71 */ "dnode_endpoint ::= NK_STRING", - /* 72 */ "dnode_endpoint ::= NK_ID", - /* 73 */ "dnode_endpoint ::= NK_IPTOKEN", - /* 74 */ "force_opt ::=", - /* 75 */ "force_opt ::= FORCE", - /* 76 */ "unsafe_opt ::= UNSAFE", - /* 77 */ "cmd ::= ALTER CLUSTER NK_STRING", - /* 78 */ "cmd ::= ALTER CLUSTER NK_STRING NK_STRING", - /* 79 */ "cmd ::= ALTER LOCAL NK_STRING", - /* 80 */ "cmd ::= ALTER LOCAL NK_STRING NK_STRING", - /* 81 */ "cmd ::= CREATE QNODE ON DNODE NK_INTEGER", - /* 82 */ "cmd ::= DROP QNODE ON DNODE NK_INTEGER", - /* 83 */ "cmd ::= RESTORE QNODE ON DNODE NK_INTEGER", - /* 84 */ "cmd ::= CREATE BNODE ON DNODE NK_INTEGER", - /* 85 */ "cmd ::= DROP BNODE ON DNODE NK_INTEGER", - /* 86 */ "cmd ::= CREATE SNODE ON DNODE NK_INTEGER", - /* 87 */ "cmd ::= DROP SNODE ON DNODE NK_INTEGER", - /* 88 */ "cmd ::= CREATE MNODE ON DNODE NK_INTEGER", - /* 89 */ "cmd ::= DROP MNODE ON DNODE NK_INTEGER", - /* 90 */ "cmd ::= RESTORE MNODE ON DNODE NK_INTEGER", - /* 91 */ "cmd ::= RESTORE VNODE ON DNODE NK_INTEGER", - /* 92 */ "cmd ::= CREATE DATABASE not_exists_opt db_name db_options", - /* 93 */ "cmd ::= DROP DATABASE exists_opt db_name", - /* 94 */ "cmd ::= USE db_name", - /* 95 */ "cmd ::= ALTER DATABASE db_name alter_db_options", - /* 96 */ "cmd ::= FLUSH DATABASE db_name", - /* 97 */ "cmd ::= TRIM DATABASE db_name speed_opt", - /* 98 */ "cmd ::= S3MIGRATE DATABASE db_name", - /* 99 */ "cmd ::= COMPACT DATABASE db_name start_opt end_opt", - /* 100 */ "not_exists_opt ::= IF NOT EXISTS", - /* 101 */ "not_exists_opt ::=", - /* 102 */ "exists_opt ::= IF EXISTS", - /* 103 */ "exists_opt ::=", - /* 104 */ "db_options ::=", - /* 105 */ "db_options ::= db_options BUFFER NK_INTEGER", - /* 106 */ "db_options ::= db_options CACHEMODEL NK_STRING", - /* 107 */ "db_options ::= db_options CACHESIZE NK_INTEGER", - /* 108 */ "db_options ::= db_options COMP NK_INTEGER", - /* 109 */ "db_options ::= db_options DURATION NK_INTEGER", - /* 110 */ "db_options ::= db_options DURATION NK_VARIABLE", - /* 111 */ "db_options ::= db_options MAXROWS NK_INTEGER", - /* 112 */ "db_options ::= db_options MINROWS NK_INTEGER", - /* 113 */ "db_options ::= db_options KEEP integer_list", - /* 114 */ "db_options ::= db_options KEEP variable_list", - /* 115 */ "db_options ::= db_options PAGES NK_INTEGER", - /* 116 */ "db_options ::= db_options PAGESIZE NK_INTEGER", - /* 117 */ "db_options ::= db_options TSDB_PAGESIZE NK_INTEGER", - /* 118 */ "db_options ::= db_options PRECISION NK_STRING", - /* 119 */ "db_options ::= db_options REPLICA NK_INTEGER", - /* 120 */ "db_options ::= db_options VGROUPS NK_INTEGER", - /* 121 */ "db_options ::= db_options SINGLE_STABLE NK_INTEGER", - /* 122 */ "db_options ::= db_options RETENTIONS retention_list", - /* 123 */ "db_options ::= db_options SCHEMALESS NK_INTEGER", - /* 124 */ "db_options ::= db_options WAL_LEVEL NK_INTEGER", - /* 125 */ "db_options ::= db_options WAL_FSYNC_PERIOD NK_INTEGER", - /* 126 */ "db_options ::= db_options WAL_RETENTION_PERIOD NK_INTEGER", - /* 127 */ "db_options ::= db_options WAL_RETENTION_PERIOD NK_MINUS NK_INTEGER", - /* 128 */ "db_options ::= db_options WAL_RETENTION_SIZE NK_INTEGER", - /* 129 */ "db_options ::= db_options WAL_RETENTION_SIZE NK_MINUS NK_INTEGER", - /* 130 */ "db_options ::= db_options WAL_ROLL_PERIOD NK_INTEGER", - /* 131 */ "db_options ::= db_options WAL_SEGMENT_SIZE NK_INTEGER", - /* 132 */ "db_options ::= db_options STT_TRIGGER NK_INTEGER", - /* 133 */ "db_options ::= db_options TABLE_PREFIX signed", - /* 134 */ "db_options ::= db_options TABLE_SUFFIX signed", - /* 135 */ "db_options ::= db_options S3_CHUNKSIZE NK_INTEGER", - /* 136 */ "db_options ::= db_options S3_KEEPLOCAL NK_INTEGER", - /* 137 */ "db_options ::= db_options S3_KEEPLOCAL NK_VARIABLE", - /* 138 */ "db_options ::= db_options S3_COMPACT NK_INTEGER", - /* 139 */ "db_options ::= db_options KEEP_TIME_OFFSET NK_INTEGER", - /* 140 */ "db_options ::= db_options ENCRYPT_ALGORITHM NK_STRING", - /* 141 */ "alter_db_options ::= alter_db_option", - /* 142 */ "alter_db_options ::= alter_db_options alter_db_option", - /* 143 */ "alter_db_option ::= BUFFER NK_INTEGER", - /* 144 */ "alter_db_option ::= CACHEMODEL NK_STRING", - /* 145 */ "alter_db_option ::= CACHESIZE NK_INTEGER", - /* 146 */ "alter_db_option ::= WAL_FSYNC_PERIOD NK_INTEGER", - /* 147 */ "alter_db_option ::= KEEP integer_list", - /* 148 */ "alter_db_option ::= KEEP variable_list", - /* 149 */ "alter_db_option ::= PAGES NK_INTEGER", - /* 150 */ "alter_db_option ::= REPLICA NK_INTEGER", - /* 151 */ "alter_db_option ::= WAL_LEVEL NK_INTEGER", - /* 152 */ "alter_db_option ::= STT_TRIGGER NK_INTEGER", - /* 153 */ "alter_db_option ::= MINROWS NK_INTEGER", - /* 154 */ "alter_db_option ::= WAL_RETENTION_PERIOD NK_INTEGER", - /* 155 */ "alter_db_option ::= WAL_RETENTION_PERIOD NK_MINUS NK_INTEGER", - /* 156 */ "alter_db_option ::= WAL_RETENTION_SIZE NK_INTEGER", - /* 157 */ "alter_db_option ::= WAL_RETENTION_SIZE NK_MINUS NK_INTEGER", - /* 158 */ "alter_db_option ::= S3_KEEPLOCAL NK_INTEGER", - /* 159 */ "alter_db_option ::= S3_KEEPLOCAL NK_VARIABLE", - /* 160 */ "alter_db_option ::= S3_COMPACT NK_INTEGER", - /* 161 */ "alter_db_option ::= KEEP_TIME_OFFSET NK_INTEGER", - /* 162 */ "alter_db_option ::= ENCRYPT_ALGORITHM NK_STRING", - /* 163 */ "integer_list ::= NK_INTEGER", - /* 164 */ "integer_list ::= integer_list NK_COMMA NK_INTEGER", - /* 165 */ "variable_list ::= NK_VARIABLE", - /* 166 */ "variable_list ::= variable_list NK_COMMA NK_VARIABLE", - /* 167 */ "retention_list ::= retention", - /* 168 */ "retention_list ::= retention_list NK_COMMA retention", - /* 169 */ "retention ::= NK_VARIABLE NK_COLON NK_VARIABLE", - /* 170 */ "retention ::= NK_MINUS NK_COLON NK_VARIABLE", - /* 171 */ "speed_opt ::=", - /* 172 */ "speed_opt ::= BWLIMIT NK_INTEGER", - /* 173 */ "start_opt ::=", - /* 174 */ "start_opt ::= START WITH NK_INTEGER", - /* 175 */ "start_opt ::= START WITH NK_STRING", - /* 176 */ "start_opt ::= START WITH TIMESTAMP NK_STRING", - /* 177 */ "end_opt ::=", - /* 178 */ "end_opt ::= END WITH NK_INTEGER", - /* 179 */ "end_opt ::= END WITH NK_STRING", - /* 180 */ "end_opt ::= END WITH TIMESTAMP NK_STRING", - /* 181 */ "cmd ::= CREATE TABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def_opt table_options", - /* 182 */ "cmd ::= CREATE TABLE multi_create_clause", - /* 183 */ "cmd ::= CREATE TABLE not_exists_opt USING full_table_name NK_LP tag_list_opt NK_RP FILE NK_STRING", - /* 184 */ "cmd ::= CREATE STABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def table_options", - /* 185 */ "cmd ::= DROP TABLE multi_drop_clause", - /* 186 */ "cmd ::= DROP STABLE exists_opt full_table_name", - /* 187 */ "cmd ::= ALTER TABLE alter_table_clause", - /* 188 */ "cmd ::= ALTER STABLE alter_table_clause", - /* 189 */ "alter_table_clause ::= full_table_name alter_table_options", - /* 190 */ "alter_table_clause ::= full_table_name ADD COLUMN column_name type_name column_options", - /* 191 */ "alter_table_clause ::= full_table_name DROP COLUMN column_name", - /* 192 */ "alter_table_clause ::= full_table_name MODIFY COLUMN column_name type_name", - /* 193 */ "alter_table_clause ::= full_table_name MODIFY COLUMN column_name column_options", - /* 194 */ "alter_table_clause ::= full_table_name RENAME COLUMN column_name column_name", - /* 195 */ "alter_table_clause ::= full_table_name ADD TAG column_name type_name", - /* 196 */ "alter_table_clause ::= full_table_name DROP TAG column_name", - /* 197 */ "alter_table_clause ::= full_table_name MODIFY TAG column_name type_name", - /* 198 */ "alter_table_clause ::= full_table_name RENAME TAG column_name column_name", - /* 199 */ "alter_table_clause ::= full_table_name SET TAG column_name NK_EQ tags_literal", - /* 200 */ "multi_create_clause ::= create_subtable_clause", - /* 201 */ "multi_create_clause ::= multi_create_clause create_subtable_clause", - /* 202 */ "create_subtable_clause ::= not_exists_opt full_table_name USING full_table_name specific_cols_opt TAGS NK_LP tags_literal_list NK_RP table_options", - /* 203 */ "multi_drop_clause ::= drop_table_clause", - /* 204 */ "multi_drop_clause ::= multi_drop_clause NK_COMMA drop_table_clause", - /* 205 */ "drop_table_clause ::= exists_opt full_table_name", - /* 206 */ "specific_cols_opt ::=", - /* 207 */ "specific_cols_opt ::= NK_LP col_name_list NK_RP", - /* 208 */ "full_table_name ::= table_name", - /* 209 */ "full_table_name ::= db_name NK_DOT table_name", - /* 210 */ "tag_def_list ::= tag_def", - /* 211 */ "tag_def_list ::= tag_def_list NK_COMMA tag_def", - /* 212 */ "tag_def ::= column_name type_name", - /* 213 */ "column_def_list ::= column_def", - /* 214 */ "column_def_list ::= column_def_list NK_COMMA column_def", - /* 215 */ "column_def ::= column_name type_name column_options", - /* 216 */ "type_name ::= BOOL", - /* 217 */ "type_name ::= TINYINT", - /* 218 */ "type_name ::= SMALLINT", - /* 219 */ "type_name ::= INT", - /* 220 */ "type_name ::= INTEGER", - /* 221 */ "type_name ::= BIGINT", - /* 222 */ "type_name ::= FLOAT", - /* 223 */ "type_name ::= DOUBLE", - /* 224 */ "type_name ::= BINARY NK_LP NK_INTEGER NK_RP", - /* 225 */ "type_name ::= TIMESTAMP", - /* 226 */ "type_name ::= NCHAR NK_LP NK_INTEGER NK_RP", - /* 227 */ "type_name ::= TINYINT UNSIGNED", - /* 228 */ "type_name ::= SMALLINT UNSIGNED", - /* 229 */ "type_name ::= INT UNSIGNED", - /* 230 */ "type_name ::= BIGINT UNSIGNED", - /* 231 */ "type_name ::= JSON", - /* 232 */ "type_name ::= VARCHAR NK_LP NK_INTEGER NK_RP", - /* 233 */ "type_name ::= MEDIUMBLOB", - /* 234 */ "type_name ::= BLOB", - /* 235 */ "type_name ::= VARBINARY NK_LP NK_INTEGER NK_RP", - /* 236 */ "type_name ::= GEOMETRY NK_LP NK_INTEGER NK_RP", - /* 237 */ "type_name ::= DECIMAL", - /* 238 */ "type_name ::= DECIMAL NK_LP NK_INTEGER NK_RP", - /* 239 */ "type_name ::= DECIMAL NK_LP NK_INTEGER NK_COMMA NK_INTEGER NK_RP", - /* 240 */ "type_name_default_len ::= BINARY", - /* 241 */ "type_name_default_len ::= NCHAR", - /* 242 */ "type_name_default_len ::= VARCHAR", - /* 243 */ "type_name_default_len ::= VARBINARY", - /* 244 */ "tags_def_opt ::=", - /* 245 */ "tags_def_opt ::= tags_def", - /* 246 */ "tags_def ::= TAGS NK_LP tag_def_list NK_RP", - /* 247 */ "table_options ::=", - /* 248 */ "table_options ::= table_options COMMENT NK_STRING", - /* 249 */ "table_options ::= table_options MAX_DELAY duration_list", - /* 250 */ "table_options ::= table_options WATERMARK duration_list", - /* 251 */ "table_options ::= table_options ROLLUP NK_LP rollup_func_list NK_RP", - /* 252 */ "table_options ::= table_options TTL NK_INTEGER", - /* 253 */ "table_options ::= table_options SMA NK_LP col_name_list NK_RP", - /* 254 */ "table_options ::= table_options DELETE_MARK duration_list", - /* 255 */ "alter_table_options ::= alter_table_option", - /* 256 */ "alter_table_options ::= alter_table_options alter_table_option", - /* 257 */ "alter_table_option ::= COMMENT NK_STRING", - /* 258 */ "alter_table_option ::= TTL NK_INTEGER", - /* 259 */ "duration_list ::= duration_literal", - /* 260 */ "duration_list ::= duration_list NK_COMMA duration_literal", - /* 261 */ "rollup_func_list ::= rollup_func_name", - /* 262 */ "rollup_func_list ::= rollup_func_list NK_COMMA rollup_func_name", - /* 263 */ "rollup_func_name ::= function_name", - /* 264 */ "rollup_func_name ::= FIRST", - /* 265 */ "rollup_func_name ::= LAST", - /* 266 */ "col_name_list ::= col_name", - /* 267 */ "col_name_list ::= col_name_list NK_COMMA col_name", - /* 268 */ "col_name ::= column_name", - /* 269 */ "cmd ::= SHOW DNODES", - /* 270 */ "cmd ::= SHOW USERS", - /* 271 */ "cmd ::= SHOW USERS FULL", - /* 272 */ "cmd ::= SHOW USER PRIVILEGES", - /* 273 */ "cmd ::= SHOW db_kind_opt DATABASES", - /* 274 */ "cmd ::= SHOW table_kind_db_name_cond_opt TABLES like_pattern_opt", - /* 275 */ "cmd ::= SHOW db_name_cond_opt STABLES like_pattern_opt", - /* 276 */ "cmd ::= SHOW db_name_cond_opt VGROUPS", - /* 277 */ "cmd ::= SHOW MNODES", - /* 278 */ "cmd ::= SHOW QNODES", - /* 279 */ "cmd ::= SHOW ARBGROUPS", - /* 280 */ "cmd ::= SHOW FUNCTIONS", - /* 281 */ "cmd ::= SHOW INDEXES FROM table_name_cond from_db_opt", - /* 282 */ "cmd ::= SHOW INDEXES FROM db_name NK_DOT table_name", - /* 283 */ "cmd ::= SHOW STREAMS", - /* 284 */ "cmd ::= SHOW ACCOUNTS", - /* 285 */ "cmd ::= SHOW APPS", - /* 286 */ "cmd ::= SHOW CONNECTIONS", - /* 287 */ "cmd ::= SHOW LICENCES", - /* 288 */ "cmd ::= SHOW GRANTS", - /* 289 */ "cmd ::= SHOW GRANTS FULL", - /* 290 */ "cmd ::= SHOW GRANTS LOGS", - /* 291 */ "cmd ::= SHOW CLUSTER MACHINES", - /* 292 */ "cmd ::= SHOW CREATE DATABASE db_name", - /* 293 */ "cmd ::= SHOW CREATE TABLE full_table_name", - /* 294 */ "cmd ::= SHOW CREATE STABLE full_table_name", - /* 295 */ "cmd ::= SHOW ENCRYPTIONS", - /* 296 */ "cmd ::= SHOW QUERIES", - /* 297 */ "cmd ::= SHOW SCORES", - /* 298 */ "cmd ::= SHOW TOPICS", - /* 299 */ "cmd ::= SHOW VARIABLES", - /* 300 */ "cmd ::= SHOW CLUSTER VARIABLES", - /* 301 */ "cmd ::= SHOW LOCAL VARIABLES", - /* 302 */ "cmd ::= SHOW DNODE NK_INTEGER VARIABLES like_pattern_opt", - /* 303 */ "cmd ::= SHOW BNODES", - /* 304 */ "cmd ::= SHOW SNODES", - /* 305 */ "cmd ::= SHOW CLUSTER", - /* 306 */ "cmd ::= SHOW TRANSACTIONS", - /* 307 */ "cmd ::= SHOW TABLE DISTRIBUTED full_table_name", - /* 308 */ "cmd ::= SHOW CONSUMERS", - /* 309 */ "cmd ::= SHOW SUBSCRIPTIONS", - /* 310 */ "cmd ::= SHOW TAGS FROM table_name_cond from_db_opt", - /* 311 */ "cmd ::= SHOW TAGS FROM db_name NK_DOT table_name", - /* 312 */ "cmd ::= SHOW TABLE TAGS tag_list_opt FROM table_name_cond from_db_opt", - /* 313 */ "cmd ::= SHOW TABLE TAGS tag_list_opt FROM db_name NK_DOT table_name", - /* 314 */ "cmd ::= SHOW VNODES ON DNODE NK_INTEGER", - /* 315 */ "cmd ::= SHOW VNODES", - /* 316 */ "cmd ::= SHOW db_name_cond_opt ALIVE", - /* 317 */ "cmd ::= SHOW CLUSTER ALIVE", - /* 318 */ "cmd ::= SHOW db_name_cond_opt VIEWS like_pattern_opt", - /* 319 */ "cmd ::= SHOW CREATE VIEW full_table_name", - /* 320 */ "cmd ::= SHOW COMPACTS", - /* 321 */ "cmd ::= SHOW COMPACT NK_INTEGER", - /* 322 */ "table_kind_db_name_cond_opt ::=", - /* 323 */ "table_kind_db_name_cond_opt ::= table_kind", - /* 324 */ "table_kind_db_name_cond_opt ::= db_name NK_DOT", - /* 325 */ "table_kind_db_name_cond_opt ::= table_kind db_name NK_DOT", - /* 326 */ "table_kind ::= NORMAL", - /* 327 */ "table_kind ::= CHILD", - /* 328 */ "db_name_cond_opt ::=", - /* 329 */ "db_name_cond_opt ::= db_name NK_DOT", - /* 330 */ "like_pattern_opt ::=", - /* 331 */ "like_pattern_opt ::= LIKE NK_STRING", - /* 332 */ "table_name_cond ::= table_name", - /* 333 */ "from_db_opt ::=", - /* 334 */ "from_db_opt ::= FROM db_name", - /* 335 */ "tag_list_opt ::=", - /* 336 */ "tag_list_opt ::= tag_item", - /* 337 */ "tag_list_opt ::= tag_list_opt NK_COMMA tag_item", - /* 338 */ "tag_item ::= TBNAME", - /* 339 */ "tag_item ::= QTAGS", - /* 340 */ "tag_item ::= column_name", - /* 341 */ "tag_item ::= column_name column_alias", - /* 342 */ "tag_item ::= column_name AS column_alias", - /* 343 */ "db_kind_opt ::=", - /* 344 */ "db_kind_opt ::= USER", - /* 345 */ "db_kind_opt ::= SYSTEM", - /* 346 */ "cmd ::= CREATE TSMA not_exists_opt tsma_name ON full_table_name tsma_func_list INTERVAL NK_LP duration_literal NK_RP", - /* 347 */ "cmd ::= CREATE RECURSIVE TSMA not_exists_opt tsma_name ON full_table_name INTERVAL NK_LP duration_literal NK_RP", - /* 348 */ "cmd ::= DROP TSMA exists_opt full_tsma_name", - /* 349 */ "cmd ::= SHOW db_name_cond_opt TSMAS", - /* 350 */ "full_tsma_name ::= tsma_name", - /* 351 */ "full_tsma_name ::= db_name NK_DOT tsma_name", - /* 352 */ "tsma_func_list ::= FUNCTION NK_LP func_list NK_RP", - /* 353 */ "cmd ::= CREATE SMA INDEX not_exists_opt col_name ON full_table_name index_options", - /* 354 */ "cmd ::= CREATE INDEX not_exists_opt col_name ON full_table_name NK_LP col_name_list NK_RP", - /* 355 */ "cmd ::= DROP INDEX exists_opt full_index_name", - /* 356 */ "full_index_name ::= index_name", - /* 357 */ "full_index_name ::= db_name NK_DOT index_name", - /* 358 */ "index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_RP sliding_opt sma_stream_opt", - /* 359 */ "index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_COMMA duration_literal NK_RP sliding_opt sma_stream_opt", - /* 360 */ "func_list ::= func", - /* 361 */ "func_list ::= func_list NK_COMMA func", - /* 362 */ "func ::= sma_func_name NK_LP expression_list NK_RP", - /* 363 */ "sma_func_name ::= function_name", - /* 364 */ "sma_func_name ::= COUNT", - /* 365 */ "sma_func_name ::= FIRST", - /* 366 */ "sma_func_name ::= LAST", - /* 367 */ "sma_func_name ::= LAST_ROW", - /* 368 */ "sma_stream_opt ::=", - /* 369 */ "sma_stream_opt ::= sma_stream_opt WATERMARK duration_literal", - /* 370 */ "sma_stream_opt ::= sma_stream_opt MAX_DELAY duration_literal", - /* 371 */ "sma_stream_opt ::= sma_stream_opt DELETE_MARK duration_literal", - /* 372 */ "with_meta ::= AS", - /* 373 */ "with_meta ::= WITH META AS", - /* 374 */ "with_meta ::= ONLY META AS", - /* 375 */ "cmd ::= CREATE TOPIC not_exists_opt topic_name AS query_or_subquery", - /* 376 */ "cmd ::= CREATE TOPIC not_exists_opt topic_name with_meta DATABASE db_name", - /* 377 */ "cmd ::= CREATE TOPIC not_exists_opt topic_name with_meta STABLE full_table_name where_clause_opt", - /* 378 */ "cmd ::= DROP TOPIC exists_opt topic_name", - /* 379 */ "cmd ::= DROP CONSUMER GROUP exists_opt cgroup_name ON topic_name", - /* 380 */ "cmd ::= DESC full_table_name", - /* 381 */ "cmd ::= DESCRIBE full_table_name", - /* 382 */ "cmd ::= RESET QUERY CACHE", - /* 383 */ "cmd ::= EXPLAIN analyze_opt explain_options query_or_subquery", - /* 384 */ "cmd ::= EXPLAIN analyze_opt explain_options insert_query", - /* 385 */ "analyze_opt ::=", - /* 386 */ "analyze_opt ::= ANALYZE", - /* 387 */ "explain_options ::=", - /* 388 */ "explain_options ::= explain_options VERBOSE NK_BOOL", - /* 389 */ "explain_options ::= explain_options RATIO NK_FLOAT", - /* 390 */ "cmd ::= CREATE or_replace_opt agg_func_opt FUNCTION not_exists_opt function_name AS NK_STRING OUTPUTTYPE type_name bufsize_opt language_opt", - /* 391 */ "cmd ::= DROP FUNCTION exists_opt function_name", - /* 392 */ "agg_func_opt ::=", - /* 393 */ "agg_func_opt ::= AGGREGATE", - /* 394 */ "bufsize_opt ::=", - /* 395 */ "bufsize_opt ::= BUFSIZE NK_INTEGER", - /* 396 */ "language_opt ::=", - /* 397 */ "language_opt ::= LANGUAGE NK_STRING", - /* 398 */ "or_replace_opt ::=", - /* 399 */ "or_replace_opt ::= OR REPLACE", - /* 400 */ "cmd ::= CREATE or_replace_opt VIEW full_view_name AS query_or_subquery", - /* 401 */ "cmd ::= DROP VIEW exists_opt full_view_name", - /* 402 */ "full_view_name ::= view_name", - /* 403 */ "full_view_name ::= db_name NK_DOT view_name", - /* 404 */ "cmd ::= CREATE STREAM not_exists_opt stream_name stream_options INTO full_table_name col_list_opt tag_def_or_ref_opt subtable_opt AS query_or_subquery", - /* 405 */ "cmd ::= DROP STREAM exists_opt stream_name", - /* 406 */ "cmd ::= PAUSE STREAM exists_opt stream_name", - /* 407 */ "cmd ::= RESUME STREAM exists_opt ignore_opt stream_name", - /* 408 */ "col_list_opt ::=", - /* 409 */ "col_list_opt ::= NK_LP column_stream_def_list NK_RP", - /* 410 */ "column_stream_def_list ::= column_stream_def", - /* 411 */ "column_stream_def_list ::= column_stream_def_list NK_COMMA column_stream_def", - /* 412 */ "column_stream_def ::= column_name stream_col_options", - /* 413 */ "stream_col_options ::=", - /* 414 */ "stream_col_options ::= stream_col_options PRIMARY KEY", - /* 415 */ "tag_def_or_ref_opt ::=", - /* 416 */ "tag_def_or_ref_opt ::= tags_def", - /* 417 */ "tag_def_or_ref_opt ::= TAGS NK_LP column_stream_def_list NK_RP", - /* 418 */ "stream_options ::=", - /* 419 */ "stream_options ::= stream_options TRIGGER AT_ONCE", - /* 420 */ "stream_options ::= stream_options TRIGGER WINDOW_CLOSE", - /* 421 */ "stream_options ::= stream_options TRIGGER MAX_DELAY duration_literal", - /* 422 */ "stream_options ::= stream_options WATERMARK duration_literal", - /* 423 */ "stream_options ::= stream_options IGNORE EXPIRED NK_INTEGER", - /* 424 */ "stream_options ::= stream_options FILL_HISTORY NK_INTEGER", - /* 425 */ "stream_options ::= stream_options DELETE_MARK duration_literal", - /* 426 */ "stream_options ::= stream_options IGNORE UPDATE NK_INTEGER", - /* 427 */ "subtable_opt ::=", - /* 428 */ "subtable_opt ::= SUBTABLE NK_LP expression NK_RP", - /* 429 */ "ignore_opt ::=", - /* 430 */ "ignore_opt ::= IGNORE UNTREATED", - /* 431 */ "cmd ::= KILL CONNECTION NK_INTEGER", - /* 432 */ "cmd ::= KILL QUERY NK_STRING", - /* 433 */ "cmd ::= KILL TRANSACTION NK_INTEGER", - /* 434 */ "cmd ::= KILL COMPACT NK_INTEGER", - /* 435 */ "cmd ::= BALANCE VGROUP", - /* 436 */ "cmd ::= BALANCE VGROUP LEADER on_vgroup_id", - /* 437 */ "cmd ::= BALANCE VGROUP LEADER DATABASE db_name", - /* 438 */ "cmd ::= MERGE VGROUP NK_INTEGER NK_INTEGER", - /* 439 */ "cmd ::= REDISTRIBUTE VGROUP NK_INTEGER dnode_list", - /* 440 */ "cmd ::= SPLIT VGROUP NK_INTEGER", - /* 441 */ "on_vgroup_id ::=", - /* 442 */ "on_vgroup_id ::= ON NK_INTEGER", - /* 443 */ "dnode_list ::= DNODE NK_INTEGER", - /* 444 */ "dnode_list ::= dnode_list DNODE NK_INTEGER", - /* 445 */ "cmd ::= DELETE FROM full_table_name where_clause_opt", - /* 446 */ "cmd ::= query_or_subquery", - /* 447 */ "cmd ::= insert_query", - /* 448 */ "insert_query ::= INSERT INTO full_table_name NK_LP col_name_list NK_RP query_or_subquery", - /* 449 */ "insert_query ::= INSERT INTO full_table_name query_or_subquery", - /* 450 */ "tags_literal ::= NK_INTEGER", - /* 451 */ "tags_literal ::= NK_INTEGER NK_PLUS duration_literal", - /* 452 */ "tags_literal ::= NK_INTEGER NK_MINUS duration_literal", - /* 453 */ "tags_literal ::= NK_PLUS NK_INTEGER", - /* 454 */ "tags_literal ::= NK_PLUS NK_INTEGER NK_PLUS duration_literal", - /* 455 */ "tags_literal ::= NK_PLUS NK_INTEGER NK_MINUS duration_literal", - /* 456 */ "tags_literal ::= NK_MINUS NK_INTEGER", - /* 457 */ "tags_literal ::= NK_MINUS NK_INTEGER NK_PLUS duration_literal", - /* 458 */ "tags_literal ::= NK_MINUS NK_INTEGER NK_MINUS duration_literal", - /* 459 */ "tags_literal ::= NK_FLOAT", - /* 460 */ "tags_literal ::= NK_PLUS NK_FLOAT", - /* 461 */ "tags_literal ::= NK_MINUS NK_FLOAT", - /* 462 */ "tags_literal ::= NK_BIN", - /* 463 */ "tags_literal ::= NK_BIN NK_PLUS duration_literal", - /* 464 */ "tags_literal ::= NK_BIN NK_MINUS duration_literal", - /* 465 */ "tags_literal ::= NK_PLUS NK_BIN", - /* 466 */ "tags_literal ::= NK_PLUS NK_BIN NK_PLUS duration_literal", - /* 467 */ "tags_literal ::= NK_PLUS NK_BIN NK_MINUS duration_literal", - /* 468 */ "tags_literal ::= NK_MINUS NK_BIN", - /* 469 */ "tags_literal ::= NK_MINUS NK_BIN NK_PLUS duration_literal", - /* 470 */ "tags_literal ::= NK_MINUS NK_BIN NK_MINUS duration_literal", - /* 471 */ "tags_literal ::= NK_HEX", - /* 472 */ "tags_literal ::= NK_HEX NK_PLUS duration_literal", - /* 473 */ "tags_literal ::= NK_HEX NK_MINUS duration_literal", - /* 474 */ "tags_literal ::= NK_PLUS NK_HEX", - /* 475 */ "tags_literal ::= NK_PLUS NK_HEX NK_PLUS duration_literal", - /* 476 */ "tags_literal ::= NK_PLUS NK_HEX NK_MINUS duration_literal", - /* 477 */ "tags_literal ::= NK_MINUS NK_HEX", - /* 478 */ "tags_literal ::= NK_MINUS NK_HEX NK_PLUS duration_literal", - /* 479 */ "tags_literal ::= NK_MINUS NK_HEX NK_MINUS duration_literal", - /* 480 */ "tags_literal ::= NK_STRING", - /* 481 */ "tags_literal ::= NK_STRING NK_PLUS duration_literal", - /* 482 */ "tags_literal ::= NK_STRING NK_MINUS duration_literal", - /* 483 */ "tags_literal ::= NK_BOOL", - /* 484 */ "tags_literal ::= NULL", - /* 485 */ "tags_literal ::= literal_func", - /* 486 */ "tags_literal ::= literal_func NK_PLUS duration_literal", - /* 487 */ "tags_literal ::= literal_func NK_MINUS duration_literal", - /* 488 */ "tags_literal_list ::= tags_literal", - /* 489 */ "tags_literal_list ::= tags_literal_list NK_COMMA tags_literal", - /* 490 */ "literal ::= NK_INTEGER", - /* 491 */ "literal ::= NK_FLOAT", - /* 492 */ "literal ::= NK_STRING", - /* 493 */ "literal ::= NK_BOOL", - /* 494 */ "literal ::= TIMESTAMP NK_STRING", - /* 495 */ "literal ::= duration_literal", - /* 496 */ "literal ::= NULL", - /* 497 */ "literal ::= NK_QUESTION", - /* 498 */ "duration_literal ::= NK_VARIABLE", - /* 499 */ "signed ::= NK_INTEGER", - /* 500 */ "signed ::= NK_PLUS NK_INTEGER", - /* 501 */ "signed ::= NK_MINUS NK_INTEGER", - /* 502 */ "signed ::= NK_FLOAT", - /* 503 */ "signed ::= NK_PLUS NK_FLOAT", - /* 504 */ "signed ::= NK_MINUS NK_FLOAT", - /* 505 */ "signed_literal ::= signed", - /* 506 */ "signed_literal ::= NK_STRING", - /* 507 */ "signed_literal ::= NK_BOOL", - /* 508 */ "signed_literal ::= TIMESTAMP NK_STRING", - /* 509 */ "signed_literal ::= duration_literal", - /* 510 */ "signed_literal ::= NULL", - /* 511 */ "signed_literal ::= literal_func", - /* 512 */ "signed_literal ::= NK_QUESTION", - /* 513 */ "literal_list ::= signed_literal", - /* 514 */ "literal_list ::= literal_list NK_COMMA signed_literal", - /* 515 */ "db_name ::= NK_ID", - /* 516 */ "table_name ::= NK_ID", - /* 517 */ "column_name ::= NK_ID", - /* 518 */ "function_name ::= NK_ID", - /* 519 */ "view_name ::= NK_ID", - /* 520 */ "table_alias ::= NK_ID", - /* 521 */ "column_alias ::= NK_ID", - /* 522 */ "column_alias ::= NK_ALIAS", - /* 523 */ "user_name ::= NK_ID", - /* 524 */ "topic_name ::= NK_ID", - /* 525 */ "stream_name ::= NK_ID", - /* 526 */ "cgroup_name ::= NK_ID", - /* 527 */ "index_name ::= NK_ID", - /* 528 */ "tsma_name ::= NK_ID", - /* 529 */ "expr_or_subquery ::= expression", - /* 530 */ "expression ::= literal", - /* 531 */ "expression ::= pseudo_column", - /* 532 */ "expression ::= column_reference", - /* 533 */ "expression ::= function_expression", - /* 534 */ "expression ::= case_when_expression", - /* 535 */ "expression ::= NK_LP expression NK_RP", - /* 536 */ "expression ::= NK_PLUS expr_or_subquery", - /* 537 */ "expression ::= NK_MINUS expr_or_subquery", - /* 538 */ "expression ::= expr_or_subquery NK_PLUS expr_or_subquery", - /* 539 */ "expression ::= expr_or_subquery NK_MINUS expr_or_subquery", - /* 540 */ "expression ::= expr_or_subquery NK_STAR expr_or_subquery", - /* 541 */ "expression ::= expr_or_subquery NK_SLASH expr_or_subquery", - /* 542 */ "expression ::= expr_or_subquery NK_REM expr_or_subquery", - /* 543 */ "expression ::= column_reference NK_ARROW NK_STRING", - /* 544 */ "expression ::= expr_or_subquery NK_BITAND expr_or_subquery", - /* 545 */ "expression ::= expr_or_subquery NK_BITOR expr_or_subquery", - /* 546 */ "expression_list ::= expr_or_subquery", - /* 547 */ "expression_list ::= expression_list NK_COMMA expr_or_subquery", - /* 548 */ "column_reference ::= column_name", - /* 549 */ "column_reference ::= table_name NK_DOT column_name", - /* 550 */ "column_reference ::= NK_ALIAS", - /* 551 */ "column_reference ::= table_name NK_DOT NK_ALIAS", - /* 552 */ "pseudo_column ::= ROWTS", - /* 553 */ "pseudo_column ::= TBNAME", - /* 554 */ "pseudo_column ::= table_name NK_DOT TBNAME", - /* 555 */ "pseudo_column ::= QSTART", - /* 556 */ "pseudo_column ::= QEND", - /* 557 */ "pseudo_column ::= QDURATION", - /* 558 */ "pseudo_column ::= WSTART", - /* 559 */ "pseudo_column ::= WEND", - /* 560 */ "pseudo_column ::= WDURATION", - /* 561 */ "pseudo_column ::= IROWTS", - /* 562 */ "pseudo_column ::= ISFILLED", - /* 563 */ "pseudo_column ::= QTAGS", - /* 564 */ "function_expression ::= function_name NK_LP expression_list NK_RP", - /* 565 */ "function_expression ::= star_func NK_LP star_func_para_list NK_RP", - /* 566 */ "function_expression ::= CAST NK_LP expr_or_subquery AS type_name NK_RP", - /* 567 */ "function_expression ::= CAST NK_LP expr_or_subquery AS type_name_default_len NK_RP", - /* 568 */ "function_expression ::= POSITION NK_LP expr_or_subquery IN expr_or_subquery NK_RP", - /* 569 */ "function_expression ::= TRIM NK_LP expr_or_subquery NK_RP", - /* 570 */ "function_expression ::= TRIM NK_LP trim_specification_type FROM expr_or_subquery NK_RP", - /* 571 */ "function_expression ::= TRIM NK_LP expr_or_subquery FROM expr_or_subquery NK_RP", - /* 572 */ "function_expression ::= TRIM NK_LP trim_specification_type expr_or_subquery FROM expr_or_subquery NK_RP", - /* 573 */ "function_expression ::= substr_func NK_LP expression_list NK_RP", - /* 574 */ "function_expression ::= substr_func NK_LP expr_or_subquery FROM expr_or_subquery NK_RP", - /* 575 */ "function_expression ::= substr_func NK_LP expr_or_subquery FROM expr_or_subquery FOR expr_or_subquery NK_RP", - /* 576 */ "function_expression ::= REPLACE NK_LP expression_list NK_RP", - /* 577 */ "function_expression ::= literal_func", - /* 578 */ "function_expression ::= rand_func", - /* 579 */ "literal_func ::= noarg_func NK_LP NK_RP", - /* 580 */ "literal_func ::= NOW", - /* 581 */ "literal_func ::= TODAY", - /* 582 */ "rand_func ::= RAND NK_LP NK_RP", - /* 583 */ "rand_func ::= RAND NK_LP expression_list NK_RP", - /* 584 */ "substr_func ::= SUBSTR", - /* 585 */ "substr_func ::= SUBSTRING", - /* 586 */ "trim_specification_type ::= BOTH", - /* 587 */ "trim_specification_type ::= TRAILING", - /* 588 */ "trim_specification_type ::= LEADING", - /* 589 */ "noarg_func ::= NOW", - /* 590 */ "noarg_func ::= TODAY", - /* 591 */ "noarg_func ::= TIMEZONE", - /* 592 */ "noarg_func ::= DATABASE", - /* 593 */ "noarg_func ::= CLIENT_VERSION", - /* 594 */ "noarg_func ::= SERVER_VERSION", - /* 595 */ "noarg_func ::= SERVER_STATUS", - /* 596 */ "noarg_func ::= CURRENT_USER", - /* 597 */ "noarg_func ::= USER", - /* 598 */ "noarg_func ::= PI", - /* 599 */ "star_func ::= COUNT", - /* 600 */ "star_func ::= FIRST", - /* 601 */ "star_func ::= LAST", - /* 602 */ "star_func ::= LAST_ROW", - /* 603 */ "star_func_para_list ::= NK_STAR", - /* 604 */ "star_func_para_list ::= other_para_list", - /* 605 */ "other_para_list ::= star_func_para", - /* 606 */ "other_para_list ::= other_para_list NK_COMMA star_func_para", - /* 607 */ "star_func_para ::= expr_or_subquery", - /* 608 */ "star_func_para ::= table_name NK_DOT NK_STAR", - /* 609 */ "case_when_expression ::= CASE when_then_list case_when_else_opt END", - /* 610 */ "case_when_expression ::= CASE common_expression when_then_list case_when_else_opt END", - /* 611 */ "when_then_list ::= when_then_expr", - /* 612 */ "when_then_list ::= when_then_list when_then_expr", - /* 613 */ "when_then_expr ::= WHEN common_expression THEN common_expression", - /* 614 */ "case_when_else_opt ::=", - /* 615 */ "case_when_else_opt ::= ELSE common_expression", - /* 616 */ "predicate ::= expr_or_subquery compare_op expr_or_subquery", - /* 617 */ "predicate ::= expr_or_subquery BETWEEN expr_or_subquery AND expr_or_subquery", - /* 618 */ "predicate ::= expr_or_subquery NOT BETWEEN expr_or_subquery AND expr_or_subquery", - /* 619 */ "predicate ::= expr_or_subquery IS NULL", - /* 620 */ "predicate ::= expr_or_subquery IS NOT NULL", - /* 621 */ "predicate ::= expr_or_subquery in_op in_predicate_value", - /* 622 */ "compare_op ::= NK_LT", - /* 623 */ "compare_op ::= NK_GT", - /* 624 */ "compare_op ::= NK_LE", - /* 625 */ "compare_op ::= NK_GE", - /* 626 */ "compare_op ::= NK_NE", - /* 627 */ "compare_op ::= NK_EQ", - /* 628 */ "compare_op ::= LIKE", - /* 629 */ "compare_op ::= NOT LIKE", - /* 630 */ "compare_op ::= MATCH", - /* 631 */ "compare_op ::= NMATCH", - /* 632 */ "compare_op ::= CONTAINS", - /* 633 */ "in_op ::= IN", - /* 634 */ "in_op ::= NOT IN", - /* 635 */ "in_predicate_value ::= NK_LP literal_list NK_RP", - /* 636 */ "boolean_value_expression ::= boolean_primary", - /* 637 */ "boolean_value_expression ::= NOT boolean_primary", - /* 638 */ "boolean_value_expression ::= boolean_value_expression OR boolean_value_expression", - /* 639 */ "boolean_value_expression ::= boolean_value_expression AND boolean_value_expression", - /* 640 */ "boolean_primary ::= predicate", - /* 641 */ "boolean_primary ::= NK_LP boolean_value_expression NK_RP", - /* 642 */ "common_expression ::= expr_or_subquery", - /* 643 */ "common_expression ::= boolean_value_expression", - /* 644 */ "from_clause_opt ::=", - /* 645 */ "from_clause_opt ::= FROM table_reference_list", - /* 646 */ "table_reference_list ::= table_reference", - /* 647 */ "table_reference_list ::= table_reference_list NK_COMMA table_reference", - /* 648 */ "table_reference ::= table_primary", - /* 649 */ "table_reference ::= joined_table", - /* 650 */ "table_primary ::= table_name alias_opt", - /* 651 */ "table_primary ::= db_name NK_DOT table_name alias_opt", - /* 652 */ "table_primary ::= subquery alias_opt", - /* 653 */ "table_primary ::= parenthesized_joined_table", - /* 654 */ "alias_opt ::=", - /* 655 */ "alias_opt ::= table_alias", - /* 656 */ "alias_opt ::= AS table_alias", - /* 657 */ "parenthesized_joined_table ::= NK_LP joined_table NK_RP", - /* 658 */ "parenthesized_joined_table ::= NK_LP parenthesized_joined_table NK_RP", - /* 659 */ "joined_table ::= table_reference join_type join_subtype JOIN table_reference join_on_clause_opt window_offset_clause_opt jlimit_clause_opt", - /* 660 */ "join_type ::=", - /* 661 */ "join_type ::= INNER", - /* 662 */ "join_type ::= LEFT", - /* 663 */ "join_type ::= RIGHT", - /* 664 */ "join_type ::= FULL", - /* 665 */ "join_subtype ::=", - /* 666 */ "join_subtype ::= OUTER", - /* 667 */ "join_subtype ::= SEMI", - /* 668 */ "join_subtype ::= ANTI", - /* 669 */ "join_subtype ::= ASOF", - /* 670 */ "join_subtype ::= WINDOW", - /* 671 */ "join_on_clause_opt ::=", - /* 672 */ "join_on_clause_opt ::= ON search_condition", - /* 673 */ "window_offset_clause_opt ::=", - /* 674 */ "window_offset_clause_opt ::= WINDOW_OFFSET NK_LP window_offset_literal NK_COMMA window_offset_literal NK_RP", - /* 675 */ "window_offset_literal ::= NK_VARIABLE", - /* 676 */ "window_offset_literal ::= NK_MINUS NK_VARIABLE", - /* 677 */ "jlimit_clause_opt ::=", - /* 678 */ "jlimit_clause_opt ::= JLIMIT NK_INTEGER", - /* 679 */ "query_specification ::= SELECT hint_list set_quantifier_opt tag_mode_opt select_list from_clause_opt where_clause_opt partition_by_clause_opt range_opt every_opt fill_opt twindow_clause_opt group_by_clause_opt having_clause_opt", - /* 680 */ "hint_list ::=", - /* 681 */ "hint_list ::= NK_HINT", - /* 682 */ "tag_mode_opt ::=", - /* 683 */ "tag_mode_opt ::= TAGS", - /* 684 */ "set_quantifier_opt ::=", - /* 685 */ "set_quantifier_opt ::= DISTINCT", - /* 686 */ "set_quantifier_opt ::= ALL", - /* 687 */ "select_list ::= select_item", - /* 688 */ "select_list ::= select_list NK_COMMA select_item", - /* 689 */ "select_item ::= NK_STAR", - /* 690 */ "select_item ::= common_expression", - /* 691 */ "select_item ::= common_expression column_alias", - /* 692 */ "select_item ::= common_expression AS column_alias", - /* 693 */ "select_item ::= table_name NK_DOT NK_STAR", - /* 694 */ "where_clause_opt ::=", - /* 695 */ "where_clause_opt ::= WHERE search_condition", - /* 696 */ "partition_by_clause_opt ::=", - /* 697 */ "partition_by_clause_opt ::= PARTITION BY partition_list", - /* 698 */ "partition_list ::= partition_item", - /* 699 */ "partition_list ::= partition_list NK_COMMA partition_item", - /* 700 */ "partition_item ::= expr_or_subquery", - /* 701 */ "partition_item ::= expr_or_subquery column_alias", - /* 702 */ "partition_item ::= expr_or_subquery AS column_alias", - /* 703 */ "twindow_clause_opt ::=", - /* 704 */ "twindow_clause_opt ::= SESSION NK_LP column_reference NK_COMMA interval_sliding_duration_literal NK_RP", - /* 705 */ "twindow_clause_opt ::= STATE_WINDOW NK_LP expr_or_subquery NK_RP", - /* 706 */ "twindow_clause_opt ::= INTERVAL NK_LP interval_sliding_duration_literal NK_RP sliding_opt fill_opt", - /* 707 */ "twindow_clause_opt ::= INTERVAL NK_LP interval_sliding_duration_literal NK_COMMA interval_sliding_duration_literal NK_RP sliding_opt fill_opt", - /* 708 */ "twindow_clause_opt ::= EVENT_WINDOW START WITH search_condition END WITH search_condition", - /* 709 */ "twindow_clause_opt ::= COUNT_WINDOW NK_LP NK_INTEGER NK_RP", - /* 710 */ "twindow_clause_opt ::= COUNT_WINDOW NK_LP NK_INTEGER NK_COMMA NK_INTEGER NK_RP", - /* 711 */ "sliding_opt ::=", - /* 712 */ "sliding_opt ::= SLIDING NK_LP interval_sliding_duration_literal NK_RP", - /* 713 */ "interval_sliding_duration_literal ::= NK_VARIABLE", - /* 714 */ "interval_sliding_duration_literal ::= NK_STRING", - /* 715 */ "interval_sliding_duration_literal ::= NK_INTEGER", - /* 716 */ "fill_opt ::=", - /* 717 */ "fill_opt ::= FILL NK_LP fill_mode NK_RP", - /* 718 */ "fill_opt ::= FILL NK_LP VALUE NK_COMMA expression_list NK_RP", - /* 719 */ "fill_opt ::= FILL NK_LP VALUE_F NK_COMMA expression_list NK_RP", - /* 720 */ "fill_mode ::= NONE", - /* 721 */ "fill_mode ::= PREV", - /* 722 */ "fill_mode ::= NULL", - /* 723 */ "fill_mode ::= NULL_F", - /* 724 */ "fill_mode ::= LINEAR", - /* 725 */ "fill_mode ::= NEXT", - /* 726 */ "group_by_clause_opt ::=", - /* 727 */ "group_by_clause_opt ::= GROUP BY group_by_list", - /* 728 */ "group_by_list ::= expr_or_subquery", - /* 729 */ "group_by_list ::= group_by_list NK_COMMA expr_or_subquery", - /* 730 */ "having_clause_opt ::=", - /* 731 */ "having_clause_opt ::= HAVING search_condition", - /* 732 */ "range_opt ::=", - /* 733 */ "range_opt ::= RANGE NK_LP expr_or_subquery NK_COMMA expr_or_subquery NK_RP", - /* 734 */ "range_opt ::= RANGE NK_LP expr_or_subquery NK_RP", - /* 735 */ "every_opt ::=", - /* 736 */ "every_opt ::= EVERY NK_LP duration_literal NK_RP", - /* 737 */ "query_expression ::= query_simple order_by_clause_opt slimit_clause_opt limit_clause_opt", - /* 738 */ "query_simple ::= query_specification", - /* 739 */ "query_simple ::= union_query_expression", - /* 740 */ "union_query_expression ::= query_simple_or_subquery UNION ALL query_simple_or_subquery", - /* 741 */ "union_query_expression ::= query_simple_or_subquery UNION query_simple_or_subquery", - /* 742 */ "query_simple_or_subquery ::= query_simple", - /* 743 */ "query_simple_or_subquery ::= subquery", - /* 744 */ "query_or_subquery ::= query_expression", - /* 745 */ "query_or_subquery ::= subquery", - /* 746 */ "order_by_clause_opt ::=", - /* 747 */ "order_by_clause_opt ::= ORDER BY sort_specification_list", - /* 748 */ "slimit_clause_opt ::=", - /* 749 */ "slimit_clause_opt ::= SLIMIT NK_INTEGER", - /* 750 */ "slimit_clause_opt ::= SLIMIT NK_INTEGER SOFFSET NK_INTEGER", - /* 751 */ "slimit_clause_opt ::= SLIMIT NK_INTEGER NK_COMMA NK_INTEGER", - /* 752 */ "limit_clause_opt ::=", - /* 753 */ "limit_clause_opt ::= LIMIT NK_INTEGER", - /* 754 */ "limit_clause_opt ::= LIMIT NK_INTEGER OFFSET NK_INTEGER", - /* 755 */ "limit_clause_opt ::= LIMIT NK_INTEGER NK_COMMA NK_INTEGER", - /* 756 */ "subquery ::= NK_LP query_expression NK_RP", - /* 757 */ "subquery ::= NK_LP subquery NK_RP", - /* 758 */ "search_condition ::= common_expression", - /* 759 */ "sort_specification_list ::= sort_specification", - /* 760 */ "sort_specification_list ::= sort_specification_list NK_COMMA sort_specification", - /* 761 */ "sort_specification ::= expr_or_subquery ordering_specification_opt null_ordering_opt", - /* 762 */ "ordering_specification_opt ::=", - /* 763 */ "ordering_specification_opt ::= ASC", - /* 764 */ "ordering_specification_opt ::= DESC", - /* 765 */ "null_ordering_opt ::=", - /* 766 */ "null_ordering_opt ::= NULLS FIRST", - /* 767 */ "null_ordering_opt ::= NULLS LAST", - /* 768 */ "column_options ::=", - /* 769 */ "column_options ::= column_options PRIMARY KEY", - /* 770 */ "column_options ::= column_options NK_ID NK_STRING", + /* 0 */ "cmd ::= CREATE ACCOUNT NK_ID PASS NK_STRING account_options", + /* 1 */ "cmd ::= ALTER ACCOUNT NK_ID alter_account_options", + /* 2 */ "account_options ::=", + /* 3 */ "account_options ::= account_options PPS literal", + /* 4 */ "account_options ::= account_options TSERIES literal", + /* 5 */ "account_options ::= account_options STORAGE literal", + /* 6 */ "account_options ::= account_options STREAMS literal", + /* 7 */ "account_options ::= account_options QTIME literal", + /* 8 */ "account_options ::= account_options DBS literal", + /* 9 */ "account_options ::= account_options USERS literal", + /* 10 */ "account_options ::= account_options CONNS literal", + /* 11 */ "account_options ::= account_options STATE literal", + /* 12 */ "alter_account_options ::= alter_account_option", + /* 13 */ "alter_account_options ::= alter_account_options alter_account_option", + /* 14 */ "alter_account_option ::= PASS literal", + /* 15 */ "alter_account_option ::= PPS literal", + /* 16 */ "alter_account_option ::= TSERIES literal", + /* 17 */ "alter_account_option ::= STORAGE literal", + /* 18 */ "alter_account_option ::= STREAMS literal", + /* 19 */ "alter_account_option ::= QTIME literal", + /* 20 */ "alter_account_option ::= DBS literal", + /* 21 */ "alter_account_option ::= USERS literal", + /* 22 */ "alter_account_option ::= CONNS literal", + /* 23 */ "alter_account_option ::= STATE literal", + /* 24 */ "ip_range_list ::= NK_STRING", + /* 25 */ "ip_range_list ::= ip_range_list NK_COMMA NK_STRING", + /* 26 */ "white_list ::= HOST ip_range_list", + /* 27 */ "white_list_opt ::=", + /* 28 */ "white_list_opt ::= white_list", + /* 29 */ "is_import_opt ::=", + /* 30 */ "is_import_opt ::= IS_IMPORT NK_INTEGER", + /* 31 */ "is_createdb_opt ::=", + /* 32 */ "is_createdb_opt ::= CREATEDB NK_INTEGER", + /* 33 */ "cmd ::= CREATE USER user_name PASS NK_STRING sysinfo_opt is_createdb_opt is_import_opt white_list_opt", + /* 34 */ "cmd ::= ALTER USER user_name PASS NK_STRING", + /* 35 */ "cmd ::= ALTER USER user_name ENABLE NK_INTEGER", + /* 36 */ "cmd ::= ALTER USER user_name SYSINFO NK_INTEGER", + /* 37 */ "cmd ::= ALTER USER user_name CREATEDB NK_INTEGER", + /* 38 */ "cmd ::= ALTER USER user_name ADD white_list", + /* 39 */ "cmd ::= ALTER USER user_name DROP white_list", + /* 40 */ "cmd ::= DROP USER user_name", + /* 41 */ "sysinfo_opt ::=", + /* 42 */ "sysinfo_opt ::= SYSINFO NK_INTEGER", + /* 43 */ "cmd ::= GRANT privileges ON priv_level with_clause_opt TO user_name", + /* 44 */ "cmd ::= REVOKE privileges ON priv_level with_clause_opt FROM user_name", + /* 45 */ "privileges ::= ALL", + /* 46 */ "privileges ::= priv_type_list", + /* 47 */ "privileges ::= SUBSCRIBE", + /* 48 */ "priv_type_list ::= priv_type", + /* 49 */ "priv_type_list ::= priv_type_list NK_COMMA priv_type", + /* 50 */ "priv_type ::= READ", + /* 51 */ "priv_type ::= WRITE", + /* 52 */ "priv_type ::= ALTER", + /* 53 */ "priv_level ::= NK_STAR NK_DOT NK_STAR", + /* 54 */ "priv_level ::= db_name NK_DOT NK_STAR", + /* 55 */ "priv_level ::= db_name NK_DOT table_name", + /* 56 */ "priv_level ::= topic_name", + /* 57 */ "with_clause_opt ::=", + /* 58 */ "with_clause_opt ::= WITH search_condition", + /* 59 */ "cmd ::= CREATE ENCRYPT_KEY NK_STRING", + /* 60 */ "cmd ::= CREATE DNODE dnode_endpoint", + /* 61 */ "cmd ::= CREATE DNODE dnode_endpoint PORT NK_INTEGER", + /* 62 */ "cmd ::= DROP DNODE NK_INTEGER force_opt", + /* 63 */ "cmd ::= DROP DNODE dnode_endpoint force_opt", + /* 64 */ "cmd ::= DROP DNODE NK_INTEGER unsafe_opt", + /* 65 */ "cmd ::= DROP DNODE dnode_endpoint unsafe_opt", + /* 66 */ "cmd ::= ALTER DNODE NK_INTEGER NK_STRING", + /* 67 */ "cmd ::= ALTER DNODE NK_INTEGER NK_STRING NK_STRING", + /* 68 */ "cmd ::= ALTER ALL DNODES NK_STRING", + /* 69 */ "cmd ::= ALTER ALL DNODES NK_STRING NK_STRING", + /* 70 */ "cmd ::= RESTORE DNODE NK_INTEGER", + /* 71 */ "dnode_endpoint ::= NK_STRING", + /* 72 */ "dnode_endpoint ::= NK_ID", + /* 73 */ "dnode_endpoint ::= NK_IPTOKEN", + /* 74 */ "force_opt ::=", + /* 75 */ "force_opt ::= FORCE", + /* 76 */ "unsafe_opt ::= UNSAFE", + /* 77 */ "cmd ::= ALTER CLUSTER NK_STRING", + /* 78 */ "cmd ::= ALTER CLUSTER NK_STRING NK_STRING", + /* 79 */ "cmd ::= ALTER LOCAL NK_STRING", + /* 80 */ "cmd ::= ALTER LOCAL NK_STRING NK_STRING", + /* 81 */ "cmd ::= CREATE QNODE ON DNODE NK_INTEGER", + /* 82 */ "cmd ::= DROP QNODE ON DNODE NK_INTEGER", + /* 83 */ "cmd ::= RESTORE QNODE ON DNODE NK_INTEGER", + /* 84 */ "cmd ::= CREATE BNODE ON DNODE NK_INTEGER", + /* 85 */ "cmd ::= DROP BNODE ON DNODE NK_INTEGER", + /* 86 */ "cmd ::= CREATE SNODE ON DNODE NK_INTEGER", + /* 87 */ "cmd ::= DROP SNODE ON DNODE NK_INTEGER", + /* 88 */ "cmd ::= CREATE MNODE ON DNODE NK_INTEGER", + /* 89 */ "cmd ::= DROP MNODE ON DNODE NK_INTEGER", + /* 90 */ "cmd ::= RESTORE MNODE ON DNODE NK_INTEGER", + /* 91 */ "cmd ::= RESTORE VNODE ON DNODE NK_INTEGER", + /* 92 */ "cmd ::= CREATE DATABASE not_exists_opt db_name db_options", + /* 93 */ "cmd ::= DROP DATABASE exists_opt db_name", + /* 94 */ "cmd ::= USE db_name", + /* 95 */ "cmd ::= ALTER DATABASE db_name alter_db_options", + /* 96 */ "cmd ::= FLUSH DATABASE db_name", + /* 97 */ "cmd ::= TRIM DATABASE db_name speed_opt", + /* 98 */ "cmd ::= S3MIGRATE DATABASE db_name", + /* 99 */ "cmd ::= COMPACT DATABASE db_name start_opt end_opt", + /* 100 */ "not_exists_opt ::= IF NOT EXISTS", + /* 101 */ "not_exists_opt ::=", + /* 102 */ "exists_opt ::= IF EXISTS", + /* 103 */ "exists_opt ::=", + /* 104 */ "db_options ::=", + /* 105 */ "db_options ::= db_options BUFFER NK_INTEGER", + /* 106 */ "db_options ::= db_options CACHEMODEL NK_STRING", + /* 107 */ "db_options ::= db_options CACHESIZE NK_INTEGER", + /* 108 */ "db_options ::= db_options COMP NK_INTEGER", + /* 109 */ "db_options ::= db_options DURATION NK_INTEGER", + /* 110 */ "db_options ::= db_options DURATION NK_VARIABLE", + /* 111 */ "db_options ::= db_options MAXROWS NK_INTEGER", + /* 112 */ "db_options ::= db_options MINROWS NK_INTEGER", + /* 113 */ "db_options ::= db_options KEEP integer_list", + /* 114 */ "db_options ::= db_options KEEP variable_list", + /* 115 */ "db_options ::= db_options PAGES NK_INTEGER", + /* 116 */ "db_options ::= db_options PAGESIZE NK_INTEGER", + /* 117 */ "db_options ::= db_options TSDB_PAGESIZE NK_INTEGER", + /* 118 */ "db_options ::= db_options PRECISION NK_STRING", + /* 119 */ "db_options ::= db_options REPLICA NK_INTEGER", + /* 120 */ "db_options ::= db_options VGROUPS NK_INTEGER", + /* 121 */ "db_options ::= db_options SINGLE_STABLE NK_INTEGER", + /* 122 */ "db_options ::= db_options RETENTIONS retention_list", + /* 123 */ "db_options ::= db_options SCHEMALESS NK_INTEGER", + /* 124 */ "db_options ::= db_options WAL_LEVEL NK_INTEGER", + /* 125 */ "db_options ::= db_options WAL_FSYNC_PERIOD NK_INTEGER", + /* 126 */ "db_options ::= db_options WAL_RETENTION_PERIOD NK_INTEGER", + /* 127 */ "db_options ::= db_options WAL_RETENTION_PERIOD NK_MINUS NK_INTEGER", + /* 128 */ "db_options ::= db_options WAL_RETENTION_SIZE NK_INTEGER", + /* 129 */ "db_options ::= db_options WAL_RETENTION_SIZE NK_MINUS NK_INTEGER", + /* 130 */ "db_options ::= db_options WAL_ROLL_PERIOD NK_INTEGER", + /* 131 */ "db_options ::= db_options WAL_SEGMENT_SIZE NK_INTEGER", + /* 132 */ "db_options ::= db_options STT_TRIGGER NK_INTEGER", + /* 133 */ "db_options ::= db_options TABLE_PREFIX signed", + /* 134 */ "db_options ::= db_options TABLE_SUFFIX signed", + /* 135 */ "db_options ::= db_options S3_CHUNKSIZE NK_INTEGER", + /* 136 */ "db_options ::= db_options S3_KEEPLOCAL NK_INTEGER", + /* 137 */ "db_options ::= db_options S3_KEEPLOCAL NK_VARIABLE", + /* 138 */ "db_options ::= db_options S3_COMPACT NK_INTEGER", + /* 139 */ "db_options ::= db_options KEEP_TIME_OFFSET NK_INTEGER", + /* 140 */ "db_options ::= db_options ENCRYPT_ALGORITHM NK_STRING", + /* 141 */ "alter_db_options ::= alter_db_option", + /* 142 */ "alter_db_options ::= alter_db_options alter_db_option", + /* 143 */ "alter_db_option ::= BUFFER NK_INTEGER", + /* 144 */ "alter_db_option ::= CACHEMODEL NK_STRING", + /* 145 */ "alter_db_option ::= CACHESIZE NK_INTEGER", + /* 146 */ "alter_db_option ::= WAL_FSYNC_PERIOD NK_INTEGER", + /* 147 */ "alter_db_option ::= KEEP integer_list", + /* 148 */ "alter_db_option ::= KEEP variable_list", + /* 149 */ "alter_db_option ::= PAGES NK_INTEGER", + /* 150 */ "alter_db_option ::= REPLICA NK_INTEGER", + /* 151 */ "alter_db_option ::= WAL_LEVEL NK_INTEGER", + /* 152 */ "alter_db_option ::= STT_TRIGGER NK_INTEGER", + /* 153 */ "alter_db_option ::= MINROWS NK_INTEGER", + /* 154 */ "alter_db_option ::= WAL_RETENTION_PERIOD NK_INTEGER", + /* 155 */ "alter_db_option ::= WAL_RETENTION_PERIOD NK_MINUS NK_INTEGER", + /* 156 */ "alter_db_option ::= WAL_RETENTION_SIZE NK_INTEGER", + /* 157 */ "alter_db_option ::= WAL_RETENTION_SIZE NK_MINUS NK_INTEGER", + /* 158 */ "alter_db_option ::= S3_KEEPLOCAL NK_INTEGER", + /* 159 */ "alter_db_option ::= S3_KEEPLOCAL NK_VARIABLE", + /* 160 */ "alter_db_option ::= S3_COMPACT NK_INTEGER", + /* 161 */ "alter_db_option ::= KEEP_TIME_OFFSET NK_INTEGER", + /* 162 */ "alter_db_option ::= ENCRYPT_ALGORITHM NK_STRING", + /* 163 */ "integer_list ::= NK_INTEGER", + /* 164 */ "integer_list ::= integer_list NK_COMMA NK_INTEGER", + /* 165 */ "variable_list ::= NK_VARIABLE", + /* 166 */ "variable_list ::= variable_list NK_COMMA NK_VARIABLE", + /* 167 */ "retention_list ::= retention", + /* 168 */ "retention_list ::= retention_list NK_COMMA retention", + /* 169 */ "retention ::= NK_VARIABLE NK_COLON NK_VARIABLE", + /* 170 */ "retention ::= NK_MINUS NK_COLON NK_VARIABLE", + /* 171 */ "speed_opt ::=", + /* 172 */ "speed_opt ::= BWLIMIT NK_INTEGER", + /* 173 */ "start_opt ::=", + /* 174 */ "start_opt ::= START WITH NK_INTEGER", + /* 175 */ "start_opt ::= START WITH NK_STRING", + /* 176 */ "start_opt ::= START WITH TIMESTAMP NK_STRING", + /* 177 */ "end_opt ::=", + /* 178 */ "end_opt ::= END WITH NK_INTEGER", + /* 179 */ "end_opt ::= END WITH NK_STRING", + /* 180 */ "end_opt ::= END WITH TIMESTAMP NK_STRING", + /* 181 */ "cmd ::= CREATE TABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def_opt table_options", + /* 182 */ "cmd ::= CREATE TABLE multi_create_clause", + /* 183 */ "cmd ::= CREATE TABLE not_exists_opt USING full_table_name NK_LP tag_list_opt NK_RP FILE NK_STRING", + /* 184 */ "cmd ::= CREATE STABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def table_options", + /* 185 */ "cmd ::= DROP TABLE with_opt multi_drop_clause", + /* 186 */ "cmd ::= DROP STABLE with_opt exists_opt full_table_name", + /* 187 */ "cmd ::= ALTER TABLE alter_table_clause", + /* 188 */ "cmd ::= ALTER STABLE alter_table_clause", + /* 189 */ "alter_table_clause ::= full_table_name alter_table_options", + /* 190 */ "alter_table_clause ::= full_table_name ADD COLUMN column_name type_name column_options", + /* 191 */ "alter_table_clause ::= full_table_name DROP COLUMN column_name", + /* 192 */ "alter_table_clause ::= full_table_name MODIFY COLUMN column_name type_name", + /* 193 */ "alter_table_clause ::= full_table_name MODIFY COLUMN column_name column_options", + /* 194 */ "alter_table_clause ::= full_table_name RENAME COLUMN column_name column_name", + /* 195 */ "alter_table_clause ::= full_table_name ADD TAG column_name type_name", + /* 196 */ "alter_table_clause ::= full_table_name DROP TAG column_name", + /* 197 */ "alter_table_clause ::= full_table_name MODIFY TAG column_name type_name", + /* 198 */ "alter_table_clause ::= full_table_name RENAME TAG column_name column_name", + /* 199 */ "alter_table_clause ::= full_table_name SET TAG column_name NK_EQ tags_literal", + /* 200 */ "multi_create_clause ::= create_subtable_clause", + /* 201 */ "multi_create_clause ::= multi_create_clause create_subtable_clause", + /* 202 */ "create_subtable_clause ::= not_exists_opt full_table_name USING full_table_name specific_cols_opt TAGS NK_LP tags_literal_list NK_RP table_options", + /* 203 */ "multi_drop_clause ::= drop_table_clause", + /* 204 */ "multi_drop_clause ::= multi_drop_clause NK_COMMA drop_table_clause", + /* 205 */ "drop_table_clause ::= exists_opt full_table_name", + /* 206 */ "with_opt ::=", + /* 207 */ "with_opt ::= WITH", + /* 208 */ "specific_cols_opt ::=", + /* 209 */ "specific_cols_opt ::= NK_LP col_name_list NK_RP", + /* 210 */ "full_table_name ::= table_name", + /* 211 */ "full_table_name ::= db_name NK_DOT table_name", + /* 212 */ "tag_def_list ::= tag_def", + /* 213 */ "tag_def_list ::= tag_def_list NK_COMMA tag_def", + /* 214 */ "tag_def ::= column_name type_name", + /* 215 */ "column_def_list ::= column_def", + /* 216 */ "column_def_list ::= column_def_list NK_COMMA column_def", + /* 217 */ "column_def ::= column_name type_name column_options", + /* 218 */ "type_name ::= BOOL", + /* 219 */ "type_name ::= TINYINT", + /* 220 */ "type_name ::= SMALLINT", + /* 221 */ "type_name ::= INT", + /* 222 */ "type_name ::= INTEGER", + /* 223 */ "type_name ::= BIGINT", + /* 224 */ "type_name ::= FLOAT", + /* 225 */ "type_name ::= DOUBLE", + /* 226 */ "type_name ::= BINARY NK_LP NK_INTEGER NK_RP", + /* 227 */ "type_name ::= TIMESTAMP", + /* 228 */ "type_name ::= NCHAR NK_LP NK_INTEGER NK_RP", + /* 229 */ "type_name ::= TINYINT UNSIGNED", + /* 230 */ "type_name ::= SMALLINT UNSIGNED", + /* 231 */ "type_name ::= INT UNSIGNED", + /* 232 */ "type_name ::= BIGINT UNSIGNED", + /* 233 */ "type_name ::= JSON", + /* 234 */ "type_name ::= VARCHAR NK_LP NK_INTEGER NK_RP", + /* 235 */ "type_name ::= MEDIUMBLOB", + /* 236 */ "type_name ::= BLOB", + /* 237 */ "type_name ::= VARBINARY NK_LP NK_INTEGER NK_RP", + /* 238 */ "type_name ::= GEOMETRY NK_LP NK_INTEGER NK_RP", + /* 239 */ "type_name ::= DECIMAL", + /* 240 */ "type_name ::= DECIMAL NK_LP NK_INTEGER NK_RP", + /* 241 */ "type_name ::= DECIMAL NK_LP NK_INTEGER NK_COMMA NK_INTEGER NK_RP", + /* 242 */ "type_name_default_len ::= BINARY", + /* 243 */ "type_name_default_len ::= NCHAR", + /* 244 */ "type_name_default_len ::= VARCHAR", + /* 245 */ "type_name_default_len ::= VARBINARY", + /* 246 */ "tags_def_opt ::=", + /* 247 */ "tags_def_opt ::= tags_def", + /* 248 */ "tags_def ::= TAGS NK_LP tag_def_list NK_RP", + /* 249 */ "table_options ::=", + /* 250 */ "table_options ::= table_options COMMENT NK_STRING", + /* 251 */ "table_options ::= table_options MAX_DELAY duration_list", + /* 252 */ "table_options ::= table_options WATERMARK duration_list", + /* 253 */ "table_options ::= table_options ROLLUP NK_LP rollup_func_list NK_RP", + /* 254 */ "table_options ::= table_options TTL NK_INTEGER", + /* 255 */ "table_options ::= table_options SMA NK_LP col_name_list NK_RP", + /* 256 */ "table_options ::= table_options DELETE_MARK duration_list", + /* 257 */ "alter_table_options ::= alter_table_option", + /* 258 */ "alter_table_options ::= alter_table_options alter_table_option", + /* 259 */ "alter_table_option ::= COMMENT NK_STRING", + /* 260 */ "alter_table_option ::= TTL NK_INTEGER", + /* 261 */ "duration_list ::= duration_literal", + /* 262 */ "duration_list ::= duration_list NK_COMMA duration_literal", + /* 263 */ "rollup_func_list ::= rollup_func_name", + /* 264 */ "rollup_func_list ::= rollup_func_list NK_COMMA rollup_func_name", + /* 265 */ "rollup_func_name ::= function_name", + /* 266 */ "rollup_func_name ::= FIRST", + /* 267 */ "rollup_func_name ::= LAST", + /* 268 */ "col_name_list ::= col_name", + /* 269 */ "col_name_list ::= col_name_list NK_COMMA col_name", + /* 270 */ "col_name ::= column_name", + /* 271 */ "cmd ::= SHOW DNODES", + /* 272 */ "cmd ::= SHOW USERS", + /* 273 */ "cmd ::= SHOW USERS FULL", + /* 274 */ "cmd ::= SHOW USER PRIVILEGES", + /* 275 */ "cmd ::= SHOW db_kind_opt DATABASES", + /* 276 */ "cmd ::= SHOW table_kind_db_name_cond_opt TABLES like_pattern_opt", + /* 277 */ "cmd ::= SHOW db_name_cond_opt STABLES like_pattern_opt", + /* 278 */ "cmd ::= SHOW db_name_cond_opt VGROUPS", + /* 279 */ "cmd ::= SHOW MNODES", + /* 280 */ "cmd ::= SHOW QNODES", + /* 281 */ "cmd ::= SHOW ARBGROUPS", + /* 282 */ "cmd ::= SHOW FUNCTIONS", + /* 283 */ "cmd ::= SHOW INDEXES FROM table_name_cond from_db_opt", + /* 284 */ "cmd ::= SHOW INDEXES FROM db_name NK_DOT table_name", + /* 285 */ "cmd ::= SHOW STREAMS", + /* 286 */ "cmd ::= SHOW ACCOUNTS", + /* 287 */ "cmd ::= SHOW APPS", + /* 288 */ "cmd ::= SHOW CONNECTIONS", + /* 289 */ "cmd ::= SHOW LICENCES", + /* 290 */ "cmd ::= SHOW GRANTS", + /* 291 */ "cmd ::= SHOW GRANTS FULL", + /* 292 */ "cmd ::= SHOW GRANTS LOGS", + /* 293 */ "cmd ::= SHOW CLUSTER MACHINES", + /* 294 */ "cmd ::= SHOW CREATE DATABASE db_name", + /* 295 */ "cmd ::= SHOW CREATE TABLE full_table_name", + /* 296 */ "cmd ::= SHOW CREATE STABLE full_table_name", + /* 297 */ "cmd ::= SHOW ENCRYPTIONS", + /* 298 */ "cmd ::= SHOW QUERIES", + /* 299 */ "cmd ::= SHOW SCORES", + /* 300 */ "cmd ::= SHOW TOPICS", + /* 301 */ "cmd ::= SHOW VARIABLES", + /* 302 */ "cmd ::= SHOW CLUSTER VARIABLES", + /* 303 */ "cmd ::= SHOW LOCAL VARIABLES", + /* 304 */ "cmd ::= SHOW DNODE NK_INTEGER VARIABLES like_pattern_opt", + /* 305 */ "cmd ::= SHOW BNODES", + /* 306 */ "cmd ::= SHOW SNODES", + /* 307 */ "cmd ::= SHOW CLUSTER", + /* 308 */ "cmd ::= SHOW TRANSACTIONS", + /* 309 */ "cmd ::= SHOW TABLE DISTRIBUTED full_table_name", + /* 310 */ "cmd ::= SHOW CONSUMERS", + /* 311 */ "cmd ::= SHOW SUBSCRIPTIONS", + /* 312 */ "cmd ::= SHOW TAGS FROM table_name_cond from_db_opt", + /* 313 */ "cmd ::= SHOW TAGS FROM db_name NK_DOT table_name", + /* 314 */ "cmd ::= SHOW TABLE TAGS tag_list_opt FROM table_name_cond from_db_opt", + /* 315 */ "cmd ::= SHOW TABLE TAGS tag_list_opt FROM db_name NK_DOT table_name", + /* 316 */ "cmd ::= SHOW VNODES ON DNODE NK_INTEGER", + /* 317 */ "cmd ::= SHOW VNODES", + /* 318 */ "cmd ::= SHOW db_name_cond_opt ALIVE", + /* 319 */ "cmd ::= SHOW CLUSTER ALIVE", + /* 320 */ "cmd ::= SHOW db_name_cond_opt VIEWS like_pattern_opt", + /* 321 */ "cmd ::= SHOW CREATE VIEW full_table_name", + /* 322 */ "cmd ::= SHOW COMPACTS", + /* 323 */ "cmd ::= SHOW COMPACT NK_INTEGER", + /* 324 */ "table_kind_db_name_cond_opt ::=", + /* 325 */ "table_kind_db_name_cond_opt ::= table_kind", + /* 326 */ "table_kind_db_name_cond_opt ::= db_name NK_DOT", + /* 327 */ "table_kind_db_name_cond_opt ::= table_kind db_name NK_DOT", + /* 328 */ "table_kind ::= NORMAL", + /* 329 */ "table_kind ::= CHILD", + /* 330 */ "db_name_cond_opt ::=", + /* 331 */ "db_name_cond_opt ::= db_name NK_DOT", + /* 332 */ "like_pattern_opt ::=", + /* 333 */ "like_pattern_opt ::= LIKE NK_STRING", + /* 334 */ "table_name_cond ::= table_name", + /* 335 */ "from_db_opt ::=", + /* 336 */ "from_db_opt ::= FROM db_name", + /* 337 */ "tag_list_opt ::=", + /* 338 */ "tag_list_opt ::= tag_item", + /* 339 */ "tag_list_opt ::= tag_list_opt NK_COMMA tag_item", + /* 340 */ "tag_item ::= TBNAME", + /* 341 */ "tag_item ::= QTAGS", + /* 342 */ "tag_item ::= column_name", + /* 343 */ "tag_item ::= column_name column_alias", + /* 344 */ "tag_item ::= column_name AS column_alias", + /* 345 */ "db_kind_opt ::=", + /* 346 */ "db_kind_opt ::= USER", + /* 347 */ "db_kind_opt ::= SYSTEM", + /* 348 */ "cmd ::= CREATE TSMA not_exists_opt tsma_name ON full_table_name tsma_func_list INTERVAL NK_LP duration_literal NK_RP", + /* 349 */ "cmd ::= CREATE RECURSIVE TSMA not_exists_opt tsma_name ON full_table_name INTERVAL NK_LP duration_literal NK_RP", + /* 350 */ "cmd ::= DROP TSMA exists_opt full_tsma_name", + /* 351 */ "cmd ::= SHOW db_name_cond_opt TSMAS", + /* 352 */ "full_tsma_name ::= tsma_name", + /* 353 */ "full_tsma_name ::= db_name NK_DOT tsma_name", + /* 354 */ "tsma_func_list ::= FUNCTION NK_LP func_list NK_RP", + /* 355 */ "cmd ::= CREATE SMA INDEX not_exists_opt col_name ON full_table_name index_options", + /* 356 */ "cmd ::= CREATE INDEX not_exists_opt col_name ON full_table_name NK_LP col_name_list NK_RP", + /* 357 */ "cmd ::= DROP INDEX exists_opt full_index_name", + /* 358 */ "full_index_name ::= index_name", + /* 359 */ "full_index_name ::= db_name NK_DOT index_name", + /* 360 */ "index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_RP sliding_opt sma_stream_opt", + /* 361 */ "index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_COMMA duration_literal NK_RP sliding_opt sma_stream_opt", + /* 362 */ "func_list ::= func", + /* 363 */ "func_list ::= func_list NK_COMMA func", + /* 364 */ "func ::= sma_func_name NK_LP expression_list NK_RP", + /* 365 */ "sma_func_name ::= function_name", + /* 366 */ "sma_func_name ::= COUNT", + /* 367 */ "sma_func_name ::= FIRST", + /* 368 */ "sma_func_name ::= LAST", + /* 369 */ "sma_func_name ::= LAST_ROW", + /* 370 */ "sma_stream_opt ::=", + /* 371 */ "sma_stream_opt ::= sma_stream_opt WATERMARK duration_literal", + /* 372 */ "sma_stream_opt ::= sma_stream_opt MAX_DELAY duration_literal", + /* 373 */ "sma_stream_opt ::= sma_stream_opt DELETE_MARK duration_literal", + /* 374 */ "with_meta ::= AS", + /* 375 */ "with_meta ::= WITH META AS", + /* 376 */ "with_meta ::= ONLY META AS", + /* 377 */ "cmd ::= CREATE TOPIC not_exists_opt topic_name AS query_or_subquery", + /* 378 */ "cmd ::= CREATE TOPIC not_exists_opt topic_name with_meta DATABASE db_name", + /* 379 */ "cmd ::= CREATE TOPIC not_exists_opt topic_name with_meta STABLE full_table_name where_clause_opt", + /* 380 */ "cmd ::= DROP TOPIC exists_opt topic_name", + /* 381 */ "cmd ::= DROP CONSUMER GROUP exists_opt cgroup_name ON topic_name", + /* 382 */ "cmd ::= DESC full_table_name", + /* 383 */ "cmd ::= DESCRIBE full_table_name", + /* 384 */ "cmd ::= RESET QUERY CACHE", + /* 385 */ "cmd ::= EXPLAIN analyze_opt explain_options query_or_subquery", + /* 386 */ "cmd ::= EXPLAIN analyze_opt explain_options insert_query", + /* 387 */ "analyze_opt ::=", + /* 388 */ "analyze_opt ::= ANALYZE", + /* 389 */ "explain_options ::=", + /* 390 */ "explain_options ::= explain_options VERBOSE NK_BOOL", + /* 391 */ "explain_options ::= explain_options RATIO NK_FLOAT", + /* 392 */ "cmd ::= CREATE or_replace_opt agg_func_opt FUNCTION not_exists_opt function_name AS NK_STRING OUTPUTTYPE type_name bufsize_opt language_opt", + /* 393 */ "cmd ::= DROP FUNCTION exists_opt function_name", + /* 394 */ "agg_func_opt ::=", + /* 395 */ "agg_func_opt ::= AGGREGATE", + /* 396 */ "bufsize_opt ::=", + /* 397 */ "bufsize_opt ::= BUFSIZE NK_INTEGER", + /* 398 */ "language_opt ::=", + /* 399 */ "language_opt ::= LANGUAGE NK_STRING", + /* 400 */ "or_replace_opt ::=", + /* 401 */ "or_replace_opt ::= OR REPLACE", + /* 402 */ "cmd ::= CREATE or_replace_opt VIEW full_view_name AS query_or_subquery", + /* 403 */ "cmd ::= DROP VIEW exists_opt full_view_name", + /* 404 */ "full_view_name ::= view_name", + /* 405 */ "full_view_name ::= db_name NK_DOT view_name", + /* 406 */ "cmd ::= CREATE STREAM not_exists_opt stream_name stream_options INTO full_table_name col_list_opt tag_def_or_ref_opt subtable_opt AS query_or_subquery", + /* 407 */ "cmd ::= DROP STREAM exists_opt stream_name", + /* 408 */ "cmd ::= PAUSE STREAM exists_opt stream_name", + /* 409 */ "cmd ::= RESUME STREAM exists_opt ignore_opt stream_name", + /* 410 */ "col_list_opt ::=", + /* 411 */ "col_list_opt ::= NK_LP column_stream_def_list NK_RP", + /* 412 */ "column_stream_def_list ::= column_stream_def", + /* 413 */ "column_stream_def_list ::= column_stream_def_list NK_COMMA column_stream_def", + /* 414 */ "column_stream_def ::= column_name stream_col_options", + /* 415 */ "stream_col_options ::=", + /* 416 */ "stream_col_options ::= stream_col_options PRIMARY KEY", + /* 417 */ "tag_def_or_ref_opt ::=", + /* 418 */ "tag_def_or_ref_opt ::= tags_def", + /* 419 */ "tag_def_or_ref_opt ::= TAGS NK_LP column_stream_def_list NK_RP", + /* 420 */ "stream_options ::=", + /* 421 */ "stream_options ::= stream_options TRIGGER AT_ONCE", + /* 422 */ "stream_options ::= stream_options TRIGGER WINDOW_CLOSE", + /* 423 */ "stream_options ::= stream_options TRIGGER MAX_DELAY duration_literal", + /* 424 */ "stream_options ::= stream_options WATERMARK duration_literal", + /* 425 */ "stream_options ::= stream_options IGNORE EXPIRED NK_INTEGER", + /* 426 */ "stream_options ::= stream_options FILL_HISTORY NK_INTEGER", + /* 427 */ "stream_options ::= stream_options DELETE_MARK duration_literal", + /* 428 */ "stream_options ::= stream_options IGNORE UPDATE NK_INTEGER", + /* 429 */ "subtable_opt ::=", + /* 430 */ "subtable_opt ::= SUBTABLE NK_LP expression NK_RP", + /* 431 */ "ignore_opt ::=", + /* 432 */ "ignore_opt ::= IGNORE UNTREATED", + /* 433 */ "cmd ::= KILL CONNECTION NK_INTEGER", + /* 434 */ "cmd ::= KILL QUERY NK_STRING", + /* 435 */ "cmd ::= KILL TRANSACTION NK_INTEGER", + /* 436 */ "cmd ::= KILL COMPACT NK_INTEGER", + /* 437 */ "cmd ::= BALANCE VGROUP", + /* 438 */ "cmd ::= BALANCE VGROUP LEADER on_vgroup_id", + /* 439 */ "cmd ::= BALANCE VGROUP LEADER DATABASE db_name", + /* 440 */ "cmd ::= MERGE VGROUP NK_INTEGER NK_INTEGER", + /* 441 */ "cmd ::= REDISTRIBUTE VGROUP NK_INTEGER dnode_list", + /* 442 */ "cmd ::= SPLIT VGROUP NK_INTEGER", + /* 443 */ "on_vgroup_id ::=", + /* 444 */ "on_vgroup_id ::= ON NK_INTEGER", + /* 445 */ "dnode_list ::= DNODE NK_INTEGER", + /* 446 */ "dnode_list ::= dnode_list DNODE NK_INTEGER", + /* 447 */ "cmd ::= DELETE FROM full_table_name where_clause_opt", + /* 448 */ "cmd ::= query_or_subquery", + /* 449 */ "cmd ::= insert_query", + /* 450 */ "insert_query ::= INSERT INTO full_table_name NK_LP col_name_list NK_RP query_or_subquery", + /* 451 */ "insert_query ::= INSERT INTO full_table_name query_or_subquery", + /* 452 */ "tags_literal ::= NK_INTEGER", + /* 453 */ "tags_literal ::= NK_INTEGER NK_PLUS duration_literal", + /* 454 */ "tags_literal ::= NK_INTEGER NK_MINUS duration_literal", + /* 455 */ "tags_literal ::= NK_PLUS NK_INTEGER", + /* 456 */ "tags_literal ::= NK_PLUS NK_INTEGER NK_PLUS duration_literal", + /* 457 */ "tags_literal ::= NK_PLUS NK_INTEGER NK_MINUS duration_literal", + /* 458 */ "tags_literal ::= NK_MINUS NK_INTEGER", + /* 459 */ "tags_literal ::= NK_MINUS NK_INTEGER NK_PLUS duration_literal", + /* 460 */ "tags_literal ::= NK_MINUS NK_INTEGER NK_MINUS duration_literal", + /* 461 */ "tags_literal ::= NK_FLOAT", + /* 462 */ "tags_literal ::= NK_PLUS NK_FLOAT", + /* 463 */ "tags_literal ::= NK_MINUS NK_FLOAT", + /* 464 */ "tags_literal ::= NK_BIN", + /* 465 */ "tags_literal ::= NK_BIN NK_PLUS duration_literal", + /* 466 */ "tags_literal ::= NK_BIN NK_MINUS duration_literal", + /* 467 */ "tags_literal ::= NK_PLUS NK_BIN", + /* 468 */ "tags_literal ::= NK_PLUS NK_BIN NK_PLUS duration_literal", + /* 469 */ "tags_literal ::= NK_PLUS NK_BIN NK_MINUS duration_literal", + /* 470 */ "tags_literal ::= NK_MINUS NK_BIN", + /* 471 */ "tags_literal ::= NK_MINUS NK_BIN NK_PLUS duration_literal", + /* 472 */ "tags_literal ::= NK_MINUS NK_BIN NK_MINUS duration_literal", + /* 473 */ "tags_literal ::= NK_HEX", + /* 474 */ "tags_literal ::= NK_HEX NK_PLUS duration_literal", + /* 475 */ "tags_literal ::= NK_HEX NK_MINUS duration_literal", + /* 476 */ "tags_literal ::= NK_PLUS NK_HEX", + /* 477 */ "tags_literal ::= NK_PLUS NK_HEX NK_PLUS duration_literal", + /* 478 */ "tags_literal ::= NK_PLUS NK_HEX NK_MINUS duration_literal", + /* 479 */ "tags_literal ::= NK_MINUS NK_HEX", + /* 480 */ "tags_literal ::= NK_MINUS NK_HEX NK_PLUS duration_literal", + /* 481 */ "tags_literal ::= NK_MINUS NK_HEX NK_MINUS duration_literal", + /* 482 */ "tags_literal ::= NK_STRING", + /* 483 */ "tags_literal ::= NK_STRING NK_PLUS duration_literal", + /* 484 */ "tags_literal ::= NK_STRING NK_MINUS duration_literal", + /* 485 */ "tags_literal ::= NK_BOOL", + /* 486 */ "tags_literal ::= NULL", + /* 487 */ "tags_literal ::= literal_func", + /* 488 */ "tags_literal ::= literal_func NK_PLUS duration_literal", + /* 489 */ "tags_literal ::= literal_func NK_MINUS duration_literal", + /* 490 */ "tags_literal_list ::= tags_literal", + /* 491 */ "tags_literal_list ::= tags_literal_list NK_COMMA tags_literal", + /* 492 */ "literal ::= NK_INTEGER", + /* 493 */ "literal ::= NK_FLOAT", + /* 494 */ "literal ::= NK_STRING", + /* 495 */ "literal ::= NK_BOOL", + /* 496 */ "literal ::= TIMESTAMP NK_STRING", + /* 497 */ "literal ::= duration_literal", + /* 498 */ "literal ::= NULL", + /* 499 */ "literal ::= NK_QUESTION", + /* 500 */ "duration_literal ::= NK_VARIABLE", + /* 501 */ "signed ::= NK_INTEGER", + /* 502 */ "signed ::= NK_PLUS NK_INTEGER", + /* 503 */ "signed ::= NK_MINUS NK_INTEGER", + /* 504 */ "signed ::= NK_FLOAT", + /* 505 */ "signed ::= NK_PLUS NK_FLOAT", + /* 506 */ "signed ::= NK_MINUS NK_FLOAT", + /* 507 */ "signed_literal ::= signed", + /* 508 */ "signed_literal ::= NK_STRING", + /* 509 */ "signed_literal ::= NK_BOOL", + /* 510 */ "signed_literal ::= TIMESTAMP NK_STRING", + /* 511 */ "signed_literal ::= duration_literal", + /* 512 */ "signed_literal ::= NULL", + /* 513 */ "signed_literal ::= literal_func", + /* 514 */ "signed_literal ::= NK_QUESTION", + /* 515 */ "literal_list ::= signed_literal", + /* 516 */ "literal_list ::= literal_list NK_COMMA signed_literal", + /* 517 */ "db_name ::= NK_ID", + /* 518 */ "table_name ::= NK_ID", + /* 519 */ "column_name ::= NK_ID", + /* 520 */ "function_name ::= NK_ID", + /* 521 */ "view_name ::= NK_ID", + /* 522 */ "table_alias ::= NK_ID", + /* 523 */ "column_alias ::= NK_ID", + /* 524 */ "column_alias ::= NK_ALIAS", + /* 525 */ "user_name ::= NK_ID", + /* 526 */ "topic_name ::= NK_ID", + /* 527 */ "stream_name ::= NK_ID", + /* 528 */ "cgroup_name ::= NK_ID", + /* 529 */ "index_name ::= NK_ID", + /* 530 */ "tsma_name ::= NK_ID", + /* 531 */ "expr_or_subquery ::= expression", + /* 532 */ "expression ::= literal", + /* 533 */ "expression ::= pseudo_column", + /* 534 */ "expression ::= column_reference", + /* 535 */ "expression ::= function_expression", + /* 536 */ "expression ::= case_when_expression", + /* 537 */ "expression ::= NK_LP expression NK_RP", + /* 538 */ "expression ::= NK_PLUS expr_or_subquery", + /* 539 */ "expression ::= NK_MINUS expr_or_subquery", + /* 540 */ "expression ::= expr_or_subquery NK_PLUS expr_or_subquery", + /* 541 */ "expression ::= expr_or_subquery NK_MINUS expr_or_subquery", + /* 542 */ "expression ::= expr_or_subquery NK_STAR expr_or_subquery", + /* 543 */ "expression ::= expr_or_subquery NK_SLASH expr_or_subquery", + /* 544 */ "expression ::= expr_or_subquery NK_REM expr_or_subquery", + /* 545 */ "expression ::= column_reference NK_ARROW NK_STRING", + /* 546 */ "expression ::= expr_or_subquery NK_BITAND expr_or_subquery", + /* 547 */ "expression ::= expr_or_subquery NK_BITOR expr_or_subquery", + /* 548 */ "expression_list ::= expr_or_subquery", + /* 549 */ "expression_list ::= expression_list NK_COMMA expr_or_subquery", + /* 550 */ "column_reference ::= column_name", + /* 551 */ "column_reference ::= table_name NK_DOT column_name", + /* 552 */ "column_reference ::= NK_ALIAS", + /* 553 */ "column_reference ::= table_name NK_DOT NK_ALIAS", + /* 554 */ "pseudo_column ::= ROWTS", + /* 555 */ "pseudo_column ::= TBNAME", + /* 556 */ "pseudo_column ::= table_name NK_DOT TBNAME", + /* 557 */ "pseudo_column ::= QSTART", + /* 558 */ "pseudo_column ::= QEND", + /* 559 */ "pseudo_column ::= QDURATION", + /* 560 */ "pseudo_column ::= WSTART", + /* 561 */ "pseudo_column ::= WEND", + /* 562 */ "pseudo_column ::= WDURATION", + /* 563 */ "pseudo_column ::= IROWTS", + /* 564 */ "pseudo_column ::= ISFILLED", + /* 565 */ "pseudo_column ::= QTAGS", + /* 566 */ "function_expression ::= function_name NK_LP expression_list NK_RP", + /* 567 */ "function_expression ::= star_func NK_LP star_func_para_list NK_RP", + /* 568 */ "function_expression ::= CAST NK_LP expr_or_subquery AS type_name NK_RP", + /* 569 */ "function_expression ::= CAST NK_LP expr_or_subquery AS type_name_default_len NK_RP", + /* 570 */ "function_expression ::= POSITION NK_LP expr_or_subquery IN expr_or_subquery NK_RP", + /* 571 */ "function_expression ::= TRIM NK_LP expr_or_subquery NK_RP", + /* 572 */ "function_expression ::= TRIM NK_LP trim_specification_type FROM expr_or_subquery NK_RP", + /* 573 */ "function_expression ::= TRIM NK_LP expr_or_subquery FROM expr_or_subquery NK_RP", + /* 574 */ "function_expression ::= TRIM NK_LP trim_specification_type expr_or_subquery FROM expr_or_subquery NK_RP", + /* 575 */ "function_expression ::= substr_func NK_LP expression_list NK_RP", + /* 576 */ "function_expression ::= substr_func NK_LP expr_or_subquery FROM expr_or_subquery NK_RP", + /* 577 */ "function_expression ::= substr_func NK_LP expr_or_subquery FROM expr_or_subquery FOR expr_or_subquery NK_RP", + /* 578 */ "function_expression ::= REPLACE NK_LP expression_list NK_RP", + /* 579 */ "function_expression ::= literal_func", + /* 580 */ "function_expression ::= rand_func", + /* 581 */ "literal_func ::= noarg_func NK_LP NK_RP", + /* 582 */ "literal_func ::= NOW", + /* 583 */ "literal_func ::= TODAY", + /* 584 */ "rand_func ::= RAND NK_LP NK_RP", + /* 585 */ "rand_func ::= RAND NK_LP expression_list NK_RP", + /* 586 */ "substr_func ::= SUBSTR", + /* 587 */ "substr_func ::= SUBSTRING", + /* 588 */ "trim_specification_type ::= BOTH", + /* 589 */ "trim_specification_type ::= TRAILING", + /* 590 */ "trim_specification_type ::= LEADING", + /* 591 */ "noarg_func ::= NOW", + /* 592 */ "noarg_func ::= TODAY", + /* 593 */ "noarg_func ::= TIMEZONE", + /* 594 */ "noarg_func ::= DATABASE", + /* 595 */ "noarg_func ::= CLIENT_VERSION", + /* 596 */ "noarg_func ::= SERVER_VERSION", + /* 597 */ "noarg_func ::= SERVER_STATUS", + /* 598 */ "noarg_func ::= CURRENT_USER", + /* 599 */ "noarg_func ::= USER", + /* 600 */ "noarg_func ::= PI", + /* 601 */ "star_func ::= COUNT", + /* 602 */ "star_func ::= FIRST", + /* 603 */ "star_func ::= LAST", + /* 604 */ "star_func ::= LAST_ROW", + /* 605 */ "star_func_para_list ::= NK_STAR", + /* 606 */ "star_func_para_list ::= other_para_list", + /* 607 */ "other_para_list ::= star_func_para", + /* 608 */ "other_para_list ::= other_para_list NK_COMMA star_func_para", + /* 609 */ "star_func_para ::= expr_or_subquery", + /* 610 */ "star_func_para ::= table_name NK_DOT NK_STAR", + /* 611 */ "case_when_expression ::= CASE when_then_list case_when_else_opt END", + /* 612 */ "case_when_expression ::= CASE common_expression when_then_list case_when_else_opt END", + /* 613 */ "when_then_list ::= when_then_expr", + /* 614 */ "when_then_list ::= when_then_list when_then_expr", + /* 615 */ "when_then_expr ::= WHEN common_expression THEN common_expression", + /* 616 */ "case_when_else_opt ::=", + /* 617 */ "case_when_else_opt ::= ELSE common_expression", + /* 618 */ "predicate ::= expr_or_subquery compare_op expr_or_subquery", + /* 619 */ "predicate ::= expr_or_subquery BETWEEN expr_or_subquery AND expr_or_subquery", + /* 620 */ "predicate ::= expr_or_subquery NOT BETWEEN expr_or_subquery AND expr_or_subquery", + /* 621 */ "predicate ::= expr_or_subquery IS NULL", + /* 622 */ "predicate ::= expr_or_subquery IS NOT NULL", + /* 623 */ "predicate ::= expr_or_subquery in_op in_predicate_value", + /* 624 */ "compare_op ::= NK_LT", + /* 625 */ "compare_op ::= NK_GT", + /* 626 */ "compare_op ::= NK_LE", + /* 627 */ "compare_op ::= NK_GE", + /* 628 */ "compare_op ::= NK_NE", + /* 629 */ "compare_op ::= NK_EQ", + /* 630 */ "compare_op ::= LIKE", + /* 631 */ "compare_op ::= NOT LIKE", + /* 632 */ "compare_op ::= MATCH", + /* 633 */ "compare_op ::= NMATCH", + /* 634 */ "compare_op ::= CONTAINS", + /* 635 */ "in_op ::= IN", + /* 636 */ "in_op ::= NOT IN", + /* 637 */ "in_predicate_value ::= NK_LP literal_list NK_RP", + /* 638 */ "boolean_value_expression ::= boolean_primary", + /* 639 */ "boolean_value_expression ::= NOT boolean_primary", + /* 640 */ "boolean_value_expression ::= boolean_value_expression OR boolean_value_expression", + /* 641 */ "boolean_value_expression ::= boolean_value_expression AND boolean_value_expression", + /* 642 */ "boolean_primary ::= predicate", + /* 643 */ "boolean_primary ::= NK_LP boolean_value_expression NK_RP", + /* 644 */ "common_expression ::= expr_or_subquery", + /* 645 */ "common_expression ::= boolean_value_expression", + /* 646 */ "from_clause_opt ::=", + /* 647 */ "from_clause_opt ::= FROM table_reference_list", + /* 648 */ "table_reference_list ::= table_reference", + /* 649 */ "table_reference_list ::= table_reference_list NK_COMMA table_reference", + /* 650 */ "table_reference ::= table_primary", + /* 651 */ "table_reference ::= joined_table", + /* 652 */ "table_primary ::= table_name alias_opt", + /* 653 */ "table_primary ::= db_name NK_DOT table_name alias_opt", + /* 654 */ "table_primary ::= subquery alias_opt", + /* 655 */ "table_primary ::= parenthesized_joined_table", + /* 656 */ "alias_opt ::=", + /* 657 */ "alias_opt ::= table_alias", + /* 658 */ "alias_opt ::= AS table_alias", + /* 659 */ "parenthesized_joined_table ::= NK_LP joined_table NK_RP", + /* 660 */ "parenthesized_joined_table ::= NK_LP parenthesized_joined_table NK_RP", + /* 661 */ "joined_table ::= table_reference join_type join_subtype JOIN table_reference join_on_clause_opt window_offset_clause_opt jlimit_clause_opt", + /* 662 */ "join_type ::=", + /* 663 */ "join_type ::= INNER", + /* 664 */ "join_type ::= LEFT", + /* 665 */ "join_type ::= RIGHT", + /* 666 */ "join_type ::= FULL", + /* 667 */ "join_subtype ::=", + /* 668 */ "join_subtype ::= OUTER", + /* 669 */ "join_subtype ::= SEMI", + /* 670 */ "join_subtype ::= ANTI", + /* 671 */ "join_subtype ::= ASOF", + /* 672 */ "join_subtype ::= WINDOW", + /* 673 */ "join_on_clause_opt ::=", + /* 674 */ "join_on_clause_opt ::= ON search_condition", + /* 675 */ "window_offset_clause_opt ::=", + /* 676 */ "window_offset_clause_opt ::= WINDOW_OFFSET NK_LP window_offset_literal NK_COMMA window_offset_literal NK_RP", + /* 677 */ "window_offset_literal ::= NK_VARIABLE", + /* 678 */ "window_offset_literal ::= NK_MINUS NK_VARIABLE", + /* 679 */ "jlimit_clause_opt ::=", + /* 680 */ "jlimit_clause_opt ::= JLIMIT NK_INTEGER", + /* 681 */ "query_specification ::= SELECT hint_list set_quantifier_opt tag_mode_opt select_list from_clause_opt where_clause_opt partition_by_clause_opt range_opt every_opt fill_opt twindow_clause_opt group_by_clause_opt having_clause_opt", + /* 682 */ "hint_list ::=", + /* 683 */ "hint_list ::= NK_HINT", + /* 684 */ "tag_mode_opt ::=", + /* 685 */ "tag_mode_opt ::= TAGS", + /* 686 */ "set_quantifier_opt ::=", + /* 687 */ "set_quantifier_opt ::= DISTINCT", + /* 688 */ "set_quantifier_opt ::= ALL", + /* 689 */ "select_list ::= select_item", + /* 690 */ "select_list ::= select_list NK_COMMA select_item", + /* 691 */ "select_item ::= NK_STAR", + /* 692 */ "select_item ::= common_expression", + /* 693 */ "select_item ::= common_expression column_alias", + /* 694 */ "select_item ::= common_expression AS column_alias", + /* 695 */ "select_item ::= table_name NK_DOT NK_STAR", + /* 696 */ "where_clause_opt ::=", + /* 697 */ "where_clause_opt ::= WHERE search_condition", + /* 698 */ "partition_by_clause_opt ::=", + /* 699 */ "partition_by_clause_opt ::= PARTITION BY partition_list", + /* 700 */ "partition_list ::= partition_item", + /* 701 */ "partition_list ::= partition_list NK_COMMA partition_item", + /* 702 */ "partition_item ::= expr_or_subquery", + /* 703 */ "partition_item ::= expr_or_subquery column_alias", + /* 704 */ "partition_item ::= expr_or_subquery AS column_alias", + /* 705 */ "twindow_clause_opt ::=", + /* 706 */ "twindow_clause_opt ::= SESSION NK_LP column_reference NK_COMMA interval_sliding_duration_literal NK_RP", + /* 707 */ "twindow_clause_opt ::= STATE_WINDOW NK_LP expr_or_subquery NK_RP", + /* 708 */ "twindow_clause_opt ::= INTERVAL NK_LP interval_sliding_duration_literal NK_RP sliding_opt fill_opt", + /* 709 */ "twindow_clause_opt ::= INTERVAL NK_LP interval_sliding_duration_literal NK_COMMA interval_sliding_duration_literal NK_RP sliding_opt fill_opt", + /* 710 */ "twindow_clause_opt ::= EVENT_WINDOW START WITH search_condition END WITH search_condition", + /* 711 */ "twindow_clause_opt ::= COUNT_WINDOW NK_LP NK_INTEGER NK_RP", + /* 712 */ "twindow_clause_opt ::= COUNT_WINDOW NK_LP NK_INTEGER NK_COMMA NK_INTEGER NK_RP", + /* 713 */ "sliding_opt ::=", + /* 714 */ "sliding_opt ::= SLIDING NK_LP interval_sliding_duration_literal NK_RP", + /* 715 */ "interval_sliding_duration_literal ::= NK_VARIABLE", + /* 716 */ "interval_sliding_duration_literal ::= NK_STRING", + /* 717 */ "interval_sliding_duration_literal ::= NK_INTEGER", + /* 718 */ "fill_opt ::=", + /* 719 */ "fill_opt ::= FILL NK_LP fill_mode NK_RP", + /* 720 */ "fill_opt ::= FILL NK_LP VALUE NK_COMMA expression_list NK_RP", + /* 721 */ "fill_opt ::= FILL NK_LP VALUE_F NK_COMMA expression_list NK_RP", + /* 722 */ "fill_mode ::= NONE", + /* 723 */ "fill_mode ::= PREV", + /* 724 */ "fill_mode ::= NULL", + /* 725 */ "fill_mode ::= NULL_F", + /* 726 */ "fill_mode ::= LINEAR", + /* 727 */ "fill_mode ::= NEXT", + /* 728 */ "group_by_clause_opt ::=", + /* 729 */ "group_by_clause_opt ::= GROUP BY group_by_list", + /* 730 */ "group_by_list ::= expr_or_subquery", + /* 731 */ "group_by_list ::= group_by_list NK_COMMA expr_or_subquery", + /* 732 */ "having_clause_opt ::=", + /* 733 */ "having_clause_opt ::= HAVING search_condition", + /* 734 */ "range_opt ::=", + /* 735 */ "range_opt ::= RANGE NK_LP expr_or_subquery NK_COMMA expr_or_subquery NK_RP", + /* 736 */ "range_opt ::= RANGE NK_LP expr_or_subquery NK_RP", + /* 737 */ "every_opt ::=", + /* 738 */ "every_opt ::= EVERY NK_LP duration_literal NK_RP", + /* 739 */ "query_expression ::= query_simple order_by_clause_opt slimit_clause_opt limit_clause_opt", + /* 740 */ "query_simple ::= query_specification", + /* 741 */ "query_simple ::= union_query_expression", + /* 742 */ "union_query_expression ::= query_simple_or_subquery UNION ALL query_simple_or_subquery", + /* 743 */ "union_query_expression ::= query_simple_or_subquery UNION query_simple_or_subquery", + /* 744 */ "query_simple_or_subquery ::= query_simple", + /* 745 */ "query_simple_or_subquery ::= subquery", + /* 746 */ "query_or_subquery ::= query_expression", + /* 747 */ "query_or_subquery ::= subquery", + /* 748 */ "order_by_clause_opt ::=", + /* 749 */ "order_by_clause_opt ::= ORDER BY sort_specification_list", + /* 750 */ "slimit_clause_opt ::=", + /* 751 */ "slimit_clause_opt ::= SLIMIT NK_INTEGER", + /* 752 */ "slimit_clause_opt ::= SLIMIT NK_INTEGER SOFFSET NK_INTEGER", + /* 753 */ "slimit_clause_opt ::= SLIMIT NK_INTEGER NK_COMMA NK_INTEGER", + /* 754 */ "limit_clause_opt ::=", + /* 755 */ "limit_clause_opt ::= LIMIT NK_INTEGER", + /* 756 */ "limit_clause_opt ::= LIMIT NK_INTEGER OFFSET NK_INTEGER", + /* 757 */ "limit_clause_opt ::= LIMIT NK_INTEGER NK_COMMA NK_INTEGER", + /* 758 */ "subquery ::= NK_LP query_expression NK_RP", + /* 759 */ "subquery ::= NK_LP subquery NK_RP", + /* 760 */ "search_condition ::= common_expression", + /* 761 */ "sort_specification_list ::= sort_specification", + /* 762 */ "sort_specification_list ::= sort_specification_list NK_COMMA sort_specification", + /* 763 */ "sort_specification ::= expr_or_subquery ordering_specification_opt null_ordering_opt", + /* 764 */ "ordering_specification_opt ::=", + /* 765 */ "ordering_specification_opt ::= ASC", + /* 766 */ "ordering_specification_opt ::= DESC", + /* 767 */ "null_ordering_opt ::=", + /* 768 */ "null_ordering_opt ::= NULLS FIRST", + /* 769 */ "null_ordering_opt ::= NULLS LAST", + /* 770 */ "column_options ::=", + /* 771 */ "column_options ::= column_options PRIMARY KEY", + /* 772 */ "column_options ::= column_options NK_ID NK_STRING", }; #endif /* NDEBUG */ -#if YYGROWABLESTACK +#if YYSTACKDEPTH<=0 /* ** Try to increase the size of the parser stack. Return the number ** of errors. Return 0 on success. */ static int yyGrowStack(yyParser *p){ - int oldSize = 1 + (int)(p->yystackEnd - p->yystack); int newSize; int idx; yyStackEntry *pNew; - newSize = oldSize*2 + 100; - idx = (int)(p->yytos - p->yystack); - if( p->yystack==p->yystk0 ){ - pNew = YYREALLOC(0, newSize*sizeof(pNew[0])); - if( pNew==0 ) return 1; - memcpy(pNew, p->yystack, oldSize*sizeof(pNew[0])); + newSize = p->yystksz*2 + 100; + idx = p->yytos ? (int)(p->yytos - p->yystack) : 0; + if( p->yystack==&p->yystk0 ){ + pNew = malloc(newSize*sizeof(pNew[0])); + if( pNew ) pNew[0] = p->yystk0; }else{ - pNew = YYREALLOC(p->yystack, newSize*sizeof(pNew[0])); - if( pNew==0 ) return 1; + pNew = realloc(p->yystack, newSize*sizeof(pNew[0])); } - p->yystack = pNew; - p->yytos = &p->yystack[idx]; + if( pNew ){ + p->yystack = pNew; + p->yytos = &p->yystack[idx]; #ifndef NDEBUG - if( yyTraceFILE ){ - fprintf(yyTraceFILE,"%sStack grows from %d to %d entries.\n", - yyTracePrompt, oldSize, newSize); - } + if( yyTraceFILE ){ + fprintf(yyTraceFILE,"%sStack grows from %d to %d entries.\n", + yyTracePrompt, p->yystksz, newSize); + } #endif - p->yystackEnd = &p->yystack[newSize-1]; - return 0; + p->yystksz = newSize; + } + return pNew==0; } -#endif /* YYGROWABLESTACK */ - -#if !YYGROWABLESTACK -/* For builds that do no have a growable stack, yyGrowStack always -** returns an error. -*/ -# define yyGrowStack(X) 1 #endif /* Datatype of the argument to the memory allocated passed as the @@ -3706,25 +3280,35 @@ static int yyGrowStack(yyParser *p){ #endif /* Initialize a new parser that has already been allocated. - */ +*/ void ParseInit(void *yypRawParser ParseCTX_PDECL){ yyParser *yypParser = (yyParser*)yypRawParser; ParseCTX_STORE #ifdef YYTRACKMAXSTACKDEPTH - yypParser->yyhwm = 0; + yypParser->yyhwm = 0; +#endif +#if YYSTACKDEPTH<=0 + yypParser->yytos = NULL; + yypParser->yystack = NULL; + yypParser->yystksz = 0; + if( yyGrowStack(yypParser) ){ + yypParser->yystack = &yypParser->yystk0; + yypParser->yystksz = 1; + } #endif - yypParser->yystack = yypParser->yystk0; - yypParser->yystackEnd = &yypParser->yystack[YYSTACKDEPTH-1]; #ifndef YYNOERRORRECOVERY yypParser->yyerrcnt = -1; #endif yypParser->yytos = yypParser->yystack; yypParser->yystack[0].stateno = 0; yypParser->yystack[0].major = 0; +#if YYSTACKDEPTH>0 + yypParser->yystackEnd = &yypParser->yystack[YYSTACKDEPTH-1]; +#endif } #ifndef Parse_ENGINEALWAYSONSTACK -/* +/* ** This function allocates a new parser. ** The only argument is a pointer to a function which works like ** malloc. @@ -3751,33 +3335,33 @@ void *ParseAlloc(void *(*mallocProc)(YYMALLOCARGTYPE) ParseCTX_PDECL){ /* The following function deletes the "minor type" or semantic value ** associated with a symbol. The symbol can be either a terminal ** or nonterminal. "yymajor" is the symbol code, and "yypminor" is -** a pointer to the value to be deleted. The code used to do the +** a pointer to the value to be deleted. The code used to do the ** deletions is derived from the %destructor and/or %token_destructor ** directives of the input grammar. */ static void yy_destructor( - yyParser *yypParser, /* The parser */ - YYCODETYPE yymajor, /* Type code for object to destroy */ - YYMINORTYPE *yypminor /* The object to be destroyed */ + yyParser *yypParser, /* The parser */ + YYCODETYPE yymajor, /* Type code for object to destroy */ + YYMINORTYPE *yypminor /* The object to be destroyed */ ){ ParseARG_FETCH - ParseCTX_FETCH - switch( yymajor ){ - /* Here is inserted the actions which take place when a + ParseCTX_FETCH + switch( yymajor ){ + /* Here is inserted the actions which take place when a ** terminal or non-terminal is destroyed. This can happen ** when the symbol is popped from the stack during a - ** reduce or during error processing or when a parser is + ** reduce or during error processing or when a parser is ** being destroyed before it is finished parsing. ** ** Note: during a reduce, the only symbols destroyed are those ** which appear on the RHS of the rule, but which are *not* used ** inside the C code. - */ - /********* Begin destructor definitions ***************************************/ + */ +/********* Begin destructor definitions ***************************************/ /* Default NON-TERMINAL Destructor */ case 383: /* cmd */ case 386: /* literal */ - case 397: /* with_opt */ + case 397: /* with_clause_opt */ case 403: /* search_condition */ case 408: /* db_options */ case 410: /* alter_db_options */ @@ -3787,95 +3371,95 @@ static void yy_destructor( case 419: /* retention */ case 420: /* full_table_name */ case 423: /* table_options */ - case 428: /* alter_table_clause */ - case 429: /* alter_table_options */ - case 432: /* column_options */ - case 433: /* tags_literal */ - case 434: /* create_subtable_clause */ - case 437: /* drop_table_clause */ - case 440: /* tag_def */ - case 441: /* column_def */ - case 446: /* duration_literal */ - case 447: /* rollup_func_name */ - case 449: /* col_name */ - case 452: /* like_pattern_opt */ - case 453: /* db_name_cond_opt */ - case 454: /* table_name_cond */ - case 455: /* from_db_opt */ - case 457: /* tag_item */ - case 461: /* full_tsma_name */ - case 463: /* index_options */ - case 464: /* full_index_name */ - case 466: /* sliding_opt */ - case 467: /* sma_stream_opt */ - case 468: /* func */ - case 472: /* query_or_subquery */ - case 473: /* where_clause_opt */ - case 476: /* explain_options */ - case 477: /* insert_query */ - case 482: /* full_view_name */ - case 485: /* stream_options */ - case 488: /* subtable_opt */ - case 491: /* column_stream_def */ - case 492: /* stream_col_options */ - case 493: /* expression */ - case 496: /* literal_func */ - case 497: /* signed_literal */ - case 500: /* expr_or_subquery */ - case 501: /* pseudo_column */ - case 502: /* column_reference */ - case 503: /* function_expression */ - case 504: /* case_when_expression */ - case 509: /* rand_func */ - case 512: /* star_func_para */ - case 514: /* case_when_else_opt */ - case 515: /* common_expression */ - case 516: /* when_then_expr */ - case 517: /* predicate */ - case 520: /* in_predicate_value */ - case 521: /* boolean_value_expression */ - case 522: /* boolean_primary */ - case 523: /* from_clause_opt */ - case 524: /* table_reference_list */ - case 525: /* table_reference */ - case 526: /* table_primary */ - case 527: /* joined_table */ - case 529: /* subquery */ - case 530: /* parenthesized_joined_table */ - case 533: /* join_on_clause_opt */ - case 534: /* window_offset_clause_opt */ - case 535: /* jlimit_clause_opt */ - case 536: /* window_offset_literal */ - case 537: /* query_specification */ - case 543: /* range_opt */ - case 544: /* every_opt */ - case 545: /* fill_opt */ - case 546: /* twindow_clause_opt */ - case 548: /* having_clause_opt */ - case 549: /* select_item */ - case 551: /* partition_item */ - case 552: /* interval_sliding_duration_literal */ - case 555: /* query_expression */ - case 556: /* query_simple */ - case 558: /* slimit_clause_opt */ - case 559: /* limit_clause_opt */ - case 560: /* union_query_expression */ - case 561: /* query_simple_or_subquery */ - case 563: /* sort_specification */ - { - nodesDestroyNode((yypminor->yy724)); - } - break; + case 429: /* alter_table_clause */ + case 430: /* alter_table_options */ + case 433: /* column_options */ + case 434: /* tags_literal */ + case 435: /* create_subtable_clause */ + case 438: /* drop_table_clause */ + case 441: /* tag_def */ + case 442: /* column_def */ + case 447: /* duration_literal */ + case 448: /* rollup_func_name */ + case 450: /* col_name */ + case 453: /* like_pattern_opt */ + case 454: /* db_name_cond_opt */ + case 455: /* table_name_cond */ + case 456: /* from_db_opt */ + case 458: /* tag_item */ + case 462: /* full_tsma_name */ + case 464: /* index_options */ + case 465: /* full_index_name */ + case 467: /* sliding_opt */ + case 468: /* sma_stream_opt */ + case 469: /* func */ + case 473: /* query_or_subquery */ + case 474: /* where_clause_opt */ + case 477: /* explain_options */ + case 478: /* insert_query */ + case 483: /* full_view_name */ + case 486: /* stream_options */ + case 489: /* subtable_opt */ + case 492: /* column_stream_def */ + case 493: /* stream_col_options */ + case 494: /* expression */ + case 497: /* literal_func */ + case 498: /* signed_literal */ + case 501: /* expr_or_subquery */ + case 502: /* pseudo_column */ + case 503: /* column_reference */ + case 504: /* function_expression */ + case 505: /* case_when_expression */ + case 510: /* rand_func */ + case 513: /* star_func_para */ + case 515: /* case_when_else_opt */ + case 516: /* common_expression */ + case 517: /* when_then_expr */ + case 518: /* predicate */ + case 521: /* in_predicate_value */ + case 522: /* boolean_value_expression */ + case 523: /* boolean_primary */ + case 524: /* from_clause_opt */ + case 525: /* table_reference_list */ + case 526: /* table_reference */ + case 527: /* table_primary */ + case 528: /* joined_table */ + case 530: /* subquery */ + case 531: /* parenthesized_joined_table */ + case 534: /* join_on_clause_opt */ + case 535: /* window_offset_clause_opt */ + case 536: /* jlimit_clause_opt */ + case 537: /* window_offset_literal */ + case 538: /* query_specification */ + case 544: /* range_opt */ + case 545: /* every_opt */ + case 546: /* fill_opt */ + case 547: /* twindow_clause_opt */ + case 549: /* having_clause_opt */ + case 550: /* select_item */ + case 552: /* partition_item */ + case 553: /* interval_sliding_duration_literal */ + case 556: /* query_expression */ + case 557: /* query_simple */ + case 559: /* slimit_clause_opt */ + case 560: /* limit_clause_opt */ + case 561: /* union_query_expression */ + case 562: /* query_simple_or_subquery */ + case 564: /* sort_specification */ +{ + nodesDestroyNode((yypminor->yy560)); +} + break; case 384: /* account_options */ case 385: /* alter_account_options */ case 387: /* alter_account_option */ case 411: /* speed_opt */ - case 471: /* with_meta */ - case 480: /* bufsize_opt */ - { - - } - break; + case 472: /* with_meta */ + case 481: /* bufsize_opt */ +{ + +} + break; case 388: /* ip_range_list */ case 389: /* white_list */ case 390: /* white_list_opt */ @@ -3887,158 +3471,159 @@ static void yy_destructor( case 424: /* multi_create_clause */ case 425: /* tag_list_opt */ case 426: /* tags_def */ - case 427: /* multi_drop_clause */ - case 435: /* specific_cols_opt */ - case 436: /* tags_literal_list */ - case 438: /* col_name_list */ - case 439: /* tag_def_list */ - case 443: /* duration_list */ - case 444: /* rollup_func_list */ - case 462: /* func_list */ - case 470: /* expression_list */ - case 486: /* col_list_opt */ - case 487: /* tag_def_or_ref_opt */ - case 490: /* column_stream_def_list */ - case 495: /* dnode_list */ - case 498: /* literal_list */ - case 506: /* star_func_para_list */ - case 511: /* other_para_list */ - case 513: /* when_then_list */ - case 538: /* hint_list */ - case 541: /* select_list */ - case 542: /* partition_by_clause_opt */ - case 547: /* group_by_clause_opt */ - case 550: /* partition_list */ - case 554: /* group_by_list */ - case 557: /* order_by_clause_opt */ - case 562: /* sort_specification_list */ - { - nodesDestroyList((yypminor->yy712)); - } - break; + case 428: /* multi_drop_clause */ + case 436: /* specific_cols_opt */ + case 437: /* tags_literal_list */ + case 439: /* col_name_list */ + case 440: /* tag_def_list */ + case 444: /* duration_list */ + case 445: /* rollup_func_list */ + case 463: /* func_list */ + case 471: /* expression_list */ + case 487: /* col_list_opt */ + case 488: /* tag_def_or_ref_opt */ + case 491: /* column_stream_def_list */ + case 496: /* dnode_list */ + case 499: /* literal_list */ + case 507: /* star_func_para_list */ + case 512: /* other_para_list */ + case 514: /* when_then_list */ + case 539: /* hint_list */ + case 542: /* select_list */ + case 543: /* partition_by_clause_opt */ + case 548: /* group_by_clause_opt */ + case 551: /* partition_list */ + case 555: /* group_by_list */ + case 558: /* order_by_clause_opt */ + case 563: /* sort_specification_list */ +{ + nodesDestroyList((yypminor->yy334)); +} + break; case 391: /* is_import_opt */ case 392: /* is_createdb_opt */ case 394: /* sysinfo_opt */ - { - - } - break; +{ + +} + break; case 393: /* user_name */ case 400: /* db_name */ case 401: /* table_name */ case 402: /* topic_name */ case 404: /* dnode_endpoint */ - case 430: /* column_name */ - case 448: /* function_name */ - case 458: /* column_alias */ - case 459: /* tsma_name */ - case 465: /* index_name */ - case 469: /* sma_func_name */ - case 474: /* cgroup_name */ - case 481: /* language_opt */ - case 483: /* view_name */ - case 484: /* stream_name */ - case 494: /* on_vgroup_id */ - case 499: /* table_alias */ - case 505: /* star_func */ - case 508: /* substr_func */ - case 510: /* noarg_func */ - case 528: /* alias_opt */ - { - - } - break; + case 431: /* column_name */ + case 449: /* function_name */ + case 459: /* column_alias */ + case 460: /* tsma_name */ + case 466: /* index_name */ + case 470: /* sma_func_name */ + case 475: /* cgroup_name */ + case 482: /* language_opt */ + case 484: /* view_name */ + case 485: /* stream_name */ + case 495: /* on_vgroup_id */ + case 500: /* table_alias */ + case 506: /* star_func */ + case 509: /* substr_func */ + case 511: /* noarg_func */ + case 529: /* alias_opt */ +{ + +} + break; case 395: /* privileges */ case 398: /* priv_type_list */ case 399: /* priv_type */ - { - - } - break; +{ + +} + break; case 396: /* priv_level */ - { - - } - break; +{ + +} + break; case 405: /* force_opt */ case 406: /* unsafe_opt */ case 407: /* not_exists_opt */ case 409: /* exists_opt */ - case 475: /* analyze_opt */ - case 478: /* or_replace_opt */ - case 479: /* agg_func_opt */ - case 489: /* ignore_opt */ - case 539: /* set_quantifier_opt */ - case 540: /* tag_mode_opt */ - { - - } - break; + case 427: /* with_opt */ + case 476: /* analyze_opt */ + case 479: /* or_replace_opt */ + case 480: /* agg_func_opt */ + case 490: /* ignore_opt */ + case 540: /* set_quantifier_opt */ + case 541: /* tag_mode_opt */ +{ + +} + break; case 418: /* alter_db_option */ - case 445: /* alter_table_option */ - { - - } - break; - case 431: /* type_name */ - case 442: /* type_name_default_len */ - { - - } - break; - case 450: /* db_kind_opt */ - case 456: /* table_kind */ - { - - } - break; - case 451: /* table_kind_db_name_cond_opt */ - { - - } - break; - case 460: /* tsma_func_list */ - { - nodesDestroyNode((yypminor->yy724)); - } - break; - case 507: /* trim_specification_type */ - { - - } - break; - case 518: /* compare_op */ - case 519: /* in_op */ - { - - } - break; - case 531: /* join_type */ - { - - } - break; - case 532: /* join_subtype */ - { - - } - break; - case 553: /* fill_mode */ - { - - } - break; - case 564: /* ordering_specification_opt */ - { - - } - break; - case 565: /* null_ordering_opt */ - { - - } - break; - /********* End destructor definitions *****************************************/ + case 446: /* alter_table_option */ +{ + +} + break; + case 432: /* type_name */ + case 443: /* type_name_default_len */ +{ + +} + break; + case 451: /* db_kind_opt */ + case 457: /* table_kind */ +{ + +} + break; + case 452: /* table_kind_db_name_cond_opt */ +{ + +} + break; + case 461: /* tsma_func_list */ +{ + nodesDestroyNode((yypminor->yy560)); +} + break; + case 508: /* trim_specification_type */ +{ + +} + break; + case 519: /* compare_op */ + case 520: /* in_op */ +{ + +} + break; + case 532: /* join_type */ +{ + +} + break; + case 533: /* join_subtype */ +{ + +} + break; + case 554: /* fill_mode */ +{ + +} + break; + case 565: /* ordering_specification_opt */ +{ + +} + break; + case 566: /* null_ordering_opt */ +{ + +} + break; +/********* End destructor definitions *****************************************/ default: break; /* If no destructor action specified: do nothing */ } } @@ -4057,8 +3642,8 @@ static void yy_pop_parser_stack(yyParser *pParser){ #ifndef NDEBUG if( yyTraceFILE ){ fprintf(yyTraceFILE,"%sPopping %s\n", - yyTracePrompt, - yyTokenName[yytos->major]); + yyTracePrompt, + yyTokenName[yytos->major]); } #endif yy_destructor(pParser, yytos->major, &yytos->minor); @@ -4069,31 +3654,14 @@ static void yy_pop_parser_stack(yyParser *pParser){ */ void ParseFinalize(void *p){ yyParser *pParser = (yyParser*)p; - - /* In-lined version of calling yy_pop_parser_stack() for each - ** element left in the stack */ - yyStackEntry *yytos = pParser->yytos; - while( yytos>pParser->yystack ){ -#ifndef NDEBUG - if( yyTraceFILE ){ - fprintf(yyTraceFILE,"%sPopping %s\n", - yyTracePrompt, - yyTokenName[yytos->major]); - } -#endif - if( yytos->major>=YY_MIN_DSTRCTR ){ - yy_destructor(pParser, yytos->major, &yytos->minor); - } - yytos--; - } - -#if YYGROWABLESTACK - if( pParser->yystack!=pParser->yystk0 ) YYFREE(pParser->yystack); + while( pParser->yytos>pParser->yystack ) yy_pop_parser_stack(pParser); +#if YYSTACKDEPTH<=0 + if( pParser->yystack!=&pParser->yystk0 ) free(pParser->yystack); #endif } #ifndef Parse_ENGINEALWAYSONSTACK -/* +/* ** Deallocate and destroy a parser. Destructors are called for ** all stack elements before shutting the parser down. ** @@ -4102,8 +3670,8 @@ void ParseFinalize(void *p){ ** assumed that the input pointer is never NULL. */ void ParseFree( - void *p, /* The parser to be deleted */ - void (*freeProc)(void*) /* Function used to reclaim memory */ + void *p, /* The parser to be deleted */ + void (*freeProc)(void*) /* Function used to reclaim memory */ ){ #ifndef YYPARSEFREENEVERNULL if( p==0 ) return; @@ -4165,8 +3733,8 @@ int ParseCoverage(FILE *out){ ** look-ahead token iLookAhead. */ static YYACTIONTYPE yy_find_shift_action( - YYCODETYPE iLookAhead, /* The look-ahead token */ - YYACTIONTYPE stateno /* Current state number */ + YYCODETYPE iLookAhead, /* The look-ahead token */ + YYACTIONTYPE stateno /* Current state number */ ){ int i; @@ -4193,7 +3761,7 @@ static YYACTIONTYPE yy_find_shift_action( #ifndef NDEBUG if( yyTraceFILE ){ fprintf(yyTraceFILE, "%sFALLBACK %s => %s\n", - yyTracePrompt, yyTokenName[iLookAhead], yyTokenName[iFallback]); + yyTracePrompt, yyTokenName[iLookAhead], yyTokenName[iFallback]); } #endif assert( yyFallback[iFallback]==0 ); /* Fallback loop must terminate */ @@ -4209,8 +3777,8 @@ static YYACTIONTYPE yy_find_shift_action( #ifndef NDEBUG if( yyTraceFILE ){ fprintf(yyTraceFILE, "%sWILDCARD %s => %s\n", - yyTracePrompt, yyTokenName[iLookAhead], - yyTokenName[YYWILDCARD]); + yyTracePrompt, yyTokenName[iLookAhead], + yyTokenName[YYWILDCARD]); } #endif /* NDEBUG */ return yy_action[j]; @@ -4219,7 +3787,7 @@ static YYACTIONTYPE yy_find_shift_action( #endif /* YYWILDCARD */ return yy_default[stateno]; }else{ - assert( i>=0 && i<(int)(sizeof(yy_action)/sizeof(yy_action[0])) ); + assert( i>=0 && iyytos>yypParser->yystack ) yy_pop_parser_stack(yypParser); - /* Here code is inserted which will execute if the parser + while( yypParser->yytos>yypParser->yystack ) yy_pop_parser_stack(yypParser); + /* Here code is inserted which will execute if the parser ** stack every overflows */ - /******** Begin %stack_overflow code ******************************************/ - /******** End %stack_overflow code ********************************************/ - ParseARG_STORE /* Suppress warning about unused %extra_argument var */ - ParseCTX_STORE +/******** Begin %stack_overflow code ******************************************/ +/******** End %stack_overflow code ********************************************/ + ParseARG_STORE /* Suppress warning about unused %extra_argument var */ + ParseCTX_STORE } /* @@ -4283,12 +3851,12 @@ static void yyTraceShift(yyParser *yypParser, int yyNewState, const char *zTag){ if( yyTraceFILE ){ if( yyNewStateyytos->major], - yyNewState); + yyTracePrompt, zTag, yyTokenName[yypParser->yytos->major], + yyNewState); }else{ fprintf(yyTraceFILE,"%s%s '%s', pending reduce %d\n", - yyTracePrompt, zTag, yyTokenName[yypParser->yytos->major], - yyNewState - YY_MIN_REDUCE); + yyTracePrompt, zTag, yyTokenName[yypParser->yytos->major], + yyNewState - YY_MIN_REDUCE); } } } @@ -4300,10 +3868,10 @@ static void yyTraceShift(yyParser *yypParser, int yyNewState, const char *zTag){ ** Perform a shift action. */ static void yy_shift( - yyParser *yypParser, /* The parser to be shifted */ - YYACTIONTYPE yyNewState, /* The new state to shift in */ - YYCODETYPE yyMajor, /* The major token to shift in */ - ParseTOKENTYPE yyMinor /* The minor token to shift in */ + yyParser *yypParser, /* The parser to be shifted */ + YYACTIONTYPE yyNewState, /* The new state to shift in */ + YYCODETYPE yyMajor, /* The major token to shift in */ + ParseTOKENTYPE yyMinor /* The minor token to shift in */ ){ yyStackEntry *yytos; yypParser->yytos++; @@ -4313,19 +3881,25 @@ static void yy_shift( assert( yypParser->yyhwm == (int)(yypParser->yytos - yypParser->yystack) ); } #endif - yytos = yypParser->yytos; - if( yytos>yypParser->yystackEnd ){ +#if YYSTACKDEPTH>0 + if( yypParser->yytos>yypParser->yystackEnd ){ + yypParser->yytos--; + yyStackOverflow(yypParser); + return; + } +#else + if( yypParser->yytos>=&yypParser->yystack[yypParser->yystksz] ){ if( yyGrowStack(yypParser) ){ yypParser->yytos--; yyStackOverflow(yypParser); return; } - yytos = yypParser->yytos; - assert( yytos <= yypParser->yystackEnd ); } +#endif if( yyNewState > YY_MAX_SHIFT ){ yyNewState += YY_MIN_REDUCE - YY_MIN_SHIFTREDUCE; } + yytos = yypParser->yytos; yytos->stateno = yyNewState; yytos->major = yyMajor; yytos->minor.yy0 = yyMinor; @@ -4335,1553 +3909,1557 @@ static void yy_shift( /* For rule J, yyRuleInfoLhs[J] contains the symbol on the left-hand side ** of that rule */ static const YYCODETYPE yyRuleInfoLhs[] = { - 383, /* (0) cmd ::= CREATE ACCOUNT NK_ID PASS NK_STRING account_options */ - 383, /* (1) cmd ::= ALTER ACCOUNT NK_ID alter_account_options */ - 384, /* (2) account_options ::= */ - 384, /* (3) account_options ::= account_options PPS literal */ - 384, /* (4) account_options ::= account_options TSERIES literal */ - 384, /* (5) account_options ::= account_options STORAGE literal */ - 384, /* (6) account_options ::= account_options STREAMS literal */ - 384, /* (7) account_options ::= account_options QTIME literal */ - 384, /* (8) account_options ::= account_options DBS literal */ - 384, /* (9) account_options ::= account_options USERS literal */ - 384, /* (10) account_options ::= account_options CONNS literal */ - 384, /* (11) account_options ::= account_options STATE literal */ - 385, /* (12) alter_account_options ::= alter_account_option */ - 385, /* (13) alter_account_options ::= alter_account_options alter_account_option */ - 387, /* (14) alter_account_option ::= PASS literal */ - 387, /* (15) alter_account_option ::= PPS literal */ - 387, /* (16) alter_account_option ::= TSERIES literal */ - 387, /* (17) alter_account_option ::= STORAGE literal */ - 387, /* (18) alter_account_option ::= STREAMS literal */ - 387, /* (19) alter_account_option ::= QTIME literal */ - 387, /* (20) alter_account_option ::= DBS literal */ - 387, /* (21) alter_account_option ::= USERS literal */ - 387, /* (22) alter_account_option ::= CONNS literal */ - 387, /* (23) alter_account_option ::= STATE literal */ - 388, /* (24) ip_range_list ::= NK_STRING */ - 388, /* (25) ip_range_list ::= ip_range_list NK_COMMA NK_STRING */ - 389, /* (26) white_list ::= HOST ip_range_list */ - 390, /* (27) white_list_opt ::= */ - 390, /* (28) white_list_opt ::= white_list */ - 391, /* (29) is_import_opt ::= */ - 391, /* (30) is_import_opt ::= IS_IMPORT NK_INTEGER */ - 392, /* (31) is_createdb_opt ::= */ - 392, /* (32) is_createdb_opt ::= CREATEDB NK_INTEGER */ - 383, /* (33) cmd ::= CREATE USER user_name PASS NK_STRING sysinfo_opt is_createdb_opt is_import_opt white_list_opt */ - 383, /* (34) cmd ::= ALTER USER user_name PASS NK_STRING */ - 383, /* (35) cmd ::= ALTER USER user_name ENABLE NK_INTEGER */ - 383, /* (36) cmd ::= ALTER USER user_name SYSINFO NK_INTEGER */ - 383, /* (37) cmd ::= ALTER USER user_name CREATEDB NK_INTEGER */ - 383, /* (38) cmd ::= ALTER USER user_name ADD white_list */ - 383, /* (39) cmd ::= ALTER USER user_name DROP white_list */ - 383, /* (40) cmd ::= DROP USER user_name */ - 394, /* (41) sysinfo_opt ::= */ - 394, /* (42) sysinfo_opt ::= SYSINFO NK_INTEGER */ - 383, /* (43) cmd ::= GRANT privileges ON priv_level with_opt TO user_name */ - 383, /* (44) cmd ::= REVOKE privileges ON priv_level with_opt FROM user_name */ - 395, /* (45) privileges ::= ALL */ - 395, /* (46) privileges ::= priv_type_list */ - 395, /* (47) privileges ::= SUBSCRIBE */ - 398, /* (48) priv_type_list ::= priv_type */ - 398, /* (49) priv_type_list ::= priv_type_list NK_COMMA priv_type */ - 399, /* (50) priv_type ::= READ */ - 399, /* (51) priv_type ::= WRITE */ - 399, /* (52) priv_type ::= ALTER */ - 396, /* (53) priv_level ::= NK_STAR NK_DOT NK_STAR */ - 396, /* (54) priv_level ::= db_name NK_DOT NK_STAR */ - 396, /* (55) priv_level ::= db_name NK_DOT table_name */ - 396, /* (56) priv_level ::= topic_name */ - 397, /* (57) with_opt ::= */ - 397, /* (58) with_opt ::= WITH search_condition */ - 383, /* (59) cmd ::= CREATE ENCRYPT_KEY NK_STRING */ - 383, /* (60) cmd ::= CREATE DNODE dnode_endpoint */ - 383, /* (61) cmd ::= CREATE DNODE dnode_endpoint PORT NK_INTEGER */ - 383, /* (62) cmd ::= DROP DNODE NK_INTEGER force_opt */ - 383, /* (63) cmd ::= DROP DNODE dnode_endpoint force_opt */ - 383, /* (64) cmd ::= DROP DNODE NK_INTEGER unsafe_opt */ - 383, /* (65) cmd ::= DROP DNODE dnode_endpoint unsafe_opt */ - 383, /* (66) cmd ::= ALTER DNODE NK_INTEGER NK_STRING */ - 383, /* (67) cmd ::= ALTER DNODE NK_INTEGER NK_STRING NK_STRING */ - 383, /* (68) cmd ::= ALTER ALL DNODES NK_STRING */ - 383, /* (69) cmd ::= ALTER ALL DNODES NK_STRING NK_STRING */ - 383, /* (70) cmd ::= RESTORE DNODE NK_INTEGER */ - 404, /* (71) dnode_endpoint ::= NK_STRING */ - 404, /* (72) dnode_endpoint ::= NK_ID */ - 404, /* (73) dnode_endpoint ::= NK_IPTOKEN */ - 405, /* (74) force_opt ::= */ - 405, /* (75) force_opt ::= FORCE */ - 406, /* (76) unsafe_opt ::= UNSAFE */ - 383, /* (77) cmd ::= ALTER CLUSTER NK_STRING */ - 383, /* (78) cmd ::= ALTER CLUSTER NK_STRING NK_STRING */ - 383, /* (79) cmd ::= ALTER LOCAL NK_STRING */ - 383, /* (80) cmd ::= ALTER LOCAL NK_STRING NK_STRING */ - 383, /* (81) cmd ::= CREATE QNODE ON DNODE NK_INTEGER */ - 383, /* (82) cmd ::= DROP QNODE ON DNODE NK_INTEGER */ - 383, /* (83) cmd ::= RESTORE QNODE ON DNODE NK_INTEGER */ - 383, /* (84) cmd ::= CREATE BNODE ON DNODE NK_INTEGER */ - 383, /* (85) cmd ::= DROP BNODE ON DNODE NK_INTEGER */ - 383, /* (86) cmd ::= CREATE SNODE ON DNODE NK_INTEGER */ - 383, /* (87) cmd ::= DROP SNODE ON DNODE NK_INTEGER */ - 383, /* (88) cmd ::= CREATE MNODE ON DNODE NK_INTEGER */ - 383, /* (89) cmd ::= DROP MNODE ON DNODE NK_INTEGER */ - 383, /* (90) cmd ::= RESTORE MNODE ON DNODE NK_INTEGER */ - 383, /* (91) cmd ::= RESTORE VNODE ON DNODE NK_INTEGER */ - 383, /* (92) cmd ::= CREATE DATABASE not_exists_opt db_name db_options */ - 383, /* (93) cmd ::= DROP DATABASE exists_opt db_name */ - 383, /* (94) cmd ::= USE db_name */ - 383, /* (95) cmd ::= ALTER DATABASE db_name alter_db_options */ - 383, /* (96) cmd ::= FLUSH DATABASE db_name */ - 383, /* (97) cmd ::= TRIM DATABASE db_name speed_opt */ - 383, /* (98) cmd ::= S3MIGRATE DATABASE db_name */ - 383, /* (99) cmd ::= COMPACT DATABASE db_name start_opt end_opt */ - 407, /* (100) not_exists_opt ::= IF NOT EXISTS */ - 407, /* (101) not_exists_opt ::= */ - 409, /* (102) exists_opt ::= IF EXISTS */ - 409, /* (103) exists_opt ::= */ - 408, /* (104) db_options ::= */ - 408, /* (105) db_options ::= db_options BUFFER NK_INTEGER */ - 408, /* (106) db_options ::= db_options CACHEMODEL NK_STRING */ - 408, /* (107) db_options ::= db_options CACHESIZE NK_INTEGER */ - 408, /* (108) db_options ::= db_options COMP NK_INTEGER */ - 408, /* (109) db_options ::= db_options DURATION NK_INTEGER */ - 408, /* (110) db_options ::= db_options DURATION NK_VARIABLE */ - 408, /* (111) db_options ::= db_options MAXROWS NK_INTEGER */ - 408, /* (112) db_options ::= db_options MINROWS NK_INTEGER */ - 408, /* (113) db_options ::= db_options KEEP integer_list */ - 408, /* (114) db_options ::= db_options KEEP variable_list */ - 408, /* (115) db_options ::= db_options PAGES NK_INTEGER */ - 408, /* (116) db_options ::= db_options PAGESIZE NK_INTEGER */ - 408, /* (117) db_options ::= db_options TSDB_PAGESIZE NK_INTEGER */ - 408, /* (118) db_options ::= db_options PRECISION NK_STRING */ - 408, /* (119) db_options ::= db_options REPLICA NK_INTEGER */ - 408, /* (120) db_options ::= db_options VGROUPS NK_INTEGER */ - 408, /* (121) db_options ::= db_options SINGLE_STABLE NK_INTEGER */ - 408, /* (122) db_options ::= db_options RETENTIONS retention_list */ - 408, /* (123) db_options ::= db_options SCHEMALESS NK_INTEGER */ - 408, /* (124) db_options ::= db_options WAL_LEVEL NK_INTEGER */ - 408, /* (125) db_options ::= db_options WAL_FSYNC_PERIOD NK_INTEGER */ - 408, /* (126) db_options ::= db_options WAL_RETENTION_PERIOD NK_INTEGER */ - 408, /* (127) db_options ::= db_options WAL_RETENTION_PERIOD NK_MINUS NK_INTEGER */ - 408, /* (128) db_options ::= db_options WAL_RETENTION_SIZE NK_INTEGER */ - 408, /* (129) db_options ::= db_options WAL_RETENTION_SIZE NK_MINUS NK_INTEGER */ - 408, /* (130) db_options ::= db_options WAL_ROLL_PERIOD NK_INTEGER */ - 408, /* (131) db_options ::= db_options WAL_SEGMENT_SIZE NK_INTEGER */ - 408, /* (132) db_options ::= db_options STT_TRIGGER NK_INTEGER */ - 408, /* (133) db_options ::= db_options TABLE_PREFIX signed */ - 408, /* (134) db_options ::= db_options TABLE_SUFFIX signed */ - 408, /* (135) db_options ::= db_options S3_CHUNKSIZE NK_INTEGER */ - 408, /* (136) db_options ::= db_options S3_KEEPLOCAL NK_INTEGER */ - 408, /* (137) db_options ::= db_options S3_KEEPLOCAL NK_VARIABLE */ - 408, /* (138) db_options ::= db_options S3_COMPACT NK_INTEGER */ - 408, /* (139) db_options ::= db_options KEEP_TIME_OFFSET NK_INTEGER */ - 408, /* (140) db_options ::= db_options ENCRYPT_ALGORITHM NK_STRING */ - 410, /* (141) alter_db_options ::= alter_db_option */ - 410, /* (142) alter_db_options ::= alter_db_options alter_db_option */ - 418, /* (143) alter_db_option ::= BUFFER NK_INTEGER */ - 418, /* (144) alter_db_option ::= CACHEMODEL NK_STRING */ - 418, /* (145) alter_db_option ::= CACHESIZE NK_INTEGER */ - 418, /* (146) alter_db_option ::= WAL_FSYNC_PERIOD NK_INTEGER */ - 418, /* (147) alter_db_option ::= KEEP integer_list */ - 418, /* (148) alter_db_option ::= KEEP variable_list */ - 418, /* (149) alter_db_option ::= PAGES NK_INTEGER */ - 418, /* (150) alter_db_option ::= REPLICA NK_INTEGER */ - 418, /* (151) alter_db_option ::= WAL_LEVEL NK_INTEGER */ - 418, /* (152) alter_db_option ::= STT_TRIGGER NK_INTEGER */ - 418, /* (153) alter_db_option ::= MINROWS NK_INTEGER */ - 418, /* (154) alter_db_option ::= WAL_RETENTION_PERIOD NK_INTEGER */ - 418, /* (155) alter_db_option ::= WAL_RETENTION_PERIOD NK_MINUS NK_INTEGER */ - 418, /* (156) alter_db_option ::= WAL_RETENTION_SIZE NK_INTEGER */ - 418, /* (157) alter_db_option ::= WAL_RETENTION_SIZE NK_MINUS NK_INTEGER */ - 418, /* (158) alter_db_option ::= S3_KEEPLOCAL NK_INTEGER */ - 418, /* (159) alter_db_option ::= S3_KEEPLOCAL NK_VARIABLE */ - 418, /* (160) alter_db_option ::= S3_COMPACT NK_INTEGER */ - 418, /* (161) alter_db_option ::= KEEP_TIME_OFFSET NK_INTEGER */ - 418, /* (162) alter_db_option ::= ENCRYPT_ALGORITHM NK_STRING */ - 414, /* (163) integer_list ::= NK_INTEGER */ - 414, /* (164) integer_list ::= integer_list NK_COMMA NK_INTEGER */ - 415, /* (165) variable_list ::= NK_VARIABLE */ - 415, /* (166) variable_list ::= variable_list NK_COMMA NK_VARIABLE */ - 416, /* (167) retention_list ::= retention */ - 416, /* (168) retention_list ::= retention_list NK_COMMA retention */ - 419, /* (169) retention ::= NK_VARIABLE NK_COLON NK_VARIABLE */ - 419, /* (170) retention ::= NK_MINUS NK_COLON NK_VARIABLE */ - 411, /* (171) speed_opt ::= */ - 411, /* (172) speed_opt ::= BWLIMIT NK_INTEGER */ - 412, /* (173) start_opt ::= */ - 412, /* (174) start_opt ::= START WITH NK_INTEGER */ - 412, /* (175) start_opt ::= START WITH NK_STRING */ - 412, /* (176) start_opt ::= START WITH TIMESTAMP NK_STRING */ - 413, /* (177) end_opt ::= */ - 413, /* (178) end_opt ::= END WITH NK_INTEGER */ - 413, /* (179) end_opt ::= END WITH NK_STRING */ - 413, /* (180) end_opt ::= END WITH TIMESTAMP NK_STRING */ - 383, /* (181) cmd ::= CREATE TABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def_opt table_options */ - 383, /* (182) cmd ::= CREATE TABLE multi_create_clause */ - 383, /* (183) cmd ::= CREATE TABLE not_exists_opt USING full_table_name NK_LP tag_list_opt NK_RP FILE NK_STRING */ - 383, /* (184) cmd ::= CREATE STABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def table_options */ - 383, /* (185) cmd ::= DROP TABLE multi_drop_clause */ - 383, /* (186) cmd ::= DROP STABLE exists_opt full_table_name */ - 383, /* (187) cmd ::= ALTER TABLE alter_table_clause */ - 383, /* (188) cmd ::= ALTER STABLE alter_table_clause */ - 428, /* (189) alter_table_clause ::= full_table_name alter_table_options */ - 428, /* (190) alter_table_clause ::= full_table_name ADD COLUMN column_name type_name column_options */ - 428, /* (191) alter_table_clause ::= full_table_name DROP COLUMN column_name */ - 428, /* (192) alter_table_clause ::= full_table_name MODIFY COLUMN column_name type_name */ - 428, /* (193) alter_table_clause ::= full_table_name MODIFY COLUMN column_name column_options */ - 428, /* (194) alter_table_clause ::= full_table_name RENAME COLUMN column_name column_name */ - 428, /* (195) alter_table_clause ::= full_table_name ADD TAG column_name type_name */ - 428, /* (196) alter_table_clause ::= full_table_name DROP TAG column_name */ - 428, /* (197) alter_table_clause ::= full_table_name MODIFY TAG column_name type_name */ - 428, /* (198) alter_table_clause ::= full_table_name RENAME TAG column_name column_name */ - 428, /* (199) alter_table_clause ::= full_table_name SET TAG column_name NK_EQ tags_literal */ - 424, /* (200) multi_create_clause ::= create_subtable_clause */ - 424, /* (201) multi_create_clause ::= multi_create_clause create_subtable_clause */ - 434, /* (202) create_subtable_clause ::= not_exists_opt full_table_name USING full_table_name specific_cols_opt TAGS NK_LP tags_literal_list NK_RP table_options */ - 427, /* (203) multi_drop_clause ::= drop_table_clause */ - 427, /* (204) multi_drop_clause ::= multi_drop_clause NK_COMMA drop_table_clause */ - 437, /* (205) drop_table_clause ::= exists_opt full_table_name */ - 435, /* (206) specific_cols_opt ::= */ - 435, /* (207) specific_cols_opt ::= NK_LP col_name_list NK_RP */ - 420, /* (208) full_table_name ::= table_name */ - 420, /* (209) full_table_name ::= db_name NK_DOT table_name */ - 439, /* (210) tag_def_list ::= tag_def */ - 439, /* (211) tag_def_list ::= tag_def_list NK_COMMA tag_def */ - 440, /* (212) tag_def ::= column_name type_name */ - 421, /* (213) column_def_list ::= column_def */ - 421, /* (214) column_def_list ::= column_def_list NK_COMMA column_def */ - 441, /* (215) column_def ::= column_name type_name column_options */ - 431, /* (216) type_name ::= BOOL */ - 431, /* (217) type_name ::= TINYINT */ - 431, /* (218) type_name ::= SMALLINT */ - 431, /* (219) type_name ::= INT */ - 431, /* (220) type_name ::= INTEGER */ - 431, /* (221) type_name ::= BIGINT */ - 431, /* (222) type_name ::= FLOAT */ - 431, /* (223) type_name ::= DOUBLE */ - 431, /* (224) type_name ::= BINARY NK_LP NK_INTEGER NK_RP */ - 431, /* (225) type_name ::= TIMESTAMP */ - 431, /* (226) type_name ::= NCHAR NK_LP NK_INTEGER NK_RP */ - 431, /* (227) type_name ::= TINYINT UNSIGNED */ - 431, /* (228) type_name ::= SMALLINT UNSIGNED */ - 431, /* (229) type_name ::= INT UNSIGNED */ - 431, /* (230) type_name ::= BIGINT UNSIGNED */ - 431, /* (231) type_name ::= JSON */ - 431, /* (232) type_name ::= VARCHAR NK_LP NK_INTEGER NK_RP */ - 431, /* (233) type_name ::= MEDIUMBLOB */ - 431, /* (234) type_name ::= BLOB */ - 431, /* (235) type_name ::= VARBINARY NK_LP NK_INTEGER NK_RP */ - 431, /* (236) type_name ::= GEOMETRY NK_LP NK_INTEGER NK_RP */ - 431, /* (237) type_name ::= DECIMAL */ - 431, /* (238) type_name ::= DECIMAL NK_LP NK_INTEGER NK_RP */ - 431, /* (239) type_name ::= DECIMAL NK_LP NK_INTEGER NK_COMMA NK_INTEGER NK_RP */ - 442, /* (240) type_name_default_len ::= BINARY */ - 442, /* (241) type_name_default_len ::= NCHAR */ - 442, /* (242) type_name_default_len ::= VARCHAR */ - 442, /* (243) type_name_default_len ::= VARBINARY */ - 422, /* (244) tags_def_opt ::= */ - 422, /* (245) tags_def_opt ::= tags_def */ - 426, /* (246) tags_def ::= TAGS NK_LP tag_def_list NK_RP */ - 423, /* (247) table_options ::= */ - 423, /* (248) table_options ::= table_options COMMENT NK_STRING */ - 423, /* (249) table_options ::= table_options MAX_DELAY duration_list */ - 423, /* (250) table_options ::= table_options WATERMARK duration_list */ - 423, /* (251) table_options ::= table_options ROLLUP NK_LP rollup_func_list NK_RP */ - 423, /* (252) table_options ::= table_options TTL NK_INTEGER */ - 423, /* (253) table_options ::= table_options SMA NK_LP col_name_list NK_RP */ - 423, /* (254) table_options ::= table_options DELETE_MARK duration_list */ - 429, /* (255) alter_table_options ::= alter_table_option */ - 429, /* (256) alter_table_options ::= alter_table_options alter_table_option */ - 445, /* (257) alter_table_option ::= COMMENT NK_STRING */ - 445, /* (258) alter_table_option ::= TTL NK_INTEGER */ - 443, /* (259) duration_list ::= duration_literal */ - 443, /* (260) duration_list ::= duration_list NK_COMMA duration_literal */ - 444, /* (261) rollup_func_list ::= rollup_func_name */ - 444, /* (262) rollup_func_list ::= rollup_func_list NK_COMMA rollup_func_name */ - 447, /* (263) rollup_func_name ::= function_name */ - 447, /* (264) rollup_func_name ::= FIRST */ - 447, /* (265) rollup_func_name ::= LAST */ - 438, /* (266) col_name_list ::= col_name */ - 438, /* (267) col_name_list ::= col_name_list NK_COMMA col_name */ - 449, /* (268) col_name ::= column_name */ - 383, /* (269) cmd ::= SHOW DNODES */ - 383, /* (270) cmd ::= SHOW USERS */ - 383, /* (271) cmd ::= SHOW USERS FULL */ - 383, /* (272) cmd ::= SHOW USER PRIVILEGES */ - 383, /* (273) cmd ::= SHOW db_kind_opt DATABASES */ - 383, /* (274) cmd ::= SHOW table_kind_db_name_cond_opt TABLES like_pattern_opt */ - 383, /* (275) cmd ::= SHOW db_name_cond_opt STABLES like_pattern_opt */ - 383, /* (276) cmd ::= SHOW db_name_cond_opt VGROUPS */ - 383, /* (277) cmd ::= SHOW MNODES */ - 383, /* (278) cmd ::= SHOW QNODES */ - 383, /* (279) cmd ::= SHOW ARBGROUPS */ - 383, /* (280) cmd ::= SHOW FUNCTIONS */ - 383, /* (281) cmd ::= SHOW INDEXES FROM table_name_cond from_db_opt */ - 383, /* (282) cmd ::= SHOW INDEXES FROM db_name NK_DOT table_name */ - 383, /* (283) cmd ::= SHOW STREAMS */ - 383, /* (284) cmd ::= SHOW ACCOUNTS */ - 383, /* (285) cmd ::= SHOW APPS */ - 383, /* (286) cmd ::= SHOW CONNECTIONS */ - 383, /* (287) cmd ::= SHOW LICENCES */ - 383, /* (288) cmd ::= SHOW GRANTS */ - 383, /* (289) cmd ::= SHOW GRANTS FULL */ - 383, /* (290) cmd ::= SHOW GRANTS LOGS */ - 383, /* (291) cmd ::= SHOW CLUSTER MACHINES */ - 383, /* (292) cmd ::= SHOW CREATE DATABASE db_name */ - 383, /* (293) cmd ::= SHOW CREATE TABLE full_table_name */ - 383, /* (294) cmd ::= SHOW CREATE STABLE full_table_name */ - 383, /* (295) cmd ::= SHOW ENCRYPTIONS */ - 383, /* (296) cmd ::= SHOW QUERIES */ - 383, /* (297) cmd ::= SHOW SCORES */ - 383, /* (298) cmd ::= SHOW TOPICS */ - 383, /* (299) cmd ::= SHOW VARIABLES */ - 383, /* (300) cmd ::= SHOW CLUSTER VARIABLES */ - 383, /* (301) cmd ::= SHOW LOCAL VARIABLES */ - 383, /* (302) cmd ::= SHOW DNODE NK_INTEGER VARIABLES like_pattern_opt */ - 383, /* (303) cmd ::= SHOW BNODES */ - 383, /* (304) cmd ::= SHOW SNODES */ - 383, /* (305) cmd ::= SHOW CLUSTER */ - 383, /* (306) cmd ::= SHOW TRANSACTIONS */ - 383, /* (307) cmd ::= SHOW TABLE DISTRIBUTED full_table_name */ - 383, /* (308) cmd ::= SHOW CONSUMERS */ - 383, /* (309) cmd ::= SHOW SUBSCRIPTIONS */ - 383, /* (310) cmd ::= SHOW TAGS FROM table_name_cond from_db_opt */ - 383, /* (311) cmd ::= SHOW TAGS FROM db_name NK_DOT table_name */ - 383, /* (312) cmd ::= SHOW TABLE TAGS tag_list_opt FROM table_name_cond from_db_opt */ - 383, /* (313) cmd ::= SHOW TABLE TAGS tag_list_opt FROM db_name NK_DOT table_name */ - 383, /* (314) cmd ::= SHOW VNODES ON DNODE NK_INTEGER */ - 383, /* (315) cmd ::= SHOW VNODES */ - 383, /* (316) cmd ::= SHOW db_name_cond_opt ALIVE */ - 383, /* (317) cmd ::= SHOW CLUSTER ALIVE */ - 383, /* (318) cmd ::= SHOW db_name_cond_opt VIEWS like_pattern_opt */ - 383, /* (319) cmd ::= SHOW CREATE VIEW full_table_name */ - 383, /* (320) cmd ::= SHOW COMPACTS */ - 383, /* (321) cmd ::= SHOW COMPACT NK_INTEGER */ - 451, /* (322) table_kind_db_name_cond_opt ::= */ - 451, /* (323) table_kind_db_name_cond_opt ::= table_kind */ - 451, /* (324) table_kind_db_name_cond_opt ::= db_name NK_DOT */ - 451, /* (325) table_kind_db_name_cond_opt ::= table_kind db_name NK_DOT */ - 456, /* (326) table_kind ::= NORMAL */ - 456, /* (327) table_kind ::= CHILD */ - 453, /* (328) db_name_cond_opt ::= */ - 453, /* (329) db_name_cond_opt ::= db_name NK_DOT */ - 452, /* (330) like_pattern_opt ::= */ - 452, /* (331) like_pattern_opt ::= LIKE NK_STRING */ - 454, /* (332) table_name_cond ::= table_name */ - 455, /* (333) from_db_opt ::= */ - 455, /* (334) from_db_opt ::= FROM db_name */ - 425, /* (335) tag_list_opt ::= */ - 425, /* (336) tag_list_opt ::= tag_item */ - 425, /* (337) tag_list_opt ::= tag_list_opt NK_COMMA tag_item */ - 457, /* (338) tag_item ::= TBNAME */ - 457, /* (339) tag_item ::= QTAGS */ - 457, /* (340) tag_item ::= column_name */ - 457, /* (341) tag_item ::= column_name column_alias */ - 457, /* (342) tag_item ::= column_name AS column_alias */ - 450, /* (343) db_kind_opt ::= */ - 450, /* (344) db_kind_opt ::= USER */ - 450, /* (345) db_kind_opt ::= SYSTEM */ - 383, /* (346) cmd ::= CREATE TSMA not_exists_opt tsma_name ON full_table_name tsma_func_list INTERVAL NK_LP duration_literal NK_RP */ - 383, /* (347) cmd ::= CREATE RECURSIVE TSMA not_exists_opt tsma_name ON full_table_name INTERVAL NK_LP duration_literal NK_RP */ - 383, /* (348) cmd ::= DROP TSMA exists_opt full_tsma_name */ - 383, /* (349) cmd ::= SHOW db_name_cond_opt TSMAS */ - 461, /* (350) full_tsma_name ::= tsma_name */ - 461, /* (351) full_tsma_name ::= db_name NK_DOT tsma_name */ - 460, /* (352) tsma_func_list ::= FUNCTION NK_LP func_list NK_RP */ - 383, /* (353) cmd ::= CREATE SMA INDEX not_exists_opt col_name ON full_table_name index_options */ - 383, /* (354) cmd ::= CREATE INDEX not_exists_opt col_name ON full_table_name NK_LP col_name_list NK_RP */ - 383, /* (355) cmd ::= DROP INDEX exists_opt full_index_name */ - 464, /* (356) full_index_name ::= index_name */ - 464, /* (357) full_index_name ::= db_name NK_DOT index_name */ - 463, /* (358) index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_RP sliding_opt sma_stream_opt */ - 463, /* (359) index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_COMMA duration_literal NK_RP sliding_opt sma_stream_opt */ - 462, /* (360) func_list ::= func */ - 462, /* (361) func_list ::= func_list NK_COMMA func */ - 468, /* (362) func ::= sma_func_name NK_LP expression_list NK_RP */ - 469, /* (363) sma_func_name ::= function_name */ - 469, /* (364) sma_func_name ::= COUNT */ - 469, /* (365) sma_func_name ::= FIRST */ - 469, /* (366) sma_func_name ::= LAST */ - 469, /* (367) sma_func_name ::= LAST_ROW */ - 467, /* (368) sma_stream_opt ::= */ - 467, /* (369) sma_stream_opt ::= sma_stream_opt WATERMARK duration_literal */ - 467, /* (370) sma_stream_opt ::= sma_stream_opt MAX_DELAY duration_literal */ - 467, /* (371) sma_stream_opt ::= sma_stream_opt DELETE_MARK duration_literal */ - 471, /* (372) with_meta ::= AS */ - 471, /* (373) with_meta ::= WITH META AS */ - 471, /* (374) with_meta ::= ONLY META AS */ - 383, /* (375) cmd ::= CREATE TOPIC not_exists_opt topic_name AS query_or_subquery */ - 383, /* (376) cmd ::= CREATE TOPIC not_exists_opt topic_name with_meta DATABASE db_name */ - 383, /* (377) cmd ::= CREATE TOPIC not_exists_opt topic_name with_meta STABLE full_table_name where_clause_opt */ - 383, /* (378) cmd ::= DROP TOPIC exists_opt topic_name */ - 383, /* (379) cmd ::= DROP CONSUMER GROUP exists_opt cgroup_name ON topic_name */ - 383, /* (380) cmd ::= DESC full_table_name */ - 383, /* (381) cmd ::= DESCRIBE full_table_name */ - 383, /* (382) cmd ::= RESET QUERY CACHE */ - 383, /* (383) cmd ::= EXPLAIN analyze_opt explain_options query_or_subquery */ - 383, /* (384) cmd ::= EXPLAIN analyze_opt explain_options insert_query */ - 475, /* (385) analyze_opt ::= */ - 475, /* (386) analyze_opt ::= ANALYZE */ - 476, /* (387) explain_options ::= */ - 476, /* (388) explain_options ::= explain_options VERBOSE NK_BOOL */ - 476, /* (389) explain_options ::= explain_options RATIO NK_FLOAT */ - 383, /* (390) cmd ::= CREATE or_replace_opt agg_func_opt FUNCTION not_exists_opt function_name AS NK_STRING OUTPUTTYPE type_name bufsize_opt language_opt */ - 383, /* (391) cmd ::= DROP FUNCTION exists_opt function_name */ - 479, /* (392) agg_func_opt ::= */ - 479, /* (393) agg_func_opt ::= AGGREGATE */ - 480, /* (394) bufsize_opt ::= */ - 480, /* (395) bufsize_opt ::= BUFSIZE NK_INTEGER */ - 481, /* (396) language_opt ::= */ - 481, /* (397) language_opt ::= LANGUAGE NK_STRING */ - 478, /* (398) or_replace_opt ::= */ - 478, /* (399) or_replace_opt ::= OR REPLACE */ - 383, /* (400) cmd ::= CREATE or_replace_opt VIEW full_view_name AS query_or_subquery */ - 383, /* (401) cmd ::= DROP VIEW exists_opt full_view_name */ - 482, /* (402) full_view_name ::= view_name */ - 482, /* (403) full_view_name ::= db_name NK_DOT view_name */ - 383, /* (404) cmd ::= CREATE STREAM not_exists_opt stream_name stream_options INTO full_table_name col_list_opt tag_def_or_ref_opt subtable_opt AS query_or_subquery */ - 383, /* (405) cmd ::= DROP STREAM exists_opt stream_name */ - 383, /* (406) cmd ::= PAUSE STREAM exists_opt stream_name */ - 383, /* (407) cmd ::= RESUME STREAM exists_opt ignore_opt stream_name */ - 486, /* (408) col_list_opt ::= */ - 486, /* (409) col_list_opt ::= NK_LP column_stream_def_list NK_RP */ - 490, /* (410) column_stream_def_list ::= column_stream_def */ - 490, /* (411) column_stream_def_list ::= column_stream_def_list NK_COMMA column_stream_def */ - 491, /* (412) column_stream_def ::= column_name stream_col_options */ - 492, /* (413) stream_col_options ::= */ - 492, /* (414) stream_col_options ::= stream_col_options PRIMARY KEY */ - 487, /* (415) tag_def_or_ref_opt ::= */ - 487, /* (416) tag_def_or_ref_opt ::= tags_def */ - 487, /* (417) tag_def_or_ref_opt ::= TAGS NK_LP column_stream_def_list NK_RP */ - 485, /* (418) stream_options ::= */ - 485, /* (419) stream_options ::= stream_options TRIGGER AT_ONCE */ - 485, /* (420) stream_options ::= stream_options TRIGGER WINDOW_CLOSE */ - 485, /* (421) stream_options ::= stream_options TRIGGER MAX_DELAY duration_literal */ - 485, /* (422) stream_options ::= stream_options WATERMARK duration_literal */ - 485, /* (423) stream_options ::= stream_options IGNORE EXPIRED NK_INTEGER */ - 485, /* (424) stream_options ::= stream_options FILL_HISTORY NK_INTEGER */ - 485, /* (425) stream_options ::= stream_options DELETE_MARK duration_literal */ - 485, /* (426) stream_options ::= stream_options IGNORE UPDATE NK_INTEGER */ - 488, /* (427) subtable_opt ::= */ - 488, /* (428) subtable_opt ::= SUBTABLE NK_LP expression NK_RP */ - 489, /* (429) ignore_opt ::= */ - 489, /* (430) ignore_opt ::= IGNORE UNTREATED */ - 383, /* (431) cmd ::= KILL CONNECTION NK_INTEGER */ - 383, /* (432) cmd ::= KILL QUERY NK_STRING */ - 383, /* (433) cmd ::= KILL TRANSACTION NK_INTEGER */ - 383, /* (434) cmd ::= KILL COMPACT NK_INTEGER */ - 383, /* (435) cmd ::= BALANCE VGROUP */ - 383, /* (436) cmd ::= BALANCE VGROUP LEADER on_vgroup_id */ - 383, /* (437) cmd ::= BALANCE VGROUP LEADER DATABASE db_name */ - 383, /* (438) cmd ::= MERGE VGROUP NK_INTEGER NK_INTEGER */ - 383, /* (439) cmd ::= REDISTRIBUTE VGROUP NK_INTEGER dnode_list */ - 383, /* (440) cmd ::= SPLIT VGROUP NK_INTEGER */ - 494, /* (441) on_vgroup_id ::= */ - 494, /* (442) on_vgroup_id ::= ON NK_INTEGER */ - 495, /* (443) dnode_list ::= DNODE NK_INTEGER */ - 495, /* (444) dnode_list ::= dnode_list DNODE NK_INTEGER */ - 383, /* (445) cmd ::= DELETE FROM full_table_name where_clause_opt */ - 383, /* (446) cmd ::= query_or_subquery */ - 383, /* (447) cmd ::= insert_query */ - 477, /* (448) insert_query ::= INSERT INTO full_table_name NK_LP col_name_list NK_RP query_or_subquery */ - 477, /* (449) insert_query ::= INSERT INTO full_table_name query_or_subquery */ - 433, /* (450) tags_literal ::= NK_INTEGER */ - 433, /* (451) tags_literal ::= NK_INTEGER NK_PLUS duration_literal */ - 433, /* (452) tags_literal ::= NK_INTEGER NK_MINUS duration_literal */ - 433, /* (453) tags_literal ::= NK_PLUS NK_INTEGER */ - 433, /* (454) tags_literal ::= NK_PLUS NK_INTEGER NK_PLUS duration_literal */ - 433, /* (455) tags_literal ::= NK_PLUS NK_INTEGER NK_MINUS duration_literal */ - 433, /* (456) tags_literal ::= NK_MINUS NK_INTEGER */ - 433, /* (457) tags_literal ::= NK_MINUS NK_INTEGER NK_PLUS duration_literal */ - 433, /* (458) tags_literal ::= NK_MINUS NK_INTEGER NK_MINUS duration_literal */ - 433, /* (459) tags_literal ::= NK_FLOAT */ - 433, /* (460) tags_literal ::= NK_PLUS NK_FLOAT */ - 433, /* (461) tags_literal ::= NK_MINUS NK_FLOAT */ - 433, /* (462) tags_literal ::= NK_BIN */ - 433, /* (463) tags_literal ::= NK_BIN NK_PLUS duration_literal */ - 433, /* (464) tags_literal ::= NK_BIN NK_MINUS duration_literal */ - 433, /* (465) tags_literal ::= NK_PLUS NK_BIN */ - 433, /* (466) tags_literal ::= NK_PLUS NK_BIN NK_PLUS duration_literal */ - 433, /* (467) tags_literal ::= NK_PLUS NK_BIN NK_MINUS duration_literal */ - 433, /* (468) tags_literal ::= NK_MINUS NK_BIN */ - 433, /* (469) tags_literal ::= NK_MINUS NK_BIN NK_PLUS duration_literal */ - 433, /* (470) tags_literal ::= NK_MINUS NK_BIN NK_MINUS duration_literal */ - 433, /* (471) tags_literal ::= NK_HEX */ - 433, /* (472) tags_literal ::= NK_HEX NK_PLUS duration_literal */ - 433, /* (473) tags_literal ::= NK_HEX NK_MINUS duration_literal */ - 433, /* (474) tags_literal ::= NK_PLUS NK_HEX */ - 433, /* (475) tags_literal ::= NK_PLUS NK_HEX NK_PLUS duration_literal */ - 433, /* (476) tags_literal ::= NK_PLUS NK_HEX NK_MINUS duration_literal */ - 433, /* (477) tags_literal ::= NK_MINUS NK_HEX */ - 433, /* (478) tags_literal ::= NK_MINUS NK_HEX NK_PLUS duration_literal */ - 433, /* (479) tags_literal ::= NK_MINUS NK_HEX NK_MINUS duration_literal */ - 433, /* (480) tags_literal ::= NK_STRING */ - 433, /* (481) tags_literal ::= NK_STRING NK_PLUS duration_literal */ - 433, /* (482) tags_literal ::= NK_STRING NK_MINUS duration_literal */ - 433, /* (483) tags_literal ::= NK_BOOL */ - 433, /* (484) tags_literal ::= NULL */ - 433, /* (485) tags_literal ::= literal_func */ - 433, /* (486) tags_literal ::= literal_func NK_PLUS duration_literal */ - 433, /* (487) tags_literal ::= literal_func NK_MINUS duration_literal */ - 436, /* (488) tags_literal_list ::= tags_literal */ - 436, /* (489) tags_literal_list ::= tags_literal_list NK_COMMA tags_literal */ - 386, /* (490) literal ::= NK_INTEGER */ - 386, /* (491) literal ::= NK_FLOAT */ - 386, /* (492) literal ::= NK_STRING */ - 386, /* (493) literal ::= NK_BOOL */ - 386, /* (494) literal ::= TIMESTAMP NK_STRING */ - 386, /* (495) literal ::= duration_literal */ - 386, /* (496) literal ::= NULL */ - 386, /* (497) literal ::= NK_QUESTION */ - 446, /* (498) duration_literal ::= NK_VARIABLE */ - 417, /* (499) signed ::= NK_INTEGER */ - 417, /* (500) signed ::= NK_PLUS NK_INTEGER */ - 417, /* (501) signed ::= NK_MINUS NK_INTEGER */ - 417, /* (502) signed ::= NK_FLOAT */ - 417, /* (503) signed ::= NK_PLUS NK_FLOAT */ - 417, /* (504) signed ::= NK_MINUS NK_FLOAT */ - 497, /* (505) signed_literal ::= signed */ - 497, /* (506) signed_literal ::= NK_STRING */ - 497, /* (507) signed_literal ::= NK_BOOL */ - 497, /* (508) signed_literal ::= TIMESTAMP NK_STRING */ - 497, /* (509) signed_literal ::= duration_literal */ - 497, /* (510) signed_literal ::= NULL */ - 497, /* (511) signed_literal ::= literal_func */ - 497, /* (512) signed_literal ::= NK_QUESTION */ - 498, /* (513) literal_list ::= signed_literal */ - 498, /* (514) literal_list ::= literal_list NK_COMMA signed_literal */ - 400, /* (515) db_name ::= NK_ID */ - 401, /* (516) table_name ::= NK_ID */ - 430, /* (517) column_name ::= NK_ID */ - 448, /* (518) function_name ::= NK_ID */ - 483, /* (519) view_name ::= NK_ID */ - 499, /* (520) table_alias ::= NK_ID */ - 458, /* (521) column_alias ::= NK_ID */ - 458, /* (522) column_alias ::= NK_ALIAS */ - 393, /* (523) user_name ::= NK_ID */ - 402, /* (524) topic_name ::= NK_ID */ - 484, /* (525) stream_name ::= NK_ID */ - 474, /* (526) cgroup_name ::= NK_ID */ - 465, /* (527) index_name ::= NK_ID */ - 459, /* (528) tsma_name ::= NK_ID */ - 500, /* (529) expr_or_subquery ::= expression */ - 493, /* (530) expression ::= literal */ - 493, /* (531) expression ::= pseudo_column */ - 493, /* (532) expression ::= column_reference */ - 493, /* (533) expression ::= function_expression */ - 493, /* (534) expression ::= case_when_expression */ - 493, /* (535) expression ::= NK_LP expression NK_RP */ - 493, /* (536) expression ::= NK_PLUS expr_or_subquery */ - 493, /* (537) expression ::= NK_MINUS expr_or_subquery */ - 493, /* (538) expression ::= expr_or_subquery NK_PLUS expr_or_subquery */ - 493, /* (539) expression ::= expr_or_subquery NK_MINUS expr_or_subquery */ - 493, /* (540) expression ::= expr_or_subquery NK_STAR expr_or_subquery */ - 493, /* (541) expression ::= expr_or_subquery NK_SLASH expr_or_subquery */ - 493, /* (542) expression ::= expr_or_subquery NK_REM expr_or_subquery */ - 493, /* (543) expression ::= column_reference NK_ARROW NK_STRING */ - 493, /* (544) expression ::= expr_or_subquery NK_BITAND expr_or_subquery */ - 493, /* (545) expression ::= expr_or_subquery NK_BITOR expr_or_subquery */ - 470, /* (546) expression_list ::= expr_or_subquery */ - 470, /* (547) expression_list ::= expression_list NK_COMMA expr_or_subquery */ - 502, /* (548) column_reference ::= column_name */ - 502, /* (549) column_reference ::= table_name NK_DOT column_name */ - 502, /* (550) column_reference ::= NK_ALIAS */ - 502, /* (551) column_reference ::= table_name NK_DOT NK_ALIAS */ - 501, /* (552) pseudo_column ::= ROWTS */ - 501, /* (553) pseudo_column ::= TBNAME */ - 501, /* (554) pseudo_column ::= table_name NK_DOT TBNAME */ - 501, /* (555) pseudo_column ::= QSTART */ - 501, /* (556) pseudo_column ::= QEND */ - 501, /* (557) pseudo_column ::= QDURATION */ - 501, /* (558) pseudo_column ::= WSTART */ - 501, /* (559) pseudo_column ::= WEND */ - 501, /* (560) pseudo_column ::= WDURATION */ - 501, /* (561) pseudo_column ::= IROWTS */ - 501, /* (562) pseudo_column ::= ISFILLED */ - 501, /* (563) pseudo_column ::= QTAGS */ - 503, /* (564) function_expression ::= function_name NK_LP expression_list NK_RP */ - 503, /* (565) function_expression ::= star_func NK_LP star_func_para_list NK_RP */ - 503, /* (566) function_expression ::= CAST NK_LP expr_or_subquery AS type_name NK_RP */ - 503, /* (567) function_expression ::= CAST NK_LP expr_or_subquery AS type_name_default_len NK_RP */ - 503, /* (568) function_expression ::= POSITION NK_LP expr_or_subquery IN expr_or_subquery NK_RP */ - 503, /* (569) function_expression ::= TRIM NK_LP expr_or_subquery NK_RP */ - 503, /* (570) function_expression ::= TRIM NK_LP trim_specification_type FROM expr_or_subquery NK_RP */ - 503, /* (571) function_expression ::= TRIM NK_LP expr_or_subquery FROM expr_or_subquery NK_RP */ - 503, /* (572) function_expression ::= TRIM NK_LP trim_specification_type expr_or_subquery FROM expr_or_subquery NK_RP */ - 503, /* (573) function_expression ::= substr_func NK_LP expression_list NK_RP */ - 503, /* (574) function_expression ::= substr_func NK_LP expr_or_subquery FROM expr_or_subquery NK_RP */ - 503, /* (575) function_expression ::= substr_func NK_LP expr_or_subquery FROM expr_or_subquery FOR expr_or_subquery NK_RP */ - 503, /* (576) function_expression ::= REPLACE NK_LP expression_list NK_RP */ - 503, /* (577) function_expression ::= literal_func */ - 503, /* (578) function_expression ::= rand_func */ - 496, /* (579) literal_func ::= noarg_func NK_LP NK_RP */ - 496, /* (580) literal_func ::= NOW */ - 496, /* (581) literal_func ::= TODAY */ - 509, /* (582) rand_func ::= RAND NK_LP NK_RP */ - 509, /* (583) rand_func ::= RAND NK_LP expression_list NK_RP */ - 508, /* (584) substr_func ::= SUBSTR */ - 508, /* (585) substr_func ::= SUBSTRING */ - 507, /* (586) trim_specification_type ::= BOTH */ - 507, /* (587) trim_specification_type ::= TRAILING */ - 507, /* (588) trim_specification_type ::= LEADING */ - 510, /* (589) noarg_func ::= NOW */ - 510, /* (590) noarg_func ::= TODAY */ - 510, /* (591) noarg_func ::= TIMEZONE */ - 510, /* (592) noarg_func ::= DATABASE */ - 510, /* (593) noarg_func ::= CLIENT_VERSION */ - 510, /* (594) noarg_func ::= SERVER_VERSION */ - 510, /* (595) noarg_func ::= SERVER_STATUS */ - 510, /* (596) noarg_func ::= CURRENT_USER */ - 510, /* (597) noarg_func ::= USER */ - 510, /* (598) noarg_func ::= PI */ - 505, /* (599) star_func ::= COUNT */ - 505, /* (600) star_func ::= FIRST */ - 505, /* (601) star_func ::= LAST */ - 505, /* (602) star_func ::= LAST_ROW */ - 506, /* (603) star_func_para_list ::= NK_STAR */ - 506, /* (604) star_func_para_list ::= other_para_list */ - 511, /* (605) other_para_list ::= star_func_para */ - 511, /* (606) other_para_list ::= other_para_list NK_COMMA star_func_para */ - 512, /* (607) star_func_para ::= expr_or_subquery */ - 512, /* (608) star_func_para ::= table_name NK_DOT NK_STAR */ - 504, /* (609) case_when_expression ::= CASE when_then_list case_when_else_opt END */ - 504, /* (610) case_when_expression ::= CASE common_expression when_then_list case_when_else_opt END */ - 513, /* (611) when_then_list ::= when_then_expr */ - 513, /* (612) when_then_list ::= when_then_list when_then_expr */ - 516, /* (613) when_then_expr ::= WHEN common_expression THEN common_expression */ - 514, /* (614) case_when_else_opt ::= */ - 514, /* (615) case_when_else_opt ::= ELSE common_expression */ - 517, /* (616) predicate ::= expr_or_subquery compare_op expr_or_subquery */ - 517, /* (617) predicate ::= expr_or_subquery BETWEEN expr_or_subquery AND expr_or_subquery */ - 517, /* (618) predicate ::= expr_or_subquery NOT BETWEEN expr_or_subquery AND expr_or_subquery */ - 517, /* (619) predicate ::= expr_or_subquery IS NULL */ - 517, /* (620) predicate ::= expr_or_subquery IS NOT NULL */ - 517, /* (621) predicate ::= expr_or_subquery in_op in_predicate_value */ - 518, /* (622) compare_op ::= NK_LT */ - 518, /* (623) compare_op ::= NK_GT */ - 518, /* (624) compare_op ::= NK_LE */ - 518, /* (625) compare_op ::= NK_GE */ - 518, /* (626) compare_op ::= NK_NE */ - 518, /* (627) compare_op ::= NK_EQ */ - 518, /* (628) compare_op ::= LIKE */ - 518, /* (629) compare_op ::= NOT LIKE */ - 518, /* (630) compare_op ::= MATCH */ - 518, /* (631) compare_op ::= NMATCH */ - 518, /* (632) compare_op ::= CONTAINS */ - 519, /* (633) in_op ::= IN */ - 519, /* (634) in_op ::= NOT IN */ - 520, /* (635) in_predicate_value ::= NK_LP literal_list NK_RP */ - 521, /* (636) boolean_value_expression ::= boolean_primary */ - 521, /* (637) boolean_value_expression ::= NOT boolean_primary */ - 521, /* (638) boolean_value_expression ::= boolean_value_expression OR boolean_value_expression */ - 521, /* (639) boolean_value_expression ::= boolean_value_expression AND boolean_value_expression */ - 522, /* (640) boolean_primary ::= predicate */ - 522, /* (641) boolean_primary ::= NK_LP boolean_value_expression NK_RP */ - 515, /* (642) common_expression ::= expr_or_subquery */ - 515, /* (643) common_expression ::= boolean_value_expression */ - 523, /* (644) from_clause_opt ::= */ - 523, /* (645) from_clause_opt ::= FROM table_reference_list */ - 524, /* (646) table_reference_list ::= table_reference */ - 524, /* (647) table_reference_list ::= table_reference_list NK_COMMA table_reference */ - 525, /* (648) table_reference ::= table_primary */ - 525, /* (649) table_reference ::= joined_table */ - 526, /* (650) table_primary ::= table_name alias_opt */ - 526, /* (651) table_primary ::= db_name NK_DOT table_name alias_opt */ - 526, /* (652) table_primary ::= subquery alias_opt */ - 526, /* (653) table_primary ::= parenthesized_joined_table */ - 528, /* (654) alias_opt ::= */ - 528, /* (655) alias_opt ::= table_alias */ - 528, /* (656) alias_opt ::= AS table_alias */ - 530, /* (657) parenthesized_joined_table ::= NK_LP joined_table NK_RP */ - 530, /* (658) parenthesized_joined_table ::= NK_LP parenthesized_joined_table NK_RP */ - 527, /* (659) joined_table ::= table_reference join_type join_subtype JOIN table_reference join_on_clause_opt window_offset_clause_opt jlimit_clause_opt */ - 531, /* (660) join_type ::= */ - 531, /* (661) join_type ::= INNER */ - 531, /* (662) join_type ::= LEFT */ - 531, /* (663) join_type ::= RIGHT */ - 531, /* (664) join_type ::= FULL */ - 532, /* (665) join_subtype ::= */ - 532, /* (666) join_subtype ::= OUTER */ - 532, /* (667) join_subtype ::= SEMI */ - 532, /* (668) join_subtype ::= ANTI */ - 532, /* (669) join_subtype ::= ASOF */ - 532, /* (670) join_subtype ::= WINDOW */ - 533, /* (671) join_on_clause_opt ::= */ - 533, /* (672) join_on_clause_opt ::= ON search_condition */ - 534, /* (673) window_offset_clause_opt ::= */ - 534, /* (674) window_offset_clause_opt ::= WINDOW_OFFSET NK_LP window_offset_literal NK_COMMA window_offset_literal NK_RP */ - 536, /* (675) window_offset_literal ::= NK_VARIABLE */ - 536, /* (676) window_offset_literal ::= NK_MINUS NK_VARIABLE */ - 535, /* (677) jlimit_clause_opt ::= */ - 535, /* (678) jlimit_clause_opt ::= JLIMIT NK_INTEGER */ - 537, /* (679) query_specification ::= SELECT hint_list set_quantifier_opt tag_mode_opt select_list from_clause_opt where_clause_opt partition_by_clause_opt range_opt every_opt fill_opt twindow_clause_opt group_by_clause_opt having_clause_opt */ - 538, /* (680) hint_list ::= */ - 538, /* (681) hint_list ::= NK_HINT */ - 540, /* (682) tag_mode_opt ::= */ - 540, /* (683) tag_mode_opt ::= TAGS */ - 539, /* (684) set_quantifier_opt ::= */ - 539, /* (685) set_quantifier_opt ::= DISTINCT */ - 539, /* (686) set_quantifier_opt ::= ALL */ - 541, /* (687) select_list ::= select_item */ - 541, /* (688) select_list ::= select_list NK_COMMA select_item */ - 549, /* (689) select_item ::= NK_STAR */ - 549, /* (690) select_item ::= common_expression */ - 549, /* (691) select_item ::= common_expression column_alias */ - 549, /* (692) select_item ::= common_expression AS column_alias */ - 549, /* (693) select_item ::= table_name NK_DOT NK_STAR */ - 473, /* (694) where_clause_opt ::= */ - 473, /* (695) where_clause_opt ::= WHERE search_condition */ - 542, /* (696) partition_by_clause_opt ::= */ - 542, /* (697) partition_by_clause_opt ::= PARTITION BY partition_list */ - 550, /* (698) partition_list ::= partition_item */ - 550, /* (699) partition_list ::= partition_list NK_COMMA partition_item */ - 551, /* (700) partition_item ::= expr_or_subquery */ - 551, /* (701) partition_item ::= expr_or_subquery column_alias */ - 551, /* (702) partition_item ::= expr_or_subquery AS column_alias */ - 546, /* (703) twindow_clause_opt ::= */ - 546, /* (704) twindow_clause_opt ::= SESSION NK_LP column_reference NK_COMMA interval_sliding_duration_literal NK_RP */ - 546, /* (705) twindow_clause_opt ::= STATE_WINDOW NK_LP expr_or_subquery NK_RP */ - 546, /* (706) twindow_clause_opt ::= INTERVAL NK_LP interval_sliding_duration_literal NK_RP sliding_opt fill_opt */ - 546, /* (707) twindow_clause_opt ::= INTERVAL NK_LP interval_sliding_duration_literal NK_COMMA interval_sliding_duration_literal NK_RP sliding_opt fill_opt */ - 546, /* (708) twindow_clause_opt ::= EVENT_WINDOW START WITH search_condition END WITH search_condition */ - 546, /* (709) twindow_clause_opt ::= COUNT_WINDOW NK_LP NK_INTEGER NK_RP */ - 546, /* (710) twindow_clause_opt ::= COUNT_WINDOW NK_LP NK_INTEGER NK_COMMA NK_INTEGER NK_RP */ - 466, /* (711) sliding_opt ::= */ - 466, /* (712) sliding_opt ::= SLIDING NK_LP interval_sliding_duration_literal NK_RP */ - 552, /* (713) interval_sliding_duration_literal ::= NK_VARIABLE */ - 552, /* (714) interval_sliding_duration_literal ::= NK_STRING */ - 552, /* (715) interval_sliding_duration_literal ::= NK_INTEGER */ - 545, /* (716) fill_opt ::= */ - 545, /* (717) fill_opt ::= FILL NK_LP fill_mode NK_RP */ - 545, /* (718) fill_opt ::= FILL NK_LP VALUE NK_COMMA expression_list NK_RP */ - 545, /* (719) fill_opt ::= FILL NK_LP VALUE_F NK_COMMA expression_list NK_RP */ - 553, /* (720) fill_mode ::= NONE */ - 553, /* (721) fill_mode ::= PREV */ - 553, /* (722) fill_mode ::= NULL */ - 553, /* (723) fill_mode ::= NULL_F */ - 553, /* (724) fill_mode ::= LINEAR */ - 553, /* (725) fill_mode ::= NEXT */ - 547, /* (726) group_by_clause_opt ::= */ - 547, /* (727) group_by_clause_opt ::= GROUP BY group_by_list */ - 554, /* (728) group_by_list ::= expr_or_subquery */ - 554, /* (729) group_by_list ::= group_by_list NK_COMMA expr_or_subquery */ - 548, /* (730) having_clause_opt ::= */ - 548, /* (731) having_clause_opt ::= HAVING search_condition */ - 543, /* (732) range_opt ::= */ - 543, /* (733) range_opt ::= RANGE NK_LP expr_or_subquery NK_COMMA expr_or_subquery NK_RP */ - 543, /* (734) range_opt ::= RANGE NK_LP expr_or_subquery NK_RP */ - 544, /* (735) every_opt ::= */ - 544, /* (736) every_opt ::= EVERY NK_LP duration_literal NK_RP */ - 555, /* (737) query_expression ::= query_simple order_by_clause_opt slimit_clause_opt limit_clause_opt */ - 556, /* (738) query_simple ::= query_specification */ - 556, /* (739) query_simple ::= union_query_expression */ - 560, /* (740) union_query_expression ::= query_simple_or_subquery UNION ALL query_simple_or_subquery */ - 560, /* (741) union_query_expression ::= query_simple_or_subquery UNION query_simple_or_subquery */ - 561, /* (742) query_simple_or_subquery ::= query_simple */ - 561, /* (743) query_simple_or_subquery ::= subquery */ - 472, /* (744) query_or_subquery ::= query_expression */ - 472, /* (745) query_or_subquery ::= subquery */ - 557, /* (746) order_by_clause_opt ::= */ - 557, /* (747) order_by_clause_opt ::= ORDER BY sort_specification_list */ - 558, /* (748) slimit_clause_opt ::= */ - 558, /* (749) slimit_clause_opt ::= SLIMIT NK_INTEGER */ - 558, /* (750) slimit_clause_opt ::= SLIMIT NK_INTEGER SOFFSET NK_INTEGER */ - 558, /* (751) slimit_clause_opt ::= SLIMIT NK_INTEGER NK_COMMA NK_INTEGER */ - 559, /* (752) limit_clause_opt ::= */ - 559, /* (753) limit_clause_opt ::= LIMIT NK_INTEGER */ - 559, /* (754) limit_clause_opt ::= LIMIT NK_INTEGER OFFSET NK_INTEGER */ - 559, /* (755) limit_clause_opt ::= LIMIT NK_INTEGER NK_COMMA NK_INTEGER */ - 529, /* (756) subquery ::= NK_LP query_expression NK_RP */ - 529, /* (757) subquery ::= NK_LP subquery NK_RP */ - 403, /* (758) search_condition ::= common_expression */ - 562, /* (759) sort_specification_list ::= sort_specification */ - 562, /* (760) sort_specification_list ::= sort_specification_list NK_COMMA sort_specification */ - 563, /* (761) sort_specification ::= expr_or_subquery ordering_specification_opt null_ordering_opt */ - 564, /* (762) ordering_specification_opt ::= */ - 564, /* (763) ordering_specification_opt ::= ASC */ - 564, /* (764) ordering_specification_opt ::= DESC */ - 565, /* (765) null_ordering_opt ::= */ - 565, /* (766) null_ordering_opt ::= NULLS FIRST */ - 565, /* (767) null_ordering_opt ::= NULLS LAST */ - 432, /* (768) column_options ::= */ - 432, /* (769) column_options ::= column_options PRIMARY KEY */ - 432, /* (770) column_options ::= column_options NK_ID NK_STRING */ + 383, /* (0) cmd ::= CREATE ACCOUNT NK_ID PASS NK_STRING account_options */ + 383, /* (1) cmd ::= ALTER ACCOUNT NK_ID alter_account_options */ + 384, /* (2) account_options ::= */ + 384, /* (3) account_options ::= account_options PPS literal */ + 384, /* (4) account_options ::= account_options TSERIES literal */ + 384, /* (5) account_options ::= account_options STORAGE literal */ + 384, /* (6) account_options ::= account_options STREAMS literal */ + 384, /* (7) account_options ::= account_options QTIME literal */ + 384, /* (8) account_options ::= account_options DBS literal */ + 384, /* (9) account_options ::= account_options USERS literal */ + 384, /* (10) account_options ::= account_options CONNS literal */ + 384, /* (11) account_options ::= account_options STATE literal */ + 385, /* (12) alter_account_options ::= alter_account_option */ + 385, /* (13) alter_account_options ::= alter_account_options alter_account_option */ + 387, /* (14) alter_account_option ::= PASS literal */ + 387, /* (15) alter_account_option ::= PPS literal */ + 387, /* (16) alter_account_option ::= TSERIES literal */ + 387, /* (17) alter_account_option ::= STORAGE literal */ + 387, /* (18) alter_account_option ::= STREAMS literal */ + 387, /* (19) alter_account_option ::= QTIME literal */ + 387, /* (20) alter_account_option ::= DBS literal */ + 387, /* (21) alter_account_option ::= USERS literal */ + 387, /* (22) alter_account_option ::= CONNS literal */ + 387, /* (23) alter_account_option ::= STATE literal */ + 388, /* (24) ip_range_list ::= NK_STRING */ + 388, /* (25) ip_range_list ::= ip_range_list NK_COMMA NK_STRING */ + 389, /* (26) white_list ::= HOST ip_range_list */ + 390, /* (27) white_list_opt ::= */ + 390, /* (28) white_list_opt ::= white_list */ + 391, /* (29) is_import_opt ::= */ + 391, /* (30) is_import_opt ::= IS_IMPORT NK_INTEGER */ + 392, /* (31) is_createdb_opt ::= */ + 392, /* (32) is_createdb_opt ::= CREATEDB NK_INTEGER */ + 383, /* (33) cmd ::= CREATE USER user_name PASS NK_STRING sysinfo_opt is_createdb_opt is_import_opt white_list_opt */ + 383, /* (34) cmd ::= ALTER USER user_name PASS NK_STRING */ + 383, /* (35) cmd ::= ALTER USER user_name ENABLE NK_INTEGER */ + 383, /* (36) cmd ::= ALTER USER user_name SYSINFO NK_INTEGER */ + 383, /* (37) cmd ::= ALTER USER user_name CREATEDB NK_INTEGER */ + 383, /* (38) cmd ::= ALTER USER user_name ADD white_list */ + 383, /* (39) cmd ::= ALTER USER user_name DROP white_list */ + 383, /* (40) cmd ::= DROP USER user_name */ + 394, /* (41) sysinfo_opt ::= */ + 394, /* (42) sysinfo_opt ::= SYSINFO NK_INTEGER */ + 383, /* (43) cmd ::= GRANT privileges ON priv_level with_clause_opt TO user_name */ + 383, /* (44) cmd ::= REVOKE privileges ON priv_level with_clause_opt FROM user_name */ + 395, /* (45) privileges ::= ALL */ + 395, /* (46) privileges ::= priv_type_list */ + 395, /* (47) privileges ::= SUBSCRIBE */ + 398, /* (48) priv_type_list ::= priv_type */ + 398, /* (49) priv_type_list ::= priv_type_list NK_COMMA priv_type */ + 399, /* (50) priv_type ::= READ */ + 399, /* (51) priv_type ::= WRITE */ + 399, /* (52) priv_type ::= ALTER */ + 396, /* (53) priv_level ::= NK_STAR NK_DOT NK_STAR */ + 396, /* (54) priv_level ::= db_name NK_DOT NK_STAR */ + 396, /* (55) priv_level ::= db_name NK_DOT table_name */ + 396, /* (56) priv_level ::= topic_name */ + 397, /* (57) with_clause_opt ::= */ + 397, /* (58) with_clause_opt ::= WITH search_condition */ + 383, /* (59) cmd ::= CREATE ENCRYPT_KEY NK_STRING */ + 383, /* (60) cmd ::= CREATE DNODE dnode_endpoint */ + 383, /* (61) cmd ::= CREATE DNODE dnode_endpoint PORT NK_INTEGER */ + 383, /* (62) cmd ::= DROP DNODE NK_INTEGER force_opt */ + 383, /* (63) cmd ::= DROP DNODE dnode_endpoint force_opt */ + 383, /* (64) cmd ::= DROP DNODE NK_INTEGER unsafe_opt */ + 383, /* (65) cmd ::= DROP DNODE dnode_endpoint unsafe_opt */ + 383, /* (66) cmd ::= ALTER DNODE NK_INTEGER NK_STRING */ + 383, /* (67) cmd ::= ALTER DNODE NK_INTEGER NK_STRING NK_STRING */ + 383, /* (68) cmd ::= ALTER ALL DNODES NK_STRING */ + 383, /* (69) cmd ::= ALTER ALL DNODES NK_STRING NK_STRING */ + 383, /* (70) cmd ::= RESTORE DNODE NK_INTEGER */ + 404, /* (71) dnode_endpoint ::= NK_STRING */ + 404, /* (72) dnode_endpoint ::= NK_ID */ + 404, /* (73) dnode_endpoint ::= NK_IPTOKEN */ + 405, /* (74) force_opt ::= */ + 405, /* (75) force_opt ::= FORCE */ + 406, /* (76) unsafe_opt ::= UNSAFE */ + 383, /* (77) cmd ::= ALTER CLUSTER NK_STRING */ + 383, /* (78) cmd ::= ALTER CLUSTER NK_STRING NK_STRING */ + 383, /* (79) cmd ::= ALTER LOCAL NK_STRING */ + 383, /* (80) cmd ::= ALTER LOCAL NK_STRING NK_STRING */ + 383, /* (81) cmd ::= CREATE QNODE ON DNODE NK_INTEGER */ + 383, /* (82) cmd ::= DROP QNODE ON DNODE NK_INTEGER */ + 383, /* (83) cmd ::= RESTORE QNODE ON DNODE NK_INTEGER */ + 383, /* (84) cmd ::= CREATE BNODE ON DNODE NK_INTEGER */ + 383, /* (85) cmd ::= DROP BNODE ON DNODE NK_INTEGER */ + 383, /* (86) cmd ::= CREATE SNODE ON DNODE NK_INTEGER */ + 383, /* (87) cmd ::= DROP SNODE ON DNODE NK_INTEGER */ + 383, /* (88) cmd ::= CREATE MNODE ON DNODE NK_INTEGER */ + 383, /* (89) cmd ::= DROP MNODE ON DNODE NK_INTEGER */ + 383, /* (90) cmd ::= RESTORE MNODE ON DNODE NK_INTEGER */ + 383, /* (91) cmd ::= RESTORE VNODE ON DNODE NK_INTEGER */ + 383, /* (92) cmd ::= CREATE DATABASE not_exists_opt db_name db_options */ + 383, /* (93) cmd ::= DROP DATABASE exists_opt db_name */ + 383, /* (94) cmd ::= USE db_name */ + 383, /* (95) cmd ::= ALTER DATABASE db_name alter_db_options */ + 383, /* (96) cmd ::= FLUSH DATABASE db_name */ + 383, /* (97) cmd ::= TRIM DATABASE db_name speed_opt */ + 383, /* (98) cmd ::= S3MIGRATE DATABASE db_name */ + 383, /* (99) cmd ::= COMPACT DATABASE db_name start_opt end_opt */ + 407, /* (100) not_exists_opt ::= IF NOT EXISTS */ + 407, /* (101) not_exists_opt ::= */ + 409, /* (102) exists_opt ::= IF EXISTS */ + 409, /* (103) exists_opt ::= */ + 408, /* (104) db_options ::= */ + 408, /* (105) db_options ::= db_options BUFFER NK_INTEGER */ + 408, /* (106) db_options ::= db_options CACHEMODEL NK_STRING */ + 408, /* (107) db_options ::= db_options CACHESIZE NK_INTEGER */ + 408, /* (108) db_options ::= db_options COMP NK_INTEGER */ + 408, /* (109) db_options ::= db_options DURATION NK_INTEGER */ + 408, /* (110) db_options ::= db_options DURATION NK_VARIABLE */ + 408, /* (111) db_options ::= db_options MAXROWS NK_INTEGER */ + 408, /* (112) db_options ::= db_options MINROWS NK_INTEGER */ + 408, /* (113) db_options ::= db_options KEEP integer_list */ + 408, /* (114) db_options ::= db_options KEEP variable_list */ + 408, /* (115) db_options ::= db_options PAGES NK_INTEGER */ + 408, /* (116) db_options ::= db_options PAGESIZE NK_INTEGER */ + 408, /* (117) db_options ::= db_options TSDB_PAGESIZE NK_INTEGER */ + 408, /* (118) db_options ::= db_options PRECISION NK_STRING */ + 408, /* (119) db_options ::= db_options REPLICA NK_INTEGER */ + 408, /* (120) db_options ::= db_options VGROUPS NK_INTEGER */ + 408, /* (121) db_options ::= db_options SINGLE_STABLE NK_INTEGER */ + 408, /* (122) db_options ::= db_options RETENTIONS retention_list */ + 408, /* (123) db_options ::= db_options SCHEMALESS NK_INTEGER */ + 408, /* (124) db_options ::= db_options WAL_LEVEL NK_INTEGER */ + 408, /* (125) db_options ::= db_options WAL_FSYNC_PERIOD NK_INTEGER */ + 408, /* (126) db_options ::= db_options WAL_RETENTION_PERIOD NK_INTEGER */ + 408, /* (127) db_options ::= db_options WAL_RETENTION_PERIOD NK_MINUS NK_INTEGER */ + 408, /* (128) db_options ::= db_options WAL_RETENTION_SIZE NK_INTEGER */ + 408, /* (129) db_options ::= db_options WAL_RETENTION_SIZE NK_MINUS NK_INTEGER */ + 408, /* (130) db_options ::= db_options WAL_ROLL_PERIOD NK_INTEGER */ + 408, /* (131) db_options ::= db_options WAL_SEGMENT_SIZE NK_INTEGER */ + 408, /* (132) db_options ::= db_options STT_TRIGGER NK_INTEGER */ + 408, /* (133) db_options ::= db_options TABLE_PREFIX signed */ + 408, /* (134) db_options ::= db_options TABLE_SUFFIX signed */ + 408, /* (135) db_options ::= db_options S3_CHUNKSIZE NK_INTEGER */ + 408, /* (136) db_options ::= db_options S3_KEEPLOCAL NK_INTEGER */ + 408, /* (137) db_options ::= db_options S3_KEEPLOCAL NK_VARIABLE */ + 408, /* (138) db_options ::= db_options S3_COMPACT NK_INTEGER */ + 408, /* (139) db_options ::= db_options KEEP_TIME_OFFSET NK_INTEGER */ + 408, /* (140) db_options ::= db_options ENCRYPT_ALGORITHM NK_STRING */ + 410, /* (141) alter_db_options ::= alter_db_option */ + 410, /* (142) alter_db_options ::= alter_db_options alter_db_option */ + 418, /* (143) alter_db_option ::= BUFFER NK_INTEGER */ + 418, /* (144) alter_db_option ::= CACHEMODEL NK_STRING */ + 418, /* (145) alter_db_option ::= CACHESIZE NK_INTEGER */ + 418, /* (146) alter_db_option ::= WAL_FSYNC_PERIOD NK_INTEGER */ + 418, /* (147) alter_db_option ::= KEEP integer_list */ + 418, /* (148) alter_db_option ::= KEEP variable_list */ + 418, /* (149) alter_db_option ::= PAGES NK_INTEGER */ + 418, /* (150) alter_db_option ::= REPLICA NK_INTEGER */ + 418, /* (151) alter_db_option ::= WAL_LEVEL NK_INTEGER */ + 418, /* (152) alter_db_option ::= STT_TRIGGER NK_INTEGER */ + 418, /* (153) alter_db_option ::= MINROWS NK_INTEGER */ + 418, /* (154) alter_db_option ::= WAL_RETENTION_PERIOD NK_INTEGER */ + 418, /* (155) alter_db_option ::= WAL_RETENTION_PERIOD NK_MINUS NK_INTEGER */ + 418, /* (156) alter_db_option ::= WAL_RETENTION_SIZE NK_INTEGER */ + 418, /* (157) alter_db_option ::= WAL_RETENTION_SIZE NK_MINUS NK_INTEGER */ + 418, /* (158) alter_db_option ::= S3_KEEPLOCAL NK_INTEGER */ + 418, /* (159) alter_db_option ::= S3_KEEPLOCAL NK_VARIABLE */ + 418, /* (160) alter_db_option ::= S3_COMPACT NK_INTEGER */ + 418, /* (161) alter_db_option ::= KEEP_TIME_OFFSET NK_INTEGER */ + 418, /* (162) alter_db_option ::= ENCRYPT_ALGORITHM NK_STRING */ + 414, /* (163) integer_list ::= NK_INTEGER */ + 414, /* (164) integer_list ::= integer_list NK_COMMA NK_INTEGER */ + 415, /* (165) variable_list ::= NK_VARIABLE */ + 415, /* (166) variable_list ::= variable_list NK_COMMA NK_VARIABLE */ + 416, /* (167) retention_list ::= retention */ + 416, /* (168) retention_list ::= retention_list NK_COMMA retention */ + 419, /* (169) retention ::= NK_VARIABLE NK_COLON NK_VARIABLE */ + 419, /* (170) retention ::= NK_MINUS NK_COLON NK_VARIABLE */ + 411, /* (171) speed_opt ::= */ + 411, /* (172) speed_opt ::= BWLIMIT NK_INTEGER */ + 412, /* (173) start_opt ::= */ + 412, /* (174) start_opt ::= START WITH NK_INTEGER */ + 412, /* (175) start_opt ::= START WITH NK_STRING */ + 412, /* (176) start_opt ::= START WITH TIMESTAMP NK_STRING */ + 413, /* (177) end_opt ::= */ + 413, /* (178) end_opt ::= END WITH NK_INTEGER */ + 413, /* (179) end_opt ::= END WITH NK_STRING */ + 413, /* (180) end_opt ::= END WITH TIMESTAMP NK_STRING */ + 383, /* (181) cmd ::= CREATE TABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def_opt table_options */ + 383, /* (182) cmd ::= CREATE TABLE multi_create_clause */ + 383, /* (183) cmd ::= CREATE TABLE not_exists_opt USING full_table_name NK_LP tag_list_opt NK_RP FILE NK_STRING */ + 383, /* (184) cmd ::= CREATE STABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def table_options */ + 383, /* (185) cmd ::= DROP TABLE with_opt multi_drop_clause */ + 383, /* (186) cmd ::= DROP STABLE with_opt exists_opt full_table_name */ + 383, /* (187) cmd ::= ALTER TABLE alter_table_clause */ + 383, /* (188) cmd ::= ALTER STABLE alter_table_clause */ + 429, /* (189) alter_table_clause ::= full_table_name alter_table_options */ + 429, /* (190) alter_table_clause ::= full_table_name ADD COLUMN column_name type_name column_options */ + 429, /* (191) alter_table_clause ::= full_table_name DROP COLUMN column_name */ + 429, /* (192) alter_table_clause ::= full_table_name MODIFY COLUMN column_name type_name */ + 429, /* (193) alter_table_clause ::= full_table_name MODIFY COLUMN column_name column_options */ + 429, /* (194) alter_table_clause ::= full_table_name RENAME COLUMN column_name column_name */ + 429, /* (195) alter_table_clause ::= full_table_name ADD TAG column_name type_name */ + 429, /* (196) alter_table_clause ::= full_table_name DROP TAG column_name */ + 429, /* (197) alter_table_clause ::= full_table_name MODIFY TAG column_name type_name */ + 429, /* (198) alter_table_clause ::= full_table_name RENAME TAG column_name column_name */ + 429, /* (199) alter_table_clause ::= full_table_name SET TAG column_name NK_EQ tags_literal */ + 424, /* (200) multi_create_clause ::= create_subtable_clause */ + 424, /* (201) multi_create_clause ::= multi_create_clause create_subtable_clause */ + 435, /* (202) create_subtable_clause ::= not_exists_opt full_table_name USING full_table_name specific_cols_opt TAGS NK_LP tags_literal_list NK_RP table_options */ + 428, /* (203) multi_drop_clause ::= drop_table_clause */ + 428, /* (204) multi_drop_clause ::= multi_drop_clause NK_COMMA drop_table_clause */ + 438, /* (205) drop_table_clause ::= exists_opt full_table_name */ + 427, /* (206) with_opt ::= */ + 427, /* (207) with_opt ::= WITH */ + 436, /* (208) specific_cols_opt ::= */ + 436, /* (209) specific_cols_opt ::= NK_LP col_name_list NK_RP */ + 420, /* (210) full_table_name ::= table_name */ + 420, /* (211) full_table_name ::= db_name NK_DOT table_name */ + 440, /* (212) tag_def_list ::= tag_def */ + 440, /* (213) tag_def_list ::= tag_def_list NK_COMMA tag_def */ + 441, /* (214) tag_def ::= column_name type_name */ + 421, /* (215) column_def_list ::= column_def */ + 421, /* (216) column_def_list ::= column_def_list NK_COMMA column_def */ + 442, /* (217) column_def ::= column_name type_name column_options */ + 432, /* (218) type_name ::= BOOL */ + 432, /* (219) type_name ::= TINYINT */ + 432, /* (220) type_name ::= SMALLINT */ + 432, /* (221) type_name ::= INT */ + 432, /* (222) type_name ::= INTEGER */ + 432, /* (223) type_name ::= BIGINT */ + 432, /* (224) type_name ::= FLOAT */ + 432, /* (225) type_name ::= DOUBLE */ + 432, /* (226) type_name ::= BINARY NK_LP NK_INTEGER NK_RP */ + 432, /* (227) type_name ::= TIMESTAMP */ + 432, /* (228) type_name ::= NCHAR NK_LP NK_INTEGER NK_RP */ + 432, /* (229) type_name ::= TINYINT UNSIGNED */ + 432, /* (230) type_name ::= SMALLINT UNSIGNED */ + 432, /* (231) type_name ::= INT UNSIGNED */ + 432, /* (232) type_name ::= BIGINT UNSIGNED */ + 432, /* (233) type_name ::= JSON */ + 432, /* (234) type_name ::= VARCHAR NK_LP NK_INTEGER NK_RP */ + 432, /* (235) type_name ::= MEDIUMBLOB */ + 432, /* (236) type_name ::= BLOB */ + 432, /* (237) type_name ::= VARBINARY NK_LP NK_INTEGER NK_RP */ + 432, /* (238) type_name ::= GEOMETRY NK_LP NK_INTEGER NK_RP */ + 432, /* (239) type_name ::= DECIMAL */ + 432, /* (240) type_name ::= DECIMAL NK_LP NK_INTEGER NK_RP */ + 432, /* (241) type_name ::= DECIMAL NK_LP NK_INTEGER NK_COMMA NK_INTEGER NK_RP */ + 443, /* (242) type_name_default_len ::= BINARY */ + 443, /* (243) type_name_default_len ::= NCHAR */ + 443, /* (244) type_name_default_len ::= VARCHAR */ + 443, /* (245) type_name_default_len ::= VARBINARY */ + 422, /* (246) tags_def_opt ::= */ + 422, /* (247) tags_def_opt ::= tags_def */ + 426, /* (248) tags_def ::= TAGS NK_LP tag_def_list NK_RP */ + 423, /* (249) table_options ::= */ + 423, /* (250) table_options ::= table_options COMMENT NK_STRING */ + 423, /* (251) table_options ::= table_options MAX_DELAY duration_list */ + 423, /* (252) table_options ::= table_options WATERMARK duration_list */ + 423, /* (253) table_options ::= table_options ROLLUP NK_LP rollup_func_list NK_RP */ + 423, /* (254) table_options ::= table_options TTL NK_INTEGER */ + 423, /* (255) table_options ::= table_options SMA NK_LP col_name_list NK_RP */ + 423, /* (256) table_options ::= table_options DELETE_MARK duration_list */ + 430, /* (257) alter_table_options ::= alter_table_option */ + 430, /* (258) alter_table_options ::= alter_table_options alter_table_option */ + 446, /* (259) alter_table_option ::= COMMENT NK_STRING */ + 446, /* (260) alter_table_option ::= TTL NK_INTEGER */ + 444, /* (261) duration_list ::= duration_literal */ + 444, /* (262) duration_list ::= duration_list NK_COMMA duration_literal */ + 445, /* (263) rollup_func_list ::= rollup_func_name */ + 445, /* (264) rollup_func_list ::= rollup_func_list NK_COMMA rollup_func_name */ + 448, /* (265) rollup_func_name ::= function_name */ + 448, /* (266) rollup_func_name ::= FIRST */ + 448, /* (267) rollup_func_name ::= LAST */ + 439, /* (268) col_name_list ::= col_name */ + 439, /* (269) col_name_list ::= col_name_list NK_COMMA col_name */ + 450, /* (270) col_name ::= column_name */ + 383, /* (271) cmd ::= SHOW DNODES */ + 383, /* (272) cmd ::= SHOW USERS */ + 383, /* (273) cmd ::= SHOW USERS FULL */ + 383, /* (274) cmd ::= SHOW USER PRIVILEGES */ + 383, /* (275) cmd ::= SHOW db_kind_opt DATABASES */ + 383, /* (276) cmd ::= SHOW table_kind_db_name_cond_opt TABLES like_pattern_opt */ + 383, /* (277) cmd ::= SHOW db_name_cond_opt STABLES like_pattern_opt */ + 383, /* (278) cmd ::= SHOW db_name_cond_opt VGROUPS */ + 383, /* (279) cmd ::= SHOW MNODES */ + 383, /* (280) cmd ::= SHOW QNODES */ + 383, /* (281) cmd ::= SHOW ARBGROUPS */ + 383, /* (282) cmd ::= SHOW FUNCTIONS */ + 383, /* (283) cmd ::= SHOW INDEXES FROM table_name_cond from_db_opt */ + 383, /* (284) cmd ::= SHOW INDEXES FROM db_name NK_DOT table_name */ + 383, /* (285) cmd ::= SHOW STREAMS */ + 383, /* (286) cmd ::= SHOW ACCOUNTS */ + 383, /* (287) cmd ::= SHOW APPS */ + 383, /* (288) cmd ::= SHOW CONNECTIONS */ + 383, /* (289) cmd ::= SHOW LICENCES */ + 383, /* (290) cmd ::= SHOW GRANTS */ + 383, /* (291) cmd ::= SHOW GRANTS FULL */ + 383, /* (292) cmd ::= SHOW GRANTS LOGS */ + 383, /* (293) cmd ::= SHOW CLUSTER MACHINES */ + 383, /* (294) cmd ::= SHOW CREATE DATABASE db_name */ + 383, /* (295) cmd ::= SHOW CREATE TABLE full_table_name */ + 383, /* (296) cmd ::= SHOW CREATE STABLE full_table_name */ + 383, /* (297) cmd ::= SHOW ENCRYPTIONS */ + 383, /* (298) cmd ::= SHOW QUERIES */ + 383, /* (299) cmd ::= SHOW SCORES */ + 383, /* (300) cmd ::= SHOW TOPICS */ + 383, /* (301) cmd ::= SHOW VARIABLES */ + 383, /* (302) cmd ::= SHOW CLUSTER VARIABLES */ + 383, /* (303) cmd ::= SHOW LOCAL VARIABLES */ + 383, /* (304) cmd ::= SHOW DNODE NK_INTEGER VARIABLES like_pattern_opt */ + 383, /* (305) cmd ::= SHOW BNODES */ + 383, /* (306) cmd ::= SHOW SNODES */ + 383, /* (307) cmd ::= SHOW CLUSTER */ + 383, /* (308) cmd ::= SHOW TRANSACTIONS */ + 383, /* (309) cmd ::= SHOW TABLE DISTRIBUTED full_table_name */ + 383, /* (310) cmd ::= SHOW CONSUMERS */ + 383, /* (311) cmd ::= SHOW SUBSCRIPTIONS */ + 383, /* (312) cmd ::= SHOW TAGS FROM table_name_cond from_db_opt */ + 383, /* (313) cmd ::= SHOW TAGS FROM db_name NK_DOT table_name */ + 383, /* (314) cmd ::= SHOW TABLE TAGS tag_list_opt FROM table_name_cond from_db_opt */ + 383, /* (315) cmd ::= SHOW TABLE TAGS tag_list_opt FROM db_name NK_DOT table_name */ + 383, /* (316) cmd ::= SHOW VNODES ON DNODE NK_INTEGER */ + 383, /* (317) cmd ::= SHOW VNODES */ + 383, /* (318) cmd ::= SHOW db_name_cond_opt ALIVE */ + 383, /* (319) cmd ::= SHOW CLUSTER ALIVE */ + 383, /* (320) cmd ::= SHOW db_name_cond_opt VIEWS like_pattern_opt */ + 383, /* (321) cmd ::= SHOW CREATE VIEW full_table_name */ + 383, /* (322) cmd ::= SHOW COMPACTS */ + 383, /* (323) cmd ::= SHOW COMPACT NK_INTEGER */ + 452, /* (324) table_kind_db_name_cond_opt ::= */ + 452, /* (325) table_kind_db_name_cond_opt ::= table_kind */ + 452, /* (326) table_kind_db_name_cond_opt ::= db_name NK_DOT */ + 452, /* (327) table_kind_db_name_cond_opt ::= table_kind db_name NK_DOT */ + 457, /* (328) table_kind ::= NORMAL */ + 457, /* (329) table_kind ::= CHILD */ + 454, /* (330) db_name_cond_opt ::= */ + 454, /* (331) db_name_cond_opt ::= db_name NK_DOT */ + 453, /* (332) like_pattern_opt ::= */ + 453, /* (333) like_pattern_opt ::= LIKE NK_STRING */ + 455, /* (334) table_name_cond ::= table_name */ + 456, /* (335) from_db_opt ::= */ + 456, /* (336) from_db_opt ::= FROM db_name */ + 425, /* (337) tag_list_opt ::= */ + 425, /* (338) tag_list_opt ::= tag_item */ + 425, /* (339) tag_list_opt ::= tag_list_opt NK_COMMA tag_item */ + 458, /* (340) tag_item ::= TBNAME */ + 458, /* (341) tag_item ::= QTAGS */ + 458, /* (342) tag_item ::= column_name */ + 458, /* (343) tag_item ::= column_name column_alias */ + 458, /* (344) tag_item ::= column_name AS column_alias */ + 451, /* (345) db_kind_opt ::= */ + 451, /* (346) db_kind_opt ::= USER */ + 451, /* (347) db_kind_opt ::= SYSTEM */ + 383, /* (348) cmd ::= CREATE TSMA not_exists_opt tsma_name ON full_table_name tsma_func_list INTERVAL NK_LP duration_literal NK_RP */ + 383, /* (349) cmd ::= CREATE RECURSIVE TSMA not_exists_opt tsma_name ON full_table_name INTERVAL NK_LP duration_literal NK_RP */ + 383, /* (350) cmd ::= DROP TSMA exists_opt full_tsma_name */ + 383, /* (351) cmd ::= SHOW db_name_cond_opt TSMAS */ + 462, /* (352) full_tsma_name ::= tsma_name */ + 462, /* (353) full_tsma_name ::= db_name NK_DOT tsma_name */ + 461, /* (354) tsma_func_list ::= FUNCTION NK_LP func_list NK_RP */ + 383, /* (355) cmd ::= CREATE SMA INDEX not_exists_opt col_name ON full_table_name index_options */ + 383, /* (356) cmd ::= CREATE INDEX not_exists_opt col_name ON full_table_name NK_LP col_name_list NK_RP */ + 383, /* (357) cmd ::= DROP INDEX exists_opt full_index_name */ + 465, /* (358) full_index_name ::= index_name */ + 465, /* (359) full_index_name ::= db_name NK_DOT index_name */ + 464, /* (360) index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_RP sliding_opt sma_stream_opt */ + 464, /* (361) index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_COMMA duration_literal NK_RP sliding_opt sma_stream_opt */ + 463, /* (362) func_list ::= func */ + 463, /* (363) func_list ::= func_list NK_COMMA func */ + 469, /* (364) func ::= sma_func_name NK_LP expression_list NK_RP */ + 470, /* (365) sma_func_name ::= function_name */ + 470, /* (366) sma_func_name ::= COUNT */ + 470, /* (367) sma_func_name ::= FIRST */ + 470, /* (368) sma_func_name ::= LAST */ + 470, /* (369) sma_func_name ::= LAST_ROW */ + 468, /* (370) sma_stream_opt ::= */ + 468, /* (371) sma_stream_opt ::= sma_stream_opt WATERMARK duration_literal */ + 468, /* (372) sma_stream_opt ::= sma_stream_opt MAX_DELAY duration_literal */ + 468, /* (373) sma_stream_opt ::= sma_stream_opt DELETE_MARK duration_literal */ + 472, /* (374) with_meta ::= AS */ + 472, /* (375) with_meta ::= WITH META AS */ + 472, /* (376) with_meta ::= ONLY META AS */ + 383, /* (377) cmd ::= CREATE TOPIC not_exists_opt topic_name AS query_or_subquery */ + 383, /* (378) cmd ::= CREATE TOPIC not_exists_opt topic_name with_meta DATABASE db_name */ + 383, /* (379) cmd ::= CREATE TOPIC not_exists_opt topic_name with_meta STABLE full_table_name where_clause_opt */ + 383, /* (380) cmd ::= DROP TOPIC exists_opt topic_name */ + 383, /* (381) cmd ::= DROP CONSUMER GROUP exists_opt cgroup_name ON topic_name */ + 383, /* (382) cmd ::= DESC full_table_name */ + 383, /* (383) cmd ::= DESCRIBE full_table_name */ + 383, /* (384) cmd ::= RESET QUERY CACHE */ + 383, /* (385) cmd ::= EXPLAIN analyze_opt explain_options query_or_subquery */ + 383, /* (386) cmd ::= EXPLAIN analyze_opt explain_options insert_query */ + 476, /* (387) analyze_opt ::= */ + 476, /* (388) analyze_opt ::= ANALYZE */ + 477, /* (389) explain_options ::= */ + 477, /* (390) explain_options ::= explain_options VERBOSE NK_BOOL */ + 477, /* (391) explain_options ::= explain_options RATIO NK_FLOAT */ + 383, /* (392) cmd ::= CREATE or_replace_opt agg_func_opt FUNCTION not_exists_opt function_name AS NK_STRING OUTPUTTYPE type_name bufsize_opt language_opt */ + 383, /* (393) cmd ::= DROP FUNCTION exists_opt function_name */ + 480, /* (394) agg_func_opt ::= */ + 480, /* (395) agg_func_opt ::= AGGREGATE */ + 481, /* (396) bufsize_opt ::= */ + 481, /* (397) bufsize_opt ::= BUFSIZE NK_INTEGER */ + 482, /* (398) language_opt ::= */ + 482, /* (399) language_opt ::= LANGUAGE NK_STRING */ + 479, /* (400) or_replace_opt ::= */ + 479, /* (401) or_replace_opt ::= OR REPLACE */ + 383, /* (402) cmd ::= CREATE or_replace_opt VIEW full_view_name AS query_or_subquery */ + 383, /* (403) cmd ::= DROP VIEW exists_opt full_view_name */ + 483, /* (404) full_view_name ::= view_name */ + 483, /* (405) full_view_name ::= db_name NK_DOT view_name */ + 383, /* (406) cmd ::= CREATE STREAM not_exists_opt stream_name stream_options INTO full_table_name col_list_opt tag_def_or_ref_opt subtable_opt AS query_or_subquery */ + 383, /* (407) cmd ::= DROP STREAM exists_opt stream_name */ + 383, /* (408) cmd ::= PAUSE STREAM exists_opt stream_name */ + 383, /* (409) cmd ::= RESUME STREAM exists_opt ignore_opt stream_name */ + 487, /* (410) col_list_opt ::= */ + 487, /* (411) col_list_opt ::= NK_LP column_stream_def_list NK_RP */ + 491, /* (412) column_stream_def_list ::= column_stream_def */ + 491, /* (413) column_stream_def_list ::= column_stream_def_list NK_COMMA column_stream_def */ + 492, /* (414) column_stream_def ::= column_name stream_col_options */ + 493, /* (415) stream_col_options ::= */ + 493, /* (416) stream_col_options ::= stream_col_options PRIMARY KEY */ + 488, /* (417) tag_def_or_ref_opt ::= */ + 488, /* (418) tag_def_or_ref_opt ::= tags_def */ + 488, /* (419) tag_def_or_ref_opt ::= TAGS NK_LP column_stream_def_list NK_RP */ + 486, /* (420) stream_options ::= */ + 486, /* (421) stream_options ::= stream_options TRIGGER AT_ONCE */ + 486, /* (422) stream_options ::= stream_options TRIGGER WINDOW_CLOSE */ + 486, /* (423) stream_options ::= stream_options TRIGGER MAX_DELAY duration_literal */ + 486, /* (424) stream_options ::= stream_options WATERMARK duration_literal */ + 486, /* (425) stream_options ::= stream_options IGNORE EXPIRED NK_INTEGER */ + 486, /* (426) stream_options ::= stream_options FILL_HISTORY NK_INTEGER */ + 486, /* (427) stream_options ::= stream_options DELETE_MARK duration_literal */ + 486, /* (428) stream_options ::= stream_options IGNORE UPDATE NK_INTEGER */ + 489, /* (429) subtable_opt ::= */ + 489, /* (430) subtable_opt ::= SUBTABLE NK_LP expression NK_RP */ + 490, /* (431) ignore_opt ::= */ + 490, /* (432) ignore_opt ::= IGNORE UNTREATED */ + 383, /* (433) cmd ::= KILL CONNECTION NK_INTEGER */ + 383, /* (434) cmd ::= KILL QUERY NK_STRING */ + 383, /* (435) cmd ::= KILL TRANSACTION NK_INTEGER */ + 383, /* (436) cmd ::= KILL COMPACT NK_INTEGER */ + 383, /* (437) cmd ::= BALANCE VGROUP */ + 383, /* (438) cmd ::= BALANCE VGROUP LEADER on_vgroup_id */ + 383, /* (439) cmd ::= BALANCE VGROUP LEADER DATABASE db_name */ + 383, /* (440) cmd ::= MERGE VGROUP NK_INTEGER NK_INTEGER */ + 383, /* (441) cmd ::= REDISTRIBUTE VGROUP NK_INTEGER dnode_list */ + 383, /* (442) cmd ::= SPLIT VGROUP NK_INTEGER */ + 495, /* (443) on_vgroup_id ::= */ + 495, /* (444) on_vgroup_id ::= ON NK_INTEGER */ + 496, /* (445) dnode_list ::= DNODE NK_INTEGER */ + 496, /* (446) dnode_list ::= dnode_list DNODE NK_INTEGER */ + 383, /* (447) cmd ::= DELETE FROM full_table_name where_clause_opt */ + 383, /* (448) cmd ::= query_or_subquery */ + 383, /* (449) cmd ::= insert_query */ + 478, /* (450) insert_query ::= INSERT INTO full_table_name NK_LP col_name_list NK_RP query_or_subquery */ + 478, /* (451) insert_query ::= INSERT INTO full_table_name query_or_subquery */ + 434, /* (452) tags_literal ::= NK_INTEGER */ + 434, /* (453) tags_literal ::= NK_INTEGER NK_PLUS duration_literal */ + 434, /* (454) tags_literal ::= NK_INTEGER NK_MINUS duration_literal */ + 434, /* (455) tags_literal ::= NK_PLUS NK_INTEGER */ + 434, /* (456) tags_literal ::= NK_PLUS NK_INTEGER NK_PLUS duration_literal */ + 434, /* (457) tags_literal ::= NK_PLUS NK_INTEGER NK_MINUS duration_literal */ + 434, /* (458) tags_literal ::= NK_MINUS NK_INTEGER */ + 434, /* (459) tags_literal ::= NK_MINUS NK_INTEGER NK_PLUS duration_literal */ + 434, /* (460) tags_literal ::= NK_MINUS NK_INTEGER NK_MINUS duration_literal */ + 434, /* (461) tags_literal ::= NK_FLOAT */ + 434, /* (462) tags_literal ::= NK_PLUS NK_FLOAT */ + 434, /* (463) tags_literal ::= NK_MINUS NK_FLOAT */ + 434, /* (464) tags_literal ::= NK_BIN */ + 434, /* (465) tags_literal ::= NK_BIN NK_PLUS duration_literal */ + 434, /* (466) tags_literal ::= NK_BIN NK_MINUS duration_literal */ + 434, /* (467) tags_literal ::= NK_PLUS NK_BIN */ + 434, /* (468) tags_literal ::= NK_PLUS NK_BIN NK_PLUS duration_literal */ + 434, /* (469) tags_literal ::= NK_PLUS NK_BIN NK_MINUS duration_literal */ + 434, /* (470) tags_literal ::= NK_MINUS NK_BIN */ + 434, /* (471) tags_literal ::= NK_MINUS NK_BIN NK_PLUS duration_literal */ + 434, /* (472) tags_literal ::= NK_MINUS NK_BIN NK_MINUS duration_literal */ + 434, /* (473) tags_literal ::= NK_HEX */ + 434, /* (474) tags_literal ::= NK_HEX NK_PLUS duration_literal */ + 434, /* (475) tags_literal ::= NK_HEX NK_MINUS duration_literal */ + 434, /* (476) tags_literal ::= NK_PLUS NK_HEX */ + 434, /* (477) tags_literal ::= NK_PLUS NK_HEX NK_PLUS duration_literal */ + 434, /* (478) tags_literal ::= NK_PLUS NK_HEX NK_MINUS duration_literal */ + 434, /* (479) tags_literal ::= NK_MINUS NK_HEX */ + 434, /* (480) tags_literal ::= NK_MINUS NK_HEX NK_PLUS duration_literal */ + 434, /* (481) tags_literal ::= NK_MINUS NK_HEX NK_MINUS duration_literal */ + 434, /* (482) tags_literal ::= NK_STRING */ + 434, /* (483) tags_literal ::= NK_STRING NK_PLUS duration_literal */ + 434, /* (484) tags_literal ::= NK_STRING NK_MINUS duration_literal */ + 434, /* (485) tags_literal ::= NK_BOOL */ + 434, /* (486) tags_literal ::= NULL */ + 434, /* (487) tags_literal ::= literal_func */ + 434, /* (488) tags_literal ::= literal_func NK_PLUS duration_literal */ + 434, /* (489) tags_literal ::= literal_func NK_MINUS duration_literal */ + 437, /* (490) tags_literal_list ::= tags_literal */ + 437, /* (491) tags_literal_list ::= tags_literal_list NK_COMMA tags_literal */ + 386, /* (492) literal ::= NK_INTEGER */ + 386, /* (493) literal ::= NK_FLOAT */ + 386, /* (494) literal ::= NK_STRING */ + 386, /* (495) literal ::= NK_BOOL */ + 386, /* (496) literal ::= TIMESTAMP NK_STRING */ + 386, /* (497) literal ::= duration_literal */ + 386, /* (498) literal ::= NULL */ + 386, /* (499) literal ::= NK_QUESTION */ + 447, /* (500) duration_literal ::= NK_VARIABLE */ + 417, /* (501) signed ::= NK_INTEGER */ + 417, /* (502) signed ::= NK_PLUS NK_INTEGER */ + 417, /* (503) signed ::= NK_MINUS NK_INTEGER */ + 417, /* (504) signed ::= NK_FLOAT */ + 417, /* (505) signed ::= NK_PLUS NK_FLOAT */ + 417, /* (506) signed ::= NK_MINUS NK_FLOAT */ + 498, /* (507) signed_literal ::= signed */ + 498, /* (508) signed_literal ::= NK_STRING */ + 498, /* (509) signed_literal ::= NK_BOOL */ + 498, /* (510) signed_literal ::= TIMESTAMP NK_STRING */ + 498, /* (511) signed_literal ::= duration_literal */ + 498, /* (512) signed_literal ::= NULL */ + 498, /* (513) signed_literal ::= literal_func */ + 498, /* (514) signed_literal ::= NK_QUESTION */ + 499, /* (515) literal_list ::= signed_literal */ + 499, /* (516) literal_list ::= literal_list NK_COMMA signed_literal */ + 400, /* (517) db_name ::= NK_ID */ + 401, /* (518) table_name ::= NK_ID */ + 431, /* (519) column_name ::= NK_ID */ + 449, /* (520) function_name ::= NK_ID */ + 484, /* (521) view_name ::= NK_ID */ + 500, /* (522) table_alias ::= NK_ID */ + 459, /* (523) column_alias ::= NK_ID */ + 459, /* (524) column_alias ::= NK_ALIAS */ + 393, /* (525) user_name ::= NK_ID */ + 402, /* (526) topic_name ::= NK_ID */ + 485, /* (527) stream_name ::= NK_ID */ + 475, /* (528) cgroup_name ::= NK_ID */ + 466, /* (529) index_name ::= NK_ID */ + 460, /* (530) tsma_name ::= NK_ID */ + 501, /* (531) expr_or_subquery ::= expression */ + 494, /* (532) expression ::= literal */ + 494, /* (533) expression ::= pseudo_column */ + 494, /* (534) expression ::= column_reference */ + 494, /* (535) expression ::= function_expression */ + 494, /* (536) expression ::= case_when_expression */ + 494, /* (537) expression ::= NK_LP expression NK_RP */ + 494, /* (538) expression ::= NK_PLUS expr_or_subquery */ + 494, /* (539) expression ::= NK_MINUS expr_or_subquery */ + 494, /* (540) expression ::= expr_or_subquery NK_PLUS expr_or_subquery */ + 494, /* (541) expression ::= expr_or_subquery NK_MINUS expr_or_subquery */ + 494, /* (542) expression ::= expr_or_subquery NK_STAR expr_or_subquery */ + 494, /* (543) expression ::= expr_or_subquery NK_SLASH expr_or_subquery */ + 494, /* (544) expression ::= expr_or_subquery NK_REM expr_or_subquery */ + 494, /* (545) expression ::= column_reference NK_ARROW NK_STRING */ + 494, /* (546) expression ::= expr_or_subquery NK_BITAND expr_or_subquery */ + 494, /* (547) expression ::= expr_or_subquery NK_BITOR expr_or_subquery */ + 471, /* (548) expression_list ::= expr_or_subquery */ + 471, /* (549) expression_list ::= expression_list NK_COMMA expr_or_subquery */ + 503, /* (550) column_reference ::= column_name */ + 503, /* (551) column_reference ::= table_name NK_DOT column_name */ + 503, /* (552) column_reference ::= NK_ALIAS */ + 503, /* (553) column_reference ::= table_name NK_DOT NK_ALIAS */ + 502, /* (554) pseudo_column ::= ROWTS */ + 502, /* (555) pseudo_column ::= TBNAME */ + 502, /* (556) pseudo_column ::= table_name NK_DOT TBNAME */ + 502, /* (557) pseudo_column ::= QSTART */ + 502, /* (558) pseudo_column ::= QEND */ + 502, /* (559) pseudo_column ::= QDURATION */ + 502, /* (560) pseudo_column ::= WSTART */ + 502, /* (561) pseudo_column ::= WEND */ + 502, /* (562) pseudo_column ::= WDURATION */ + 502, /* (563) pseudo_column ::= IROWTS */ + 502, /* (564) pseudo_column ::= ISFILLED */ + 502, /* (565) pseudo_column ::= QTAGS */ + 504, /* (566) function_expression ::= function_name NK_LP expression_list NK_RP */ + 504, /* (567) function_expression ::= star_func NK_LP star_func_para_list NK_RP */ + 504, /* (568) function_expression ::= CAST NK_LP expr_or_subquery AS type_name NK_RP */ + 504, /* (569) function_expression ::= CAST NK_LP expr_or_subquery AS type_name_default_len NK_RP */ + 504, /* (570) function_expression ::= POSITION NK_LP expr_or_subquery IN expr_or_subquery NK_RP */ + 504, /* (571) function_expression ::= TRIM NK_LP expr_or_subquery NK_RP */ + 504, /* (572) function_expression ::= TRIM NK_LP trim_specification_type FROM expr_or_subquery NK_RP */ + 504, /* (573) function_expression ::= TRIM NK_LP expr_or_subquery FROM expr_or_subquery NK_RP */ + 504, /* (574) function_expression ::= TRIM NK_LP trim_specification_type expr_or_subquery FROM expr_or_subquery NK_RP */ + 504, /* (575) function_expression ::= substr_func NK_LP expression_list NK_RP */ + 504, /* (576) function_expression ::= substr_func NK_LP expr_or_subquery FROM expr_or_subquery NK_RP */ + 504, /* (577) function_expression ::= substr_func NK_LP expr_or_subquery FROM expr_or_subquery FOR expr_or_subquery NK_RP */ + 504, /* (578) function_expression ::= REPLACE NK_LP expression_list NK_RP */ + 504, /* (579) function_expression ::= literal_func */ + 504, /* (580) function_expression ::= rand_func */ + 497, /* (581) literal_func ::= noarg_func NK_LP NK_RP */ + 497, /* (582) literal_func ::= NOW */ + 497, /* (583) literal_func ::= TODAY */ + 510, /* (584) rand_func ::= RAND NK_LP NK_RP */ + 510, /* (585) rand_func ::= RAND NK_LP expression_list NK_RP */ + 509, /* (586) substr_func ::= SUBSTR */ + 509, /* (587) substr_func ::= SUBSTRING */ + 508, /* (588) trim_specification_type ::= BOTH */ + 508, /* (589) trim_specification_type ::= TRAILING */ + 508, /* (590) trim_specification_type ::= LEADING */ + 511, /* (591) noarg_func ::= NOW */ + 511, /* (592) noarg_func ::= TODAY */ + 511, /* (593) noarg_func ::= TIMEZONE */ + 511, /* (594) noarg_func ::= DATABASE */ + 511, /* (595) noarg_func ::= CLIENT_VERSION */ + 511, /* (596) noarg_func ::= SERVER_VERSION */ + 511, /* (597) noarg_func ::= SERVER_STATUS */ + 511, /* (598) noarg_func ::= CURRENT_USER */ + 511, /* (599) noarg_func ::= USER */ + 511, /* (600) noarg_func ::= PI */ + 506, /* (601) star_func ::= COUNT */ + 506, /* (602) star_func ::= FIRST */ + 506, /* (603) star_func ::= LAST */ + 506, /* (604) star_func ::= LAST_ROW */ + 507, /* (605) star_func_para_list ::= NK_STAR */ + 507, /* (606) star_func_para_list ::= other_para_list */ + 512, /* (607) other_para_list ::= star_func_para */ + 512, /* (608) other_para_list ::= other_para_list NK_COMMA star_func_para */ + 513, /* (609) star_func_para ::= expr_or_subquery */ + 513, /* (610) star_func_para ::= table_name NK_DOT NK_STAR */ + 505, /* (611) case_when_expression ::= CASE when_then_list case_when_else_opt END */ + 505, /* (612) case_when_expression ::= CASE common_expression when_then_list case_when_else_opt END */ + 514, /* (613) when_then_list ::= when_then_expr */ + 514, /* (614) when_then_list ::= when_then_list when_then_expr */ + 517, /* (615) when_then_expr ::= WHEN common_expression THEN common_expression */ + 515, /* (616) case_when_else_opt ::= */ + 515, /* (617) case_when_else_opt ::= ELSE common_expression */ + 518, /* (618) predicate ::= expr_or_subquery compare_op expr_or_subquery */ + 518, /* (619) predicate ::= expr_or_subquery BETWEEN expr_or_subquery AND expr_or_subquery */ + 518, /* (620) predicate ::= expr_or_subquery NOT BETWEEN expr_or_subquery AND expr_or_subquery */ + 518, /* (621) predicate ::= expr_or_subquery IS NULL */ + 518, /* (622) predicate ::= expr_or_subquery IS NOT NULL */ + 518, /* (623) predicate ::= expr_or_subquery in_op in_predicate_value */ + 519, /* (624) compare_op ::= NK_LT */ + 519, /* (625) compare_op ::= NK_GT */ + 519, /* (626) compare_op ::= NK_LE */ + 519, /* (627) compare_op ::= NK_GE */ + 519, /* (628) compare_op ::= NK_NE */ + 519, /* (629) compare_op ::= NK_EQ */ + 519, /* (630) compare_op ::= LIKE */ + 519, /* (631) compare_op ::= NOT LIKE */ + 519, /* (632) compare_op ::= MATCH */ + 519, /* (633) compare_op ::= NMATCH */ + 519, /* (634) compare_op ::= CONTAINS */ + 520, /* (635) in_op ::= IN */ + 520, /* (636) in_op ::= NOT IN */ + 521, /* (637) in_predicate_value ::= NK_LP literal_list NK_RP */ + 522, /* (638) boolean_value_expression ::= boolean_primary */ + 522, /* (639) boolean_value_expression ::= NOT boolean_primary */ + 522, /* (640) boolean_value_expression ::= boolean_value_expression OR boolean_value_expression */ + 522, /* (641) boolean_value_expression ::= boolean_value_expression AND boolean_value_expression */ + 523, /* (642) boolean_primary ::= predicate */ + 523, /* (643) boolean_primary ::= NK_LP boolean_value_expression NK_RP */ + 516, /* (644) common_expression ::= expr_or_subquery */ + 516, /* (645) common_expression ::= boolean_value_expression */ + 524, /* (646) from_clause_opt ::= */ + 524, /* (647) from_clause_opt ::= FROM table_reference_list */ + 525, /* (648) table_reference_list ::= table_reference */ + 525, /* (649) table_reference_list ::= table_reference_list NK_COMMA table_reference */ + 526, /* (650) table_reference ::= table_primary */ + 526, /* (651) table_reference ::= joined_table */ + 527, /* (652) table_primary ::= table_name alias_opt */ + 527, /* (653) table_primary ::= db_name NK_DOT table_name alias_opt */ + 527, /* (654) table_primary ::= subquery alias_opt */ + 527, /* (655) table_primary ::= parenthesized_joined_table */ + 529, /* (656) alias_opt ::= */ + 529, /* (657) alias_opt ::= table_alias */ + 529, /* (658) alias_opt ::= AS table_alias */ + 531, /* (659) parenthesized_joined_table ::= NK_LP joined_table NK_RP */ + 531, /* (660) parenthesized_joined_table ::= NK_LP parenthesized_joined_table NK_RP */ + 528, /* (661) joined_table ::= table_reference join_type join_subtype JOIN table_reference join_on_clause_opt window_offset_clause_opt jlimit_clause_opt */ + 532, /* (662) join_type ::= */ + 532, /* (663) join_type ::= INNER */ + 532, /* (664) join_type ::= LEFT */ + 532, /* (665) join_type ::= RIGHT */ + 532, /* (666) join_type ::= FULL */ + 533, /* (667) join_subtype ::= */ + 533, /* (668) join_subtype ::= OUTER */ + 533, /* (669) join_subtype ::= SEMI */ + 533, /* (670) join_subtype ::= ANTI */ + 533, /* (671) join_subtype ::= ASOF */ + 533, /* (672) join_subtype ::= WINDOW */ + 534, /* (673) join_on_clause_opt ::= */ + 534, /* (674) join_on_clause_opt ::= ON search_condition */ + 535, /* (675) window_offset_clause_opt ::= */ + 535, /* (676) window_offset_clause_opt ::= WINDOW_OFFSET NK_LP window_offset_literal NK_COMMA window_offset_literal NK_RP */ + 537, /* (677) window_offset_literal ::= NK_VARIABLE */ + 537, /* (678) window_offset_literal ::= NK_MINUS NK_VARIABLE */ + 536, /* (679) jlimit_clause_opt ::= */ + 536, /* (680) jlimit_clause_opt ::= JLIMIT NK_INTEGER */ + 538, /* (681) query_specification ::= SELECT hint_list set_quantifier_opt tag_mode_opt select_list from_clause_opt where_clause_opt partition_by_clause_opt range_opt every_opt fill_opt twindow_clause_opt group_by_clause_opt having_clause_opt */ + 539, /* (682) hint_list ::= */ + 539, /* (683) hint_list ::= NK_HINT */ + 541, /* (684) tag_mode_opt ::= */ + 541, /* (685) tag_mode_opt ::= TAGS */ + 540, /* (686) set_quantifier_opt ::= */ + 540, /* (687) set_quantifier_opt ::= DISTINCT */ + 540, /* (688) set_quantifier_opt ::= ALL */ + 542, /* (689) select_list ::= select_item */ + 542, /* (690) select_list ::= select_list NK_COMMA select_item */ + 550, /* (691) select_item ::= NK_STAR */ + 550, /* (692) select_item ::= common_expression */ + 550, /* (693) select_item ::= common_expression column_alias */ + 550, /* (694) select_item ::= common_expression AS column_alias */ + 550, /* (695) select_item ::= table_name NK_DOT NK_STAR */ + 474, /* (696) where_clause_opt ::= */ + 474, /* (697) where_clause_opt ::= WHERE search_condition */ + 543, /* (698) partition_by_clause_opt ::= */ + 543, /* (699) partition_by_clause_opt ::= PARTITION BY partition_list */ + 551, /* (700) partition_list ::= partition_item */ + 551, /* (701) partition_list ::= partition_list NK_COMMA partition_item */ + 552, /* (702) partition_item ::= expr_or_subquery */ + 552, /* (703) partition_item ::= expr_or_subquery column_alias */ + 552, /* (704) partition_item ::= expr_or_subquery AS column_alias */ + 547, /* (705) twindow_clause_opt ::= */ + 547, /* (706) twindow_clause_opt ::= SESSION NK_LP column_reference NK_COMMA interval_sliding_duration_literal NK_RP */ + 547, /* (707) twindow_clause_opt ::= STATE_WINDOW NK_LP expr_or_subquery NK_RP */ + 547, /* (708) twindow_clause_opt ::= INTERVAL NK_LP interval_sliding_duration_literal NK_RP sliding_opt fill_opt */ + 547, /* (709) twindow_clause_opt ::= INTERVAL NK_LP interval_sliding_duration_literal NK_COMMA interval_sliding_duration_literal NK_RP sliding_opt fill_opt */ + 547, /* (710) twindow_clause_opt ::= EVENT_WINDOW START WITH search_condition END WITH search_condition */ + 547, /* (711) twindow_clause_opt ::= COUNT_WINDOW NK_LP NK_INTEGER NK_RP */ + 547, /* (712) twindow_clause_opt ::= COUNT_WINDOW NK_LP NK_INTEGER NK_COMMA NK_INTEGER NK_RP */ + 467, /* (713) sliding_opt ::= */ + 467, /* (714) sliding_opt ::= SLIDING NK_LP interval_sliding_duration_literal NK_RP */ + 553, /* (715) interval_sliding_duration_literal ::= NK_VARIABLE */ + 553, /* (716) interval_sliding_duration_literal ::= NK_STRING */ + 553, /* (717) interval_sliding_duration_literal ::= NK_INTEGER */ + 546, /* (718) fill_opt ::= */ + 546, /* (719) fill_opt ::= FILL NK_LP fill_mode NK_RP */ + 546, /* (720) fill_opt ::= FILL NK_LP VALUE NK_COMMA expression_list NK_RP */ + 546, /* (721) fill_opt ::= FILL NK_LP VALUE_F NK_COMMA expression_list NK_RP */ + 554, /* (722) fill_mode ::= NONE */ + 554, /* (723) fill_mode ::= PREV */ + 554, /* (724) fill_mode ::= NULL */ + 554, /* (725) fill_mode ::= NULL_F */ + 554, /* (726) fill_mode ::= LINEAR */ + 554, /* (727) fill_mode ::= NEXT */ + 548, /* (728) group_by_clause_opt ::= */ + 548, /* (729) group_by_clause_opt ::= GROUP BY group_by_list */ + 555, /* (730) group_by_list ::= expr_or_subquery */ + 555, /* (731) group_by_list ::= group_by_list NK_COMMA expr_or_subquery */ + 549, /* (732) having_clause_opt ::= */ + 549, /* (733) having_clause_opt ::= HAVING search_condition */ + 544, /* (734) range_opt ::= */ + 544, /* (735) range_opt ::= RANGE NK_LP expr_or_subquery NK_COMMA expr_or_subquery NK_RP */ + 544, /* (736) range_opt ::= RANGE NK_LP expr_or_subquery NK_RP */ + 545, /* (737) every_opt ::= */ + 545, /* (738) every_opt ::= EVERY NK_LP duration_literal NK_RP */ + 556, /* (739) query_expression ::= query_simple order_by_clause_opt slimit_clause_opt limit_clause_opt */ + 557, /* (740) query_simple ::= query_specification */ + 557, /* (741) query_simple ::= union_query_expression */ + 561, /* (742) union_query_expression ::= query_simple_or_subquery UNION ALL query_simple_or_subquery */ + 561, /* (743) union_query_expression ::= query_simple_or_subquery UNION query_simple_or_subquery */ + 562, /* (744) query_simple_or_subquery ::= query_simple */ + 562, /* (745) query_simple_or_subquery ::= subquery */ + 473, /* (746) query_or_subquery ::= query_expression */ + 473, /* (747) query_or_subquery ::= subquery */ + 558, /* (748) order_by_clause_opt ::= */ + 558, /* (749) order_by_clause_opt ::= ORDER BY sort_specification_list */ + 559, /* (750) slimit_clause_opt ::= */ + 559, /* (751) slimit_clause_opt ::= SLIMIT NK_INTEGER */ + 559, /* (752) slimit_clause_opt ::= SLIMIT NK_INTEGER SOFFSET NK_INTEGER */ + 559, /* (753) slimit_clause_opt ::= SLIMIT NK_INTEGER NK_COMMA NK_INTEGER */ + 560, /* (754) limit_clause_opt ::= */ + 560, /* (755) limit_clause_opt ::= LIMIT NK_INTEGER */ + 560, /* (756) limit_clause_opt ::= LIMIT NK_INTEGER OFFSET NK_INTEGER */ + 560, /* (757) limit_clause_opt ::= LIMIT NK_INTEGER NK_COMMA NK_INTEGER */ + 530, /* (758) subquery ::= NK_LP query_expression NK_RP */ + 530, /* (759) subquery ::= NK_LP subquery NK_RP */ + 403, /* (760) search_condition ::= common_expression */ + 563, /* (761) sort_specification_list ::= sort_specification */ + 563, /* (762) sort_specification_list ::= sort_specification_list NK_COMMA sort_specification */ + 564, /* (763) sort_specification ::= expr_or_subquery ordering_specification_opt null_ordering_opt */ + 565, /* (764) ordering_specification_opt ::= */ + 565, /* (765) ordering_specification_opt ::= ASC */ + 565, /* (766) ordering_specification_opt ::= DESC */ + 566, /* (767) null_ordering_opt ::= */ + 566, /* (768) null_ordering_opt ::= NULLS FIRST */ + 566, /* (769) null_ordering_opt ::= NULLS LAST */ + 433, /* (770) column_options ::= */ + 433, /* (771) column_options ::= column_options PRIMARY KEY */ + 433, /* (772) column_options ::= column_options NK_ID NK_STRING */ }; /* For rule J, yyRuleInfoNRhs[J] contains the negative of the number ** of symbols on the right-hand side of that rule. */ static const signed char yyRuleInfoNRhs[] = { - -6, /* (0) cmd ::= CREATE ACCOUNT NK_ID PASS NK_STRING account_options */ - -4, /* (1) cmd ::= ALTER ACCOUNT NK_ID alter_account_options */ + -6, /* (0) cmd ::= CREATE ACCOUNT NK_ID PASS NK_STRING account_options */ + -4, /* (1) cmd ::= ALTER ACCOUNT NK_ID alter_account_options */ 0, /* (2) account_options ::= */ - -3, /* (3) account_options ::= account_options PPS literal */ - -3, /* (4) account_options ::= account_options TSERIES literal */ - -3, /* (5) account_options ::= account_options STORAGE literal */ - -3, /* (6) account_options ::= account_options STREAMS literal */ - -3, /* (7) account_options ::= account_options QTIME literal */ - -3, /* (8) account_options ::= account_options DBS literal */ - -3, /* (9) account_options ::= account_options USERS literal */ - -3, /* (10) account_options ::= account_options CONNS literal */ - -3, /* (11) account_options ::= account_options STATE literal */ - -1, /* (12) alter_account_options ::= alter_account_option */ - -2, /* (13) alter_account_options ::= alter_account_options alter_account_option */ - -2, /* (14) alter_account_option ::= PASS literal */ - -2, /* (15) alter_account_option ::= PPS literal */ - -2, /* (16) alter_account_option ::= TSERIES literal */ - -2, /* (17) alter_account_option ::= STORAGE literal */ - -2, /* (18) alter_account_option ::= STREAMS literal */ - -2, /* (19) alter_account_option ::= QTIME literal */ - -2, /* (20) alter_account_option ::= DBS literal */ - -2, /* (21) alter_account_option ::= USERS literal */ - -2, /* (22) alter_account_option ::= CONNS literal */ - -2, /* (23) alter_account_option ::= STATE literal */ - -1, /* (24) ip_range_list ::= NK_STRING */ - -3, /* (25) ip_range_list ::= ip_range_list NK_COMMA NK_STRING */ - -2, /* (26) white_list ::= HOST ip_range_list */ + -3, /* (3) account_options ::= account_options PPS literal */ + -3, /* (4) account_options ::= account_options TSERIES literal */ + -3, /* (5) account_options ::= account_options STORAGE literal */ + -3, /* (6) account_options ::= account_options STREAMS literal */ + -3, /* (7) account_options ::= account_options QTIME literal */ + -3, /* (8) account_options ::= account_options DBS literal */ + -3, /* (9) account_options ::= account_options USERS literal */ + -3, /* (10) account_options ::= account_options CONNS literal */ + -3, /* (11) account_options ::= account_options STATE literal */ + -1, /* (12) alter_account_options ::= alter_account_option */ + -2, /* (13) alter_account_options ::= alter_account_options alter_account_option */ + -2, /* (14) alter_account_option ::= PASS literal */ + -2, /* (15) alter_account_option ::= PPS literal */ + -2, /* (16) alter_account_option ::= TSERIES literal */ + -2, /* (17) alter_account_option ::= STORAGE literal */ + -2, /* (18) alter_account_option ::= STREAMS literal */ + -2, /* (19) alter_account_option ::= QTIME literal */ + -2, /* (20) alter_account_option ::= DBS literal */ + -2, /* (21) alter_account_option ::= USERS literal */ + -2, /* (22) alter_account_option ::= CONNS literal */ + -2, /* (23) alter_account_option ::= STATE literal */ + -1, /* (24) ip_range_list ::= NK_STRING */ + -3, /* (25) ip_range_list ::= ip_range_list NK_COMMA NK_STRING */ + -2, /* (26) white_list ::= HOST ip_range_list */ 0, /* (27) white_list_opt ::= */ - -1, /* (28) white_list_opt ::= white_list */ + -1, /* (28) white_list_opt ::= white_list */ 0, /* (29) is_import_opt ::= */ - -2, /* (30) is_import_opt ::= IS_IMPORT NK_INTEGER */ + -2, /* (30) is_import_opt ::= IS_IMPORT NK_INTEGER */ 0, /* (31) is_createdb_opt ::= */ - -2, /* (32) is_createdb_opt ::= CREATEDB NK_INTEGER */ - -9, /* (33) cmd ::= CREATE USER user_name PASS NK_STRING sysinfo_opt is_createdb_opt is_import_opt white_list_opt */ - -5, /* (34) cmd ::= ALTER USER user_name PASS NK_STRING */ - -5, /* (35) cmd ::= ALTER USER user_name ENABLE NK_INTEGER */ - -5, /* (36) cmd ::= ALTER USER user_name SYSINFO NK_INTEGER */ - -5, /* (37) cmd ::= ALTER USER user_name CREATEDB NK_INTEGER */ - -5, /* (38) cmd ::= ALTER USER user_name ADD white_list */ - -5, /* (39) cmd ::= ALTER USER user_name DROP white_list */ - -3, /* (40) cmd ::= DROP USER user_name */ + -2, /* (32) is_createdb_opt ::= CREATEDB NK_INTEGER */ + -9, /* (33) cmd ::= CREATE USER user_name PASS NK_STRING sysinfo_opt is_createdb_opt is_import_opt white_list_opt */ + -5, /* (34) cmd ::= ALTER USER user_name PASS NK_STRING */ + -5, /* (35) cmd ::= ALTER USER user_name ENABLE NK_INTEGER */ + -5, /* (36) cmd ::= ALTER USER user_name SYSINFO NK_INTEGER */ + -5, /* (37) cmd ::= ALTER USER user_name CREATEDB NK_INTEGER */ + -5, /* (38) cmd ::= ALTER USER user_name ADD white_list */ + -5, /* (39) cmd ::= ALTER USER user_name DROP white_list */ + -3, /* (40) cmd ::= DROP USER user_name */ 0, /* (41) sysinfo_opt ::= */ - -2, /* (42) sysinfo_opt ::= SYSINFO NK_INTEGER */ - -7, /* (43) cmd ::= GRANT privileges ON priv_level with_opt TO user_name */ - -7, /* (44) cmd ::= REVOKE privileges ON priv_level with_opt FROM user_name */ - -1, /* (45) privileges ::= ALL */ - -1, /* (46) privileges ::= priv_type_list */ - -1, /* (47) privileges ::= SUBSCRIBE */ - -1, /* (48) priv_type_list ::= priv_type */ - -3, /* (49) priv_type_list ::= priv_type_list NK_COMMA priv_type */ - -1, /* (50) priv_type ::= READ */ - -1, /* (51) priv_type ::= WRITE */ - -1, /* (52) priv_type ::= ALTER */ - -3, /* (53) priv_level ::= NK_STAR NK_DOT NK_STAR */ - -3, /* (54) priv_level ::= db_name NK_DOT NK_STAR */ - -3, /* (55) priv_level ::= db_name NK_DOT table_name */ - -1, /* (56) priv_level ::= topic_name */ - 0, /* (57) with_opt ::= */ - -2, /* (58) with_opt ::= WITH search_condition */ - -3, /* (59) cmd ::= CREATE ENCRYPT_KEY NK_STRING */ - -3, /* (60) cmd ::= CREATE DNODE dnode_endpoint */ - -5, /* (61) cmd ::= CREATE DNODE dnode_endpoint PORT NK_INTEGER */ - -4, /* (62) cmd ::= DROP DNODE NK_INTEGER force_opt */ - -4, /* (63) cmd ::= DROP DNODE dnode_endpoint force_opt */ - -4, /* (64) cmd ::= DROP DNODE NK_INTEGER unsafe_opt */ - -4, /* (65) cmd ::= DROP DNODE dnode_endpoint unsafe_opt */ - -4, /* (66) cmd ::= ALTER DNODE NK_INTEGER NK_STRING */ - -5, /* (67) cmd ::= ALTER DNODE NK_INTEGER NK_STRING NK_STRING */ - -4, /* (68) cmd ::= ALTER ALL DNODES NK_STRING */ - -5, /* (69) cmd ::= ALTER ALL DNODES NK_STRING NK_STRING */ - -3, /* (70) cmd ::= RESTORE DNODE NK_INTEGER */ - -1, /* (71) dnode_endpoint ::= NK_STRING */ - -1, /* (72) dnode_endpoint ::= NK_ID */ - -1, /* (73) dnode_endpoint ::= NK_IPTOKEN */ + -2, /* (42) sysinfo_opt ::= SYSINFO NK_INTEGER */ + -7, /* (43) cmd ::= GRANT privileges ON priv_level with_clause_opt TO user_name */ + -7, /* (44) cmd ::= REVOKE privileges ON priv_level with_clause_opt FROM user_name */ + -1, /* (45) privileges ::= ALL */ + -1, /* (46) privileges ::= priv_type_list */ + -1, /* (47) privileges ::= SUBSCRIBE */ + -1, /* (48) priv_type_list ::= priv_type */ + -3, /* (49) priv_type_list ::= priv_type_list NK_COMMA priv_type */ + -1, /* (50) priv_type ::= READ */ + -1, /* (51) priv_type ::= WRITE */ + -1, /* (52) priv_type ::= ALTER */ + -3, /* (53) priv_level ::= NK_STAR NK_DOT NK_STAR */ + -3, /* (54) priv_level ::= db_name NK_DOT NK_STAR */ + -3, /* (55) priv_level ::= db_name NK_DOT table_name */ + -1, /* (56) priv_level ::= topic_name */ + 0, /* (57) with_clause_opt ::= */ + -2, /* (58) with_clause_opt ::= WITH search_condition */ + -3, /* (59) cmd ::= CREATE ENCRYPT_KEY NK_STRING */ + -3, /* (60) cmd ::= CREATE DNODE dnode_endpoint */ + -5, /* (61) cmd ::= CREATE DNODE dnode_endpoint PORT NK_INTEGER */ + -4, /* (62) cmd ::= DROP DNODE NK_INTEGER force_opt */ + -4, /* (63) cmd ::= DROP DNODE dnode_endpoint force_opt */ + -4, /* (64) cmd ::= DROP DNODE NK_INTEGER unsafe_opt */ + -4, /* (65) cmd ::= DROP DNODE dnode_endpoint unsafe_opt */ + -4, /* (66) cmd ::= ALTER DNODE NK_INTEGER NK_STRING */ + -5, /* (67) cmd ::= ALTER DNODE NK_INTEGER NK_STRING NK_STRING */ + -4, /* (68) cmd ::= ALTER ALL DNODES NK_STRING */ + -5, /* (69) cmd ::= ALTER ALL DNODES NK_STRING NK_STRING */ + -3, /* (70) cmd ::= RESTORE DNODE NK_INTEGER */ + -1, /* (71) dnode_endpoint ::= NK_STRING */ + -1, /* (72) dnode_endpoint ::= NK_ID */ + -1, /* (73) dnode_endpoint ::= NK_IPTOKEN */ 0, /* (74) force_opt ::= */ - -1, /* (75) force_opt ::= FORCE */ - -1, /* (76) unsafe_opt ::= UNSAFE */ - -3, /* (77) cmd ::= ALTER CLUSTER NK_STRING */ - -4, /* (78) cmd ::= ALTER CLUSTER NK_STRING NK_STRING */ - -3, /* (79) cmd ::= ALTER LOCAL NK_STRING */ - -4, /* (80) cmd ::= ALTER LOCAL NK_STRING NK_STRING */ - -5, /* (81) cmd ::= CREATE QNODE ON DNODE NK_INTEGER */ - -5, /* (82) cmd ::= DROP QNODE ON DNODE NK_INTEGER */ - -5, /* (83) cmd ::= RESTORE QNODE ON DNODE NK_INTEGER */ - -5, /* (84) cmd ::= CREATE BNODE ON DNODE NK_INTEGER */ - -5, /* (85) cmd ::= DROP BNODE ON DNODE NK_INTEGER */ - -5, /* (86) cmd ::= CREATE SNODE ON DNODE NK_INTEGER */ - -5, /* (87) cmd ::= DROP SNODE ON DNODE NK_INTEGER */ - -5, /* (88) cmd ::= CREATE MNODE ON DNODE NK_INTEGER */ - -5, /* (89) cmd ::= DROP MNODE ON DNODE NK_INTEGER */ - -5, /* (90) cmd ::= RESTORE MNODE ON DNODE NK_INTEGER */ - -5, /* (91) cmd ::= RESTORE VNODE ON DNODE NK_INTEGER */ - -5, /* (92) cmd ::= CREATE DATABASE not_exists_opt db_name db_options */ - -4, /* (93) cmd ::= DROP DATABASE exists_opt db_name */ - -2, /* (94) cmd ::= USE db_name */ - -4, /* (95) cmd ::= ALTER DATABASE db_name alter_db_options */ - -3, /* (96) cmd ::= FLUSH DATABASE db_name */ - -4, /* (97) cmd ::= TRIM DATABASE db_name speed_opt */ - -3, /* (98) cmd ::= S3MIGRATE DATABASE db_name */ - -5, /* (99) cmd ::= COMPACT DATABASE db_name start_opt end_opt */ - -3, /* (100) not_exists_opt ::= IF NOT EXISTS */ + -1, /* (75) force_opt ::= FORCE */ + -1, /* (76) unsafe_opt ::= UNSAFE */ + -3, /* (77) cmd ::= ALTER CLUSTER NK_STRING */ + -4, /* (78) cmd ::= ALTER CLUSTER NK_STRING NK_STRING */ + -3, /* (79) cmd ::= ALTER LOCAL NK_STRING */ + -4, /* (80) cmd ::= ALTER LOCAL NK_STRING NK_STRING */ + -5, /* (81) cmd ::= CREATE QNODE ON DNODE NK_INTEGER */ + -5, /* (82) cmd ::= DROP QNODE ON DNODE NK_INTEGER */ + -5, /* (83) cmd ::= RESTORE QNODE ON DNODE NK_INTEGER */ + -5, /* (84) cmd ::= CREATE BNODE ON DNODE NK_INTEGER */ + -5, /* (85) cmd ::= DROP BNODE ON DNODE NK_INTEGER */ + -5, /* (86) cmd ::= CREATE SNODE ON DNODE NK_INTEGER */ + -5, /* (87) cmd ::= DROP SNODE ON DNODE NK_INTEGER */ + -5, /* (88) cmd ::= CREATE MNODE ON DNODE NK_INTEGER */ + -5, /* (89) cmd ::= DROP MNODE ON DNODE NK_INTEGER */ + -5, /* (90) cmd ::= RESTORE MNODE ON DNODE NK_INTEGER */ + -5, /* (91) cmd ::= RESTORE VNODE ON DNODE NK_INTEGER */ + -5, /* (92) cmd ::= CREATE DATABASE not_exists_opt db_name db_options */ + -4, /* (93) cmd ::= DROP DATABASE exists_opt db_name */ + -2, /* (94) cmd ::= USE db_name */ + -4, /* (95) cmd ::= ALTER DATABASE db_name alter_db_options */ + -3, /* (96) cmd ::= FLUSH DATABASE db_name */ + -4, /* (97) cmd ::= TRIM DATABASE db_name speed_opt */ + -3, /* (98) cmd ::= S3MIGRATE DATABASE db_name */ + -5, /* (99) cmd ::= COMPACT DATABASE db_name start_opt end_opt */ + -3, /* (100) not_exists_opt ::= IF NOT EXISTS */ 0, /* (101) not_exists_opt ::= */ - -2, /* (102) exists_opt ::= IF EXISTS */ + -2, /* (102) exists_opt ::= IF EXISTS */ 0, /* (103) exists_opt ::= */ 0, /* (104) db_options ::= */ - -3, /* (105) db_options ::= db_options BUFFER NK_INTEGER */ - -3, /* (106) db_options ::= db_options CACHEMODEL NK_STRING */ - -3, /* (107) db_options ::= db_options CACHESIZE NK_INTEGER */ - -3, /* (108) db_options ::= db_options COMP NK_INTEGER */ - -3, /* (109) db_options ::= db_options DURATION NK_INTEGER */ - -3, /* (110) db_options ::= db_options DURATION NK_VARIABLE */ - -3, /* (111) db_options ::= db_options MAXROWS NK_INTEGER */ - -3, /* (112) db_options ::= db_options MINROWS NK_INTEGER */ - -3, /* (113) db_options ::= db_options KEEP integer_list */ - -3, /* (114) db_options ::= db_options KEEP variable_list */ - -3, /* (115) db_options ::= db_options PAGES NK_INTEGER */ - -3, /* (116) db_options ::= db_options PAGESIZE NK_INTEGER */ - -3, /* (117) db_options ::= db_options TSDB_PAGESIZE NK_INTEGER */ - -3, /* (118) db_options ::= db_options PRECISION NK_STRING */ - -3, /* (119) db_options ::= db_options REPLICA NK_INTEGER */ - -3, /* (120) db_options ::= db_options VGROUPS NK_INTEGER */ - -3, /* (121) db_options ::= db_options SINGLE_STABLE NK_INTEGER */ - -3, /* (122) db_options ::= db_options RETENTIONS retention_list */ - -3, /* (123) db_options ::= db_options SCHEMALESS NK_INTEGER */ - -3, /* (124) db_options ::= db_options WAL_LEVEL NK_INTEGER */ - -3, /* (125) db_options ::= db_options WAL_FSYNC_PERIOD NK_INTEGER */ - -3, /* (126) db_options ::= db_options WAL_RETENTION_PERIOD NK_INTEGER */ - -4, /* (127) db_options ::= db_options WAL_RETENTION_PERIOD NK_MINUS NK_INTEGER */ - -3, /* (128) db_options ::= db_options WAL_RETENTION_SIZE NK_INTEGER */ - -4, /* (129) db_options ::= db_options WAL_RETENTION_SIZE NK_MINUS NK_INTEGER */ - -3, /* (130) db_options ::= db_options WAL_ROLL_PERIOD NK_INTEGER */ - -3, /* (131) db_options ::= db_options WAL_SEGMENT_SIZE NK_INTEGER */ - -3, /* (132) db_options ::= db_options STT_TRIGGER NK_INTEGER */ - -3, /* (133) db_options ::= db_options TABLE_PREFIX signed */ - -3, /* (134) db_options ::= db_options TABLE_SUFFIX signed */ - -3, /* (135) db_options ::= db_options S3_CHUNKSIZE NK_INTEGER */ - -3, /* (136) db_options ::= db_options S3_KEEPLOCAL NK_INTEGER */ - -3, /* (137) db_options ::= db_options S3_KEEPLOCAL NK_VARIABLE */ - -3, /* (138) db_options ::= db_options S3_COMPACT NK_INTEGER */ - -3, /* (139) db_options ::= db_options KEEP_TIME_OFFSET NK_INTEGER */ - -3, /* (140) db_options ::= db_options ENCRYPT_ALGORITHM NK_STRING */ - -1, /* (141) alter_db_options ::= alter_db_option */ - -2, /* (142) alter_db_options ::= alter_db_options alter_db_option */ - -2, /* (143) alter_db_option ::= BUFFER NK_INTEGER */ - -2, /* (144) alter_db_option ::= CACHEMODEL NK_STRING */ - -2, /* (145) alter_db_option ::= CACHESIZE NK_INTEGER */ - -2, /* (146) alter_db_option ::= WAL_FSYNC_PERIOD NK_INTEGER */ - -2, /* (147) alter_db_option ::= KEEP integer_list */ - -2, /* (148) alter_db_option ::= KEEP variable_list */ - -2, /* (149) alter_db_option ::= PAGES NK_INTEGER */ - -2, /* (150) alter_db_option ::= REPLICA NK_INTEGER */ - -2, /* (151) alter_db_option ::= WAL_LEVEL NK_INTEGER */ - -2, /* (152) alter_db_option ::= STT_TRIGGER NK_INTEGER */ - -2, /* (153) alter_db_option ::= MINROWS NK_INTEGER */ - -2, /* (154) alter_db_option ::= WAL_RETENTION_PERIOD NK_INTEGER */ - -3, /* (155) alter_db_option ::= WAL_RETENTION_PERIOD NK_MINUS NK_INTEGER */ - -2, /* (156) alter_db_option ::= WAL_RETENTION_SIZE NK_INTEGER */ - -3, /* (157) alter_db_option ::= WAL_RETENTION_SIZE NK_MINUS NK_INTEGER */ - -2, /* (158) alter_db_option ::= S3_KEEPLOCAL NK_INTEGER */ - -2, /* (159) alter_db_option ::= S3_KEEPLOCAL NK_VARIABLE */ - -2, /* (160) alter_db_option ::= S3_COMPACT NK_INTEGER */ - -2, /* (161) alter_db_option ::= KEEP_TIME_OFFSET NK_INTEGER */ - -2, /* (162) alter_db_option ::= ENCRYPT_ALGORITHM NK_STRING */ - -1, /* (163) integer_list ::= NK_INTEGER */ - -3, /* (164) integer_list ::= integer_list NK_COMMA NK_INTEGER */ - -1, /* (165) variable_list ::= NK_VARIABLE */ - -3, /* (166) variable_list ::= variable_list NK_COMMA NK_VARIABLE */ - -1, /* (167) retention_list ::= retention */ - -3, /* (168) retention_list ::= retention_list NK_COMMA retention */ - -3, /* (169) retention ::= NK_VARIABLE NK_COLON NK_VARIABLE */ - -3, /* (170) retention ::= NK_MINUS NK_COLON NK_VARIABLE */ + -3, /* (105) db_options ::= db_options BUFFER NK_INTEGER */ + -3, /* (106) db_options ::= db_options CACHEMODEL NK_STRING */ + -3, /* (107) db_options ::= db_options CACHESIZE NK_INTEGER */ + -3, /* (108) db_options ::= db_options COMP NK_INTEGER */ + -3, /* (109) db_options ::= db_options DURATION NK_INTEGER */ + -3, /* (110) db_options ::= db_options DURATION NK_VARIABLE */ + -3, /* (111) db_options ::= db_options MAXROWS NK_INTEGER */ + -3, /* (112) db_options ::= db_options MINROWS NK_INTEGER */ + -3, /* (113) db_options ::= db_options KEEP integer_list */ + -3, /* (114) db_options ::= db_options KEEP variable_list */ + -3, /* (115) db_options ::= db_options PAGES NK_INTEGER */ + -3, /* (116) db_options ::= db_options PAGESIZE NK_INTEGER */ + -3, /* (117) db_options ::= db_options TSDB_PAGESIZE NK_INTEGER */ + -3, /* (118) db_options ::= db_options PRECISION NK_STRING */ + -3, /* (119) db_options ::= db_options REPLICA NK_INTEGER */ + -3, /* (120) db_options ::= db_options VGROUPS NK_INTEGER */ + -3, /* (121) db_options ::= db_options SINGLE_STABLE NK_INTEGER */ + -3, /* (122) db_options ::= db_options RETENTIONS retention_list */ + -3, /* (123) db_options ::= db_options SCHEMALESS NK_INTEGER */ + -3, /* (124) db_options ::= db_options WAL_LEVEL NK_INTEGER */ + -3, /* (125) db_options ::= db_options WAL_FSYNC_PERIOD NK_INTEGER */ + -3, /* (126) db_options ::= db_options WAL_RETENTION_PERIOD NK_INTEGER */ + -4, /* (127) db_options ::= db_options WAL_RETENTION_PERIOD NK_MINUS NK_INTEGER */ + -3, /* (128) db_options ::= db_options WAL_RETENTION_SIZE NK_INTEGER */ + -4, /* (129) db_options ::= db_options WAL_RETENTION_SIZE NK_MINUS NK_INTEGER */ + -3, /* (130) db_options ::= db_options WAL_ROLL_PERIOD NK_INTEGER */ + -3, /* (131) db_options ::= db_options WAL_SEGMENT_SIZE NK_INTEGER */ + -3, /* (132) db_options ::= db_options STT_TRIGGER NK_INTEGER */ + -3, /* (133) db_options ::= db_options TABLE_PREFIX signed */ + -3, /* (134) db_options ::= db_options TABLE_SUFFIX signed */ + -3, /* (135) db_options ::= db_options S3_CHUNKSIZE NK_INTEGER */ + -3, /* (136) db_options ::= db_options S3_KEEPLOCAL NK_INTEGER */ + -3, /* (137) db_options ::= db_options S3_KEEPLOCAL NK_VARIABLE */ + -3, /* (138) db_options ::= db_options S3_COMPACT NK_INTEGER */ + -3, /* (139) db_options ::= db_options KEEP_TIME_OFFSET NK_INTEGER */ + -3, /* (140) db_options ::= db_options ENCRYPT_ALGORITHM NK_STRING */ + -1, /* (141) alter_db_options ::= alter_db_option */ + -2, /* (142) alter_db_options ::= alter_db_options alter_db_option */ + -2, /* (143) alter_db_option ::= BUFFER NK_INTEGER */ + -2, /* (144) alter_db_option ::= CACHEMODEL NK_STRING */ + -2, /* (145) alter_db_option ::= CACHESIZE NK_INTEGER */ + -2, /* (146) alter_db_option ::= WAL_FSYNC_PERIOD NK_INTEGER */ + -2, /* (147) alter_db_option ::= KEEP integer_list */ + -2, /* (148) alter_db_option ::= KEEP variable_list */ + -2, /* (149) alter_db_option ::= PAGES NK_INTEGER */ + -2, /* (150) alter_db_option ::= REPLICA NK_INTEGER */ + -2, /* (151) alter_db_option ::= WAL_LEVEL NK_INTEGER */ + -2, /* (152) alter_db_option ::= STT_TRIGGER NK_INTEGER */ + -2, /* (153) alter_db_option ::= MINROWS NK_INTEGER */ + -2, /* (154) alter_db_option ::= WAL_RETENTION_PERIOD NK_INTEGER */ + -3, /* (155) alter_db_option ::= WAL_RETENTION_PERIOD NK_MINUS NK_INTEGER */ + -2, /* (156) alter_db_option ::= WAL_RETENTION_SIZE NK_INTEGER */ + -3, /* (157) alter_db_option ::= WAL_RETENTION_SIZE NK_MINUS NK_INTEGER */ + -2, /* (158) alter_db_option ::= S3_KEEPLOCAL NK_INTEGER */ + -2, /* (159) alter_db_option ::= S3_KEEPLOCAL NK_VARIABLE */ + -2, /* (160) alter_db_option ::= S3_COMPACT NK_INTEGER */ + -2, /* (161) alter_db_option ::= KEEP_TIME_OFFSET NK_INTEGER */ + -2, /* (162) alter_db_option ::= ENCRYPT_ALGORITHM NK_STRING */ + -1, /* (163) integer_list ::= NK_INTEGER */ + -3, /* (164) integer_list ::= integer_list NK_COMMA NK_INTEGER */ + -1, /* (165) variable_list ::= NK_VARIABLE */ + -3, /* (166) variable_list ::= variable_list NK_COMMA NK_VARIABLE */ + -1, /* (167) retention_list ::= retention */ + -3, /* (168) retention_list ::= retention_list NK_COMMA retention */ + -3, /* (169) retention ::= NK_VARIABLE NK_COLON NK_VARIABLE */ + -3, /* (170) retention ::= NK_MINUS NK_COLON NK_VARIABLE */ 0, /* (171) speed_opt ::= */ - -2, /* (172) speed_opt ::= BWLIMIT NK_INTEGER */ + -2, /* (172) speed_opt ::= BWLIMIT NK_INTEGER */ 0, /* (173) start_opt ::= */ - -3, /* (174) start_opt ::= START WITH NK_INTEGER */ - -3, /* (175) start_opt ::= START WITH NK_STRING */ - -4, /* (176) start_opt ::= START WITH TIMESTAMP NK_STRING */ + -3, /* (174) start_opt ::= START WITH NK_INTEGER */ + -3, /* (175) start_opt ::= START WITH NK_STRING */ + -4, /* (176) start_opt ::= START WITH TIMESTAMP NK_STRING */ 0, /* (177) end_opt ::= */ - -3, /* (178) end_opt ::= END WITH NK_INTEGER */ - -3, /* (179) end_opt ::= END WITH NK_STRING */ - -4, /* (180) end_opt ::= END WITH TIMESTAMP NK_STRING */ - -9, /* (181) cmd ::= CREATE TABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def_opt table_options */ - -3, /* (182) cmd ::= CREATE TABLE multi_create_clause */ - -10, /* (183) cmd ::= CREATE TABLE not_exists_opt USING full_table_name NK_LP tag_list_opt NK_RP FILE NK_STRING */ - -9, /* (184) cmd ::= CREATE STABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def table_options */ - -3, /* (185) cmd ::= DROP TABLE multi_drop_clause */ - -4, /* (186) cmd ::= DROP STABLE exists_opt full_table_name */ - -3, /* (187) cmd ::= ALTER TABLE alter_table_clause */ - -3, /* (188) cmd ::= ALTER STABLE alter_table_clause */ - -2, /* (189) alter_table_clause ::= full_table_name alter_table_options */ - -6, /* (190) alter_table_clause ::= full_table_name ADD COLUMN column_name type_name column_options */ - -4, /* (191) alter_table_clause ::= full_table_name DROP COLUMN column_name */ - -5, /* (192) alter_table_clause ::= full_table_name MODIFY COLUMN column_name type_name */ - -5, /* (193) alter_table_clause ::= full_table_name MODIFY COLUMN column_name column_options */ - -5, /* (194) alter_table_clause ::= full_table_name RENAME COLUMN column_name column_name */ - -5, /* (195) alter_table_clause ::= full_table_name ADD TAG column_name type_name */ - -4, /* (196) alter_table_clause ::= full_table_name DROP TAG column_name */ - -5, /* (197) alter_table_clause ::= full_table_name MODIFY TAG column_name type_name */ - -5, /* (198) alter_table_clause ::= full_table_name RENAME TAG column_name column_name */ - -6, /* (199) alter_table_clause ::= full_table_name SET TAG column_name NK_EQ tags_literal */ - -1, /* (200) multi_create_clause ::= create_subtable_clause */ - -2, /* (201) multi_create_clause ::= multi_create_clause create_subtable_clause */ - -10, /* (202) create_subtable_clause ::= not_exists_opt full_table_name USING full_table_name specific_cols_opt TAGS NK_LP tags_literal_list NK_RP table_options */ - -1, /* (203) multi_drop_clause ::= drop_table_clause */ - -3, /* (204) multi_drop_clause ::= multi_drop_clause NK_COMMA drop_table_clause */ - -2, /* (205) drop_table_clause ::= exists_opt full_table_name */ - 0, /* (206) specific_cols_opt ::= */ - -3, /* (207) specific_cols_opt ::= NK_LP col_name_list NK_RP */ - -1, /* (208) full_table_name ::= table_name */ - -3, /* (209) full_table_name ::= db_name NK_DOT table_name */ - -1, /* (210) tag_def_list ::= tag_def */ - -3, /* (211) tag_def_list ::= tag_def_list NK_COMMA tag_def */ - -2, /* (212) tag_def ::= column_name type_name */ - -1, /* (213) column_def_list ::= column_def */ - -3, /* (214) column_def_list ::= column_def_list NK_COMMA column_def */ - -3, /* (215) column_def ::= column_name type_name column_options */ - -1, /* (216) type_name ::= BOOL */ - -1, /* (217) type_name ::= TINYINT */ - -1, /* (218) type_name ::= SMALLINT */ - -1, /* (219) type_name ::= INT */ - -1, /* (220) type_name ::= INTEGER */ - -1, /* (221) type_name ::= BIGINT */ - -1, /* (222) type_name ::= FLOAT */ - -1, /* (223) type_name ::= DOUBLE */ - -4, /* (224) type_name ::= BINARY NK_LP NK_INTEGER NK_RP */ - -1, /* (225) type_name ::= TIMESTAMP */ - -4, /* (226) type_name ::= NCHAR NK_LP NK_INTEGER NK_RP */ - -2, /* (227) type_name ::= TINYINT UNSIGNED */ - -2, /* (228) type_name ::= SMALLINT UNSIGNED */ - -2, /* (229) type_name ::= INT UNSIGNED */ - -2, /* (230) type_name ::= BIGINT UNSIGNED */ - -1, /* (231) type_name ::= JSON */ - -4, /* (232) type_name ::= VARCHAR NK_LP NK_INTEGER NK_RP */ - -1, /* (233) type_name ::= MEDIUMBLOB */ - -1, /* (234) type_name ::= BLOB */ - -4, /* (235) type_name ::= VARBINARY NK_LP NK_INTEGER NK_RP */ - -4, /* (236) type_name ::= GEOMETRY NK_LP NK_INTEGER NK_RP */ - -1, /* (237) type_name ::= DECIMAL */ - -4, /* (238) type_name ::= DECIMAL NK_LP NK_INTEGER NK_RP */ - -6, /* (239) type_name ::= DECIMAL NK_LP NK_INTEGER NK_COMMA NK_INTEGER NK_RP */ - -1, /* (240) type_name_default_len ::= BINARY */ - -1, /* (241) type_name_default_len ::= NCHAR */ - -1, /* (242) type_name_default_len ::= VARCHAR */ - -1, /* (243) type_name_default_len ::= VARBINARY */ - 0, /* (244) tags_def_opt ::= */ - -1, /* (245) tags_def_opt ::= tags_def */ - -4, /* (246) tags_def ::= TAGS NK_LP tag_def_list NK_RP */ - 0, /* (247) table_options ::= */ - -3, /* (248) table_options ::= table_options COMMENT NK_STRING */ - -3, /* (249) table_options ::= table_options MAX_DELAY duration_list */ - -3, /* (250) table_options ::= table_options WATERMARK duration_list */ - -5, /* (251) table_options ::= table_options ROLLUP NK_LP rollup_func_list NK_RP */ - -3, /* (252) table_options ::= table_options TTL NK_INTEGER */ - -5, /* (253) table_options ::= table_options SMA NK_LP col_name_list NK_RP */ - -3, /* (254) table_options ::= table_options DELETE_MARK duration_list */ - -1, /* (255) alter_table_options ::= alter_table_option */ - -2, /* (256) alter_table_options ::= alter_table_options alter_table_option */ - -2, /* (257) alter_table_option ::= COMMENT NK_STRING */ - -2, /* (258) alter_table_option ::= TTL NK_INTEGER */ - -1, /* (259) duration_list ::= duration_literal */ - -3, /* (260) duration_list ::= duration_list NK_COMMA duration_literal */ - -1, /* (261) rollup_func_list ::= rollup_func_name */ - -3, /* (262) rollup_func_list ::= rollup_func_list NK_COMMA rollup_func_name */ - -1, /* (263) rollup_func_name ::= function_name */ - -1, /* (264) rollup_func_name ::= FIRST */ - -1, /* (265) rollup_func_name ::= LAST */ - -1, /* (266) col_name_list ::= col_name */ - -3, /* (267) col_name_list ::= col_name_list NK_COMMA col_name */ - -1, /* (268) col_name ::= column_name */ - -2, /* (269) cmd ::= SHOW DNODES */ - -2, /* (270) cmd ::= SHOW USERS */ - -3, /* (271) cmd ::= SHOW USERS FULL */ - -3, /* (272) cmd ::= SHOW USER PRIVILEGES */ - -3, /* (273) cmd ::= SHOW db_kind_opt DATABASES */ - -4, /* (274) cmd ::= SHOW table_kind_db_name_cond_opt TABLES like_pattern_opt */ - -4, /* (275) cmd ::= SHOW db_name_cond_opt STABLES like_pattern_opt */ - -3, /* (276) cmd ::= SHOW db_name_cond_opt VGROUPS */ - -2, /* (277) cmd ::= SHOW MNODES */ - -2, /* (278) cmd ::= SHOW QNODES */ - -2, /* (279) cmd ::= SHOW ARBGROUPS */ - -2, /* (280) cmd ::= SHOW FUNCTIONS */ - -5, /* (281) cmd ::= SHOW INDEXES FROM table_name_cond from_db_opt */ - -6, /* (282) cmd ::= SHOW INDEXES FROM db_name NK_DOT table_name */ - -2, /* (283) cmd ::= SHOW STREAMS */ - -2, /* (284) cmd ::= SHOW ACCOUNTS */ - -2, /* (285) cmd ::= SHOW APPS */ - -2, /* (286) cmd ::= SHOW CONNECTIONS */ - -2, /* (287) cmd ::= SHOW LICENCES */ - -2, /* (288) cmd ::= SHOW GRANTS */ - -3, /* (289) cmd ::= SHOW GRANTS FULL */ - -3, /* (290) cmd ::= SHOW GRANTS LOGS */ - -3, /* (291) cmd ::= SHOW CLUSTER MACHINES */ - -4, /* (292) cmd ::= SHOW CREATE DATABASE db_name */ - -4, /* (293) cmd ::= SHOW CREATE TABLE full_table_name */ - -4, /* (294) cmd ::= SHOW CREATE STABLE full_table_name */ - -2, /* (295) cmd ::= SHOW ENCRYPTIONS */ - -2, /* (296) cmd ::= SHOW QUERIES */ - -2, /* (297) cmd ::= SHOW SCORES */ - -2, /* (298) cmd ::= SHOW TOPICS */ - -2, /* (299) cmd ::= SHOW VARIABLES */ - -3, /* (300) cmd ::= SHOW CLUSTER VARIABLES */ - -3, /* (301) cmd ::= SHOW LOCAL VARIABLES */ - -5, /* (302) cmd ::= SHOW DNODE NK_INTEGER VARIABLES like_pattern_opt */ - -2, /* (303) cmd ::= SHOW BNODES */ - -2, /* (304) cmd ::= SHOW SNODES */ - -2, /* (305) cmd ::= SHOW CLUSTER */ - -2, /* (306) cmd ::= SHOW TRANSACTIONS */ - -4, /* (307) cmd ::= SHOW TABLE DISTRIBUTED full_table_name */ - -2, /* (308) cmd ::= SHOW CONSUMERS */ - -2, /* (309) cmd ::= SHOW SUBSCRIPTIONS */ - -5, /* (310) cmd ::= SHOW TAGS FROM table_name_cond from_db_opt */ - -6, /* (311) cmd ::= SHOW TAGS FROM db_name NK_DOT table_name */ - -7, /* (312) cmd ::= SHOW TABLE TAGS tag_list_opt FROM table_name_cond from_db_opt */ - -8, /* (313) cmd ::= SHOW TABLE TAGS tag_list_opt FROM db_name NK_DOT table_name */ - -5, /* (314) cmd ::= SHOW VNODES ON DNODE NK_INTEGER */ - -2, /* (315) cmd ::= SHOW VNODES */ - -3, /* (316) cmd ::= SHOW db_name_cond_opt ALIVE */ - -3, /* (317) cmd ::= SHOW CLUSTER ALIVE */ - -4, /* (318) cmd ::= SHOW db_name_cond_opt VIEWS like_pattern_opt */ - -4, /* (319) cmd ::= SHOW CREATE VIEW full_table_name */ - -2, /* (320) cmd ::= SHOW COMPACTS */ - -3, /* (321) cmd ::= SHOW COMPACT NK_INTEGER */ - 0, /* (322) table_kind_db_name_cond_opt ::= */ - -1, /* (323) table_kind_db_name_cond_opt ::= table_kind */ - -2, /* (324) table_kind_db_name_cond_opt ::= db_name NK_DOT */ - -3, /* (325) table_kind_db_name_cond_opt ::= table_kind db_name NK_DOT */ - -1, /* (326) table_kind ::= NORMAL */ - -1, /* (327) table_kind ::= CHILD */ - 0, /* (328) db_name_cond_opt ::= */ - -2, /* (329) db_name_cond_opt ::= db_name NK_DOT */ - 0, /* (330) like_pattern_opt ::= */ - -2, /* (331) like_pattern_opt ::= LIKE NK_STRING */ - -1, /* (332) table_name_cond ::= table_name */ - 0, /* (333) from_db_opt ::= */ - -2, /* (334) from_db_opt ::= FROM db_name */ - 0, /* (335) tag_list_opt ::= */ - -1, /* (336) tag_list_opt ::= tag_item */ - -3, /* (337) tag_list_opt ::= tag_list_opt NK_COMMA tag_item */ - -1, /* (338) tag_item ::= TBNAME */ - -1, /* (339) tag_item ::= QTAGS */ - -1, /* (340) tag_item ::= column_name */ - -2, /* (341) tag_item ::= column_name column_alias */ - -3, /* (342) tag_item ::= column_name AS column_alias */ - 0, /* (343) db_kind_opt ::= */ - -1, /* (344) db_kind_opt ::= USER */ - -1, /* (345) db_kind_opt ::= SYSTEM */ - -11, /* (346) cmd ::= CREATE TSMA not_exists_opt tsma_name ON full_table_name tsma_func_list INTERVAL NK_LP duration_literal NK_RP */ - -11, /* (347) cmd ::= CREATE RECURSIVE TSMA not_exists_opt tsma_name ON full_table_name INTERVAL NK_LP duration_literal NK_RP */ - -4, /* (348) cmd ::= DROP TSMA exists_opt full_tsma_name */ - -3, /* (349) cmd ::= SHOW db_name_cond_opt TSMAS */ - -1, /* (350) full_tsma_name ::= tsma_name */ - -3, /* (351) full_tsma_name ::= db_name NK_DOT tsma_name */ - -4, /* (352) tsma_func_list ::= FUNCTION NK_LP func_list NK_RP */ - -8, /* (353) cmd ::= CREATE SMA INDEX not_exists_opt col_name ON full_table_name index_options */ - -9, /* (354) cmd ::= CREATE INDEX not_exists_opt col_name ON full_table_name NK_LP col_name_list NK_RP */ - -4, /* (355) cmd ::= DROP INDEX exists_opt full_index_name */ - -1, /* (356) full_index_name ::= index_name */ - -3, /* (357) full_index_name ::= db_name NK_DOT index_name */ - -10, /* (358) index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_RP sliding_opt sma_stream_opt */ - -12, /* (359) index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_COMMA duration_literal NK_RP sliding_opt sma_stream_opt */ - -1, /* (360) func_list ::= func */ - -3, /* (361) func_list ::= func_list NK_COMMA func */ - -4, /* (362) func ::= sma_func_name NK_LP expression_list NK_RP */ - -1, /* (363) sma_func_name ::= function_name */ - -1, /* (364) sma_func_name ::= COUNT */ - -1, /* (365) sma_func_name ::= FIRST */ - -1, /* (366) sma_func_name ::= LAST */ - -1, /* (367) sma_func_name ::= LAST_ROW */ - 0, /* (368) sma_stream_opt ::= */ - -3, /* (369) sma_stream_opt ::= sma_stream_opt WATERMARK duration_literal */ - -3, /* (370) sma_stream_opt ::= sma_stream_opt MAX_DELAY duration_literal */ - -3, /* (371) sma_stream_opt ::= sma_stream_opt DELETE_MARK duration_literal */ - -1, /* (372) with_meta ::= AS */ - -3, /* (373) with_meta ::= WITH META AS */ - -3, /* (374) with_meta ::= ONLY META AS */ - -6, /* (375) cmd ::= CREATE TOPIC not_exists_opt topic_name AS query_or_subquery */ - -7, /* (376) cmd ::= CREATE TOPIC not_exists_opt topic_name with_meta DATABASE db_name */ - -8, /* (377) cmd ::= CREATE TOPIC not_exists_opt topic_name with_meta STABLE full_table_name where_clause_opt */ - -4, /* (378) cmd ::= DROP TOPIC exists_opt topic_name */ - -7, /* (379) cmd ::= DROP CONSUMER GROUP exists_opt cgroup_name ON topic_name */ - -2, /* (380) cmd ::= DESC full_table_name */ - -2, /* (381) cmd ::= DESCRIBE full_table_name */ - -3, /* (382) cmd ::= RESET QUERY CACHE */ - -4, /* (383) cmd ::= EXPLAIN analyze_opt explain_options query_or_subquery */ - -4, /* (384) cmd ::= EXPLAIN analyze_opt explain_options insert_query */ - 0, /* (385) analyze_opt ::= */ - -1, /* (386) analyze_opt ::= ANALYZE */ - 0, /* (387) explain_options ::= */ - -3, /* (388) explain_options ::= explain_options VERBOSE NK_BOOL */ - -3, /* (389) explain_options ::= explain_options RATIO NK_FLOAT */ - -12, /* (390) cmd ::= CREATE or_replace_opt agg_func_opt FUNCTION not_exists_opt function_name AS NK_STRING OUTPUTTYPE type_name bufsize_opt language_opt */ - -4, /* (391) cmd ::= DROP FUNCTION exists_opt function_name */ - 0, /* (392) agg_func_opt ::= */ - -1, /* (393) agg_func_opt ::= AGGREGATE */ - 0, /* (394) bufsize_opt ::= */ - -2, /* (395) bufsize_opt ::= BUFSIZE NK_INTEGER */ - 0, /* (396) language_opt ::= */ - -2, /* (397) language_opt ::= LANGUAGE NK_STRING */ - 0, /* (398) or_replace_opt ::= */ - -2, /* (399) or_replace_opt ::= OR REPLACE */ - -6, /* (400) cmd ::= CREATE or_replace_opt VIEW full_view_name AS query_or_subquery */ - -4, /* (401) cmd ::= DROP VIEW exists_opt full_view_name */ - -1, /* (402) full_view_name ::= view_name */ - -3, /* (403) full_view_name ::= db_name NK_DOT view_name */ - -12, /* (404) cmd ::= CREATE STREAM not_exists_opt stream_name stream_options INTO full_table_name col_list_opt tag_def_or_ref_opt subtable_opt AS query_or_subquery */ - -4, /* (405) cmd ::= DROP STREAM exists_opt stream_name */ - -4, /* (406) cmd ::= PAUSE STREAM exists_opt stream_name */ - -5, /* (407) cmd ::= RESUME STREAM exists_opt ignore_opt stream_name */ - 0, /* (408) col_list_opt ::= */ - -3, /* (409) col_list_opt ::= NK_LP column_stream_def_list NK_RP */ - -1, /* (410) column_stream_def_list ::= column_stream_def */ - -3, /* (411) column_stream_def_list ::= column_stream_def_list NK_COMMA column_stream_def */ - -2, /* (412) column_stream_def ::= column_name stream_col_options */ - 0, /* (413) stream_col_options ::= */ - -3, /* (414) stream_col_options ::= stream_col_options PRIMARY KEY */ - 0, /* (415) tag_def_or_ref_opt ::= */ - -1, /* (416) tag_def_or_ref_opt ::= tags_def */ - -4, /* (417) tag_def_or_ref_opt ::= TAGS NK_LP column_stream_def_list NK_RP */ - 0, /* (418) stream_options ::= */ - -3, /* (419) stream_options ::= stream_options TRIGGER AT_ONCE */ - -3, /* (420) stream_options ::= stream_options TRIGGER WINDOW_CLOSE */ - -4, /* (421) stream_options ::= stream_options TRIGGER MAX_DELAY duration_literal */ - -3, /* (422) stream_options ::= stream_options WATERMARK duration_literal */ - -4, /* (423) stream_options ::= stream_options IGNORE EXPIRED NK_INTEGER */ - -3, /* (424) stream_options ::= stream_options FILL_HISTORY NK_INTEGER */ - -3, /* (425) stream_options ::= stream_options DELETE_MARK duration_literal */ - -4, /* (426) stream_options ::= stream_options IGNORE UPDATE NK_INTEGER */ - 0, /* (427) subtable_opt ::= */ - -4, /* (428) subtable_opt ::= SUBTABLE NK_LP expression NK_RP */ - 0, /* (429) ignore_opt ::= */ - -2, /* (430) ignore_opt ::= IGNORE UNTREATED */ - -3, /* (431) cmd ::= KILL CONNECTION NK_INTEGER */ - -3, /* (432) cmd ::= KILL QUERY NK_STRING */ - -3, /* (433) cmd ::= KILL TRANSACTION NK_INTEGER */ - -3, /* (434) cmd ::= KILL COMPACT NK_INTEGER */ - -2, /* (435) cmd ::= BALANCE VGROUP */ - -4, /* (436) cmd ::= BALANCE VGROUP LEADER on_vgroup_id */ - -5, /* (437) cmd ::= BALANCE VGROUP LEADER DATABASE db_name */ - -4, /* (438) cmd ::= MERGE VGROUP NK_INTEGER NK_INTEGER */ - -4, /* (439) cmd ::= REDISTRIBUTE VGROUP NK_INTEGER dnode_list */ - -3, /* (440) cmd ::= SPLIT VGROUP NK_INTEGER */ - 0, /* (441) on_vgroup_id ::= */ - -2, /* (442) on_vgroup_id ::= ON NK_INTEGER */ - -2, /* (443) dnode_list ::= DNODE NK_INTEGER */ - -3, /* (444) dnode_list ::= dnode_list DNODE NK_INTEGER */ - -4, /* (445) cmd ::= DELETE FROM full_table_name where_clause_opt */ - -1, /* (446) cmd ::= query_or_subquery */ - -1, /* (447) cmd ::= insert_query */ - -7, /* (448) insert_query ::= INSERT INTO full_table_name NK_LP col_name_list NK_RP query_or_subquery */ - -4, /* (449) insert_query ::= INSERT INTO full_table_name query_or_subquery */ - -1, /* (450) tags_literal ::= NK_INTEGER */ - -3, /* (451) tags_literal ::= NK_INTEGER NK_PLUS duration_literal */ - -3, /* (452) tags_literal ::= NK_INTEGER NK_MINUS duration_literal */ - -2, /* (453) tags_literal ::= NK_PLUS NK_INTEGER */ - -4, /* (454) tags_literal ::= NK_PLUS NK_INTEGER NK_PLUS duration_literal */ - -4, /* (455) tags_literal ::= NK_PLUS NK_INTEGER NK_MINUS duration_literal */ - -2, /* (456) tags_literal ::= NK_MINUS NK_INTEGER */ - -4, /* (457) tags_literal ::= NK_MINUS NK_INTEGER NK_PLUS duration_literal */ - -4, /* (458) tags_literal ::= NK_MINUS NK_INTEGER NK_MINUS duration_literal */ - -1, /* (459) tags_literal ::= NK_FLOAT */ - -2, /* (460) tags_literal ::= NK_PLUS NK_FLOAT */ - -2, /* (461) tags_literal ::= NK_MINUS NK_FLOAT */ - -1, /* (462) tags_literal ::= NK_BIN */ - -3, /* (463) tags_literal ::= NK_BIN NK_PLUS duration_literal */ - -3, /* (464) tags_literal ::= NK_BIN NK_MINUS duration_literal */ - -2, /* (465) tags_literal ::= NK_PLUS NK_BIN */ - -4, /* (466) tags_literal ::= NK_PLUS NK_BIN NK_PLUS duration_literal */ - -4, /* (467) tags_literal ::= NK_PLUS NK_BIN NK_MINUS duration_literal */ - -2, /* (468) tags_literal ::= NK_MINUS NK_BIN */ - -4, /* (469) tags_literal ::= NK_MINUS NK_BIN NK_PLUS duration_literal */ - -4, /* (470) tags_literal ::= NK_MINUS NK_BIN NK_MINUS duration_literal */ - -1, /* (471) tags_literal ::= NK_HEX */ - -3, /* (472) tags_literal ::= NK_HEX NK_PLUS duration_literal */ - -3, /* (473) tags_literal ::= NK_HEX NK_MINUS duration_literal */ - -2, /* (474) tags_literal ::= NK_PLUS NK_HEX */ - -4, /* (475) tags_literal ::= NK_PLUS NK_HEX NK_PLUS duration_literal */ - -4, /* (476) tags_literal ::= NK_PLUS NK_HEX NK_MINUS duration_literal */ - -2, /* (477) tags_literal ::= NK_MINUS NK_HEX */ - -4, /* (478) tags_literal ::= NK_MINUS NK_HEX NK_PLUS duration_literal */ - -4, /* (479) tags_literal ::= NK_MINUS NK_HEX NK_MINUS duration_literal */ - -1, /* (480) tags_literal ::= NK_STRING */ - -3, /* (481) tags_literal ::= NK_STRING NK_PLUS duration_literal */ - -3, /* (482) tags_literal ::= NK_STRING NK_MINUS duration_literal */ - -1, /* (483) tags_literal ::= NK_BOOL */ - -1, /* (484) tags_literal ::= NULL */ - -1, /* (485) tags_literal ::= literal_func */ - -3, /* (486) tags_literal ::= literal_func NK_PLUS duration_literal */ - -3, /* (487) tags_literal ::= literal_func NK_MINUS duration_literal */ - -1, /* (488) tags_literal_list ::= tags_literal */ - -3, /* (489) tags_literal_list ::= tags_literal_list NK_COMMA tags_literal */ - -1, /* (490) literal ::= NK_INTEGER */ - -1, /* (491) literal ::= NK_FLOAT */ - -1, /* (492) literal ::= NK_STRING */ - -1, /* (493) literal ::= NK_BOOL */ - -2, /* (494) literal ::= TIMESTAMP NK_STRING */ - -1, /* (495) literal ::= duration_literal */ - -1, /* (496) literal ::= NULL */ - -1, /* (497) literal ::= NK_QUESTION */ - -1, /* (498) duration_literal ::= NK_VARIABLE */ - -1, /* (499) signed ::= NK_INTEGER */ - -2, /* (500) signed ::= NK_PLUS NK_INTEGER */ - -2, /* (501) signed ::= NK_MINUS NK_INTEGER */ - -1, /* (502) signed ::= NK_FLOAT */ - -2, /* (503) signed ::= NK_PLUS NK_FLOAT */ - -2, /* (504) signed ::= NK_MINUS NK_FLOAT */ - -1, /* (505) signed_literal ::= signed */ - -1, /* (506) signed_literal ::= NK_STRING */ - -1, /* (507) signed_literal ::= NK_BOOL */ - -2, /* (508) signed_literal ::= TIMESTAMP NK_STRING */ - -1, /* (509) signed_literal ::= duration_literal */ - -1, /* (510) signed_literal ::= NULL */ - -1, /* (511) signed_literal ::= literal_func */ - -1, /* (512) signed_literal ::= NK_QUESTION */ - -1, /* (513) literal_list ::= signed_literal */ - -3, /* (514) literal_list ::= literal_list NK_COMMA signed_literal */ - -1, /* (515) db_name ::= NK_ID */ - -1, /* (516) table_name ::= NK_ID */ - -1, /* (517) column_name ::= NK_ID */ - -1, /* (518) function_name ::= NK_ID */ - -1, /* (519) view_name ::= NK_ID */ - -1, /* (520) table_alias ::= NK_ID */ - -1, /* (521) column_alias ::= NK_ID */ - -1, /* (522) column_alias ::= NK_ALIAS */ - -1, /* (523) user_name ::= NK_ID */ - -1, /* (524) topic_name ::= NK_ID */ - -1, /* (525) stream_name ::= NK_ID */ - -1, /* (526) cgroup_name ::= NK_ID */ - -1, /* (527) index_name ::= NK_ID */ - -1, /* (528) tsma_name ::= NK_ID */ - -1, /* (529) expr_or_subquery ::= expression */ - -1, /* (530) expression ::= literal */ - -1, /* (531) expression ::= pseudo_column */ - -1, /* (532) expression ::= column_reference */ - -1, /* (533) expression ::= function_expression */ - -1, /* (534) expression ::= case_when_expression */ - -3, /* (535) expression ::= NK_LP expression NK_RP */ - -2, /* (536) expression ::= NK_PLUS expr_or_subquery */ - -2, /* (537) expression ::= NK_MINUS expr_or_subquery */ - -3, /* (538) expression ::= expr_or_subquery NK_PLUS expr_or_subquery */ - -3, /* (539) expression ::= expr_or_subquery NK_MINUS expr_or_subquery */ - -3, /* (540) expression ::= expr_or_subquery NK_STAR expr_or_subquery */ - -3, /* (541) expression ::= expr_or_subquery NK_SLASH expr_or_subquery */ - -3, /* (542) expression ::= expr_or_subquery NK_REM expr_or_subquery */ - -3, /* (543) expression ::= column_reference NK_ARROW NK_STRING */ - -3, /* (544) expression ::= expr_or_subquery NK_BITAND expr_or_subquery */ - -3, /* (545) expression ::= expr_or_subquery NK_BITOR expr_or_subquery */ - -1, /* (546) expression_list ::= expr_or_subquery */ - -3, /* (547) expression_list ::= expression_list NK_COMMA expr_or_subquery */ - -1, /* (548) column_reference ::= column_name */ - -3, /* (549) column_reference ::= table_name NK_DOT column_name */ - -1, /* (550) column_reference ::= NK_ALIAS */ - -3, /* (551) column_reference ::= table_name NK_DOT NK_ALIAS */ - -1, /* (552) pseudo_column ::= ROWTS */ - -1, /* (553) pseudo_column ::= TBNAME */ - -3, /* (554) pseudo_column ::= table_name NK_DOT TBNAME */ - -1, /* (555) pseudo_column ::= QSTART */ - -1, /* (556) pseudo_column ::= QEND */ - -1, /* (557) pseudo_column ::= QDURATION */ - -1, /* (558) pseudo_column ::= WSTART */ - -1, /* (559) pseudo_column ::= WEND */ - -1, /* (560) pseudo_column ::= WDURATION */ - -1, /* (561) pseudo_column ::= IROWTS */ - -1, /* (562) pseudo_column ::= ISFILLED */ - -1, /* (563) pseudo_column ::= QTAGS */ - -4, /* (564) function_expression ::= function_name NK_LP expression_list NK_RP */ - -4, /* (565) function_expression ::= star_func NK_LP star_func_para_list NK_RP */ - -6, /* (566) function_expression ::= CAST NK_LP expr_or_subquery AS type_name NK_RP */ - -6, /* (567) function_expression ::= CAST NK_LP expr_or_subquery AS type_name_default_len NK_RP */ - -6, /* (568) function_expression ::= POSITION NK_LP expr_or_subquery IN expr_or_subquery NK_RP */ - -4, /* (569) function_expression ::= TRIM NK_LP expr_or_subquery NK_RP */ - -6, /* (570) function_expression ::= TRIM NK_LP trim_specification_type FROM expr_or_subquery NK_RP */ - -6, /* (571) function_expression ::= TRIM NK_LP expr_or_subquery FROM expr_or_subquery NK_RP */ - -7, /* (572) function_expression ::= TRIM NK_LP trim_specification_type expr_or_subquery FROM expr_or_subquery NK_RP */ - -4, /* (573) function_expression ::= substr_func NK_LP expression_list NK_RP */ - -6, /* (574) function_expression ::= substr_func NK_LP expr_or_subquery FROM expr_or_subquery NK_RP */ - -8, /* (575) function_expression ::= substr_func NK_LP expr_or_subquery FROM expr_or_subquery FOR expr_or_subquery NK_RP */ - -4, /* (576) function_expression ::= REPLACE NK_LP expression_list NK_RP */ - -1, /* (577) function_expression ::= literal_func */ - -1, /* (578) function_expression ::= rand_func */ - -3, /* (579) literal_func ::= noarg_func NK_LP NK_RP */ - -1, /* (580) literal_func ::= NOW */ - -1, /* (581) literal_func ::= TODAY */ - -3, /* (582) rand_func ::= RAND NK_LP NK_RP */ - -4, /* (583) rand_func ::= RAND NK_LP expression_list NK_RP */ - -1, /* (584) substr_func ::= SUBSTR */ - -1, /* (585) substr_func ::= SUBSTRING */ - -1, /* (586) trim_specification_type ::= BOTH */ - -1, /* (587) trim_specification_type ::= TRAILING */ - -1, /* (588) trim_specification_type ::= LEADING */ - -1, /* (589) noarg_func ::= NOW */ - -1, /* (590) noarg_func ::= TODAY */ - -1, /* (591) noarg_func ::= TIMEZONE */ - -1, /* (592) noarg_func ::= DATABASE */ - -1, /* (593) noarg_func ::= CLIENT_VERSION */ - -1, /* (594) noarg_func ::= SERVER_VERSION */ - -1, /* (595) noarg_func ::= SERVER_STATUS */ - -1, /* (596) noarg_func ::= CURRENT_USER */ - -1, /* (597) noarg_func ::= USER */ - -1, /* (598) noarg_func ::= PI */ - -1, /* (599) star_func ::= COUNT */ - -1, /* (600) star_func ::= FIRST */ - -1, /* (601) star_func ::= LAST */ - -1, /* (602) star_func ::= LAST_ROW */ - -1, /* (603) star_func_para_list ::= NK_STAR */ - -1, /* (604) star_func_para_list ::= other_para_list */ - -1, /* (605) other_para_list ::= star_func_para */ - -3, /* (606) other_para_list ::= other_para_list NK_COMMA star_func_para */ - -1, /* (607) star_func_para ::= expr_or_subquery */ - -3, /* (608) star_func_para ::= table_name NK_DOT NK_STAR */ - -4, /* (609) case_when_expression ::= CASE when_then_list case_when_else_opt END */ - -5, /* (610) case_when_expression ::= CASE common_expression when_then_list case_when_else_opt END */ - -1, /* (611) when_then_list ::= when_then_expr */ - -2, /* (612) when_then_list ::= when_then_list when_then_expr */ - -4, /* (613) when_then_expr ::= WHEN common_expression THEN common_expression */ - 0, /* (614) case_when_else_opt ::= */ - -2, /* (615) case_when_else_opt ::= ELSE common_expression */ - -3, /* (616) predicate ::= expr_or_subquery compare_op expr_or_subquery */ - -5, /* (617) predicate ::= expr_or_subquery BETWEEN expr_or_subquery AND expr_or_subquery */ - -6, /* (618) predicate ::= expr_or_subquery NOT BETWEEN expr_or_subquery AND expr_or_subquery */ - -3, /* (619) predicate ::= expr_or_subquery IS NULL */ - -4, /* (620) predicate ::= expr_or_subquery IS NOT NULL */ - -3, /* (621) predicate ::= expr_or_subquery in_op in_predicate_value */ - -1, /* (622) compare_op ::= NK_LT */ - -1, /* (623) compare_op ::= NK_GT */ - -1, /* (624) compare_op ::= NK_LE */ - -1, /* (625) compare_op ::= NK_GE */ - -1, /* (626) compare_op ::= NK_NE */ - -1, /* (627) compare_op ::= NK_EQ */ - -1, /* (628) compare_op ::= LIKE */ - -2, /* (629) compare_op ::= NOT LIKE */ - -1, /* (630) compare_op ::= MATCH */ - -1, /* (631) compare_op ::= NMATCH */ - -1, /* (632) compare_op ::= CONTAINS */ - -1, /* (633) in_op ::= IN */ - -2, /* (634) in_op ::= NOT IN */ - -3, /* (635) in_predicate_value ::= NK_LP literal_list NK_RP */ - -1, /* (636) boolean_value_expression ::= boolean_primary */ - -2, /* (637) boolean_value_expression ::= NOT boolean_primary */ - -3, /* (638) boolean_value_expression ::= boolean_value_expression OR boolean_value_expression */ - -3, /* (639) boolean_value_expression ::= boolean_value_expression AND boolean_value_expression */ - -1, /* (640) boolean_primary ::= predicate */ - -3, /* (641) boolean_primary ::= NK_LP boolean_value_expression NK_RP */ - -1, /* (642) common_expression ::= expr_or_subquery */ - -1, /* (643) common_expression ::= boolean_value_expression */ - 0, /* (644) from_clause_opt ::= */ - -2, /* (645) from_clause_opt ::= FROM table_reference_list */ - -1, /* (646) table_reference_list ::= table_reference */ - -3, /* (647) table_reference_list ::= table_reference_list NK_COMMA table_reference */ - -1, /* (648) table_reference ::= table_primary */ - -1, /* (649) table_reference ::= joined_table */ - -2, /* (650) table_primary ::= table_name alias_opt */ - -4, /* (651) table_primary ::= db_name NK_DOT table_name alias_opt */ - -2, /* (652) table_primary ::= subquery alias_opt */ - -1, /* (653) table_primary ::= parenthesized_joined_table */ - 0, /* (654) alias_opt ::= */ - -1, /* (655) alias_opt ::= table_alias */ - -2, /* (656) alias_opt ::= AS table_alias */ - -3, /* (657) parenthesized_joined_table ::= NK_LP joined_table NK_RP */ - -3, /* (658) parenthesized_joined_table ::= NK_LP parenthesized_joined_table NK_RP */ - -8, /* (659) joined_table ::= table_reference join_type join_subtype JOIN table_reference join_on_clause_opt window_offset_clause_opt jlimit_clause_opt */ - 0, /* (660) join_type ::= */ - -1, /* (661) join_type ::= INNER */ - -1, /* (662) join_type ::= LEFT */ - -1, /* (663) join_type ::= RIGHT */ - -1, /* (664) join_type ::= FULL */ - 0, /* (665) join_subtype ::= */ - -1, /* (666) join_subtype ::= OUTER */ - -1, /* (667) join_subtype ::= SEMI */ - -1, /* (668) join_subtype ::= ANTI */ - -1, /* (669) join_subtype ::= ASOF */ - -1, /* (670) join_subtype ::= WINDOW */ - 0, /* (671) join_on_clause_opt ::= */ - -2, /* (672) join_on_clause_opt ::= ON search_condition */ - 0, /* (673) window_offset_clause_opt ::= */ - -6, /* (674) window_offset_clause_opt ::= WINDOW_OFFSET NK_LP window_offset_literal NK_COMMA window_offset_literal NK_RP */ - -1, /* (675) window_offset_literal ::= NK_VARIABLE */ - -2, /* (676) window_offset_literal ::= NK_MINUS NK_VARIABLE */ - 0, /* (677) jlimit_clause_opt ::= */ - -2, /* (678) jlimit_clause_opt ::= JLIMIT NK_INTEGER */ - -14, /* (679) query_specification ::= SELECT hint_list set_quantifier_opt tag_mode_opt select_list from_clause_opt where_clause_opt partition_by_clause_opt range_opt every_opt fill_opt twindow_clause_opt group_by_clause_opt having_clause_opt */ - 0, /* (680) hint_list ::= */ - -1, /* (681) hint_list ::= NK_HINT */ - 0, /* (682) tag_mode_opt ::= */ - -1, /* (683) tag_mode_opt ::= TAGS */ - 0, /* (684) set_quantifier_opt ::= */ - -1, /* (685) set_quantifier_opt ::= DISTINCT */ - -1, /* (686) set_quantifier_opt ::= ALL */ - -1, /* (687) select_list ::= select_item */ - -3, /* (688) select_list ::= select_list NK_COMMA select_item */ - -1, /* (689) select_item ::= NK_STAR */ - -1, /* (690) select_item ::= common_expression */ - -2, /* (691) select_item ::= common_expression column_alias */ - -3, /* (692) select_item ::= common_expression AS column_alias */ - -3, /* (693) select_item ::= table_name NK_DOT NK_STAR */ - 0, /* (694) where_clause_opt ::= */ - -2, /* (695) where_clause_opt ::= WHERE search_condition */ - 0, /* (696) partition_by_clause_opt ::= */ - -3, /* (697) partition_by_clause_opt ::= PARTITION BY partition_list */ - -1, /* (698) partition_list ::= partition_item */ - -3, /* (699) partition_list ::= partition_list NK_COMMA partition_item */ - -1, /* (700) partition_item ::= expr_or_subquery */ - -2, /* (701) partition_item ::= expr_or_subquery column_alias */ - -3, /* (702) partition_item ::= expr_or_subquery AS column_alias */ - 0, /* (703) twindow_clause_opt ::= */ - -6, /* (704) twindow_clause_opt ::= SESSION NK_LP column_reference NK_COMMA interval_sliding_duration_literal NK_RP */ - -4, /* (705) twindow_clause_opt ::= STATE_WINDOW NK_LP expr_or_subquery NK_RP */ - -6, /* (706) twindow_clause_opt ::= INTERVAL NK_LP interval_sliding_duration_literal NK_RP sliding_opt fill_opt */ - -8, /* (707) twindow_clause_opt ::= INTERVAL NK_LP interval_sliding_duration_literal NK_COMMA interval_sliding_duration_literal NK_RP sliding_opt fill_opt */ - -7, /* (708) twindow_clause_opt ::= EVENT_WINDOW START WITH search_condition END WITH search_condition */ - -4, /* (709) twindow_clause_opt ::= COUNT_WINDOW NK_LP NK_INTEGER NK_RP */ - -6, /* (710) twindow_clause_opt ::= COUNT_WINDOW NK_LP NK_INTEGER NK_COMMA NK_INTEGER NK_RP */ - 0, /* (711) sliding_opt ::= */ - -4, /* (712) sliding_opt ::= SLIDING NK_LP interval_sliding_duration_literal NK_RP */ - -1, /* (713) interval_sliding_duration_literal ::= NK_VARIABLE */ - -1, /* (714) interval_sliding_duration_literal ::= NK_STRING */ - -1, /* (715) interval_sliding_duration_literal ::= NK_INTEGER */ - 0, /* (716) fill_opt ::= */ - -4, /* (717) fill_opt ::= FILL NK_LP fill_mode NK_RP */ - -6, /* (718) fill_opt ::= FILL NK_LP VALUE NK_COMMA expression_list NK_RP */ - -6, /* (719) fill_opt ::= FILL NK_LP VALUE_F NK_COMMA expression_list NK_RP */ - -1, /* (720) fill_mode ::= NONE */ - -1, /* (721) fill_mode ::= PREV */ - -1, /* (722) fill_mode ::= NULL */ - -1, /* (723) fill_mode ::= NULL_F */ - -1, /* (724) fill_mode ::= LINEAR */ - -1, /* (725) fill_mode ::= NEXT */ - 0, /* (726) group_by_clause_opt ::= */ - -3, /* (727) group_by_clause_opt ::= GROUP BY group_by_list */ - -1, /* (728) group_by_list ::= expr_or_subquery */ - -3, /* (729) group_by_list ::= group_by_list NK_COMMA expr_or_subquery */ - 0, /* (730) having_clause_opt ::= */ - -2, /* (731) having_clause_opt ::= HAVING search_condition */ - 0, /* (732) range_opt ::= */ - -6, /* (733) range_opt ::= RANGE NK_LP expr_or_subquery NK_COMMA expr_or_subquery NK_RP */ - -4, /* (734) range_opt ::= RANGE NK_LP expr_or_subquery NK_RP */ - 0, /* (735) every_opt ::= */ - -4, /* (736) every_opt ::= EVERY NK_LP duration_literal NK_RP */ - -4, /* (737) query_expression ::= query_simple order_by_clause_opt slimit_clause_opt limit_clause_opt */ - -1, /* (738) query_simple ::= query_specification */ - -1, /* (739) query_simple ::= union_query_expression */ - -4, /* (740) union_query_expression ::= query_simple_or_subquery UNION ALL query_simple_or_subquery */ - -3, /* (741) union_query_expression ::= query_simple_or_subquery UNION query_simple_or_subquery */ - -1, /* (742) query_simple_or_subquery ::= query_simple */ - -1, /* (743) query_simple_or_subquery ::= subquery */ - -1, /* (744) query_or_subquery ::= query_expression */ - -1, /* (745) query_or_subquery ::= subquery */ - 0, /* (746) order_by_clause_opt ::= */ - -3, /* (747) order_by_clause_opt ::= ORDER BY sort_specification_list */ - 0, /* (748) slimit_clause_opt ::= */ - -2, /* (749) slimit_clause_opt ::= SLIMIT NK_INTEGER */ - -4, /* (750) slimit_clause_opt ::= SLIMIT NK_INTEGER SOFFSET NK_INTEGER */ - -4, /* (751) slimit_clause_opt ::= SLIMIT NK_INTEGER NK_COMMA NK_INTEGER */ - 0, /* (752) limit_clause_opt ::= */ - -2, /* (753) limit_clause_opt ::= LIMIT NK_INTEGER */ - -4, /* (754) limit_clause_opt ::= LIMIT NK_INTEGER OFFSET NK_INTEGER */ - -4, /* (755) limit_clause_opt ::= LIMIT NK_INTEGER NK_COMMA NK_INTEGER */ - -3, /* (756) subquery ::= NK_LP query_expression NK_RP */ - -3, /* (757) subquery ::= NK_LP subquery NK_RP */ - -1, /* (758) search_condition ::= common_expression */ - -1, /* (759) sort_specification_list ::= sort_specification */ - -3, /* (760) sort_specification_list ::= sort_specification_list NK_COMMA sort_specification */ - -3, /* (761) sort_specification ::= expr_or_subquery ordering_specification_opt null_ordering_opt */ - 0, /* (762) ordering_specification_opt ::= */ - -1, /* (763) ordering_specification_opt ::= ASC */ - -1, /* (764) ordering_specification_opt ::= DESC */ - 0, /* (765) null_ordering_opt ::= */ - -2, /* (766) null_ordering_opt ::= NULLS FIRST */ - -2, /* (767) null_ordering_opt ::= NULLS LAST */ - 0, /* (768) column_options ::= */ - -3, /* (769) column_options ::= column_options PRIMARY KEY */ - -3, /* (770) column_options ::= column_options NK_ID NK_STRING */ + -3, /* (178) end_opt ::= END WITH NK_INTEGER */ + -3, /* (179) end_opt ::= END WITH NK_STRING */ + -4, /* (180) end_opt ::= END WITH TIMESTAMP NK_STRING */ + -9, /* (181) cmd ::= CREATE TABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def_opt table_options */ + -3, /* (182) cmd ::= CREATE TABLE multi_create_clause */ + -10, /* (183) cmd ::= CREATE TABLE not_exists_opt USING full_table_name NK_LP tag_list_opt NK_RP FILE NK_STRING */ + -9, /* (184) cmd ::= CREATE STABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def table_options */ + -4, /* (185) cmd ::= DROP TABLE with_opt multi_drop_clause */ + -5, /* (186) cmd ::= DROP STABLE with_opt exists_opt full_table_name */ + -3, /* (187) cmd ::= ALTER TABLE alter_table_clause */ + -3, /* (188) cmd ::= ALTER STABLE alter_table_clause */ + -2, /* (189) alter_table_clause ::= full_table_name alter_table_options */ + -6, /* (190) alter_table_clause ::= full_table_name ADD COLUMN column_name type_name column_options */ + -4, /* (191) alter_table_clause ::= full_table_name DROP COLUMN column_name */ + -5, /* (192) alter_table_clause ::= full_table_name MODIFY COLUMN column_name type_name */ + -5, /* (193) alter_table_clause ::= full_table_name MODIFY COLUMN column_name column_options */ + -5, /* (194) alter_table_clause ::= full_table_name RENAME COLUMN column_name column_name */ + -5, /* (195) alter_table_clause ::= full_table_name ADD TAG column_name type_name */ + -4, /* (196) alter_table_clause ::= full_table_name DROP TAG column_name */ + -5, /* (197) alter_table_clause ::= full_table_name MODIFY TAG column_name type_name */ + -5, /* (198) alter_table_clause ::= full_table_name RENAME TAG column_name column_name */ + -6, /* (199) alter_table_clause ::= full_table_name SET TAG column_name NK_EQ tags_literal */ + -1, /* (200) multi_create_clause ::= create_subtable_clause */ + -2, /* (201) multi_create_clause ::= multi_create_clause create_subtable_clause */ + -10, /* (202) create_subtable_clause ::= not_exists_opt full_table_name USING full_table_name specific_cols_opt TAGS NK_LP tags_literal_list NK_RP table_options */ + -1, /* (203) multi_drop_clause ::= drop_table_clause */ + -3, /* (204) multi_drop_clause ::= multi_drop_clause NK_COMMA drop_table_clause */ + -2, /* (205) drop_table_clause ::= exists_opt full_table_name */ + 0, /* (206) with_opt ::= */ + -1, /* (207) with_opt ::= WITH */ + 0, /* (208) specific_cols_opt ::= */ + -3, /* (209) specific_cols_opt ::= NK_LP col_name_list NK_RP */ + -1, /* (210) full_table_name ::= table_name */ + -3, /* (211) full_table_name ::= db_name NK_DOT table_name */ + -1, /* (212) tag_def_list ::= tag_def */ + -3, /* (213) tag_def_list ::= tag_def_list NK_COMMA tag_def */ + -2, /* (214) tag_def ::= column_name type_name */ + -1, /* (215) column_def_list ::= column_def */ + -3, /* (216) column_def_list ::= column_def_list NK_COMMA column_def */ + -3, /* (217) column_def ::= column_name type_name column_options */ + -1, /* (218) type_name ::= BOOL */ + -1, /* (219) type_name ::= TINYINT */ + -1, /* (220) type_name ::= SMALLINT */ + -1, /* (221) type_name ::= INT */ + -1, /* (222) type_name ::= INTEGER */ + -1, /* (223) type_name ::= BIGINT */ + -1, /* (224) type_name ::= FLOAT */ + -1, /* (225) type_name ::= DOUBLE */ + -4, /* (226) type_name ::= BINARY NK_LP NK_INTEGER NK_RP */ + -1, /* (227) type_name ::= TIMESTAMP */ + -4, /* (228) type_name ::= NCHAR NK_LP NK_INTEGER NK_RP */ + -2, /* (229) type_name ::= TINYINT UNSIGNED */ + -2, /* (230) type_name ::= SMALLINT UNSIGNED */ + -2, /* (231) type_name ::= INT UNSIGNED */ + -2, /* (232) type_name ::= BIGINT UNSIGNED */ + -1, /* (233) type_name ::= JSON */ + -4, /* (234) type_name ::= VARCHAR NK_LP NK_INTEGER NK_RP */ + -1, /* (235) type_name ::= MEDIUMBLOB */ + -1, /* (236) type_name ::= BLOB */ + -4, /* (237) type_name ::= VARBINARY NK_LP NK_INTEGER NK_RP */ + -4, /* (238) type_name ::= GEOMETRY NK_LP NK_INTEGER NK_RP */ + -1, /* (239) type_name ::= DECIMAL */ + -4, /* (240) type_name ::= DECIMAL NK_LP NK_INTEGER NK_RP */ + -6, /* (241) type_name ::= DECIMAL NK_LP NK_INTEGER NK_COMMA NK_INTEGER NK_RP */ + -1, /* (242) type_name_default_len ::= BINARY */ + -1, /* (243) type_name_default_len ::= NCHAR */ + -1, /* (244) type_name_default_len ::= VARCHAR */ + -1, /* (245) type_name_default_len ::= VARBINARY */ + 0, /* (246) tags_def_opt ::= */ + -1, /* (247) tags_def_opt ::= tags_def */ + -4, /* (248) tags_def ::= TAGS NK_LP tag_def_list NK_RP */ + 0, /* (249) table_options ::= */ + -3, /* (250) table_options ::= table_options COMMENT NK_STRING */ + -3, /* (251) table_options ::= table_options MAX_DELAY duration_list */ + -3, /* (252) table_options ::= table_options WATERMARK duration_list */ + -5, /* (253) table_options ::= table_options ROLLUP NK_LP rollup_func_list NK_RP */ + -3, /* (254) table_options ::= table_options TTL NK_INTEGER */ + -5, /* (255) table_options ::= table_options SMA NK_LP col_name_list NK_RP */ + -3, /* (256) table_options ::= table_options DELETE_MARK duration_list */ + -1, /* (257) alter_table_options ::= alter_table_option */ + -2, /* (258) alter_table_options ::= alter_table_options alter_table_option */ + -2, /* (259) alter_table_option ::= COMMENT NK_STRING */ + -2, /* (260) alter_table_option ::= TTL NK_INTEGER */ + -1, /* (261) duration_list ::= duration_literal */ + -3, /* (262) duration_list ::= duration_list NK_COMMA duration_literal */ + -1, /* (263) rollup_func_list ::= rollup_func_name */ + -3, /* (264) rollup_func_list ::= rollup_func_list NK_COMMA rollup_func_name */ + -1, /* (265) rollup_func_name ::= function_name */ + -1, /* (266) rollup_func_name ::= FIRST */ + -1, /* (267) rollup_func_name ::= LAST */ + -1, /* (268) col_name_list ::= col_name */ + -3, /* (269) col_name_list ::= col_name_list NK_COMMA col_name */ + -1, /* (270) col_name ::= column_name */ + -2, /* (271) cmd ::= SHOW DNODES */ + -2, /* (272) cmd ::= SHOW USERS */ + -3, /* (273) cmd ::= SHOW USERS FULL */ + -3, /* (274) cmd ::= SHOW USER PRIVILEGES */ + -3, /* (275) cmd ::= SHOW db_kind_opt DATABASES */ + -4, /* (276) cmd ::= SHOW table_kind_db_name_cond_opt TABLES like_pattern_opt */ + -4, /* (277) cmd ::= SHOW db_name_cond_opt STABLES like_pattern_opt */ + -3, /* (278) cmd ::= SHOW db_name_cond_opt VGROUPS */ + -2, /* (279) cmd ::= SHOW MNODES */ + -2, /* (280) cmd ::= SHOW QNODES */ + -2, /* (281) cmd ::= SHOW ARBGROUPS */ + -2, /* (282) cmd ::= SHOW FUNCTIONS */ + -5, /* (283) cmd ::= SHOW INDEXES FROM table_name_cond from_db_opt */ + -6, /* (284) cmd ::= SHOW INDEXES FROM db_name NK_DOT table_name */ + -2, /* (285) cmd ::= SHOW STREAMS */ + -2, /* (286) cmd ::= SHOW ACCOUNTS */ + -2, /* (287) cmd ::= SHOW APPS */ + -2, /* (288) cmd ::= SHOW CONNECTIONS */ + -2, /* (289) cmd ::= SHOW LICENCES */ + -2, /* (290) cmd ::= SHOW GRANTS */ + -3, /* (291) cmd ::= SHOW GRANTS FULL */ + -3, /* (292) cmd ::= SHOW GRANTS LOGS */ + -3, /* (293) cmd ::= SHOW CLUSTER MACHINES */ + -4, /* (294) cmd ::= SHOW CREATE DATABASE db_name */ + -4, /* (295) cmd ::= SHOW CREATE TABLE full_table_name */ + -4, /* (296) cmd ::= SHOW CREATE STABLE full_table_name */ + -2, /* (297) cmd ::= SHOW ENCRYPTIONS */ + -2, /* (298) cmd ::= SHOW QUERIES */ + -2, /* (299) cmd ::= SHOW SCORES */ + -2, /* (300) cmd ::= SHOW TOPICS */ + -2, /* (301) cmd ::= SHOW VARIABLES */ + -3, /* (302) cmd ::= SHOW CLUSTER VARIABLES */ + -3, /* (303) cmd ::= SHOW LOCAL VARIABLES */ + -5, /* (304) cmd ::= SHOW DNODE NK_INTEGER VARIABLES like_pattern_opt */ + -2, /* (305) cmd ::= SHOW BNODES */ + -2, /* (306) cmd ::= SHOW SNODES */ + -2, /* (307) cmd ::= SHOW CLUSTER */ + -2, /* (308) cmd ::= SHOW TRANSACTIONS */ + -4, /* (309) cmd ::= SHOW TABLE DISTRIBUTED full_table_name */ + -2, /* (310) cmd ::= SHOW CONSUMERS */ + -2, /* (311) cmd ::= SHOW SUBSCRIPTIONS */ + -5, /* (312) cmd ::= SHOW TAGS FROM table_name_cond from_db_opt */ + -6, /* (313) cmd ::= SHOW TAGS FROM db_name NK_DOT table_name */ + -7, /* (314) cmd ::= SHOW TABLE TAGS tag_list_opt FROM table_name_cond from_db_opt */ + -8, /* (315) cmd ::= SHOW TABLE TAGS tag_list_opt FROM db_name NK_DOT table_name */ + -5, /* (316) cmd ::= SHOW VNODES ON DNODE NK_INTEGER */ + -2, /* (317) cmd ::= SHOW VNODES */ + -3, /* (318) cmd ::= SHOW db_name_cond_opt ALIVE */ + -3, /* (319) cmd ::= SHOW CLUSTER ALIVE */ + -4, /* (320) cmd ::= SHOW db_name_cond_opt VIEWS like_pattern_opt */ + -4, /* (321) cmd ::= SHOW CREATE VIEW full_table_name */ + -2, /* (322) cmd ::= SHOW COMPACTS */ + -3, /* (323) cmd ::= SHOW COMPACT NK_INTEGER */ + 0, /* (324) table_kind_db_name_cond_opt ::= */ + -1, /* (325) table_kind_db_name_cond_opt ::= table_kind */ + -2, /* (326) table_kind_db_name_cond_opt ::= db_name NK_DOT */ + -3, /* (327) table_kind_db_name_cond_opt ::= table_kind db_name NK_DOT */ + -1, /* (328) table_kind ::= NORMAL */ + -1, /* (329) table_kind ::= CHILD */ + 0, /* (330) db_name_cond_opt ::= */ + -2, /* (331) db_name_cond_opt ::= db_name NK_DOT */ + 0, /* (332) like_pattern_opt ::= */ + -2, /* (333) like_pattern_opt ::= LIKE NK_STRING */ + -1, /* (334) table_name_cond ::= table_name */ + 0, /* (335) from_db_opt ::= */ + -2, /* (336) from_db_opt ::= FROM db_name */ + 0, /* (337) tag_list_opt ::= */ + -1, /* (338) tag_list_opt ::= tag_item */ + -3, /* (339) tag_list_opt ::= tag_list_opt NK_COMMA tag_item */ + -1, /* (340) tag_item ::= TBNAME */ + -1, /* (341) tag_item ::= QTAGS */ + -1, /* (342) tag_item ::= column_name */ + -2, /* (343) tag_item ::= column_name column_alias */ + -3, /* (344) tag_item ::= column_name AS column_alias */ + 0, /* (345) db_kind_opt ::= */ + -1, /* (346) db_kind_opt ::= USER */ + -1, /* (347) db_kind_opt ::= SYSTEM */ + -11, /* (348) cmd ::= CREATE TSMA not_exists_opt tsma_name ON full_table_name tsma_func_list INTERVAL NK_LP duration_literal NK_RP */ + -11, /* (349) cmd ::= CREATE RECURSIVE TSMA not_exists_opt tsma_name ON full_table_name INTERVAL NK_LP duration_literal NK_RP */ + -4, /* (350) cmd ::= DROP TSMA exists_opt full_tsma_name */ + -3, /* (351) cmd ::= SHOW db_name_cond_opt TSMAS */ + -1, /* (352) full_tsma_name ::= tsma_name */ + -3, /* (353) full_tsma_name ::= db_name NK_DOT tsma_name */ + -4, /* (354) tsma_func_list ::= FUNCTION NK_LP func_list NK_RP */ + -8, /* (355) cmd ::= CREATE SMA INDEX not_exists_opt col_name ON full_table_name index_options */ + -9, /* (356) cmd ::= CREATE INDEX not_exists_opt col_name ON full_table_name NK_LP col_name_list NK_RP */ + -4, /* (357) cmd ::= DROP INDEX exists_opt full_index_name */ + -1, /* (358) full_index_name ::= index_name */ + -3, /* (359) full_index_name ::= db_name NK_DOT index_name */ + -10, /* (360) index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_RP sliding_opt sma_stream_opt */ + -12, /* (361) index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_COMMA duration_literal NK_RP sliding_opt sma_stream_opt */ + -1, /* (362) func_list ::= func */ + -3, /* (363) func_list ::= func_list NK_COMMA func */ + -4, /* (364) func ::= sma_func_name NK_LP expression_list NK_RP */ + -1, /* (365) sma_func_name ::= function_name */ + -1, /* (366) sma_func_name ::= COUNT */ + -1, /* (367) sma_func_name ::= FIRST */ + -1, /* (368) sma_func_name ::= LAST */ + -1, /* (369) sma_func_name ::= LAST_ROW */ + 0, /* (370) sma_stream_opt ::= */ + -3, /* (371) sma_stream_opt ::= sma_stream_opt WATERMARK duration_literal */ + -3, /* (372) sma_stream_opt ::= sma_stream_opt MAX_DELAY duration_literal */ + -3, /* (373) sma_stream_opt ::= sma_stream_opt DELETE_MARK duration_literal */ + -1, /* (374) with_meta ::= AS */ + -3, /* (375) with_meta ::= WITH META AS */ + -3, /* (376) with_meta ::= ONLY META AS */ + -6, /* (377) cmd ::= CREATE TOPIC not_exists_opt topic_name AS query_or_subquery */ + -7, /* (378) cmd ::= CREATE TOPIC not_exists_opt topic_name with_meta DATABASE db_name */ + -8, /* (379) cmd ::= CREATE TOPIC not_exists_opt topic_name with_meta STABLE full_table_name where_clause_opt */ + -4, /* (380) cmd ::= DROP TOPIC exists_opt topic_name */ + -7, /* (381) cmd ::= DROP CONSUMER GROUP exists_opt cgroup_name ON topic_name */ + -2, /* (382) cmd ::= DESC full_table_name */ + -2, /* (383) cmd ::= DESCRIBE full_table_name */ + -3, /* (384) cmd ::= RESET QUERY CACHE */ + -4, /* (385) cmd ::= EXPLAIN analyze_opt explain_options query_or_subquery */ + -4, /* (386) cmd ::= EXPLAIN analyze_opt explain_options insert_query */ + 0, /* (387) analyze_opt ::= */ + -1, /* (388) analyze_opt ::= ANALYZE */ + 0, /* (389) explain_options ::= */ + -3, /* (390) explain_options ::= explain_options VERBOSE NK_BOOL */ + -3, /* (391) explain_options ::= explain_options RATIO NK_FLOAT */ + -12, /* (392) cmd ::= CREATE or_replace_opt agg_func_opt FUNCTION not_exists_opt function_name AS NK_STRING OUTPUTTYPE type_name bufsize_opt language_opt */ + -4, /* (393) cmd ::= DROP FUNCTION exists_opt function_name */ + 0, /* (394) agg_func_opt ::= */ + -1, /* (395) agg_func_opt ::= AGGREGATE */ + 0, /* (396) bufsize_opt ::= */ + -2, /* (397) bufsize_opt ::= BUFSIZE NK_INTEGER */ + 0, /* (398) language_opt ::= */ + -2, /* (399) language_opt ::= LANGUAGE NK_STRING */ + 0, /* (400) or_replace_opt ::= */ + -2, /* (401) or_replace_opt ::= OR REPLACE */ + -6, /* (402) cmd ::= CREATE or_replace_opt VIEW full_view_name AS query_or_subquery */ + -4, /* (403) cmd ::= DROP VIEW exists_opt full_view_name */ + -1, /* (404) full_view_name ::= view_name */ + -3, /* (405) full_view_name ::= db_name NK_DOT view_name */ + -12, /* (406) cmd ::= CREATE STREAM not_exists_opt stream_name stream_options INTO full_table_name col_list_opt tag_def_or_ref_opt subtable_opt AS query_or_subquery */ + -4, /* (407) cmd ::= DROP STREAM exists_opt stream_name */ + -4, /* (408) cmd ::= PAUSE STREAM exists_opt stream_name */ + -5, /* (409) cmd ::= RESUME STREAM exists_opt ignore_opt stream_name */ + 0, /* (410) col_list_opt ::= */ + -3, /* (411) col_list_opt ::= NK_LP column_stream_def_list NK_RP */ + -1, /* (412) column_stream_def_list ::= column_stream_def */ + -3, /* (413) column_stream_def_list ::= column_stream_def_list NK_COMMA column_stream_def */ + -2, /* (414) column_stream_def ::= column_name stream_col_options */ + 0, /* (415) stream_col_options ::= */ + -3, /* (416) stream_col_options ::= stream_col_options PRIMARY KEY */ + 0, /* (417) tag_def_or_ref_opt ::= */ + -1, /* (418) tag_def_or_ref_opt ::= tags_def */ + -4, /* (419) tag_def_or_ref_opt ::= TAGS NK_LP column_stream_def_list NK_RP */ + 0, /* (420) stream_options ::= */ + -3, /* (421) stream_options ::= stream_options TRIGGER AT_ONCE */ + -3, /* (422) stream_options ::= stream_options TRIGGER WINDOW_CLOSE */ + -4, /* (423) stream_options ::= stream_options TRIGGER MAX_DELAY duration_literal */ + -3, /* (424) stream_options ::= stream_options WATERMARK duration_literal */ + -4, /* (425) stream_options ::= stream_options IGNORE EXPIRED NK_INTEGER */ + -3, /* (426) stream_options ::= stream_options FILL_HISTORY NK_INTEGER */ + -3, /* (427) stream_options ::= stream_options DELETE_MARK duration_literal */ + -4, /* (428) stream_options ::= stream_options IGNORE UPDATE NK_INTEGER */ + 0, /* (429) subtable_opt ::= */ + -4, /* (430) subtable_opt ::= SUBTABLE NK_LP expression NK_RP */ + 0, /* (431) ignore_opt ::= */ + -2, /* (432) ignore_opt ::= IGNORE UNTREATED */ + -3, /* (433) cmd ::= KILL CONNECTION NK_INTEGER */ + -3, /* (434) cmd ::= KILL QUERY NK_STRING */ + -3, /* (435) cmd ::= KILL TRANSACTION NK_INTEGER */ + -3, /* (436) cmd ::= KILL COMPACT NK_INTEGER */ + -2, /* (437) cmd ::= BALANCE VGROUP */ + -4, /* (438) cmd ::= BALANCE VGROUP LEADER on_vgroup_id */ + -5, /* (439) cmd ::= BALANCE VGROUP LEADER DATABASE db_name */ + -4, /* (440) cmd ::= MERGE VGROUP NK_INTEGER NK_INTEGER */ + -4, /* (441) cmd ::= REDISTRIBUTE VGROUP NK_INTEGER dnode_list */ + -3, /* (442) cmd ::= SPLIT VGROUP NK_INTEGER */ + 0, /* (443) on_vgroup_id ::= */ + -2, /* (444) on_vgroup_id ::= ON NK_INTEGER */ + -2, /* (445) dnode_list ::= DNODE NK_INTEGER */ + -3, /* (446) dnode_list ::= dnode_list DNODE NK_INTEGER */ + -4, /* (447) cmd ::= DELETE FROM full_table_name where_clause_opt */ + -1, /* (448) cmd ::= query_or_subquery */ + -1, /* (449) cmd ::= insert_query */ + -7, /* (450) insert_query ::= INSERT INTO full_table_name NK_LP col_name_list NK_RP query_or_subquery */ + -4, /* (451) insert_query ::= INSERT INTO full_table_name query_or_subquery */ + -1, /* (452) tags_literal ::= NK_INTEGER */ + -3, /* (453) tags_literal ::= NK_INTEGER NK_PLUS duration_literal */ + -3, /* (454) tags_literal ::= NK_INTEGER NK_MINUS duration_literal */ + -2, /* (455) tags_literal ::= NK_PLUS NK_INTEGER */ + -4, /* (456) tags_literal ::= NK_PLUS NK_INTEGER NK_PLUS duration_literal */ + -4, /* (457) tags_literal ::= NK_PLUS NK_INTEGER NK_MINUS duration_literal */ + -2, /* (458) tags_literal ::= NK_MINUS NK_INTEGER */ + -4, /* (459) tags_literal ::= NK_MINUS NK_INTEGER NK_PLUS duration_literal */ + -4, /* (460) tags_literal ::= NK_MINUS NK_INTEGER NK_MINUS duration_literal */ + -1, /* (461) tags_literal ::= NK_FLOAT */ + -2, /* (462) tags_literal ::= NK_PLUS NK_FLOAT */ + -2, /* (463) tags_literal ::= NK_MINUS NK_FLOAT */ + -1, /* (464) tags_literal ::= NK_BIN */ + -3, /* (465) tags_literal ::= NK_BIN NK_PLUS duration_literal */ + -3, /* (466) tags_literal ::= NK_BIN NK_MINUS duration_literal */ + -2, /* (467) tags_literal ::= NK_PLUS NK_BIN */ + -4, /* (468) tags_literal ::= NK_PLUS NK_BIN NK_PLUS duration_literal */ + -4, /* (469) tags_literal ::= NK_PLUS NK_BIN NK_MINUS duration_literal */ + -2, /* (470) tags_literal ::= NK_MINUS NK_BIN */ + -4, /* (471) tags_literal ::= NK_MINUS NK_BIN NK_PLUS duration_literal */ + -4, /* (472) tags_literal ::= NK_MINUS NK_BIN NK_MINUS duration_literal */ + -1, /* (473) tags_literal ::= NK_HEX */ + -3, /* (474) tags_literal ::= NK_HEX NK_PLUS duration_literal */ + -3, /* (475) tags_literal ::= NK_HEX NK_MINUS duration_literal */ + -2, /* (476) tags_literal ::= NK_PLUS NK_HEX */ + -4, /* (477) tags_literal ::= NK_PLUS NK_HEX NK_PLUS duration_literal */ + -4, /* (478) tags_literal ::= NK_PLUS NK_HEX NK_MINUS duration_literal */ + -2, /* (479) tags_literal ::= NK_MINUS NK_HEX */ + -4, /* (480) tags_literal ::= NK_MINUS NK_HEX NK_PLUS duration_literal */ + -4, /* (481) tags_literal ::= NK_MINUS NK_HEX NK_MINUS duration_literal */ + -1, /* (482) tags_literal ::= NK_STRING */ + -3, /* (483) tags_literal ::= NK_STRING NK_PLUS duration_literal */ + -3, /* (484) tags_literal ::= NK_STRING NK_MINUS duration_literal */ + -1, /* (485) tags_literal ::= NK_BOOL */ + -1, /* (486) tags_literal ::= NULL */ + -1, /* (487) tags_literal ::= literal_func */ + -3, /* (488) tags_literal ::= literal_func NK_PLUS duration_literal */ + -3, /* (489) tags_literal ::= literal_func NK_MINUS duration_literal */ + -1, /* (490) tags_literal_list ::= tags_literal */ + -3, /* (491) tags_literal_list ::= tags_literal_list NK_COMMA tags_literal */ + -1, /* (492) literal ::= NK_INTEGER */ + -1, /* (493) literal ::= NK_FLOAT */ + -1, /* (494) literal ::= NK_STRING */ + -1, /* (495) literal ::= NK_BOOL */ + -2, /* (496) literal ::= TIMESTAMP NK_STRING */ + -1, /* (497) literal ::= duration_literal */ + -1, /* (498) literal ::= NULL */ + -1, /* (499) literal ::= NK_QUESTION */ + -1, /* (500) duration_literal ::= NK_VARIABLE */ + -1, /* (501) signed ::= NK_INTEGER */ + -2, /* (502) signed ::= NK_PLUS NK_INTEGER */ + -2, /* (503) signed ::= NK_MINUS NK_INTEGER */ + -1, /* (504) signed ::= NK_FLOAT */ + -2, /* (505) signed ::= NK_PLUS NK_FLOAT */ + -2, /* (506) signed ::= NK_MINUS NK_FLOAT */ + -1, /* (507) signed_literal ::= signed */ + -1, /* (508) signed_literal ::= NK_STRING */ + -1, /* (509) signed_literal ::= NK_BOOL */ + -2, /* (510) signed_literal ::= TIMESTAMP NK_STRING */ + -1, /* (511) signed_literal ::= duration_literal */ + -1, /* (512) signed_literal ::= NULL */ + -1, /* (513) signed_literal ::= literal_func */ + -1, /* (514) signed_literal ::= NK_QUESTION */ + -1, /* (515) literal_list ::= signed_literal */ + -3, /* (516) literal_list ::= literal_list NK_COMMA signed_literal */ + -1, /* (517) db_name ::= NK_ID */ + -1, /* (518) table_name ::= NK_ID */ + -1, /* (519) column_name ::= NK_ID */ + -1, /* (520) function_name ::= NK_ID */ + -1, /* (521) view_name ::= NK_ID */ + -1, /* (522) table_alias ::= NK_ID */ + -1, /* (523) column_alias ::= NK_ID */ + -1, /* (524) column_alias ::= NK_ALIAS */ + -1, /* (525) user_name ::= NK_ID */ + -1, /* (526) topic_name ::= NK_ID */ + -1, /* (527) stream_name ::= NK_ID */ + -1, /* (528) cgroup_name ::= NK_ID */ + -1, /* (529) index_name ::= NK_ID */ + -1, /* (530) tsma_name ::= NK_ID */ + -1, /* (531) expr_or_subquery ::= expression */ + -1, /* (532) expression ::= literal */ + -1, /* (533) expression ::= pseudo_column */ + -1, /* (534) expression ::= column_reference */ + -1, /* (535) expression ::= function_expression */ + -1, /* (536) expression ::= case_when_expression */ + -3, /* (537) expression ::= NK_LP expression NK_RP */ + -2, /* (538) expression ::= NK_PLUS expr_or_subquery */ + -2, /* (539) expression ::= NK_MINUS expr_or_subquery */ + -3, /* (540) expression ::= expr_or_subquery NK_PLUS expr_or_subquery */ + -3, /* (541) expression ::= expr_or_subquery NK_MINUS expr_or_subquery */ + -3, /* (542) expression ::= expr_or_subquery NK_STAR expr_or_subquery */ + -3, /* (543) expression ::= expr_or_subquery NK_SLASH expr_or_subquery */ + -3, /* (544) expression ::= expr_or_subquery NK_REM expr_or_subquery */ + -3, /* (545) expression ::= column_reference NK_ARROW NK_STRING */ + -3, /* (546) expression ::= expr_or_subquery NK_BITAND expr_or_subquery */ + -3, /* (547) expression ::= expr_or_subquery NK_BITOR expr_or_subquery */ + -1, /* (548) expression_list ::= expr_or_subquery */ + -3, /* (549) expression_list ::= expression_list NK_COMMA expr_or_subquery */ + -1, /* (550) column_reference ::= column_name */ + -3, /* (551) column_reference ::= table_name NK_DOT column_name */ + -1, /* (552) column_reference ::= NK_ALIAS */ + -3, /* (553) column_reference ::= table_name NK_DOT NK_ALIAS */ + -1, /* (554) pseudo_column ::= ROWTS */ + -1, /* (555) pseudo_column ::= TBNAME */ + -3, /* (556) pseudo_column ::= table_name NK_DOT TBNAME */ + -1, /* (557) pseudo_column ::= QSTART */ + -1, /* (558) pseudo_column ::= QEND */ + -1, /* (559) pseudo_column ::= QDURATION */ + -1, /* (560) pseudo_column ::= WSTART */ + -1, /* (561) pseudo_column ::= WEND */ + -1, /* (562) pseudo_column ::= WDURATION */ + -1, /* (563) pseudo_column ::= IROWTS */ + -1, /* (564) pseudo_column ::= ISFILLED */ + -1, /* (565) pseudo_column ::= QTAGS */ + -4, /* (566) function_expression ::= function_name NK_LP expression_list NK_RP */ + -4, /* (567) function_expression ::= star_func NK_LP star_func_para_list NK_RP */ + -6, /* (568) function_expression ::= CAST NK_LP expr_or_subquery AS type_name NK_RP */ + -6, /* (569) function_expression ::= CAST NK_LP expr_or_subquery AS type_name_default_len NK_RP */ + -6, /* (570) function_expression ::= POSITION NK_LP expr_or_subquery IN expr_or_subquery NK_RP */ + -4, /* (571) function_expression ::= TRIM NK_LP expr_or_subquery NK_RP */ + -6, /* (572) function_expression ::= TRIM NK_LP trim_specification_type FROM expr_or_subquery NK_RP */ + -6, /* (573) function_expression ::= TRIM NK_LP expr_or_subquery FROM expr_or_subquery NK_RP */ + -7, /* (574) function_expression ::= TRIM NK_LP trim_specification_type expr_or_subquery FROM expr_or_subquery NK_RP */ + -4, /* (575) function_expression ::= substr_func NK_LP expression_list NK_RP */ + -6, /* (576) function_expression ::= substr_func NK_LP expr_or_subquery FROM expr_or_subquery NK_RP */ + -8, /* (577) function_expression ::= substr_func NK_LP expr_or_subquery FROM expr_or_subquery FOR expr_or_subquery NK_RP */ + -4, /* (578) function_expression ::= REPLACE NK_LP expression_list NK_RP */ + -1, /* (579) function_expression ::= literal_func */ + -1, /* (580) function_expression ::= rand_func */ + -3, /* (581) literal_func ::= noarg_func NK_LP NK_RP */ + -1, /* (582) literal_func ::= NOW */ + -1, /* (583) literal_func ::= TODAY */ + -3, /* (584) rand_func ::= RAND NK_LP NK_RP */ + -4, /* (585) rand_func ::= RAND NK_LP expression_list NK_RP */ + -1, /* (586) substr_func ::= SUBSTR */ + -1, /* (587) substr_func ::= SUBSTRING */ + -1, /* (588) trim_specification_type ::= BOTH */ + -1, /* (589) trim_specification_type ::= TRAILING */ + -1, /* (590) trim_specification_type ::= LEADING */ + -1, /* (591) noarg_func ::= NOW */ + -1, /* (592) noarg_func ::= TODAY */ + -1, /* (593) noarg_func ::= TIMEZONE */ + -1, /* (594) noarg_func ::= DATABASE */ + -1, /* (595) noarg_func ::= CLIENT_VERSION */ + -1, /* (596) noarg_func ::= SERVER_VERSION */ + -1, /* (597) noarg_func ::= SERVER_STATUS */ + -1, /* (598) noarg_func ::= CURRENT_USER */ + -1, /* (599) noarg_func ::= USER */ + -1, /* (600) noarg_func ::= PI */ + -1, /* (601) star_func ::= COUNT */ + -1, /* (602) star_func ::= FIRST */ + -1, /* (603) star_func ::= LAST */ + -1, /* (604) star_func ::= LAST_ROW */ + -1, /* (605) star_func_para_list ::= NK_STAR */ + -1, /* (606) star_func_para_list ::= other_para_list */ + -1, /* (607) other_para_list ::= star_func_para */ + -3, /* (608) other_para_list ::= other_para_list NK_COMMA star_func_para */ + -1, /* (609) star_func_para ::= expr_or_subquery */ + -3, /* (610) star_func_para ::= table_name NK_DOT NK_STAR */ + -4, /* (611) case_when_expression ::= CASE when_then_list case_when_else_opt END */ + -5, /* (612) case_when_expression ::= CASE common_expression when_then_list case_when_else_opt END */ + -1, /* (613) when_then_list ::= when_then_expr */ + -2, /* (614) when_then_list ::= when_then_list when_then_expr */ + -4, /* (615) when_then_expr ::= WHEN common_expression THEN common_expression */ + 0, /* (616) case_when_else_opt ::= */ + -2, /* (617) case_when_else_opt ::= ELSE common_expression */ + -3, /* (618) predicate ::= expr_or_subquery compare_op expr_or_subquery */ + -5, /* (619) predicate ::= expr_or_subquery BETWEEN expr_or_subquery AND expr_or_subquery */ + -6, /* (620) predicate ::= expr_or_subquery NOT BETWEEN expr_or_subquery AND expr_or_subquery */ + -3, /* (621) predicate ::= expr_or_subquery IS NULL */ + -4, /* (622) predicate ::= expr_or_subquery IS NOT NULL */ + -3, /* (623) predicate ::= expr_or_subquery in_op in_predicate_value */ + -1, /* (624) compare_op ::= NK_LT */ + -1, /* (625) compare_op ::= NK_GT */ + -1, /* (626) compare_op ::= NK_LE */ + -1, /* (627) compare_op ::= NK_GE */ + -1, /* (628) compare_op ::= NK_NE */ + -1, /* (629) compare_op ::= NK_EQ */ + -1, /* (630) compare_op ::= LIKE */ + -2, /* (631) compare_op ::= NOT LIKE */ + -1, /* (632) compare_op ::= MATCH */ + -1, /* (633) compare_op ::= NMATCH */ + -1, /* (634) compare_op ::= CONTAINS */ + -1, /* (635) in_op ::= IN */ + -2, /* (636) in_op ::= NOT IN */ + -3, /* (637) in_predicate_value ::= NK_LP literal_list NK_RP */ + -1, /* (638) boolean_value_expression ::= boolean_primary */ + -2, /* (639) boolean_value_expression ::= NOT boolean_primary */ + -3, /* (640) boolean_value_expression ::= boolean_value_expression OR boolean_value_expression */ + -3, /* (641) boolean_value_expression ::= boolean_value_expression AND boolean_value_expression */ + -1, /* (642) boolean_primary ::= predicate */ + -3, /* (643) boolean_primary ::= NK_LP boolean_value_expression NK_RP */ + -1, /* (644) common_expression ::= expr_or_subquery */ + -1, /* (645) common_expression ::= boolean_value_expression */ + 0, /* (646) from_clause_opt ::= */ + -2, /* (647) from_clause_opt ::= FROM table_reference_list */ + -1, /* (648) table_reference_list ::= table_reference */ + -3, /* (649) table_reference_list ::= table_reference_list NK_COMMA table_reference */ + -1, /* (650) table_reference ::= table_primary */ + -1, /* (651) table_reference ::= joined_table */ + -2, /* (652) table_primary ::= table_name alias_opt */ + -4, /* (653) table_primary ::= db_name NK_DOT table_name alias_opt */ + -2, /* (654) table_primary ::= subquery alias_opt */ + -1, /* (655) table_primary ::= parenthesized_joined_table */ + 0, /* (656) alias_opt ::= */ + -1, /* (657) alias_opt ::= table_alias */ + -2, /* (658) alias_opt ::= AS table_alias */ + -3, /* (659) parenthesized_joined_table ::= NK_LP joined_table NK_RP */ + -3, /* (660) parenthesized_joined_table ::= NK_LP parenthesized_joined_table NK_RP */ + -8, /* (661) joined_table ::= table_reference join_type join_subtype JOIN table_reference join_on_clause_opt window_offset_clause_opt jlimit_clause_opt */ + 0, /* (662) join_type ::= */ + -1, /* (663) join_type ::= INNER */ + -1, /* (664) join_type ::= LEFT */ + -1, /* (665) join_type ::= RIGHT */ + -1, /* (666) join_type ::= FULL */ + 0, /* (667) join_subtype ::= */ + -1, /* (668) join_subtype ::= OUTER */ + -1, /* (669) join_subtype ::= SEMI */ + -1, /* (670) join_subtype ::= ANTI */ + -1, /* (671) join_subtype ::= ASOF */ + -1, /* (672) join_subtype ::= WINDOW */ + 0, /* (673) join_on_clause_opt ::= */ + -2, /* (674) join_on_clause_opt ::= ON search_condition */ + 0, /* (675) window_offset_clause_opt ::= */ + -6, /* (676) window_offset_clause_opt ::= WINDOW_OFFSET NK_LP window_offset_literal NK_COMMA window_offset_literal NK_RP */ + -1, /* (677) window_offset_literal ::= NK_VARIABLE */ + -2, /* (678) window_offset_literal ::= NK_MINUS NK_VARIABLE */ + 0, /* (679) jlimit_clause_opt ::= */ + -2, /* (680) jlimit_clause_opt ::= JLIMIT NK_INTEGER */ + -14, /* (681) query_specification ::= SELECT hint_list set_quantifier_opt tag_mode_opt select_list from_clause_opt where_clause_opt partition_by_clause_opt range_opt every_opt fill_opt twindow_clause_opt group_by_clause_opt having_clause_opt */ + 0, /* (682) hint_list ::= */ + -1, /* (683) hint_list ::= NK_HINT */ + 0, /* (684) tag_mode_opt ::= */ + -1, /* (685) tag_mode_opt ::= TAGS */ + 0, /* (686) set_quantifier_opt ::= */ + -1, /* (687) set_quantifier_opt ::= DISTINCT */ + -1, /* (688) set_quantifier_opt ::= ALL */ + -1, /* (689) select_list ::= select_item */ + -3, /* (690) select_list ::= select_list NK_COMMA select_item */ + -1, /* (691) select_item ::= NK_STAR */ + -1, /* (692) select_item ::= common_expression */ + -2, /* (693) select_item ::= common_expression column_alias */ + -3, /* (694) select_item ::= common_expression AS column_alias */ + -3, /* (695) select_item ::= table_name NK_DOT NK_STAR */ + 0, /* (696) where_clause_opt ::= */ + -2, /* (697) where_clause_opt ::= WHERE search_condition */ + 0, /* (698) partition_by_clause_opt ::= */ + -3, /* (699) partition_by_clause_opt ::= PARTITION BY partition_list */ + -1, /* (700) partition_list ::= partition_item */ + -3, /* (701) partition_list ::= partition_list NK_COMMA partition_item */ + -1, /* (702) partition_item ::= expr_or_subquery */ + -2, /* (703) partition_item ::= expr_or_subquery column_alias */ + -3, /* (704) partition_item ::= expr_or_subquery AS column_alias */ + 0, /* (705) twindow_clause_opt ::= */ + -6, /* (706) twindow_clause_opt ::= SESSION NK_LP column_reference NK_COMMA interval_sliding_duration_literal NK_RP */ + -4, /* (707) twindow_clause_opt ::= STATE_WINDOW NK_LP expr_or_subquery NK_RP */ + -6, /* (708) twindow_clause_opt ::= INTERVAL NK_LP interval_sliding_duration_literal NK_RP sliding_opt fill_opt */ + -8, /* (709) twindow_clause_opt ::= INTERVAL NK_LP interval_sliding_duration_literal NK_COMMA interval_sliding_duration_literal NK_RP sliding_opt fill_opt */ + -7, /* (710) twindow_clause_opt ::= EVENT_WINDOW START WITH search_condition END WITH search_condition */ + -4, /* (711) twindow_clause_opt ::= COUNT_WINDOW NK_LP NK_INTEGER NK_RP */ + -6, /* (712) twindow_clause_opt ::= COUNT_WINDOW NK_LP NK_INTEGER NK_COMMA NK_INTEGER NK_RP */ + 0, /* (713) sliding_opt ::= */ + -4, /* (714) sliding_opt ::= SLIDING NK_LP interval_sliding_duration_literal NK_RP */ + -1, /* (715) interval_sliding_duration_literal ::= NK_VARIABLE */ + -1, /* (716) interval_sliding_duration_literal ::= NK_STRING */ + -1, /* (717) interval_sliding_duration_literal ::= NK_INTEGER */ + 0, /* (718) fill_opt ::= */ + -4, /* (719) fill_opt ::= FILL NK_LP fill_mode NK_RP */ + -6, /* (720) fill_opt ::= FILL NK_LP VALUE NK_COMMA expression_list NK_RP */ + -6, /* (721) fill_opt ::= FILL NK_LP VALUE_F NK_COMMA expression_list NK_RP */ + -1, /* (722) fill_mode ::= NONE */ + -1, /* (723) fill_mode ::= PREV */ + -1, /* (724) fill_mode ::= NULL */ + -1, /* (725) fill_mode ::= NULL_F */ + -1, /* (726) fill_mode ::= LINEAR */ + -1, /* (727) fill_mode ::= NEXT */ + 0, /* (728) group_by_clause_opt ::= */ + -3, /* (729) group_by_clause_opt ::= GROUP BY group_by_list */ + -1, /* (730) group_by_list ::= expr_or_subquery */ + -3, /* (731) group_by_list ::= group_by_list NK_COMMA expr_or_subquery */ + 0, /* (732) having_clause_opt ::= */ + -2, /* (733) having_clause_opt ::= HAVING search_condition */ + 0, /* (734) range_opt ::= */ + -6, /* (735) range_opt ::= RANGE NK_LP expr_or_subquery NK_COMMA expr_or_subquery NK_RP */ + -4, /* (736) range_opt ::= RANGE NK_LP expr_or_subquery NK_RP */ + 0, /* (737) every_opt ::= */ + -4, /* (738) every_opt ::= EVERY NK_LP duration_literal NK_RP */ + -4, /* (739) query_expression ::= query_simple order_by_clause_opt slimit_clause_opt limit_clause_opt */ + -1, /* (740) query_simple ::= query_specification */ + -1, /* (741) query_simple ::= union_query_expression */ + -4, /* (742) union_query_expression ::= query_simple_or_subquery UNION ALL query_simple_or_subquery */ + -3, /* (743) union_query_expression ::= query_simple_or_subquery UNION query_simple_or_subquery */ + -1, /* (744) query_simple_or_subquery ::= query_simple */ + -1, /* (745) query_simple_or_subquery ::= subquery */ + -1, /* (746) query_or_subquery ::= query_expression */ + -1, /* (747) query_or_subquery ::= subquery */ + 0, /* (748) order_by_clause_opt ::= */ + -3, /* (749) order_by_clause_opt ::= ORDER BY sort_specification_list */ + 0, /* (750) slimit_clause_opt ::= */ + -2, /* (751) slimit_clause_opt ::= SLIMIT NK_INTEGER */ + -4, /* (752) slimit_clause_opt ::= SLIMIT NK_INTEGER SOFFSET NK_INTEGER */ + -4, /* (753) slimit_clause_opt ::= SLIMIT NK_INTEGER NK_COMMA NK_INTEGER */ + 0, /* (754) limit_clause_opt ::= */ + -2, /* (755) limit_clause_opt ::= LIMIT NK_INTEGER */ + -4, /* (756) limit_clause_opt ::= LIMIT NK_INTEGER OFFSET NK_INTEGER */ + -4, /* (757) limit_clause_opt ::= LIMIT NK_INTEGER NK_COMMA NK_INTEGER */ + -3, /* (758) subquery ::= NK_LP query_expression NK_RP */ + -3, /* (759) subquery ::= NK_LP subquery NK_RP */ + -1, /* (760) search_condition ::= common_expression */ + -1, /* (761) sort_specification_list ::= sort_specification */ + -3, /* (762) sort_specification_list ::= sort_specification_list NK_COMMA sort_specification */ + -3, /* (763) sort_specification ::= expr_or_subquery ordering_specification_opt null_ordering_opt */ + 0, /* (764) ordering_specification_opt ::= */ + -1, /* (765) ordering_specification_opt ::= ASC */ + -1, /* (766) ordering_specification_opt ::= DESC */ + 0, /* (767) null_ordering_opt ::= */ + -2, /* (768) null_ordering_opt ::= NULLS FIRST */ + -2, /* (769) null_ordering_opt ::= NULLS LAST */ + 0, /* (770) column_options ::= */ + -3, /* (771) column_options ::= column_options PRIMARY KEY */ + -3, /* (772) column_options ::= column_options NK_ID NK_STRING */ }; static void yy_accept(yyParser*); /* Forward Declaration */ @@ -5897,2185 +5475,2235 @@ static void yy_accept(yyParser*); /* Forward Declaration */ ** means that the extra parameters have no performance impact. */ static YYACTIONTYPE yy_reduce( - yyParser *yypParser, /* The parser */ - unsigned int yyruleno, /* Number of the rule by which to reduce */ - int yyLookahead, /* Lookahead token, or YYNOCODE if none */ - ParseTOKENTYPE yyLookaheadToken /* Value of the lookahead token */ - ParseCTX_PDECL /* %extra_context */ + yyParser *yypParser, /* The parser */ + unsigned int yyruleno, /* Number of the rule by which to reduce */ + int yyLookahead, /* Lookahead token, or YYNOCODE if none */ + ParseTOKENTYPE yyLookaheadToken /* Value of the lookahead token */ + ParseCTX_PDECL /* %extra_context */ ){ int yygoto; /* The next state */ YYACTIONTYPE yyact; /* The next action */ yyStackEntry *yymsp; /* The top of the parser's stack */ int yysize; /* Amount to pop the stack */ ParseARG_FETCH - (void)yyLookahead; + (void)yyLookahead; (void)yyLookaheadToken; yymsp = yypParser->yytos; +#ifndef NDEBUG + if( yyTraceFILE && yyruleno<(int)(sizeof(yyRuleName)/sizeof(yyRuleName[0])) ){ + yysize = yyRuleInfoNRhs[yyruleno]; + if( yysize ){ + fprintf(yyTraceFILE, "%sReduce %d [%s]%s, pop back to state %d.\n", + yyTracePrompt, + yyruleno, yyRuleName[yyruleno], + yyrulenoyytos - yypParser->yystack)>yypParser->yyhwm ){ + yypParser->yyhwm++; + assert( yypParser->yyhwm == (int)(yypParser->yytos - yypParser->yystack)); + } +#endif +#if YYSTACKDEPTH>0 + if( yypParser->yytos>=yypParser->yystackEnd ){ + yyStackOverflow(yypParser); + /* The call to yyStackOverflow() above pops the stack until it is + ** empty, causing the main parser loop to exit. So the return value + ** is never used and does not matter. */ + return 0; + } +#else + if( yypParser->yytos>=&yypParser->yystack[yypParser->yystksz-1] ){ + if( yyGrowStack(yypParser) ){ + yyStackOverflow(yypParser); + /* The call to yyStackOverflow() above pops the stack until it is + ** empty, causing the main parser loop to exit. So the return value + ** is never used and does not matter. */ + return 0; + } + yymsp = yypParser->yytos; + } +#endif + } switch( yyruleno ){ - /* Beginning here are the reduction cases. A typical example + /* Beginning here are the reduction cases. A typical example ** follows: ** case 0: ** #line ** { ... } // User supplied code ** #line ** break; - */ - /********** Begin reduce actions **********************************************/ - YYMINORTYPE yylhsminor; - case 0: /* cmd ::= CREATE ACCOUNT NK_ID PASS NK_STRING account_options */ - { pCxt->errCode = generateSyntaxErrMsg(&pCxt->msgBuf, TSDB_CODE_PAR_EXPRIE_STATEMENT); } - yy_destructor(yypParser,384,&yymsp[0].minor); - break; - case 1: /* cmd ::= ALTER ACCOUNT NK_ID alter_account_options */ - { pCxt->errCode = generateSyntaxErrMsg(&pCxt->msgBuf, TSDB_CODE_PAR_EXPRIE_STATEMENT); } - yy_destructor(yypParser,385,&yymsp[0].minor); - break; - case 2: /* account_options ::= */ - { } - break; - case 3: /* account_options ::= account_options PPS literal */ - case 4: /* account_options ::= account_options TSERIES literal */ yytestcase(yyruleno==4); - case 5: /* account_options ::= account_options STORAGE literal */ yytestcase(yyruleno==5); - case 6: /* account_options ::= account_options STREAMS literal */ yytestcase(yyruleno==6); - case 7: /* account_options ::= account_options QTIME literal */ yytestcase(yyruleno==7); - case 8: /* account_options ::= account_options DBS literal */ yytestcase(yyruleno==8); - case 9: /* account_options ::= account_options USERS literal */ yytestcase(yyruleno==9); - case 10: /* account_options ::= account_options CONNS literal */ yytestcase(yyruleno==10); - case 11: /* account_options ::= account_options STATE literal */ yytestcase(yyruleno==11); - { yy_destructor(yypParser,384,&yymsp[-2].minor); - { } - yy_destructor(yypParser,386,&yymsp[0].minor); - } - break; - case 12: /* alter_account_options ::= alter_account_option */ - { yy_destructor(yypParser,387,&yymsp[0].minor); - { } - } - break; - case 13: /* alter_account_options ::= alter_account_options alter_account_option */ - { yy_destructor(yypParser,385,&yymsp[-1].minor); - { } - yy_destructor(yypParser,387,&yymsp[0].minor); - } - break; - case 14: /* alter_account_option ::= PASS literal */ - case 15: /* alter_account_option ::= PPS literal */ yytestcase(yyruleno==15); - case 16: /* alter_account_option ::= TSERIES literal */ yytestcase(yyruleno==16); - case 17: /* alter_account_option ::= STORAGE literal */ yytestcase(yyruleno==17); - case 18: /* alter_account_option ::= STREAMS literal */ yytestcase(yyruleno==18); - case 19: /* alter_account_option ::= QTIME literal */ yytestcase(yyruleno==19); - case 20: /* alter_account_option ::= DBS literal */ yytestcase(yyruleno==20); - case 21: /* alter_account_option ::= USERS literal */ yytestcase(yyruleno==21); - case 22: /* alter_account_option ::= CONNS literal */ yytestcase(yyruleno==22); - case 23: /* alter_account_option ::= STATE literal */ yytestcase(yyruleno==23); - { } - yy_destructor(yypParser,386,&yymsp[0].minor); - break; - case 24: /* ip_range_list ::= NK_STRING */ - { yylhsminor.yy712 = createNodeList(pCxt, createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy0)); } - yymsp[0].minor.yy712 = yylhsminor.yy712; - break; - case 25: /* ip_range_list ::= ip_range_list NK_COMMA NK_STRING */ - { yylhsminor.yy712 = addNodeToList(pCxt, yymsp[-2].minor.yy712, createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy0)); } - yymsp[-2].minor.yy712 = yylhsminor.yy712; - break; - case 26: /* white_list ::= HOST ip_range_list */ - { yymsp[-1].minor.yy712 = yymsp[0].minor.yy712; } - break; - case 27: /* white_list_opt ::= */ - case 206: /* specific_cols_opt ::= */ yytestcase(yyruleno==206); - case 244: /* tags_def_opt ::= */ yytestcase(yyruleno==244); - case 335: /* tag_list_opt ::= */ yytestcase(yyruleno==335); - case 408: /* col_list_opt ::= */ yytestcase(yyruleno==408); - case 415: /* tag_def_or_ref_opt ::= */ yytestcase(yyruleno==415); - case 696: /* partition_by_clause_opt ::= */ yytestcase(yyruleno==696); - case 726: /* group_by_clause_opt ::= */ yytestcase(yyruleno==726); - case 746: /* order_by_clause_opt ::= */ yytestcase(yyruleno==746); - { yymsp[1].minor.yy712 = NULL; } - break; - case 28: /* white_list_opt ::= white_list */ - case 245: /* tags_def_opt ::= tags_def */ yytestcase(yyruleno==245); - case 416: /* tag_def_or_ref_opt ::= tags_def */ yytestcase(yyruleno==416); - case 604: /* star_func_para_list ::= other_para_list */ yytestcase(yyruleno==604); - { yylhsminor.yy712 = yymsp[0].minor.yy712; } - yymsp[0].minor.yy712 = yylhsminor.yy712; - break; - case 29: /* is_import_opt ::= */ - case 31: /* is_createdb_opt ::= */ yytestcase(yyruleno==31); - { yymsp[1].minor.yy107 = 0; } - break; - case 30: /* is_import_opt ::= IS_IMPORT NK_INTEGER */ - case 32: /* is_createdb_opt ::= CREATEDB NK_INTEGER */ yytestcase(yyruleno==32); - case 42: /* sysinfo_opt ::= SYSINFO NK_INTEGER */ yytestcase(yyruleno==42); - { yymsp[-1].minor.yy107 = taosStr2Int8(yymsp[0].minor.yy0.z, NULL, 10); } - break; - case 33: /* cmd ::= CREATE USER user_name PASS NK_STRING sysinfo_opt is_createdb_opt is_import_opt white_list_opt */ - { - pCxt->pRootNode = createCreateUserStmt(pCxt, &yymsp[-6].minor.yy461, &yymsp[-4].minor.yy0, yymsp[-3].minor.yy107, yymsp[-1].minor.yy107, yymsp[-2].minor.yy107); - pCxt->pRootNode = addCreateUserStmtWhiteList(pCxt, pCxt->pRootNode, yymsp[0].minor.yy712); - } - break; - case 34: /* cmd ::= ALTER USER user_name PASS NK_STRING */ - { pCxt->pRootNode = createAlterUserStmt(pCxt, &yymsp[-2].minor.yy461, TSDB_ALTER_USER_PASSWD, &yymsp[0].minor.yy0); } - break; - case 35: /* cmd ::= ALTER USER user_name ENABLE NK_INTEGER */ - { pCxt->pRootNode = createAlterUserStmt(pCxt, &yymsp[-2].minor.yy461, TSDB_ALTER_USER_ENABLE, &yymsp[0].minor.yy0); } - break; - case 36: /* cmd ::= ALTER USER user_name SYSINFO NK_INTEGER */ - { pCxt->pRootNode = createAlterUserStmt(pCxt, &yymsp[-2].minor.yy461, TSDB_ALTER_USER_SYSINFO, &yymsp[0].minor.yy0); } - break; - case 37: /* cmd ::= ALTER USER user_name CREATEDB NK_INTEGER */ - { pCxt->pRootNode = createAlterUserStmt(pCxt, &yymsp[-2].minor.yy461, TSDB_ALTER_USER_CREATEDB, &yymsp[0].minor.yy0); } - break; - case 38: /* cmd ::= ALTER USER user_name ADD white_list */ - { pCxt->pRootNode = createAlterUserStmt(pCxt, &yymsp[-2].minor.yy461, TSDB_ALTER_USER_ADD_WHITE_LIST, yymsp[0].minor.yy712); } - break; - case 39: /* cmd ::= ALTER USER user_name DROP white_list */ - { pCxt->pRootNode = createAlterUserStmt(pCxt, &yymsp[-2].minor.yy461, TSDB_ALTER_USER_DROP_WHITE_LIST, yymsp[0].minor.yy712); } - break; - case 40: /* cmd ::= DROP USER user_name */ - { pCxt->pRootNode = createDropUserStmt(pCxt, &yymsp[0].minor.yy461); } - break; - case 41: /* sysinfo_opt ::= */ - { yymsp[1].minor.yy107 = 1; } - break; - case 43: /* cmd ::= GRANT privileges ON priv_level with_opt TO user_name */ - { pCxt->pRootNode = createGrantStmt(pCxt, yymsp[-5].minor.yy145, &yymsp[-3].minor.yy517, &yymsp[0].minor.yy461, yymsp[-2].minor.yy724); } - break; - case 44: /* cmd ::= REVOKE privileges ON priv_level with_opt FROM user_name */ - { pCxt->pRootNode = createRevokeStmt(pCxt, yymsp[-5].minor.yy145, &yymsp[-3].minor.yy517, &yymsp[0].minor.yy461, yymsp[-2].minor.yy724); } - break; - case 45: /* privileges ::= ALL */ - { yymsp[0].minor.yy145 = PRIVILEGE_TYPE_ALL; } - break; - case 46: /* privileges ::= priv_type_list */ - case 48: /* priv_type_list ::= priv_type */ yytestcase(yyruleno==48); - { yylhsminor.yy145 = yymsp[0].minor.yy145; } - yymsp[0].minor.yy145 = yylhsminor.yy145; - break; - case 47: /* privileges ::= SUBSCRIBE */ - { yymsp[0].minor.yy145 = PRIVILEGE_TYPE_SUBSCRIBE; } - break; - case 49: /* priv_type_list ::= priv_type_list NK_COMMA priv_type */ - { yylhsminor.yy145 = yymsp[-2].minor.yy145 | yymsp[0].minor.yy145; } - yymsp[-2].minor.yy145 = yylhsminor.yy145; - break; - case 50: /* priv_type ::= READ */ - { yymsp[0].minor.yy145 = PRIVILEGE_TYPE_READ; } - break; - case 51: /* priv_type ::= WRITE */ - { yymsp[0].minor.yy145 = PRIVILEGE_TYPE_WRITE; } - break; - case 52: /* priv_type ::= ALTER */ - { yymsp[0].minor.yy145 = PRIVILEGE_TYPE_ALTER; } - break; - case 53: /* priv_level ::= NK_STAR NK_DOT NK_STAR */ - { yylhsminor.yy517.first = yymsp[-2].minor.yy0; yylhsminor.yy517.second = yymsp[0].minor.yy0; } - yymsp[-2].minor.yy517 = yylhsminor.yy517; - break; - case 54: /* priv_level ::= db_name NK_DOT NK_STAR */ - { yylhsminor.yy517.first = yymsp[-2].minor.yy461; yylhsminor.yy517.second = yymsp[0].minor.yy0; } - yymsp[-2].minor.yy517 = yylhsminor.yy517; - break; - case 55: /* priv_level ::= db_name NK_DOT table_name */ - { yylhsminor.yy517.first = yymsp[-2].minor.yy461; yylhsminor.yy517.second = yymsp[0].minor.yy461; } - yymsp[-2].minor.yy517 = yylhsminor.yy517; - break; - case 56: /* priv_level ::= topic_name */ - { yylhsminor.yy517.first = yymsp[0].minor.yy461; yylhsminor.yy517.second = nil_token; } - yymsp[0].minor.yy517 = yylhsminor.yy517; - break; - case 57: /* with_opt ::= */ - case 173: /* start_opt ::= */ yytestcase(yyruleno==173); - case 177: /* end_opt ::= */ yytestcase(yyruleno==177); - case 330: /* like_pattern_opt ::= */ yytestcase(yyruleno==330); - case 427: /* subtable_opt ::= */ yytestcase(yyruleno==427); - case 614: /* case_when_else_opt ::= */ yytestcase(yyruleno==614); - case 644: /* from_clause_opt ::= */ yytestcase(yyruleno==644); - case 671: /* join_on_clause_opt ::= */ yytestcase(yyruleno==671); - case 673: /* window_offset_clause_opt ::= */ yytestcase(yyruleno==673); - case 677: /* jlimit_clause_opt ::= */ yytestcase(yyruleno==677); - case 694: /* where_clause_opt ::= */ yytestcase(yyruleno==694); - case 703: /* twindow_clause_opt ::= */ yytestcase(yyruleno==703); - case 711: /* sliding_opt ::= */ yytestcase(yyruleno==711); - case 716: /* fill_opt ::= */ yytestcase(yyruleno==716); - case 730: /* having_clause_opt ::= */ yytestcase(yyruleno==730); - case 732: /* range_opt ::= */ yytestcase(yyruleno==732); - case 735: /* every_opt ::= */ yytestcase(yyruleno==735); - case 748: /* slimit_clause_opt ::= */ yytestcase(yyruleno==748); - case 752: /* limit_clause_opt ::= */ yytestcase(yyruleno==752); - { yymsp[1].minor.yy724 = NULL; } - break; - case 58: /* with_opt ::= WITH search_condition */ - case 645: /* from_clause_opt ::= FROM table_reference_list */ yytestcase(yyruleno==645); - case 672: /* join_on_clause_opt ::= ON search_condition */ yytestcase(yyruleno==672); - case 695: /* where_clause_opt ::= WHERE search_condition */ yytestcase(yyruleno==695); - case 731: /* having_clause_opt ::= HAVING search_condition */ yytestcase(yyruleno==731); - { yymsp[-1].minor.yy724 = yymsp[0].minor.yy724; } - break; - case 59: /* cmd ::= CREATE ENCRYPT_KEY NK_STRING */ - { pCxt->pRootNode = createEncryptKeyStmt(pCxt, &yymsp[0].minor.yy0); } - break; - case 60: /* cmd ::= CREATE DNODE dnode_endpoint */ - { pCxt->pRootNode = createCreateDnodeStmt(pCxt, &yymsp[0].minor.yy461, NULL); } - break; - case 61: /* cmd ::= CREATE DNODE dnode_endpoint PORT NK_INTEGER */ - { pCxt->pRootNode = createCreateDnodeStmt(pCxt, &yymsp[-2].minor.yy461, &yymsp[0].minor.yy0); } - break; - case 62: /* cmd ::= DROP DNODE NK_INTEGER force_opt */ - { pCxt->pRootNode = createDropDnodeStmt(pCxt, &yymsp[-1].minor.yy0, yymsp[0].minor.yy429, false); } - break; - case 63: /* cmd ::= DROP DNODE dnode_endpoint force_opt */ - { pCxt->pRootNode = createDropDnodeStmt(pCxt, &yymsp[-1].minor.yy461, yymsp[0].minor.yy429, false); } - break; - case 64: /* cmd ::= DROP DNODE NK_INTEGER unsafe_opt */ - { pCxt->pRootNode = createDropDnodeStmt(pCxt, &yymsp[-1].minor.yy0, false, yymsp[0].minor.yy429); } - break; - case 65: /* cmd ::= DROP DNODE dnode_endpoint unsafe_opt */ - { pCxt->pRootNode = createDropDnodeStmt(pCxt, &yymsp[-1].minor.yy461, false, yymsp[0].minor.yy429); } - break; - case 66: /* cmd ::= ALTER DNODE NK_INTEGER NK_STRING */ - { pCxt->pRootNode = createAlterDnodeStmt(pCxt, &yymsp[-1].minor.yy0, &yymsp[0].minor.yy0, NULL); } - break; - case 67: /* cmd ::= ALTER DNODE NK_INTEGER NK_STRING NK_STRING */ - { pCxt->pRootNode = createAlterDnodeStmt(pCxt, &yymsp[-2].minor.yy0, &yymsp[-1].minor.yy0, &yymsp[0].minor.yy0); } - break; - case 68: /* cmd ::= ALTER ALL DNODES NK_STRING */ - { pCxt->pRootNode = createAlterDnodeStmt(pCxt, NULL, &yymsp[0].minor.yy0, NULL); } - break; - case 69: /* cmd ::= ALTER ALL DNODES NK_STRING NK_STRING */ - { pCxt->pRootNode = createAlterDnodeStmt(pCxt, NULL, &yymsp[-1].minor.yy0, &yymsp[0].minor.yy0); } - break; - case 70: /* cmd ::= RESTORE DNODE NK_INTEGER */ - { pCxt->pRootNode = createRestoreComponentNodeStmt(pCxt, QUERY_NODE_RESTORE_DNODE_STMT, &yymsp[0].minor.yy0); } - break; - case 71: /* dnode_endpoint ::= NK_STRING */ - case 72: /* dnode_endpoint ::= NK_ID */ yytestcase(yyruleno==72); - case 73: /* dnode_endpoint ::= NK_IPTOKEN */ yytestcase(yyruleno==73); - case 364: /* sma_func_name ::= COUNT */ yytestcase(yyruleno==364); - case 365: /* sma_func_name ::= FIRST */ yytestcase(yyruleno==365); - case 366: /* sma_func_name ::= LAST */ yytestcase(yyruleno==366); - case 367: /* sma_func_name ::= LAST_ROW */ yytestcase(yyruleno==367); - case 515: /* db_name ::= NK_ID */ yytestcase(yyruleno==515); - case 516: /* table_name ::= NK_ID */ yytestcase(yyruleno==516); - case 517: /* column_name ::= NK_ID */ yytestcase(yyruleno==517); - case 518: /* function_name ::= NK_ID */ yytestcase(yyruleno==518); - case 519: /* view_name ::= NK_ID */ yytestcase(yyruleno==519); - case 520: /* table_alias ::= NK_ID */ yytestcase(yyruleno==520); - case 521: /* column_alias ::= NK_ID */ yytestcase(yyruleno==521); - case 522: /* column_alias ::= NK_ALIAS */ yytestcase(yyruleno==522); - case 523: /* user_name ::= NK_ID */ yytestcase(yyruleno==523); - case 524: /* topic_name ::= NK_ID */ yytestcase(yyruleno==524); - case 525: /* stream_name ::= NK_ID */ yytestcase(yyruleno==525); - case 526: /* cgroup_name ::= NK_ID */ yytestcase(yyruleno==526); - case 527: /* index_name ::= NK_ID */ yytestcase(yyruleno==527); - case 528: /* tsma_name ::= NK_ID */ yytestcase(yyruleno==528); - case 584: /* substr_func ::= SUBSTR */ yytestcase(yyruleno==584); - case 585: /* substr_func ::= SUBSTRING */ yytestcase(yyruleno==585); - case 589: /* noarg_func ::= NOW */ yytestcase(yyruleno==589); - case 590: /* noarg_func ::= TODAY */ yytestcase(yyruleno==590); - case 591: /* noarg_func ::= TIMEZONE */ yytestcase(yyruleno==591); - case 592: /* noarg_func ::= DATABASE */ yytestcase(yyruleno==592); - case 593: /* noarg_func ::= CLIENT_VERSION */ yytestcase(yyruleno==593); - case 594: /* noarg_func ::= SERVER_VERSION */ yytestcase(yyruleno==594); - case 595: /* noarg_func ::= SERVER_STATUS */ yytestcase(yyruleno==595); - case 596: /* noarg_func ::= CURRENT_USER */ yytestcase(yyruleno==596); - case 597: /* noarg_func ::= USER */ yytestcase(yyruleno==597); - case 598: /* noarg_func ::= PI */ yytestcase(yyruleno==598); - case 599: /* star_func ::= COUNT */ yytestcase(yyruleno==599); - case 600: /* star_func ::= FIRST */ yytestcase(yyruleno==600); - case 601: /* star_func ::= LAST */ yytestcase(yyruleno==601); - case 602: /* star_func ::= LAST_ROW */ yytestcase(yyruleno==602); - { yylhsminor.yy461 = yymsp[0].minor.yy0; } - yymsp[0].minor.yy461 = yylhsminor.yy461; - break; - case 74: /* force_opt ::= */ - case 101: /* not_exists_opt ::= */ yytestcase(yyruleno==101); - case 103: /* exists_opt ::= */ yytestcase(yyruleno==103); - case 385: /* analyze_opt ::= */ yytestcase(yyruleno==385); - case 392: /* agg_func_opt ::= */ yytestcase(yyruleno==392); - case 398: /* or_replace_opt ::= */ yytestcase(yyruleno==398); - case 429: /* ignore_opt ::= */ yytestcase(yyruleno==429); - case 682: /* tag_mode_opt ::= */ yytestcase(yyruleno==682); - case 684: /* set_quantifier_opt ::= */ yytestcase(yyruleno==684); - { yymsp[1].minor.yy429 = false; } - break; - case 75: /* force_opt ::= FORCE */ - case 76: /* unsafe_opt ::= UNSAFE */ yytestcase(yyruleno==76); - case 386: /* analyze_opt ::= ANALYZE */ yytestcase(yyruleno==386); - case 393: /* agg_func_opt ::= AGGREGATE */ yytestcase(yyruleno==393); - case 683: /* tag_mode_opt ::= TAGS */ yytestcase(yyruleno==683); - case 685: /* set_quantifier_opt ::= DISTINCT */ yytestcase(yyruleno==685); - { yymsp[0].minor.yy429 = true; } - break; - case 77: /* cmd ::= ALTER CLUSTER NK_STRING */ - { pCxt->pRootNode = createAlterClusterStmt(pCxt, &yymsp[0].minor.yy0, NULL); } - break; - case 78: /* cmd ::= ALTER CLUSTER NK_STRING NK_STRING */ - { pCxt->pRootNode = createAlterClusterStmt(pCxt, &yymsp[-1].minor.yy0, &yymsp[0].minor.yy0); } - break; - case 79: /* cmd ::= ALTER LOCAL NK_STRING */ - { pCxt->pRootNode = createAlterLocalStmt(pCxt, &yymsp[0].minor.yy0, NULL); } - break; - case 80: /* cmd ::= ALTER LOCAL NK_STRING NK_STRING */ - { pCxt->pRootNode = createAlterLocalStmt(pCxt, &yymsp[-1].minor.yy0, &yymsp[0].minor.yy0); } - break; - case 81: /* cmd ::= CREATE QNODE ON DNODE NK_INTEGER */ - { pCxt->pRootNode = createCreateComponentNodeStmt(pCxt, QUERY_NODE_CREATE_QNODE_STMT, &yymsp[0].minor.yy0); } - break; - case 82: /* cmd ::= DROP QNODE ON DNODE NK_INTEGER */ - { pCxt->pRootNode = createDropComponentNodeStmt(pCxt, QUERY_NODE_DROP_QNODE_STMT, &yymsp[0].minor.yy0); } - break; - case 83: /* cmd ::= RESTORE QNODE ON DNODE NK_INTEGER */ - { pCxt->pRootNode = createRestoreComponentNodeStmt(pCxt, QUERY_NODE_RESTORE_QNODE_STMT, &yymsp[0].minor.yy0); } - break; - case 84: /* cmd ::= CREATE BNODE ON DNODE NK_INTEGER */ - { pCxt->pRootNode = createCreateComponentNodeStmt(pCxt, QUERY_NODE_CREATE_BNODE_STMT, &yymsp[0].minor.yy0); } - break; - case 85: /* cmd ::= DROP BNODE ON DNODE NK_INTEGER */ - { pCxt->pRootNode = createDropComponentNodeStmt(pCxt, QUERY_NODE_DROP_BNODE_STMT, &yymsp[0].minor.yy0); } - break; - case 86: /* cmd ::= CREATE SNODE ON DNODE NK_INTEGER */ - { pCxt->pRootNode = createCreateComponentNodeStmt(pCxt, QUERY_NODE_CREATE_SNODE_STMT, &yymsp[0].minor.yy0); } - break; - case 87: /* cmd ::= DROP SNODE ON DNODE NK_INTEGER */ - { pCxt->pRootNode = createDropComponentNodeStmt(pCxt, QUERY_NODE_DROP_SNODE_STMT, &yymsp[0].minor.yy0); } - break; - case 88: /* cmd ::= CREATE MNODE ON DNODE NK_INTEGER */ - { pCxt->pRootNode = createCreateComponentNodeStmt(pCxt, QUERY_NODE_CREATE_MNODE_STMT, &yymsp[0].minor.yy0); } - break; - case 89: /* cmd ::= DROP MNODE ON DNODE NK_INTEGER */ - { pCxt->pRootNode = createDropComponentNodeStmt(pCxt, QUERY_NODE_DROP_MNODE_STMT, &yymsp[0].minor.yy0); } - break; - case 90: /* cmd ::= RESTORE MNODE ON DNODE NK_INTEGER */ - { pCxt->pRootNode = createRestoreComponentNodeStmt(pCxt, QUERY_NODE_RESTORE_MNODE_STMT, &yymsp[0].minor.yy0); } - break; - case 91: /* cmd ::= RESTORE VNODE ON DNODE NK_INTEGER */ - { pCxt->pRootNode = createRestoreComponentNodeStmt(pCxt, QUERY_NODE_RESTORE_VNODE_STMT, &yymsp[0].minor.yy0); } - break; - case 92: /* cmd ::= CREATE DATABASE not_exists_opt db_name db_options */ - { pCxt->pRootNode = createCreateDatabaseStmt(pCxt, yymsp[-2].minor.yy429, &yymsp[-1].minor.yy461, yymsp[0].minor.yy724); } - break; - case 93: /* cmd ::= DROP DATABASE exists_opt db_name */ - { pCxt->pRootNode = createDropDatabaseStmt(pCxt, yymsp[-1].minor.yy429, &yymsp[0].minor.yy461); } - break; - case 94: /* cmd ::= USE db_name */ - { pCxt->pRootNode = createUseDatabaseStmt(pCxt, &yymsp[0].minor.yy461); } - break; - case 95: /* cmd ::= ALTER DATABASE db_name alter_db_options */ - { pCxt->pRootNode = createAlterDatabaseStmt(pCxt, &yymsp[-1].minor.yy461, yymsp[0].minor.yy724); } - break; - case 96: /* cmd ::= FLUSH DATABASE db_name */ - { pCxt->pRootNode = createFlushDatabaseStmt(pCxt, &yymsp[0].minor.yy461); } - break; - case 97: /* cmd ::= TRIM DATABASE db_name speed_opt */ - { pCxt->pRootNode = createTrimDatabaseStmt(pCxt, &yymsp[-1].minor.yy461, yymsp[0].minor.yy696); } - break; - case 98: /* cmd ::= S3MIGRATE DATABASE db_name */ - { pCxt->pRootNode = createS3MigrateDatabaseStmt(pCxt, &yymsp[0].minor.yy461); } - break; - case 99: /* cmd ::= COMPACT DATABASE db_name start_opt end_opt */ - { pCxt->pRootNode = createCompactStmt(pCxt, &yymsp[-2].minor.yy461, yymsp[-1].minor.yy724, yymsp[0].minor.yy724); } - break; - case 100: /* not_exists_opt ::= IF NOT EXISTS */ - { yymsp[-2].minor.yy429 = true; } - break; - case 102: /* exists_opt ::= IF EXISTS */ - case 399: /* or_replace_opt ::= OR REPLACE */ yytestcase(yyruleno==399); - case 430: /* ignore_opt ::= IGNORE UNTREATED */ yytestcase(yyruleno==430); - { yymsp[-1].minor.yy429 = true; } - break; - case 104: /* db_options ::= */ - { yymsp[1].minor.yy724 = createDefaultDatabaseOptions(pCxt); } - break; - case 105: /* db_options ::= db_options BUFFER NK_INTEGER */ - { yylhsminor.yy724 = setDatabaseOption(pCxt, yymsp[-2].minor.yy724, DB_OPTION_BUFFER, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 106: /* db_options ::= db_options CACHEMODEL NK_STRING */ - { yylhsminor.yy724 = setDatabaseOption(pCxt, yymsp[-2].minor.yy724, DB_OPTION_CACHEMODEL, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 107: /* db_options ::= db_options CACHESIZE NK_INTEGER */ - { yylhsminor.yy724 = setDatabaseOption(pCxt, yymsp[-2].minor.yy724, DB_OPTION_CACHESIZE, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 108: /* db_options ::= db_options COMP NK_INTEGER */ - { yylhsminor.yy724 = setDatabaseOption(pCxt, yymsp[-2].minor.yy724, DB_OPTION_COMP, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 109: /* db_options ::= db_options DURATION NK_INTEGER */ - case 110: /* db_options ::= db_options DURATION NK_VARIABLE */ yytestcase(yyruleno==110); - { yylhsminor.yy724 = setDatabaseOption(pCxt, yymsp[-2].minor.yy724, DB_OPTION_DAYS, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 111: /* db_options ::= db_options MAXROWS NK_INTEGER */ - { yylhsminor.yy724 = setDatabaseOption(pCxt, yymsp[-2].minor.yy724, DB_OPTION_MAXROWS, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 112: /* db_options ::= db_options MINROWS NK_INTEGER */ - { yylhsminor.yy724 = setDatabaseOption(pCxt, yymsp[-2].minor.yy724, DB_OPTION_MINROWS, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 113: /* db_options ::= db_options KEEP integer_list */ - case 114: /* db_options ::= db_options KEEP variable_list */ yytestcase(yyruleno==114); - { yylhsminor.yy724 = setDatabaseOption(pCxt, yymsp[-2].minor.yy724, DB_OPTION_KEEP, yymsp[0].minor.yy712); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 115: /* db_options ::= db_options PAGES NK_INTEGER */ - { yylhsminor.yy724 = setDatabaseOption(pCxt, yymsp[-2].minor.yy724, DB_OPTION_PAGES, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 116: /* db_options ::= db_options PAGESIZE NK_INTEGER */ - { yylhsminor.yy724 = setDatabaseOption(pCxt, yymsp[-2].minor.yy724, DB_OPTION_PAGESIZE, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 117: /* db_options ::= db_options TSDB_PAGESIZE NK_INTEGER */ - { yylhsminor.yy724 = setDatabaseOption(pCxt, yymsp[-2].minor.yy724, DB_OPTION_TSDB_PAGESIZE, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 118: /* db_options ::= db_options PRECISION NK_STRING */ - { yylhsminor.yy724 = setDatabaseOption(pCxt, yymsp[-2].minor.yy724, DB_OPTION_PRECISION, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 119: /* db_options ::= db_options REPLICA NK_INTEGER */ - { yylhsminor.yy724 = setDatabaseOption(pCxt, yymsp[-2].minor.yy724, DB_OPTION_REPLICA, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 120: /* db_options ::= db_options VGROUPS NK_INTEGER */ - { yylhsminor.yy724 = setDatabaseOption(pCxt, yymsp[-2].minor.yy724, DB_OPTION_VGROUPS, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 121: /* db_options ::= db_options SINGLE_STABLE NK_INTEGER */ - { yylhsminor.yy724 = setDatabaseOption(pCxt, yymsp[-2].minor.yy724, DB_OPTION_SINGLE_STABLE, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 122: /* db_options ::= db_options RETENTIONS retention_list */ - { yylhsminor.yy724 = setDatabaseOption(pCxt, yymsp[-2].minor.yy724, DB_OPTION_RETENTIONS, yymsp[0].minor.yy712); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 123: /* db_options ::= db_options SCHEMALESS NK_INTEGER */ - { yylhsminor.yy724 = setDatabaseOption(pCxt, yymsp[-2].minor.yy724, DB_OPTION_SCHEMALESS, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 124: /* db_options ::= db_options WAL_LEVEL NK_INTEGER */ - { yylhsminor.yy724 = setDatabaseOption(pCxt, yymsp[-2].minor.yy724, DB_OPTION_WAL, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 125: /* db_options ::= db_options WAL_FSYNC_PERIOD NK_INTEGER */ - { yylhsminor.yy724 = setDatabaseOption(pCxt, yymsp[-2].minor.yy724, DB_OPTION_FSYNC, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 126: /* db_options ::= db_options WAL_RETENTION_PERIOD NK_INTEGER */ - { yylhsminor.yy724 = setDatabaseOption(pCxt, yymsp[-2].minor.yy724, DB_OPTION_WAL_RETENTION_PERIOD, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 127: /* db_options ::= db_options WAL_RETENTION_PERIOD NK_MINUS NK_INTEGER */ - { - SToken t = yymsp[-1].minor.yy0; - t.n = (yymsp[0].minor.yy0.z + yymsp[0].minor.yy0.n) - yymsp[-1].minor.yy0.z; - yylhsminor.yy724 = setDatabaseOption(pCxt, yymsp[-3].minor.yy724, DB_OPTION_WAL_RETENTION_PERIOD, &t); - } - yymsp[-3].minor.yy724 = yylhsminor.yy724; - break; - case 128: /* db_options ::= db_options WAL_RETENTION_SIZE NK_INTEGER */ - { yylhsminor.yy724 = setDatabaseOption(pCxt, yymsp[-2].minor.yy724, DB_OPTION_WAL_RETENTION_SIZE, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 129: /* db_options ::= db_options WAL_RETENTION_SIZE NK_MINUS NK_INTEGER */ - { - SToken t = yymsp[-1].minor.yy0; - t.n = (yymsp[0].minor.yy0.z + yymsp[0].minor.yy0.n) - yymsp[-1].minor.yy0.z; - yylhsminor.yy724 = setDatabaseOption(pCxt, yymsp[-3].minor.yy724, DB_OPTION_WAL_RETENTION_SIZE, &t); - } - yymsp[-3].minor.yy724 = yylhsminor.yy724; - break; - case 130: /* db_options ::= db_options WAL_ROLL_PERIOD NK_INTEGER */ - { yylhsminor.yy724 = setDatabaseOption(pCxt, yymsp[-2].minor.yy724, DB_OPTION_WAL_ROLL_PERIOD, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 131: /* db_options ::= db_options WAL_SEGMENT_SIZE NK_INTEGER */ - { yylhsminor.yy724 = setDatabaseOption(pCxt, yymsp[-2].minor.yy724, DB_OPTION_WAL_SEGMENT_SIZE, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 132: /* db_options ::= db_options STT_TRIGGER NK_INTEGER */ - { yylhsminor.yy724 = setDatabaseOption(pCxt, yymsp[-2].minor.yy724, DB_OPTION_STT_TRIGGER, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 133: /* db_options ::= db_options TABLE_PREFIX signed */ - { yylhsminor.yy724 = setDatabaseOption(pCxt, yymsp[-2].minor.yy724, DB_OPTION_TABLE_PREFIX, yymsp[0].minor.yy724); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 134: /* db_options ::= db_options TABLE_SUFFIX signed */ - { yylhsminor.yy724 = setDatabaseOption(pCxt, yymsp[-2].minor.yy724, DB_OPTION_TABLE_SUFFIX, yymsp[0].minor.yy724); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 135: /* db_options ::= db_options S3_CHUNKSIZE NK_INTEGER */ - { yylhsminor.yy724 = setDatabaseOption(pCxt, yymsp[-2].minor.yy724, DB_OPTION_S3_CHUNKSIZE, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 136: /* db_options ::= db_options S3_KEEPLOCAL NK_INTEGER */ - case 137: /* db_options ::= db_options S3_KEEPLOCAL NK_VARIABLE */ yytestcase(yyruleno==137); - { yylhsminor.yy724 = setDatabaseOption(pCxt, yymsp[-2].minor.yy724, DB_OPTION_S3_KEEPLOCAL, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 138: /* db_options ::= db_options S3_COMPACT NK_INTEGER */ - { yylhsminor.yy724 = setDatabaseOption(pCxt, yymsp[-2].minor.yy724, DB_OPTION_S3_COMPACT, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 139: /* db_options ::= db_options KEEP_TIME_OFFSET NK_INTEGER */ - { yylhsminor.yy724 = setDatabaseOption(pCxt, yymsp[-2].minor.yy724, DB_OPTION_KEEP_TIME_OFFSET, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 140: /* db_options ::= db_options ENCRYPT_ALGORITHM NK_STRING */ - { yylhsminor.yy724 = setDatabaseOption(pCxt, yymsp[-2].minor.yy724, DB_OPTION_ENCRYPT_ALGORITHM, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 141: /* alter_db_options ::= alter_db_option */ - { yylhsminor.yy724 = createAlterDatabaseOptions(pCxt); yylhsminor.yy724 = setAlterDatabaseOption(pCxt, yylhsminor.yy724, &yymsp[0].minor.yy533); } - yymsp[0].minor.yy724 = yylhsminor.yy724; - break; - case 142: /* alter_db_options ::= alter_db_options alter_db_option */ - { yylhsminor.yy724 = setAlterDatabaseOption(pCxt, yymsp[-1].minor.yy724, &yymsp[0].minor.yy533); } - yymsp[-1].minor.yy724 = yylhsminor.yy724; - break; - case 143: /* alter_db_option ::= BUFFER NK_INTEGER */ - { yymsp[-1].minor.yy533.type = DB_OPTION_BUFFER; yymsp[-1].minor.yy533.val = yymsp[0].minor.yy0; } - break; - case 144: /* alter_db_option ::= CACHEMODEL NK_STRING */ - { yymsp[-1].minor.yy533.type = DB_OPTION_CACHEMODEL; yymsp[-1].minor.yy533.val = yymsp[0].minor.yy0; } - break; - case 145: /* alter_db_option ::= CACHESIZE NK_INTEGER */ - { yymsp[-1].minor.yy533.type = DB_OPTION_CACHESIZE; yymsp[-1].minor.yy533.val = yymsp[0].minor.yy0; } - break; - case 146: /* alter_db_option ::= WAL_FSYNC_PERIOD NK_INTEGER */ - { yymsp[-1].minor.yy533.type = DB_OPTION_FSYNC; yymsp[-1].minor.yy533.val = yymsp[0].minor.yy0; } - break; - case 147: /* alter_db_option ::= KEEP integer_list */ - case 148: /* alter_db_option ::= KEEP variable_list */ yytestcase(yyruleno==148); - { yymsp[-1].minor.yy533.type = DB_OPTION_KEEP; yymsp[-1].minor.yy533.pList = yymsp[0].minor.yy712; } - break; - case 149: /* alter_db_option ::= PAGES NK_INTEGER */ - { yymsp[-1].minor.yy533.type = DB_OPTION_PAGES; yymsp[-1].minor.yy533.val = yymsp[0].minor.yy0; } - break; - case 150: /* alter_db_option ::= REPLICA NK_INTEGER */ - { yymsp[-1].minor.yy533.type = DB_OPTION_REPLICA; yymsp[-1].minor.yy533.val = yymsp[0].minor.yy0; } - break; - case 151: /* alter_db_option ::= WAL_LEVEL NK_INTEGER */ - { yymsp[-1].minor.yy533.type = DB_OPTION_WAL; yymsp[-1].minor.yy533.val = yymsp[0].minor.yy0; } - break; - case 152: /* alter_db_option ::= STT_TRIGGER NK_INTEGER */ - { yymsp[-1].minor.yy533.type = DB_OPTION_STT_TRIGGER; yymsp[-1].minor.yy533.val = yymsp[0].minor.yy0; } - break; - case 153: /* alter_db_option ::= MINROWS NK_INTEGER */ - { yymsp[-1].minor.yy533.type = DB_OPTION_MINROWS; yymsp[-1].minor.yy533.val = yymsp[0].minor.yy0; } - break; - case 154: /* alter_db_option ::= WAL_RETENTION_PERIOD NK_INTEGER */ - { yymsp[-1].minor.yy533.type = DB_OPTION_WAL_RETENTION_PERIOD; yymsp[-1].minor.yy533.val = yymsp[0].minor.yy0; } - break; - case 155: /* alter_db_option ::= WAL_RETENTION_PERIOD NK_MINUS NK_INTEGER */ - { - SToken t = yymsp[-1].minor.yy0; - t.n = (yymsp[0].minor.yy0.z + yymsp[0].minor.yy0.n) - yymsp[-1].minor.yy0.z; - yymsp[-2].minor.yy533.type = DB_OPTION_WAL_RETENTION_PERIOD; yymsp[-2].minor.yy533.val = t; - } - break; - case 156: /* alter_db_option ::= WAL_RETENTION_SIZE NK_INTEGER */ - { yymsp[-1].minor.yy533.type = DB_OPTION_WAL_RETENTION_SIZE; yymsp[-1].minor.yy533.val = yymsp[0].minor.yy0; } - break; - case 157: /* alter_db_option ::= WAL_RETENTION_SIZE NK_MINUS NK_INTEGER */ - { - SToken t = yymsp[-1].minor.yy0; - t.n = (yymsp[0].minor.yy0.z + yymsp[0].minor.yy0.n) - yymsp[-1].minor.yy0.z; - yymsp[-2].minor.yy533.type = DB_OPTION_WAL_RETENTION_SIZE; yymsp[-2].minor.yy533.val = t; - } - break; - case 158: /* alter_db_option ::= S3_KEEPLOCAL NK_INTEGER */ - case 159: /* alter_db_option ::= S3_KEEPLOCAL NK_VARIABLE */ yytestcase(yyruleno==159); - { yymsp[-1].minor.yy533.type = DB_OPTION_S3_KEEPLOCAL; yymsp[-1].minor.yy533.val = yymsp[0].minor.yy0; } - break; - case 160: /* alter_db_option ::= S3_COMPACT NK_INTEGER */ - { yymsp[-1].minor.yy533.type = DB_OPTION_S3_COMPACT, yymsp[-1].minor.yy533.val = yymsp[0].minor.yy0; } - break; - case 161: /* alter_db_option ::= KEEP_TIME_OFFSET NK_INTEGER */ - { yymsp[-1].minor.yy533.type = DB_OPTION_KEEP_TIME_OFFSET; yymsp[-1].minor.yy533.val = yymsp[0].minor.yy0; } - break; - case 162: /* alter_db_option ::= ENCRYPT_ALGORITHM NK_STRING */ - { yymsp[-1].minor.yy533.type = DB_OPTION_ENCRYPT_ALGORITHM; yymsp[-1].minor.yy533.val = yymsp[0].minor.yy0; } - break; - case 163: /* integer_list ::= NK_INTEGER */ - { yylhsminor.yy712 = createNodeList(pCxt, createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0)); } - yymsp[0].minor.yy712 = yylhsminor.yy712; - break; - case 164: /* integer_list ::= integer_list NK_COMMA NK_INTEGER */ - case 444: /* dnode_list ::= dnode_list DNODE NK_INTEGER */ yytestcase(yyruleno==444); - { yylhsminor.yy712 = addNodeToList(pCxt, yymsp[-2].minor.yy712, createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0)); } - yymsp[-2].minor.yy712 = yylhsminor.yy712; - break; - case 165: /* variable_list ::= NK_VARIABLE */ - { yylhsminor.yy712 = createNodeList(pCxt, createDurationValueNode(pCxt, &yymsp[0].minor.yy0)); } - yymsp[0].minor.yy712 = yylhsminor.yy712; - break; - case 166: /* variable_list ::= variable_list NK_COMMA NK_VARIABLE */ - { yylhsminor.yy712 = addNodeToList(pCxt, yymsp[-2].minor.yy712, createDurationValueNode(pCxt, &yymsp[0].minor.yy0)); } - yymsp[-2].minor.yy712 = yylhsminor.yy712; - break; - case 167: /* retention_list ::= retention */ - case 200: /* multi_create_clause ::= create_subtable_clause */ yytestcase(yyruleno==200); - case 203: /* multi_drop_clause ::= drop_table_clause */ yytestcase(yyruleno==203); - case 210: /* tag_def_list ::= tag_def */ yytestcase(yyruleno==210); - case 213: /* column_def_list ::= column_def */ yytestcase(yyruleno==213); - case 261: /* rollup_func_list ::= rollup_func_name */ yytestcase(yyruleno==261); - case 266: /* col_name_list ::= col_name */ yytestcase(yyruleno==266); - case 336: /* tag_list_opt ::= tag_item */ yytestcase(yyruleno==336); - case 360: /* func_list ::= func */ yytestcase(yyruleno==360); - case 410: /* column_stream_def_list ::= column_stream_def */ yytestcase(yyruleno==410); - case 488: /* tags_literal_list ::= tags_literal */ yytestcase(yyruleno==488); - case 513: /* literal_list ::= signed_literal */ yytestcase(yyruleno==513); - case 605: /* other_para_list ::= star_func_para */ yytestcase(yyruleno==605); - case 611: /* when_then_list ::= when_then_expr */ yytestcase(yyruleno==611); - case 687: /* select_list ::= select_item */ yytestcase(yyruleno==687); - case 698: /* partition_list ::= partition_item */ yytestcase(yyruleno==698); - case 759: /* sort_specification_list ::= sort_specification */ yytestcase(yyruleno==759); - { yylhsminor.yy712 = createNodeList(pCxt, yymsp[0].minor.yy724); } - yymsp[0].minor.yy712 = yylhsminor.yy712; - break; - case 168: /* retention_list ::= retention_list NK_COMMA retention */ - case 204: /* multi_drop_clause ::= multi_drop_clause NK_COMMA drop_table_clause */ yytestcase(yyruleno==204); - case 211: /* tag_def_list ::= tag_def_list NK_COMMA tag_def */ yytestcase(yyruleno==211); - case 214: /* column_def_list ::= column_def_list NK_COMMA column_def */ yytestcase(yyruleno==214); - case 262: /* rollup_func_list ::= rollup_func_list NK_COMMA rollup_func_name */ yytestcase(yyruleno==262); - case 267: /* col_name_list ::= col_name_list NK_COMMA col_name */ yytestcase(yyruleno==267); - case 337: /* tag_list_opt ::= tag_list_opt NK_COMMA tag_item */ yytestcase(yyruleno==337); - case 361: /* func_list ::= func_list NK_COMMA func */ yytestcase(yyruleno==361); - case 411: /* column_stream_def_list ::= column_stream_def_list NK_COMMA column_stream_def */ yytestcase(yyruleno==411); - case 489: /* tags_literal_list ::= tags_literal_list NK_COMMA tags_literal */ yytestcase(yyruleno==489); - case 514: /* literal_list ::= literal_list NK_COMMA signed_literal */ yytestcase(yyruleno==514); - case 606: /* other_para_list ::= other_para_list NK_COMMA star_func_para */ yytestcase(yyruleno==606); - case 688: /* select_list ::= select_list NK_COMMA select_item */ yytestcase(yyruleno==688); - case 699: /* partition_list ::= partition_list NK_COMMA partition_item */ yytestcase(yyruleno==699); - case 760: /* sort_specification_list ::= sort_specification_list NK_COMMA sort_specification */ yytestcase(yyruleno==760); - { yylhsminor.yy712 = addNodeToList(pCxt, yymsp[-2].minor.yy712, yymsp[0].minor.yy724); } - yymsp[-2].minor.yy712 = yylhsminor.yy712; - break; - case 169: /* retention ::= NK_VARIABLE NK_COLON NK_VARIABLE */ - case 170: /* retention ::= NK_MINUS NK_COLON NK_VARIABLE */ yytestcase(yyruleno==170); - { yylhsminor.yy724 = createNodeListNodeEx(pCxt, createDurationValueNode(pCxt, &yymsp[-2].minor.yy0), createDurationValueNode(pCxt, &yymsp[0].minor.yy0)); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 171: /* speed_opt ::= */ - case 394: /* bufsize_opt ::= */ yytestcase(yyruleno==394); - { yymsp[1].minor.yy696 = 0; } - break; - case 172: /* speed_opt ::= BWLIMIT NK_INTEGER */ - case 395: /* bufsize_opt ::= BUFSIZE NK_INTEGER */ yytestcase(yyruleno==395); - { yymsp[-1].minor.yy696 = taosStr2Int32(yymsp[0].minor.yy0.z, NULL, 10); } - break; - case 174: /* start_opt ::= START WITH NK_INTEGER */ - case 178: /* end_opt ::= END WITH NK_INTEGER */ yytestcase(yyruleno==178); - { yymsp[-2].minor.yy724 = createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0); } - break; - case 175: /* start_opt ::= START WITH NK_STRING */ - case 179: /* end_opt ::= END WITH NK_STRING */ yytestcase(yyruleno==179); - { yymsp[-2].minor.yy724 = createValueNode(pCxt, TSDB_DATA_TYPE_TIMESTAMP, &yymsp[0].minor.yy0); } - break; - case 176: /* start_opt ::= START WITH TIMESTAMP NK_STRING */ - case 180: /* end_opt ::= END WITH TIMESTAMP NK_STRING */ yytestcase(yyruleno==180); - { yymsp[-3].minor.yy724 = createValueNode(pCxt, TSDB_DATA_TYPE_TIMESTAMP, &yymsp[0].minor.yy0); } - break; - case 181: /* cmd ::= CREATE TABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def_opt table_options */ - case 184: /* cmd ::= CREATE STABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def table_options */ yytestcase(yyruleno==184); - { pCxt->pRootNode = createCreateTableStmt(pCxt, yymsp[-6].minor.yy429, yymsp[-5].minor.yy724, yymsp[-3].minor.yy712, yymsp[-1].minor.yy712, yymsp[0].minor.yy724); } - break; - case 182: /* cmd ::= CREATE TABLE multi_create_clause */ - { pCxt->pRootNode = createCreateMultiTableStmt(pCxt, yymsp[0].minor.yy712); } - break; - case 183: /* cmd ::= CREATE TABLE not_exists_opt USING full_table_name NK_LP tag_list_opt NK_RP FILE NK_STRING */ - { pCxt->pRootNode = createCreateSubTableFromFileClause(pCxt, yymsp[-7].minor.yy429, yymsp[-5].minor.yy724, yymsp[-3].minor.yy712, &yymsp[0].minor.yy0); } - break; - case 185: /* cmd ::= DROP TABLE multi_drop_clause */ - { pCxt->pRootNode = createDropTableStmt(pCxt, yymsp[0].minor.yy712); } - break; - case 186: /* cmd ::= DROP STABLE exists_opt full_table_name */ - { pCxt->pRootNode = createDropSuperTableStmt(pCxt, yymsp[-1].minor.yy429, yymsp[0].minor.yy724); } - break; - case 187: /* cmd ::= ALTER TABLE alter_table_clause */ - case 446: /* cmd ::= query_or_subquery */ yytestcase(yyruleno==446); - case 447: /* cmd ::= insert_query */ yytestcase(yyruleno==447); - { pCxt->pRootNode = yymsp[0].minor.yy724; } - break; - case 188: /* cmd ::= ALTER STABLE alter_table_clause */ - { pCxt->pRootNode = setAlterSuperTableType(yymsp[0].minor.yy724); } - break; - case 189: /* alter_table_clause ::= full_table_name alter_table_options */ - { yylhsminor.yy724 = createAlterTableModifyOptions(pCxt, yymsp[-1].minor.yy724, yymsp[0].minor.yy724); } - yymsp[-1].minor.yy724 = yylhsminor.yy724; - break; - case 190: /* alter_table_clause ::= full_table_name ADD COLUMN column_name type_name column_options */ - { yylhsminor.yy724 = createAlterTableAddModifyColOptions2(pCxt, yymsp[-5].minor.yy724, TSDB_ALTER_TABLE_ADD_COLUMN, &yymsp[-2].minor.yy461, yymsp[-1].minor.yy1016, yymsp[0].minor.yy724); } - yymsp[-5].minor.yy724 = yylhsminor.yy724; - break; - case 191: /* alter_table_clause ::= full_table_name DROP COLUMN column_name */ - { yylhsminor.yy724 = createAlterTableDropCol(pCxt, yymsp[-3].minor.yy724, TSDB_ALTER_TABLE_DROP_COLUMN, &yymsp[0].minor.yy461); } - yymsp[-3].minor.yy724 = yylhsminor.yy724; - break; - case 192: /* alter_table_clause ::= full_table_name MODIFY COLUMN column_name type_name */ - { yylhsminor.yy724 = createAlterTableAddModifyCol(pCxt, yymsp[-4].minor.yy724, TSDB_ALTER_TABLE_UPDATE_COLUMN_BYTES, &yymsp[-1].minor.yy461, yymsp[0].minor.yy1016); } - yymsp[-4].minor.yy724 = yylhsminor.yy724; - break; - case 193: /* alter_table_clause ::= full_table_name MODIFY COLUMN column_name column_options */ - { yylhsminor.yy724 = createAlterTableAddModifyColOptions(pCxt, yymsp[-4].minor.yy724, TSDB_ALTER_TABLE_UPDATE_COLUMN_COMPRESS, &yymsp[-1].minor.yy461, yymsp[0].minor.yy724); } - yymsp[-4].minor.yy724 = yylhsminor.yy724; - break; - case 194: /* alter_table_clause ::= full_table_name RENAME COLUMN column_name column_name */ - { yylhsminor.yy724 = createAlterTableRenameCol(pCxt, yymsp[-4].minor.yy724, TSDB_ALTER_TABLE_UPDATE_COLUMN_NAME, &yymsp[-1].minor.yy461, &yymsp[0].minor.yy461); } - yymsp[-4].minor.yy724 = yylhsminor.yy724; - break; - case 195: /* alter_table_clause ::= full_table_name ADD TAG column_name type_name */ - { yylhsminor.yy724 = createAlterTableAddModifyCol(pCxt, yymsp[-4].minor.yy724, TSDB_ALTER_TABLE_ADD_TAG, &yymsp[-1].minor.yy461, yymsp[0].minor.yy1016); } - yymsp[-4].minor.yy724 = yylhsminor.yy724; - break; - case 196: /* alter_table_clause ::= full_table_name DROP TAG column_name */ - { yylhsminor.yy724 = createAlterTableDropCol(pCxt, yymsp[-3].minor.yy724, TSDB_ALTER_TABLE_DROP_TAG, &yymsp[0].minor.yy461); } - yymsp[-3].minor.yy724 = yylhsminor.yy724; - break; - case 197: /* alter_table_clause ::= full_table_name MODIFY TAG column_name type_name */ - { yylhsminor.yy724 = createAlterTableAddModifyCol(pCxt, yymsp[-4].minor.yy724, TSDB_ALTER_TABLE_UPDATE_TAG_BYTES, &yymsp[-1].minor.yy461, yymsp[0].minor.yy1016); } - yymsp[-4].minor.yy724 = yylhsminor.yy724; - break; - case 198: /* alter_table_clause ::= full_table_name RENAME TAG column_name column_name */ - { yylhsminor.yy724 = createAlterTableRenameCol(pCxt, yymsp[-4].minor.yy724, TSDB_ALTER_TABLE_UPDATE_TAG_NAME, &yymsp[-1].minor.yy461, &yymsp[0].minor.yy461); } - yymsp[-4].minor.yy724 = yylhsminor.yy724; - break; - case 199: /* alter_table_clause ::= full_table_name SET TAG column_name NK_EQ tags_literal */ - { yylhsminor.yy724 = createAlterTableSetTag(pCxt, yymsp[-5].minor.yy724, &yymsp[-2].minor.yy461, yymsp[0].minor.yy724); } - yymsp[-5].minor.yy724 = yylhsminor.yy724; - break; - case 201: /* multi_create_clause ::= multi_create_clause create_subtable_clause */ - case 612: /* when_then_list ::= when_then_list when_then_expr */ yytestcase(yyruleno==612); - { yylhsminor.yy712 = addNodeToList(pCxt, yymsp[-1].minor.yy712, yymsp[0].minor.yy724); } - yymsp[-1].minor.yy712 = yylhsminor.yy712; - break; - case 202: /* create_subtable_clause ::= not_exists_opt full_table_name USING full_table_name specific_cols_opt TAGS NK_LP tags_literal_list NK_RP table_options */ - { yylhsminor.yy724 = createCreateSubTableClause(pCxt, yymsp[-9].minor.yy429, yymsp[-8].minor.yy724, yymsp[-6].minor.yy724, yymsp[-5].minor.yy712, yymsp[-2].minor.yy712, yymsp[0].minor.yy724); } - yymsp[-9].minor.yy724 = yylhsminor.yy724; - break; - case 205: /* drop_table_clause ::= exists_opt full_table_name */ - { yylhsminor.yy724 = createDropTableClause(pCxt, yymsp[-1].minor.yy429, yymsp[0].minor.yy724); } - yymsp[-1].minor.yy724 = yylhsminor.yy724; - break; - case 207: /* specific_cols_opt ::= NK_LP col_name_list NK_RP */ - case 409: /* col_list_opt ::= NK_LP column_stream_def_list NK_RP */ yytestcase(yyruleno==409); - { yymsp[-2].minor.yy712 = yymsp[-1].minor.yy712; } - break; - case 208: /* full_table_name ::= table_name */ - case 350: /* full_tsma_name ::= tsma_name */ yytestcase(yyruleno==350); - { yylhsminor.yy724 = createRealTableNode(pCxt, NULL, &yymsp[0].minor.yy461, NULL); } - yymsp[0].minor.yy724 = yylhsminor.yy724; - break; - case 209: /* full_table_name ::= db_name NK_DOT table_name */ - case 351: /* full_tsma_name ::= db_name NK_DOT tsma_name */ yytestcase(yyruleno==351); - { yylhsminor.yy724 = createRealTableNode(pCxt, &yymsp[-2].minor.yy461, &yymsp[0].minor.yy461, NULL); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 212: /* tag_def ::= column_name type_name */ - { yylhsminor.yy724 = createColumnDefNode(pCxt, &yymsp[-1].minor.yy461, yymsp[0].minor.yy1016, NULL); } - yymsp[-1].minor.yy724 = yylhsminor.yy724; - break; - case 215: /* column_def ::= column_name type_name column_options */ - { yylhsminor.yy724 = createColumnDefNode(pCxt, &yymsp[-2].minor.yy461, yymsp[-1].minor.yy1016, yymsp[0].minor.yy724); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 216: /* type_name ::= BOOL */ - { yymsp[0].minor.yy1016 = createDataType(TSDB_DATA_TYPE_BOOL); } - break; - case 217: /* type_name ::= TINYINT */ - { yymsp[0].minor.yy1016 = createDataType(TSDB_DATA_TYPE_TINYINT); } - break; - case 218: /* type_name ::= SMALLINT */ - { yymsp[0].minor.yy1016 = createDataType(TSDB_DATA_TYPE_SMALLINT); } - break; - case 219: /* type_name ::= INT */ - case 220: /* type_name ::= INTEGER */ yytestcase(yyruleno==220); - { yymsp[0].minor.yy1016 = createDataType(TSDB_DATA_TYPE_INT); } - break; - case 221: /* type_name ::= BIGINT */ - { yymsp[0].minor.yy1016 = createDataType(TSDB_DATA_TYPE_BIGINT); } - break; - case 222: /* type_name ::= FLOAT */ - { yymsp[0].minor.yy1016 = createDataType(TSDB_DATA_TYPE_FLOAT); } - break; - case 223: /* type_name ::= DOUBLE */ - { yymsp[0].minor.yy1016 = createDataType(TSDB_DATA_TYPE_DOUBLE); } - break; - case 224: /* type_name ::= BINARY NK_LP NK_INTEGER NK_RP */ - { yymsp[-3].minor.yy1016 = createVarLenDataType(TSDB_DATA_TYPE_BINARY, &yymsp[-1].minor.yy0); } - break; - case 225: /* type_name ::= TIMESTAMP */ - { yymsp[0].minor.yy1016 = createDataType(TSDB_DATA_TYPE_TIMESTAMP); } - break; - case 226: /* type_name ::= NCHAR NK_LP NK_INTEGER NK_RP */ - { yymsp[-3].minor.yy1016 = createVarLenDataType(TSDB_DATA_TYPE_NCHAR, &yymsp[-1].minor.yy0); } - break; - case 227: /* type_name ::= TINYINT UNSIGNED */ - { yymsp[-1].minor.yy1016 = createDataType(TSDB_DATA_TYPE_UTINYINT); } - break; - case 228: /* type_name ::= SMALLINT UNSIGNED */ - { yymsp[-1].minor.yy1016 = createDataType(TSDB_DATA_TYPE_USMALLINT); } - break; - case 229: /* type_name ::= INT UNSIGNED */ - { yymsp[-1].minor.yy1016 = createDataType(TSDB_DATA_TYPE_UINT); } - break; - case 230: /* type_name ::= BIGINT UNSIGNED */ - { yymsp[-1].minor.yy1016 = createDataType(TSDB_DATA_TYPE_UBIGINT); } - break; - case 231: /* type_name ::= JSON */ - { yymsp[0].minor.yy1016 = createDataType(TSDB_DATA_TYPE_JSON); } - break; - case 232: /* type_name ::= VARCHAR NK_LP NK_INTEGER NK_RP */ - { yymsp[-3].minor.yy1016 = createVarLenDataType(TSDB_DATA_TYPE_VARCHAR, &yymsp[-1].minor.yy0); } - break; - case 233: /* type_name ::= MEDIUMBLOB */ - { yymsp[0].minor.yy1016 = createDataType(TSDB_DATA_TYPE_MEDIUMBLOB); } - break; - case 234: /* type_name ::= BLOB */ - { yymsp[0].minor.yy1016 = createDataType(TSDB_DATA_TYPE_BLOB); } - break; - case 235: /* type_name ::= VARBINARY NK_LP NK_INTEGER NK_RP */ - { yymsp[-3].minor.yy1016 = createVarLenDataType(TSDB_DATA_TYPE_VARBINARY, &yymsp[-1].minor.yy0); } - break; - case 236: /* type_name ::= GEOMETRY NK_LP NK_INTEGER NK_RP */ - { yymsp[-3].minor.yy1016 = createVarLenDataType(TSDB_DATA_TYPE_GEOMETRY, &yymsp[-1].minor.yy0); } - break; - case 237: /* type_name ::= DECIMAL */ - { yymsp[0].minor.yy1016 = createDataType(TSDB_DATA_TYPE_DECIMAL); } - break; - case 238: /* type_name ::= DECIMAL NK_LP NK_INTEGER NK_RP */ - { yymsp[-3].minor.yy1016 = createDataType(TSDB_DATA_TYPE_DECIMAL); } - break; - case 239: /* type_name ::= DECIMAL NK_LP NK_INTEGER NK_COMMA NK_INTEGER NK_RP */ - { yymsp[-5].minor.yy1016 = createDataType(TSDB_DATA_TYPE_DECIMAL); } - break; - case 240: /* type_name_default_len ::= BINARY */ - { yymsp[0].minor.yy1016 = createVarLenDataType(TSDB_DATA_TYPE_BINARY, NULL); } - break; - case 241: /* type_name_default_len ::= NCHAR */ - { yymsp[0].minor.yy1016 = createVarLenDataType(TSDB_DATA_TYPE_NCHAR, NULL); } - break; - case 242: /* type_name_default_len ::= VARCHAR */ - { yymsp[0].minor.yy1016 = createVarLenDataType(TSDB_DATA_TYPE_VARCHAR, NULL); } - break; - case 243: /* type_name_default_len ::= VARBINARY */ - { yymsp[0].minor.yy1016 = createVarLenDataType(TSDB_DATA_TYPE_VARBINARY, NULL); } - break; - case 246: /* tags_def ::= TAGS NK_LP tag_def_list NK_RP */ - case 417: /* tag_def_or_ref_opt ::= TAGS NK_LP column_stream_def_list NK_RP */ yytestcase(yyruleno==417); - { yymsp[-3].minor.yy712 = yymsp[-1].minor.yy712; } - break; - case 247: /* table_options ::= */ - { yymsp[1].minor.yy724 = createDefaultTableOptions(pCxt); } - break; - case 248: /* table_options ::= table_options COMMENT NK_STRING */ - { yylhsminor.yy724 = setTableOption(pCxt, yymsp[-2].minor.yy724, TABLE_OPTION_COMMENT, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 249: /* table_options ::= table_options MAX_DELAY duration_list */ - { yylhsminor.yy724 = setTableOption(pCxt, yymsp[-2].minor.yy724, TABLE_OPTION_MAXDELAY, yymsp[0].minor.yy712); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 250: /* table_options ::= table_options WATERMARK duration_list */ - { yylhsminor.yy724 = setTableOption(pCxt, yymsp[-2].minor.yy724, TABLE_OPTION_WATERMARK, yymsp[0].minor.yy712); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 251: /* table_options ::= table_options ROLLUP NK_LP rollup_func_list NK_RP */ - { yylhsminor.yy724 = setTableOption(pCxt, yymsp[-4].minor.yy724, TABLE_OPTION_ROLLUP, yymsp[-1].minor.yy712); } - yymsp[-4].minor.yy724 = yylhsminor.yy724; - break; - case 252: /* table_options ::= table_options TTL NK_INTEGER */ - { yylhsminor.yy724 = setTableOption(pCxt, yymsp[-2].minor.yy724, TABLE_OPTION_TTL, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 253: /* table_options ::= table_options SMA NK_LP col_name_list NK_RP */ - { yylhsminor.yy724 = setTableOption(pCxt, yymsp[-4].minor.yy724, TABLE_OPTION_SMA, yymsp[-1].minor.yy712); } - yymsp[-4].minor.yy724 = yylhsminor.yy724; - break; - case 254: /* table_options ::= table_options DELETE_MARK duration_list */ - { yylhsminor.yy724 = setTableOption(pCxt, yymsp[-2].minor.yy724, TABLE_OPTION_DELETE_MARK, yymsp[0].minor.yy712); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 255: /* alter_table_options ::= alter_table_option */ - { yylhsminor.yy724 = createAlterTableOptions(pCxt); yylhsminor.yy724 = setTableOption(pCxt, yylhsminor.yy724, yymsp[0].minor.yy533.type, &yymsp[0].minor.yy533.val); } - yymsp[0].minor.yy724 = yylhsminor.yy724; - break; - case 256: /* alter_table_options ::= alter_table_options alter_table_option */ - { yylhsminor.yy724 = setTableOption(pCxt, yymsp[-1].minor.yy724, yymsp[0].minor.yy533.type, &yymsp[0].minor.yy533.val); } - yymsp[-1].minor.yy724 = yylhsminor.yy724; - break; - case 257: /* alter_table_option ::= COMMENT NK_STRING */ - { yymsp[-1].minor.yy533.type = TABLE_OPTION_COMMENT; yymsp[-1].minor.yy533.val = yymsp[0].minor.yy0; } - break; - case 258: /* alter_table_option ::= TTL NK_INTEGER */ - { yymsp[-1].minor.yy533.type = TABLE_OPTION_TTL; yymsp[-1].minor.yy533.val = yymsp[0].minor.yy0; } - break; - case 259: /* duration_list ::= duration_literal */ - case 546: /* expression_list ::= expr_or_subquery */ yytestcase(yyruleno==546); - { yylhsminor.yy712 = createNodeList(pCxt, releaseRawExprNode(pCxt, yymsp[0].minor.yy724)); } - yymsp[0].minor.yy712 = yylhsminor.yy712; - break; - case 260: /* duration_list ::= duration_list NK_COMMA duration_literal */ - case 547: /* expression_list ::= expression_list NK_COMMA expr_or_subquery */ yytestcase(yyruleno==547); - { yylhsminor.yy712 = addNodeToList(pCxt, yymsp[-2].minor.yy712, releaseRawExprNode(pCxt, yymsp[0].minor.yy724)); } - yymsp[-2].minor.yy712 = yylhsminor.yy712; - break; - case 263: /* rollup_func_name ::= function_name */ - { yylhsminor.yy724 = createFunctionNode(pCxt, &yymsp[0].minor.yy461, NULL); } - yymsp[0].minor.yy724 = yylhsminor.yy724; - break; - case 264: /* rollup_func_name ::= FIRST */ - case 265: /* rollup_func_name ::= LAST */ yytestcase(yyruleno==265); - case 339: /* tag_item ::= QTAGS */ yytestcase(yyruleno==339); - { yylhsminor.yy724 = createFunctionNode(pCxt, &yymsp[0].minor.yy0, NULL); } - yymsp[0].minor.yy724 = yylhsminor.yy724; - break; - case 268: /* col_name ::= column_name */ - case 340: /* tag_item ::= column_name */ yytestcase(yyruleno==340); - { yylhsminor.yy724 = createColumnNode(pCxt, NULL, &yymsp[0].minor.yy461); } - yymsp[0].minor.yy724 = yylhsminor.yy724; - break; - case 269: /* cmd ::= SHOW DNODES */ - { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_DNODES_STMT); } - break; - case 270: /* cmd ::= SHOW USERS */ - { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_USERS_STMT); } - break; - case 271: /* cmd ::= SHOW USERS FULL */ - { pCxt->pRootNode = createShowStmtWithFull(pCxt, QUERY_NODE_SHOW_USERS_FULL_STMT); } - break; - case 272: /* cmd ::= SHOW USER PRIVILEGES */ - { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_USER_PRIVILEGES_STMT); } - break; - case 273: /* cmd ::= SHOW db_kind_opt DATABASES */ - { - pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_DATABASES_STMT); - (void)setShowKind(pCxt, pCxt->pRootNode, yymsp[-1].minor.yy973); - } - break; - case 274: /* cmd ::= SHOW table_kind_db_name_cond_opt TABLES like_pattern_opt */ - { - pCxt->pRootNode = createShowTablesStmt(pCxt, yymsp[-2].minor.yy801, yymsp[0].minor.yy724, OP_TYPE_LIKE); - } - break; - case 275: /* cmd ::= SHOW db_name_cond_opt STABLES like_pattern_opt */ - { pCxt->pRootNode = createShowStmtWithCond(pCxt, QUERY_NODE_SHOW_STABLES_STMT, yymsp[-2].minor.yy724, yymsp[0].minor.yy724, OP_TYPE_LIKE); } - break; - case 276: /* cmd ::= SHOW db_name_cond_opt VGROUPS */ - { pCxt->pRootNode = createShowStmtWithCond(pCxt, QUERY_NODE_SHOW_VGROUPS_STMT, yymsp[-1].minor.yy724, NULL, OP_TYPE_LIKE); } - break; - case 277: /* cmd ::= SHOW MNODES */ - { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_MNODES_STMT); } - break; - case 278: /* cmd ::= SHOW QNODES */ - { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_QNODES_STMT); } - break; - case 279: /* cmd ::= SHOW ARBGROUPS */ - { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_ARBGROUPS_STMT); } - break; - case 280: /* cmd ::= SHOW FUNCTIONS */ - { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_FUNCTIONS_STMT); } - break; - case 281: /* cmd ::= SHOW INDEXES FROM table_name_cond from_db_opt */ - { pCxt->pRootNode = createShowStmtWithCond(pCxt, QUERY_NODE_SHOW_INDEXES_STMT, yymsp[0].minor.yy724, yymsp[-1].minor.yy724, OP_TYPE_EQUAL); } - break; - case 282: /* cmd ::= SHOW INDEXES FROM db_name NK_DOT table_name */ - { pCxt->pRootNode = createShowStmtWithCond(pCxt, QUERY_NODE_SHOW_INDEXES_STMT, createIdentifierValueNode(pCxt, &yymsp[-2].minor.yy461), createIdentifierValueNode(pCxt, &yymsp[0].minor.yy461), OP_TYPE_EQUAL); } - break; - case 283: /* cmd ::= SHOW STREAMS */ - { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_STREAMS_STMT); } - break; - case 284: /* cmd ::= SHOW ACCOUNTS */ - { pCxt->errCode = generateSyntaxErrMsg(&pCxt->msgBuf, TSDB_CODE_PAR_EXPRIE_STATEMENT); } - break; - case 285: /* cmd ::= SHOW APPS */ - { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_APPS_STMT); } - break; - case 286: /* cmd ::= SHOW CONNECTIONS */ - { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_CONNECTIONS_STMT); } - break; - case 287: /* cmd ::= SHOW LICENCES */ - case 288: /* cmd ::= SHOW GRANTS */ yytestcase(yyruleno==288); - { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_LICENCES_STMT); } - break; - case 289: /* cmd ::= SHOW GRANTS FULL */ - { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_GRANTS_FULL_STMT); } - break; - case 290: /* cmd ::= SHOW GRANTS LOGS */ - { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_GRANTS_LOGS_STMT); } - break; - case 291: /* cmd ::= SHOW CLUSTER MACHINES */ - { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_CLUSTER_MACHINES_STMT); } - break; - case 292: /* cmd ::= SHOW CREATE DATABASE db_name */ - { pCxt->pRootNode = createShowCreateDatabaseStmt(pCxt, &yymsp[0].minor.yy461); } - break; - case 293: /* cmd ::= SHOW CREATE TABLE full_table_name */ - { pCxt->pRootNode = createShowCreateTableStmt(pCxt, QUERY_NODE_SHOW_CREATE_TABLE_STMT, yymsp[0].minor.yy724); } - break; - case 294: /* cmd ::= SHOW CREATE STABLE full_table_name */ - { pCxt->pRootNode = createShowCreateTableStmt(pCxt, QUERY_NODE_SHOW_CREATE_STABLE_STMT, - yymsp[0].minor.yy724); } - break; - case 295: /* cmd ::= SHOW ENCRYPTIONS */ - { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_ENCRYPTIONS_STMT); } - break; - case 296: /* cmd ::= SHOW QUERIES */ - { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_QUERIES_STMT); } - break; - case 297: /* cmd ::= SHOW SCORES */ - { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_SCORES_STMT); } - break; - case 298: /* cmd ::= SHOW TOPICS */ - { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_TOPICS_STMT); } - break; - case 299: /* cmd ::= SHOW VARIABLES */ - case 300: /* cmd ::= SHOW CLUSTER VARIABLES */ yytestcase(yyruleno==300); - { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_VARIABLES_STMT); } - break; - case 301: /* cmd ::= SHOW LOCAL VARIABLES */ - { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_LOCAL_VARIABLES_STMT); } - break; - case 302: /* cmd ::= SHOW DNODE NK_INTEGER VARIABLES like_pattern_opt */ - { pCxt->pRootNode = createShowDnodeVariablesStmt(pCxt, createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[-2].minor.yy0), yymsp[0].minor.yy724); } - break; - case 303: /* cmd ::= SHOW BNODES */ - { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_BNODES_STMT); } - break; - case 304: /* cmd ::= SHOW SNODES */ - { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_SNODES_STMT); } - break; - case 305: /* cmd ::= SHOW CLUSTER */ - { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_CLUSTER_STMT); } - break; - case 306: /* cmd ::= SHOW TRANSACTIONS */ - { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_TRANSACTIONS_STMT); } - break; - case 307: /* cmd ::= SHOW TABLE DISTRIBUTED full_table_name */ - { pCxt->pRootNode = createShowTableDistributedStmt(pCxt, yymsp[0].minor.yy724); } - break; - case 308: /* cmd ::= SHOW CONSUMERS */ - { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_CONSUMERS_STMT); } - break; - case 309: /* cmd ::= SHOW SUBSCRIPTIONS */ - { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_SUBSCRIPTIONS_STMT); } - break; - case 310: /* cmd ::= SHOW TAGS FROM table_name_cond from_db_opt */ - { pCxt->pRootNode = createShowStmtWithCond(pCxt, QUERY_NODE_SHOW_TAGS_STMT, yymsp[0].minor.yy724, yymsp[-1].minor.yy724, OP_TYPE_EQUAL); } - break; - case 311: /* cmd ::= SHOW TAGS FROM db_name NK_DOT table_name */ - { pCxt->pRootNode = createShowStmtWithCond(pCxt, QUERY_NODE_SHOW_TAGS_STMT, createIdentifierValueNode(pCxt, &yymsp[-2].minor.yy461), createIdentifierValueNode(pCxt, &yymsp[0].minor.yy461), OP_TYPE_EQUAL); } - break; - case 312: /* cmd ::= SHOW TABLE TAGS tag_list_opt FROM table_name_cond from_db_opt */ - { pCxt->pRootNode = createShowTableTagsStmt(pCxt, yymsp[-1].minor.yy724, yymsp[0].minor.yy724, yymsp[-3].minor.yy712); } - break; - case 313: /* cmd ::= SHOW TABLE TAGS tag_list_opt FROM db_name NK_DOT table_name */ - { pCxt->pRootNode = createShowTableTagsStmt(pCxt, createIdentifierValueNode(pCxt, &yymsp[0].minor.yy461), createIdentifierValueNode(pCxt, &yymsp[-2].minor.yy461), yymsp[-4].minor.yy712); } - break; - case 314: /* cmd ::= SHOW VNODES ON DNODE NK_INTEGER */ - { pCxt->pRootNode = createShowVnodesStmt(pCxt, createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0), NULL); } - break; - case 315: /* cmd ::= SHOW VNODES */ - { pCxt->pRootNode = createShowVnodesStmt(pCxt, NULL, NULL); } - break; - case 316: /* cmd ::= SHOW db_name_cond_opt ALIVE */ - { pCxt->pRootNode = createShowAliveStmt(pCxt, yymsp[-1].minor.yy724, QUERY_NODE_SHOW_DB_ALIVE_STMT); } - break; - case 317: /* cmd ::= SHOW CLUSTER ALIVE */ - { pCxt->pRootNode = createShowAliveStmt(pCxt, NULL, QUERY_NODE_SHOW_CLUSTER_ALIVE_STMT); } - break; - case 318: /* cmd ::= SHOW db_name_cond_opt VIEWS like_pattern_opt */ - { pCxt->pRootNode = createShowStmtWithCond(pCxt, QUERY_NODE_SHOW_VIEWS_STMT, yymsp[-2].minor.yy724, yymsp[0].minor.yy724, OP_TYPE_LIKE); } - break; - case 319: /* cmd ::= SHOW CREATE VIEW full_table_name */ - { pCxt->pRootNode = createShowCreateViewStmt(pCxt, QUERY_NODE_SHOW_CREATE_VIEW_STMT, yymsp[0].minor.yy724); } - break; - case 320: /* cmd ::= SHOW COMPACTS */ - { pCxt->pRootNode = createShowCompactsStmt(pCxt, QUERY_NODE_SHOW_COMPACTS_STMT); } - break; - case 321: /* cmd ::= SHOW COMPACT NK_INTEGER */ - { pCxt->pRootNode = createShowCompactDetailsStmt(pCxt, createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0)); } - break; - case 322: /* table_kind_db_name_cond_opt ::= */ - { yymsp[1].minor.yy801.kind = SHOW_KIND_ALL; yymsp[1].minor.yy801.dbName = nil_token; } - break; - case 323: /* table_kind_db_name_cond_opt ::= table_kind */ - { yylhsminor.yy801.kind = yymsp[0].minor.yy973; yylhsminor.yy801.dbName = nil_token; } - yymsp[0].minor.yy801 = yylhsminor.yy801; - break; - case 324: /* table_kind_db_name_cond_opt ::= db_name NK_DOT */ - { yylhsminor.yy801.kind = SHOW_KIND_ALL; yylhsminor.yy801.dbName = yymsp[-1].minor.yy461; } - yymsp[-1].minor.yy801 = yylhsminor.yy801; - break; - case 325: /* table_kind_db_name_cond_opt ::= table_kind db_name NK_DOT */ - { yylhsminor.yy801.kind = yymsp[-2].minor.yy973; yylhsminor.yy801.dbName = yymsp[-1].minor.yy461; } - yymsp[-2].minor.yy801 = yylhsminor.yy801; - break; - case 326: /* table_kind ::= NORMAL */ - { yymsp[0].minor.yy973 = SHOW_KIND_TABLES_NORMAL; } - break; - case 327: /* table_kind ::= CHILD */ - { yymsp[0].minor.yy973 = SHOW_KIND_TABLES_CHILD; } - break; - case 328: /* db_name_cond_opt ::= */ - case 333: /* from_db_opt ::= */ yytestcase(yyruleno==333); - { yymsp[1].minor.yy724 = createDefaultDatabaseCondValue(pCxt); } - break; - case 329: /* db_name_cond_opt ::= db_name NK_DOT */ - { yylhsminor.yy724 = createIdentifierValueNode(pCxt, &yymsp[-1].minor.yy461); } - yymsp[-1].minor.yy724 = yylhsminor.yy724; - break; - case 331: /* like_pattern_opt ::= LIKE NK_STRING */ - { yymsp[-1].minor.yy724 = createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy0); } - break; - case 332: /* table_name_cond ::= table_name */ - { yylhsminor.yy724 = createIdentifierValueNode(pCxt, &yymsp[0].minor.yy461); } - yymsp[0].minor.yy724 = yylhsminor.yy724; - break; - case 334: /* from_db_opt ::= FROM db_name */ - { yymsp[-1].minor.yy724 = createIdentifierValueNode(pCxt, &yymsp[0].minor.yy461); } - break; - case 338: /* tag_item ::= TBNAME */ - { yylhsminor.yy724 = setProjectionAlias(pCxt, createFunctionNode(pCxt, &yymsp[0].minor.yy0, NULL), &yymsp[0].minor.yy0); } - yymsp[0].minor.yy724 = yylhsminor.yy724; - break; - case 341: /* tag_item ::= column_name column_alias */ - { yylhsminor.yy724 = setProjectionAlias(pCxt, createColumnNode(pCxt, NULL, &yymsp[-1].minor.yy461), &yymsp[0].minor.yy461); } - yymsp[-1].minor.yy724 = yylhsminor.yy724; - break; - case 342: /* tag_item ::= column_name AS column_alias */ - { yylhsminor.yy724 = setProjectionAlias(pCxt, createColumnNode(pCxt, NULL, &yymsp[-2].minor.yy461), &yymsp[0].minor.yy461); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 343: /* db_kind_opt ::= */ - { yymsp[1].minor.yy973 = SHOW_KIND_ALL; } - break; - case 344: /* db_kind_opt ::= USER */ - { yymsp[0].minor.yy973 = SHOW_KIND_DATABASES_USER; } - break; - case 345: /* db_kind_opt ::= SYSTEM */ - { yymsp[0].minor.yy973 = SHOW_KIND_DATABASES_SYSTEM; } - break; - case 346: /* cmd ::= CREATE TSMA not_exists_opt tsma_name ON full_table_name tsma_func_list INTERVAL NK_LP duration_literal NK_RP */ - { pCxt->pRootNode = createCreateTSMAStmt(pCxt, yymsp[-8].minor.yy429, &yymsp[-7].minor.yy461, yymsp[-4].minor.yy724, yymsp[-5].minor.yy724, releaseRawExprNode(pCxt, yymsp[-1].minor.yy724)); } - break; - case 347: /* cmd ::= CREATE RECURSIVE TSMA not_exists_opt tsma_name ON full_table_name INTERVAL NK_LP duration_literal NK_RP */ - { pCxt->pRootNode = createCreateTSMAStmt(pCxt, yymsp[-7].minor.yy429, &yymsp[-6].minor.yy461, NULL, yymsp[-4].minor.yy724, releaseRawExprNode(pCxt, yymsp[-1].minor.yy724)); } - break; - case 348: /* cmd ::= DROP TSMA exists_opt full_tsma_name */ - { pCxt->pRootNode = createDropTSMAStmt(pCxt, yymsp[-1].minor.yy429, yymsp[0].minor.yy724); } - break; - case 349: /* cmd ::= SHOW db_name_cond_opt TSMAS */ - { pCxt->pRootNode = createShowTSMASStmt(pCxt, yymsp[-1].minor.yy724); } - break; - case 352: /* tsma_func_list ::= FUNCTION NK_LP func_list NK_RP */ - { yymsp[-3].minor.yy724 = createTSMAOptions(pCxt, yymsp[-1].minor.yy712); } - break; - case 353: /* cmd ::= CREATE SMA INDEX not_exists_opt col_name ON full_table_name index_options */ - { pCxt->pRootNode = createCreateIndexStmt(pCxt, INDEX_TYPE_SMA, yymsp[-4].minor.yy429, yymsp[-3].minor.yy724, yymsp[-1].minor.yy724, NULL, yymsp[0].minor.yy724); } - break; - case 354: /* cmd ::= CREATE INDEX not_exists_opt col_name ON full_table_name NK_LP col_name_list NK_RP */ - { pCxt->pRootNode = createCreateIndexStmt(pCxt, INDEX_TYPE_NORMAL, yymsp[-6].minor.yy429, yymsp[-5].minor.yy724, yymsp[-3].minor.yy724, yymsp[-1].minor.yy712, NULL); } - break; - case 355: /* cmd ::= DROP INDEX exists_opt full_index_name */ - { pCxt->pRootNode = createDropIndexStmt(pCxt, yymsp[-1].minor.yy429, yymsp[0].minor.yy724); } - break; - case 356: /* full_index_name ::= index_name */ - { yylhsminor.yy724 = createRealTableNodeForIndexName(pCxt, NULL, &yymsp[0].minor.yy461); } - yymsp[0].minor.yy724 = yylhsminor.yy724; - break; - case 357: /* full_index_name ::= db_name NK_DOT index_name */ - { yylhsminor.yy724 = createRealTableNodeForIndexName(pCxt, &yymsp[-2].minor.yy461, &yymsp[0].minor.yy461); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 358: /* index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_RP sliding_opt sma_stream_opt */ - { yymsp[-9].minor.yy724 = createIndexOption(pCxt, yymsp[-7].minor.yy712, releaseRawExprNode(pCxt, yymsp[-3].minor.yy724), NULL, yymsp[-1].minor.yy724, yymsp[0].minor.yy724); } - break; - case 359: /* index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_COMMA duration_literal NK_RP sliding_opt sma_stream_opt */ - { yymsp[-11].minor.yy724 = createIndexOption(pCxt, yymsp[-9].minor.yy712, releaseRawExprNode(pCxt, yymsp[-5].minor.yy724), releaseRawExprNode(pCxt, yymsp[-3].minor.yy724), yymsp[-1].minor.yy724, yymsp[0].minor.yy724); } - break; - case 362: /* func ::= sma_func_name NK_LP expression_list NK_RP */ - { yylhsminor.yy724 = createFunctionNode(pCxt, &yymsp[-3].minor.yy461, yymsp[-1].minor.yy712); } - yymsp[-3].minor.yy724 = yylhsminor.yy724; - break; - case 363: /* sma_func_name ::= function_name */ - case 655: /* alias_opt ::= table_alias */ yytestcase(yyruleno==655); - { yylhsminor.yy461 = yymsp[0].minor.yy461; } - yymsp[0].minor.yy461 = yylhsminor.yy461; - break; - case 368: /* sma_stream_opt ::= */ - case 418: /* stream_options ::= */ yytestcase(yyruleno==418); - { yymsp[1].minor.yy724 = createStreamOptions(pCxt); } - break; - case 369: /* sma_stream_opt ::= sma_stream_opt WATERMARK duration_literal */ - { ((SStreamOptions*)yymsp[-2].minor.yy724)->pWatermark = releaseRawExprNode(pCxt, yymsp[0].minor.yy724); yylhsminor.yy724 = yymsp[-2].minor.yy724; } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 370: /* sma_stream_opt ::= sma_stream_opt MAX_DELAY duration_literal */ - { ((SStreamOptions*)yymsp[-2].minor.yy724)->pDelay = releaseRawExprNode(pCxt, yymsp[0].minor.yy724); yylhsminor.yy724 = yymsp[-2].minor.yy724; } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 371: /* sma_stream_opt ::= sma_stream_opt DELETE_MARK duration_literal */ - { ((SStreamOptions*)yymsp[-2].minor.yy724)->pDeleteMark = releaseRawExprNode(pCxt, yymsp[0].minor.yy724); yylhsminor.yy724 = yymsp[-2].minor.yy724; } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 372: /* with_meta ::= AS */ - { yymsp[0].minor.yy696 = 0; } - break; - case 373: /* with_meta ::= WITH META AS */ - { yymsp[-2].minor.yy696 = 1; } - break; - case 374: /* with_meta ::= ONLY META AS */ - { yymsp[-2].minor.yy696 = 2; } - break; - case 375: /* cmd ::= CREATE TOPIC not_exists_opt topic_name AS query_or_subquery */ - { pCxt->pRootNode = createCreateTopicStmtUseQuery(pCxt, yymsp[-3].minor.yy429, &yymsp[-2].minor.yy461, yymsp[0].minor.yy724); } - break; - case 376: /* cmd ::= CREATE TOPIC not_exists_opt topic_name with_meta DATABASE db_name */ - { pCxt->pRootNode = createCreateTopicStmtUseDb(pCxt, yymsp[-4].minor.yy429, &yymsp[-3].minor.yy461, &yymsp[0].minor.yy461, yymsp[-2].minor.yy696); } - break; - case 377: /* cmd ::= CREATE TOPIC not_exists_opt topic_name with_meta STABLE full_table_name where_clause_opt */ - { pCxt->pRootNode = createCreateTopicStmtUseTable(pCxt, yymsp[-5].minor.yy429, &yymsp[-4].minor.yy461, yymsp[-1].minor.yy724, yymsp[-3].minor.yy696, yymsp[0].minor.yy724); } - break; - case 378: /* cmd ::= DROP TOPIC exists_opt topic_name */ - { pCxt->pRootNode = createDropTopicStmt(pCxt, yymsp[-1].minor.yy429, &yymsp[0].minor.yy461); } - break; - case 379: /* cmd ::= DROP CONSUMER GROUP exists_opt cgroup_name ON topic_name */ - { pCxt->pRootNode = createDropCGroupStmt(pCxt, yymsp[-3].minor.yy429, &yymsp[-2].minor.yy461, &yymsp[0].minor.yy461); } - break; - case 380: /* cmd ::= DESC full_table_name */ - case 381: /* cmd ::= DESCRIBE full_table_name */ yytestcase(yyruleno==381); - { pCxt->pRootNode = createDescribeStmt(pCxt, yymsp[0].minor.yy724); } - break; - case 382: /* cmd ::= RESET QUERY CACHE */ - { pCxt->pRootNode = createResetQueryCacheStmt(pCxt); } - break; - case 383: /* cmd ::= EXPLAIN analyze_opt explain_options query_or_subquery */ - case 384: /* cmd ::= EXPLAIN analyze_opt explain_options insert_query */ yytestcase(yyruleno==384); - { pCxt->pRootNode = createExplainStmt(pCxt, yymsp[-2].minor.yy429, yymsp[-1].minor.yy724, yymsp[0].minor.yy724); } - break; - case 387: /* explain_options ::= */ - { yymsp[1].minor.yy724 = createDefaultExplainOptions(pCxt); } - break; - case 388: /* explain_options ::= explain_options VERBOSE NK_BOOL */ - { yylhsminor.yy724 = setExplainVerbose(pCxt, yymsp[-2].minor.yy724, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 389: /* explain_options ::= explain_options RATIO NK_FLOAT */ - { yylhsminor.yy724 = setExplainRatio(pCxt, yymsp[-2].minor.yy724, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 390: /* cmd ::= CREATE or_replace_opt agg_func_opt FUNCTION not_exists_opt function_name AS NK_STRING OUTPUTTYPE type_name bufsize_opt language_opt */ - { pCxt->pRootNode = createCreateFunctionStmt(pCxt, yymsp[-7].minor.yy429, yymsp[-9].minor.yy429, &yymsp[-6].minor.yy461, &yymsp[-4].minor.yy0, yymsp[-2].minor.yy1016, yymsp[-1].minor.yy696, &yymsp[0].minor.yy461, yymsp[-10].minor.yy429); } - break; - case 391: /* cmd ::= DROP FUNCTION exists_opt function_name */ - { pCxt->pRootNode = createDropFunctionStmt(pCxt, yymsp[-1].minor.yy429, &yymsp[0].minor.yy461); } - break; - case 396: /* language_opt ::= */ - case 441: /* on_vgroup_id ::= */ yytestcase(yyruleno==441); - { yymsp[1].minor.yy461 = nil_token; } - break; - case 397: /* language_opt ::= LANGUAGE NK_STRING */ - case 442: /* on_vgroup_id ::= ON NK_INTEGER */ yytestcase(yyruleno==442); - { yymsp[-1].minor.yy461 = yymsp[0].minor.yy0; } - break; - case 400: /* cmd ::= CREATE or_replace_opt VIEW full_view_name AS query_or_subquery */ - { pCxt->pRootNode = createCreateViewStmt(pCxt, yymsp[-4].minor.yy429, yymsp[-2].minor.yy724, &yymsp[-1].minor.yy0, yymsp[0].minor.yy724); } - break; - case 401: /* cmd ::= DROP VIEW exists_opt full_view_name */ - { pCxt->pRootNode = createDropViewStmt(pCxt, yymsp[-1].minor.yy429, yymsp[0].minor.yy724); } - break; - case 402: /* full_view_name ::= view_name */ - { yylhsminor.yy724 = createViewNode(pCxt, NULL, &yymsp[0].minor.yy461); } - yymsp[0].minor.yy724 = yylhsminor.yy724; - break; - case 403: /* full_view_name ::= db_name NK_DOT view_name */ - { yylhsminor.yy724 = createViewNode(pCxt, &yymsp[-2].minor.yy461, &yymsp[0].minor.yy461); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 404: /* cmd ::= CREATE STREAM not_exists_opt stream_name stream_options INTO full_table_name col_list_opt tag_def_or_ref_opt subtable_opt AS query_or_subquery */ - { pCxt->pRootNode = createCreateStreamStmt(pCxt, yymsp[-9].minor.yy429, &yymsp[-8].minor.yy461, yymsp[-5].minor.yy724, yymsp[-7].minor.yy724, yymsp[-3].minor.yy712, yymsp[-2].minor.yy724, yymsp[0].minor.yy724, yymsp[-4].minor.yy712); } - break; - case 405: /* cmd ::= DROP STREAM exists_opt stream_name */ - { pCxt->pRootNode = createDropStreamStmt(pCxt, yymsp[-1].minor.yy429, &yymsp[0].minor.yy461); } - break; - case 406: /* cmd ::= PAUSE STREAM exists_opt stream_name */ - { pCxt->pRootNode = createPauseStreamStmt(pCxt, yymsp[-1].minor.yy429, &yymsp[0].minor.yy461); } - break; - case 407: /* cmd ::= RESUME STREAM exists_opt ignore_opt stream_name */ - { pCxt->pRootNode = createResumeStreamStmt(pCxt, yymsp[-2].minor.yy429, yymsp[-1].minor.yy429, &yymsp[0].minor.yy461); } - break; - case 412: /* column_stream_def ::= column_name stream_col_options */ - { yylhsminor.yy724 = createColumnDefNode(pCxt, &yymsp[-1].minor.yy461, createDataType(TSDB_DATA_TYPE_NULL), yymsp[0].minor.yy724); } - yymsp[-1].minor.yy724 = yylhsminor.yy724; - break; - case 413: /* stream_col_options ::= */ - case 768: /* column_options ::= */ yytestcase(yyruleno==768); - { yymsp[1].minor.yy724 = createDefaultColumnOptions(pCxt); } - break; - case 414: /* stream_col_options ::= stream_col_options PRIMARY KEY */ - case 769: /* column_options ::= column_options PRIMARY KEY */ yytestcase(yyruleno==769); - { yylhsminor.yy724 = setColumnOptionsPK(pCxt, yymsp[-2].minor.yy724); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 419: /* stream_options ::= stream_options TRIGGER AT_ONCE */ - case 420: /* stream_options ::= stream_options TRIGGER WINDOW_CLOSE */ yytestcase(yyruleno==420); - { yylhsminor.yy724 = setStreamOptions(pCxt, yymsp[-2].minor.yy724, SOPT_TRIGGER_TYPE_SET, &yymsp[0].minor.yy0, NULL); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 421: /* stream_options ::= stream_options TRIGGER MAX_DELAY duration_literal */ - { yylhsminor.yy724 = setStreamOptions(pCxt, yymsp[-3].minor.yy724, SOPT_TRIGGER_TYPE_SET, &yymsp[-1].minor.yy0, releaseRawExprNode(pCxt, yymsp[0].minor.yy724)); } - yymsp[-3].minor.yy724 = yylhsminor.yy724; - break; - case 422: /* stream_options ::= stream_options WATERMARK duration_literal */ - { yylhsminor.yy724 = setStreamOptions(pCxt, yymsp[-2].minor.yy724, SOPT_WATERMARK_SET, NULL, releaseRawExprNode(pCxt, yymsp[0].minor.yy724)); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 423: /* stream_options ::= stream_options IGNORE EXPIRED NK_INTEGER */ - { yylhsminor.yy724 = setStreamOptions(pCxt, yymsp[-3].minor.yy724, SOPT_IGNORE_EXPIRED_SET, &yymsp[0].minor.yy0, NULL); } - yymsp[-3].minor.yy724 = yylhsminor.yy724; - break; - case 424: /* stream_options ::= stream_options FILL_HISTORY NK_INTEGER */ - { yylhsminor.yy724 = setStreamOptions(pCxt, yymsp[-2].minor.yy724, SOPT_FILL_HISTORY_SET, &yymsp[0].minor.yy0, NULL); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 425: /* stream_options ::= stream_options DELETE_MARK duration_literal */ - { yylhsminor.yy724 = setStreamOptions(pCxt, yymsp[-2].minor.yy724, SOPT_DELETE_MARK_SET, NULL, releaseRawExprNode(pCxt, yymsp[0].minor.yy724)); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 426: /* stream_options ::= stream_options IGNORE UPDATE NK_INTEGER */ - { yylhsminor.yy724 = setStreamOptions(pCxt, yymsp[-3].minor.yy724, SOPT_IGNORE_UPDATE_SET, &yymsp[0].minor.yy0, NULL); } - yymsp[-3].minor.yy724 = yylhsminor.yy724; - break; - case 428: /* subtable_opt ::= SUBTABLE NK_LP expression NK_RP */ - case 712: /* sliding_opt ::= SLIDING NK_LP interval_sliding_duration_literal NK_RP */ yytestcase(yyruleno==712); - case 736: /* every_opt ::= EVERY NK_LP duration_literal NK_RP */ yytestcase(yyruleno==736); - { yymsp[-3].minor.yy724 = releaseRawExprNode(pCxt, yymsp[-1].minor.yy724); } - break; - case 431: /* cmd ::= KILL CONNECTION NK_INTEGER */ - { pCxt->pRootNode = createKillStmt(pCxt, QUERY_NODE_KILL_CONNECTION_STMT, &yymsp[0].minor.yy0); } - break; - case 432: /* cmd ::= KILL QUERY NK_STRING */ - { pCxt->pRootNode = createKillQueryStmt(pCxt, &yymsp[0].minor.yy0); } - break; - case 433: /* cmd ::= KILL TRANSACTION NK_INTEGER */ - { pCxt->pRootNode = createKillStmt(pCxt, QUERY_NODE_KILL_TRANSACTION_STMT, &yymsp[0].minor.yy0); } - break; - case 434: /* cmd ::= KILL COMPACT NK_INTEGER */ - { pCxt->pRootNode = createKillStmt(pCxt, QUERY_NODE_KILL_COMPACT_STMT, &yymsp[0].minor.yy0); } - break; - case 435: /* cmd ::= BALANCE VGROUP */ - { pCxt->pRootNode = createBalanceVgroupStmt(pCxt); } - break; - case 436: /* cmd ::= BALANCE VGROUP LEADER on_vgroup_id */ - { pCxt->pRootNode = createBalanceVgroupLeaderStmt(pCxt, &yymsp[0].minor.yy461); } - break; - case 437: /* cmd ::= BALANCE VGROUP LEADER DATABASE db_name */ - { pCxt->pRootNode = createBalanceVgroupLeaderDBNameStmt(pCxt, &yymsp[0].minor.yy461); } - break; - case 438: /* cmd ::= MERGE VGROUP NK_INTEGER NK_INTEGER */ - { pCxt->pRootNode = createMergeVgroupStmt(pCxt, &yymsp[-1].minor.yy0, &yymsp[0].minor.yy0); } - break; - case 439: /* cmd ::= REDISTRIBUTE VGROUP NK_INTEGER dnode_list */ - { pCxt->pRootNode = createRedistributeVgroupStmt(pCxt, &yymsp[-1].minor.yy0, yymsp[0].minor.yy712); } - break; - case 440: /* cmd ::= SPLIT VGROUP NK_INTEGER */ - { pCxt->pRootNode = createSplitVgroupStmt(pCxt, &yymsp[0].minor.yy0); } - break; - case 443: /* dnode_list ::= DNODE NK_INTEGER */ - { yymsp[-1].minor.yy712 = createNodeList(pCxt, createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0)); } - break; - case 445: /* cmd ::= DELETE FROM full_table_name where_clause_opt */ - { pCxt->pRootNode = createDeleteStmt(pCxt, yymsp[-1].minor.yy724, yymsp[0].minor.yy724); } - break; - case 448: /* insert_query ::= INSERT INTO full_table_name NK_LP col_name_list NK_RP query_or_subquery */ - { yymsp[-6].minor.yy724 = createInsertStmt(pCxt, yymsp[-4].minor.yy724, yymsp[-2].minor.yy712, yymsp[0].minor.yy724); } - break; - case 449: /* insert_query ::= INSERT INTO full_table_name query_or_subquery */ - { yymsp[-3].minor.yy724 = createInsertStmt(pCxt, yymsp[-1].minor.yy724, NULL, yymsp[0].minor.yy724); } - break; - case 450: /* tags_literal ::= NK_INTEGER */ - case 462: /* tags_literal ::= NK_BIN */ yytestcase(yyruleno==462); - case 471: /* tags_literal ::= NK_HEX */ yytestcase(yyruleno==471); - { yylhsminor.yy724 = createRawValueNode(pCxt, TSDB_DATA_TYPE_UBIGINT, &yymsp[0].minor.yy0, NULL); } - yymsp[0].minor.yy724 = yylhsminor.yy724; - break; - case 451: /* tags_literal ::= NK_INTEGER NK_PLUS duration_literal */ - case 452: /* tags_literal ::= NK_INTEGER NK_MINUS duration_literal */ yytestcase(yyruleno==452); - case 463: /* tags_literal ::= NK_BIN NK_PLUS duration_literal */ yytestcase(yyruleno==463); - case 464: /* tags_literal ::= NK_BIN NK_MINUS duration_literal */ yytestcase(yyruleno==464); - case 472: /* tags_literal ::= NK_HEX NK_PLUS duration_literal */ yytestcase(yyruleno==472); - case 473: /* tags_literal ::= NK_HEX NK_MINUS duration_literal */ yytestcase(yyruleno==473); - case 481: /* tags_literal ::= NK_STRING NK_PLUS duration_literal */ yytestcase(yyruleno==481); - case 482: /* tags_literal ::= NK_STRING NK_MINUS duration_literal */ yytestcase(yyruleno==482); - { - SToken l = yymsp[-2].minor.yy0; - SToken r = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy724); - l.n = (r.z + r.n) - l.z; - yylhsminor.yy724 = createRawValueNodeExt(pCxt, TSDB_DATA_TYPE_BINARY, &l, NULL, yymsp[0].minor.yy724); - } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 453: /* tags_literal ::= NK_PLUS NK_INTEGER */ - case 456: /* tags_literal ::= NK_MINUS NK_INTEGER */ yytestcase(yyruleno==456); - case 465: /* tags_literal ::= NK_PLUS NK_BIN */ yytestcase(yyruleno==465); - case 468: /* tags_literal ::= NK_MINUS NK_BIN */ yytestcase(yyruleno==468); - case 474: /* tags_literal ::= NK_PLUS NK_HEX */ yytestcase(yyruleno==474); - case 477: /* tags_literal ::= NK_MINUS NK_HEX */ yytestcase(yyruleno==477); - { - SToken t = yymsp[-1].minor.yy0; - t.n = (yymsp[0].minor.yy0.z + yymsp[0].minor.yy0.n) - yymsp[-1].minor.yy0.z; - yylhsminor.yy724 = createRawValueNode(pCxt, TSDB_DATA_TYPE_UBIGINT, &t, NULL); - } - yymsp[-1].minor.yy724 = yylhsminor.yy724; - break; - case 454: /* tags_literal ::= NK_PLUS NK_INTEGER NK_PLUS duration_literal */ - case 455: /* tags_literal ::= NK_PLUS NK_INTEGER NK_MINUS duration_literal */ yytestcase(yyruleno==455); - case 457: /* tags_literal ::= NK_MINUS NK_INTEGER NK_PLUS duration_literal */ yytestcase(yyruleno==457); - case 458: /* tags_literal ::= NK_MINUS NK_INTEGER NK_MINUS duration_literal */ yytestcase(yyruleno==458); - case 466: /* tags_literal ::= NK_PLUS NK_BIN NK_PLUS duration_literal */ yytestcase(yyruleno==466); - case 467: /* tags_literal ::= NK_PLUS NK_BIN NK_MINUS duration_literal */ yytestcase(yyruleno==467); - case 469: /* tags_literal ::= NK_MINUS NK_BIN NK_PLUS duration_literal */ yytestcase(yyruleno==469); - case 470: /* tags_literal ::= NK_MINUS NK_BIN NK_MINUS duration_literal */ yytestcase(yyruleno==470); - case 475: /* tags_literal ::= NK_PLUS NK_HEX NK_PLUS duration_literal */ yytestcase(yyruleno==475); - case 476: /* tags_literal ::= NK_PLUS NK_HEX NK_MINUS duration_literal */ yytestcase(yyruleno==476); - case 478: /* tags_literal ::= NK_MINUS NK_HEX NK_PLUS duration_literal */ yytestcase(yyruleno==478); - case 479: /* tags_literal ::= NK_MINUS NK_HEX NK_MINUS duration_literal */ yytestcase(yyruleno==479); - { - SToken l = yymsp[-3].minor.yy0; - SToken r = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy724); - l.n = (r.z + r.n) - l.z; - yylhsminor.yy724 = createRawValueNodeExt(pCxt, TSDB_DATA_TYPE_BINARY, &l, NULL, yymsp[0].minor.yy724); - } - yymsp[-3].minor.yy724 = yylhsminor.yy724; - break; - case 459: /* tags_literal ::= NK_FLOAT */ - { yylhsminor.yy724 = createRawValueNode(pCxt, TSDB_DATA_TYPE_DOUBLE, &yymsp[0].minor.yy0, NULL); } - yymsp[0].minor.yy724 = yylhsminor.yy724; - break; - case 460: /* tags_literal ::= NK_PLUS NK_FLOAT */ - case 461: /* tags_literal ::= NK_MINUS NK_FLOAT */ yytestcase(yyruleno==461); - { - SToken t = yymsp[-1].minor.yy0; - t.n = (yymsp[0].minor.yy0.z + yymsp[0].minor.yy0.n) - yymsp[-1].minor.yy0.z; - yylhsminor.yy724 = createRawValueNode(pCxt, TSDB_DATA_TYPE_DOUBLE, &t, NULL); - } - yymsp[-1].minor.yy724 = yylhsminor.yy724; - break; - case 480: /* tags_literal ::= NK_STRING */ - { yylhsminor.yy724 = createRawValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy0, NULL); } - yymsp[0].minor.yy724 = yylhsminor.yy724; - break; - case 483: /* tags_literal ::= NK_BOOL */ - { yylhsminor.yy724 = createRawValueNode(pCxt, TSDB_DATA_TYPE_BOOL, &yymsp[0].minor.yy0, NULL); } - yymsp[0].minor.yy724 = yylhsminor.yy724; - break; - case 484: /* tags_literal ::= NULL */ - { yylhsminor.yy724 = createRawValueNode(pCxt, TSDB_DATA_TYPE_NULL, &yymsp[0].minor.yy0, NULL); } - yymsp[0].minor.yy724 = yylhsminor.yy724; - break; - case 485: /* tags_literal ::= literal_func */ - { yylhsminor.yy724 = createRawValueNode(pCxt, TSDB_DATA_TYPE_BINARY, NULL, yymsp[0].minor.yy724); } - yymsp[0].minor.yy724 = yylhsminor.yy724; - break; - case 486: /* tags_literal ::= literal_func NK_PLUS duration_literal */ - case 487: /* tags_literal ::= literal_func NK_MINUS duration_literal */ yytestcase(yyruleno==487); - { - SToken l = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy724); - SToken r = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy724); - l.n = (r.z + r.n) - l.z; - yylhsminor.yy724 = createRawValueNodeExt(pCxt, TSDB_DATA_TYPE_BINARY, &l, yymsp[-2].minor.yy724, yymsp[0].minor.yy724); - } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 490: /* literal ::= NK_INTEGER */ - { yylhsminor.yy724 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_UBIGINT, &yymsp[0].minor.yy0)); } - yymsp[0].minor.yy724 = yylhsminor.yy724; - break; - case 491: /* literal ::= NK_FLOAT */ - { yylhsminor.yy724 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_DOUBLE, &yymsp[0].minor.yy0)); } - yymsp[0].minor.yy724 = yylhsminor.yy724; - break; - case 492: /* literal ::= NK_STRING */ - { yylhsminor.yy724 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy0)); } - yymsp[0].minor.yy724 = yylhsminor.yy724; - break; - case 493: /* literal ::= NK_BOOL */ - { yylhsminor.yy724 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_BOOL, &yymsp[0].minor.yy0)); } - yymsp[0].minor.yy724 = yylhsminor.yy724; - break; - case 494: /* literal ::= TIMESTAMP NK_STRING */ - { yylhsminor.yy724 = createRawExprNodeExt(pCxt, &yymsp[-1].minor.yy0, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_TIMESTAMP, &yymsp[0].minor.yy0)); } - yymsp[-1].minor.yy724 = yylhsminor.yy724; - break; - case 495: /* literal ::= duration_literal */ - case 505: /* signed_literal ::= signed */ yytestcase(yyruleno==505); - case 529: /* expr_or_subquery ::= expression */ yytestcase(yyruleno==529); - case 530: /* expression ::= literal */ yytestcase(yyruleno==530); - case 532: /* expression ::= column_reference */ yytestcase(yyruleno==532); - case 533: /* expression ::= function_expression */ yytestcase(yyruleno==533); - case 534: /* expression ::= case_when_expression */ yytestcase(yyruleno==534); - case 577: /* function_expression ::= literal_func */ yytestcase(yyruleno==577); - case 578: /* function_expression ::= rand_func */ yytestcase(yyruleno==578); - case 636: /* boolean_value_expression ::= boolean_primary */ yytestcase(yyruleno==636); - case 640: /* boolean_primary ::= predicate */ yytestcase(yyruleno==640); - case 642: /* common_expression ::= expr_or_subquery */ yytestcase(yyruleno==642); - case 643: /* common_expression ::= boolean_value_expression */ yytestcase(yyruleno==643); - case 646: /* table_reference_list ::= table_reference */ yytestcase(yyruleno==646); - case 648: /* table_reference ::= table_primary */ yytestcase(yyruleno==648); - case 649: /* table_reference ::= joined_table */ yytestcase(yyruleno==649); - case 653: /* table_primary ::= parenthesized_joined_table */ yytestcase(yyruleno==653); - case 738: /* query_simple ::= query_specification */ yytestcase(yyruleno==738); - case 739: /* query_simple ::= union_query_expression */ yytestcase(yyruleno==739); - case 742: /* query_simple_or_subquery ::= query_simple */ yytestcase(yyruleno==742); - case 744: /* query_or_subquery ::= query_expression */ yytestcase(yyruleno==744); - { yylhsminor.yy724 = yymsp[0].minor.yy724; } - yymsp[0].minor.yy724 = yylhsminor.yy724; - break; - case 496: /* literal ::= NULL */ - { yylhsminor.yy724 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_NULL, &yymsp[0].minor.yy0)); } - yymsp[0].minor.yy724 = yylhsminor.yy724; - break; - case 497: /* literal ::= NK_QUESTION */ - { yylhsminor.yy724 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createPlaceholderValueNode(pCxt, &yymsp[0].minor.yy0)); } - yymsp[0].minor.yy724 = yylhsminor.yy724; - break; - case 498: /* duration_literal ::= NK_VARIABLE */ - case 713: /* interval_sliding_duration_literal ::= NK_VARIABLE */ yytestcase(yyruleno==713); - case 714: /* interval_sliding_duration_literal ::= NK_STRING */ yytestcase(yyruleno==714); - case 715: /* interval_sliding_duration_literal ::= NK_INTEGER */ yytestcase(yyruleno==715); - { yylhsminor.yy724 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createDurationValueNode(pCxt, &yymsp[0].minor.yy0)); } - yymsp[0].minor.yy724 = yylhsminor.yy724; - break; - case 499: /* signed ::= NK_INTEGER */ - { yylhsminor.yy724 = createValueNode(pCxt, TSDB_DATA_TYPE_UBIGINT, &yymsp[0].minor.yy0); } - yymsp[0].minor.yy724 = yylhsminor.yy724; - break; - case 500: /* signed ::= NK_PLUS NK_INTEGER */ - { yymsp[-1].minor.yy724 = createValueNode(pCxt, TSDB_DATA_TYPE_UBIGINT, &yymsp[0].minor.yy0); } - break; - case 501: /* signed ::= NK_MINUS NK_INTEGER */ - { - SToken t = yymsp[-1].minor.yy0; - t.n = (yymsp[0].minor.yy0.z + yymsp[0].minor.yy0.n) - yymsp[-1].minor.yy0.z; - yylhsminor.yy724 = createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &t); - } - yymsp[-1].minor.yy724 = yylhsminor.yy724; - break; - case 502: /* signed ::= NK_FLOAT */ - { yylhsminor.yy724 = createValueNode(pCxt, TSDB_DATA_TYPE_DOUBLE, &yymsp[0].minor.yy0); } - yymsp[0].minor.yy724 = yylhsminor.yy724; - break; - case 503: /* signed ::= NK_PLUS NK_FLOAT */ - { yymsp[-1].minor.yy724 = createValueNode(pCxt, TSDB_DATA_TYPE_DOUBLE, &yymsp[0].minor.yy0); } - break; - case 504: /* signed ::= NK_MINUS NK_FLOAT */ - { - SToken t = yymsp[-1].minor.yy0; - t.n = (yymsp[0].minor.yy0.z + yymsp[0].minor.yy0.n) - yymsp[-1].minor.yy0.z; - yylhsminor.yy724 = createValueNode(pCxt, TSDB_DATA_TYPE_DOUBLE, &t); - } - yymsp[-1].minor.yy724 = yylhsminor.yy724; - break; - case 506: /* signed_literal ::= NK_STRING */ - { yylhsminor.yy724 = createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy0); } - yymsp[0].minor.yy724 = yylhsminor.yy724; - break; - case 507: /* signed_literal ::= NK_BOOL */ - { yylhsminor.yy724 = createValueNode(pCxt, TSDB_DATA_TYPE_BOOL, &yymsp[0].minor.yy0); } - yymsp[0].minor.yy724 = yylhsminor.yy724; - break; - case 508: /* signed_literal ::= TIMESTAMP NK_STRING */ - { yymsp[-1].minor.yy724 = createValueNode(pCxt, TSDB_DATA_TYPE_TIMESTAMP, &yymsp[0].minor.yy0); } - break; - case 509: /* signed_literal ::= duration_literal */ - case 511: /* signed_literal ::= literal_func */ yytestcase(yyruleno==511); - case 607: /* star_func_para ::= expr_or_subquery */ yytestcase(yyruleno==607); - case 690: /* select_item ::= common_expression */ yytestcase(yyruleno==690); - case 700: /* partition_item ::= expr_or_subquery */ yytestcase(yyruleno==700); - case 743: /* query_simple_or_subquery ::= subquery */ yytestcase(yyruleno==743); - case 745: /* query_or_subquery ::= subquery */ yytestcase(yyruleno==745); - case 758: /* search_condition ::= common_expression */ yytestcase(yyruleno==758); - { yylhsminor.yy724 = releaseRawExprNode(pCxt, yymsp[0].minor.yy724); } - yymsp[0].minor.yy724 = yylhsminor.yy724; - break; - case 510: /* signed_literal ::= NULL */ - { yylhsminor.yy724 = createValueNode(pCxt, TSDB_DATA_TYPE_NULL, &yymsp[0].minor.yy0); } - yymsp[0].minor.yy724 = yylhsminor.yy724; - break; - case 512: /* signed_literal ::= NK_QUESTION */ - { yylhsminor.yy724 = createPlaceholderValueNode(pCxt, &yymsp[0].minor.yy0); } - yymsp[0].minor.yy724 = yylhsminor.yy724; - break; - case 531: /* expression ::= pseudo_column */ - { yylhsminor.yy724 = yymsp[0].minor.yy724; (void)setRawExprNodeIsPseudoColumn(pCxt, yylhsminor.yy724, true); } - yymsp[0].minor.yy724 = yylhsminor.yy724; - break; - case 535: /* expression ::= NK_LP expression NK_RP */ - case 641: /* boolean_primary ::= NK_LP boolean_value_expression NK_RP */ yytestcase(yyruleno==641); - case 757: /* subquery ::= NK_LP subquery NK_RP */ yytestcase(yyruleno==757); - { yylhsminor.yy724 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy0, &yymsp[0].minor.yy0, releaseRawExprNode(pCxt, yymsp[-1].minor.yy724)); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 536: /* expression ::= NK_PLUS expr_or_subquery */ - { - SToken t = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy724); - yylhsminor.yy724 = createRawExprNodeExt(pCxt, &yymsp[-1].minor.yy0, &t, releaseRawExprNode(pCxt, yymsp[0].minor.yy724)); - } - yymsp[-1].minor.yy724 = yylhsminor.yy724; - break; - case 537: /* expression ::= NK_MINUS expr_or_subquery */ - { - SToken t = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy724); - yylhsminor.yy724 = createRawExprNodeExt(pCxt, &yymsp[-1].minor.yy0, &t, createOperatorNode(pCxt, OP_TYPE_MINUS, releaseRawExprNode(pCxt, yymsp[0].minor.yy724), NULL)); - } - yymsp[-1].minor.yy724 = yylhsminor.yy724; - break; - case 538: /* expression ::= expr_or_subquery NK_PLUS expr_or_subquery */ - { - SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy724); - SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy724); - yylhsminor.yy724 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, OP_TYPE_ADD, releaseRawExprNode(pCxt, yymsp[-2].minor.yy724), releaseRawExprNode(pCxt, yymsp[0].minor.yy724))); - } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 539: /* expression ::= expr_or_subquery NK_MINUS expr_or_subquery */ - { - SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy724); - SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy724); - yylhsminor.yy724 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, OP_TYPE_SUB, releaseRawExprNode(pCxt, yymsp[-2].minor.yy724), releaseRawExprNode(pCxt, yymsp[0].minor.yy724))); - } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 540: /* expression ::= expr_or_subquery NK_STAR expr_or_subquery */ - { - SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy724); - SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy724); - yylhsminor.yy724 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, OP_TYPE_MULTI, releaseRawExprNode(pCxt, yymsp[-2].minor.yy724), releaseRawExprNode(pCxt, yymsp[0].minor.yy724))); - } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 541: /* expression ::= expr_or_subquery NK_SLASH expr_or_subquery */ - { - SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy724); - SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy724); - yylhsminor.yy724 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, OP_TYPE_DIV, releaseRawExprNode(pCxt, yymsp[-2].minor.yy724), releaseRawExprNode(pCxt, yymsp[0].minor.yy724))); - } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 542: /* expression ::= expr_or_subquery NK_REM expr_or_subquery */ - { - SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy724); - SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy724); - yylhsminor.yy724 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, OP_TYPE_REM, releaseRawExprNode(pCxt, yymsp[-2].minor.yy724), releaseRawExprNode(pCxt, yymsp[0].minor.yy724))); - } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 543: /* expression ::= column_reference NK_ARROW NK_STRING */ - { - SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy724); - yylhsminor.yy724 = createRawExprNodeExt(pCxt, &s, &yymsp[0].minor.yy0, createOperatorNode(pCxt, OP_TYPE_JSON_GET_VALUE, releaseRawExprNode(pCxt, yymsp[-2].minor.yy724), createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy0))); - } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 544: /* expression ::= expr_or_subquery NK_BITAND expr_or_subquery */ - { - SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy724); - SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy724); - yylhsminor.yy724 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, OP_TYPE_BIT_AND, releaseRawExprNode(pCxt, yymsp[-2].minor.yy724), releaseRawExprNode(pCxt, yymsp[0].minor.yy724))); - } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 545: /* expression ::= expr_or_subquery NK_BITOR expr_or_subquery */ - { - SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy724); - SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy724); - yylhsminor.yy724 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, OP_TYPE_BIT_OR, releaseRawExprNode(pCxt, yymsp[-2].minor.yy724), releaseRawExprNode(pCxt, yymsp[0].minor.yy724))); - } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 548: /* column_reference ::= column_name */ - { yylhsminor.yy724 = createRawExprNode(pCxt, &yymsp[0].minor.yy461, createColumnNode(pCxt, NULL, &yymsp[0].minor.yy461)); } - yymsp[0].minor.yy724 = yylhsminor.yy724; - break; - case 549: /* column_reference ::= table_name NK_DOT column_name */ - { yylhsminor.yy724 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy461, &yymsp[0].minor.yy461, createColumnNode(pCxt, &yymsp[-2].minor.yy461, &yymsp[0].minor.yy461)); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 550: /* column_reference ::= NK_ALIAS */ - { yylhsminor.yy724 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createColumnNode(pCxt, NULL, &yymsp[0].minor.yy0)); } - yymsp[0].minor.yy724 = yylhsminor.yy724; - break; - case 551: /* column_reference ::= table_name NK_DOT NK_ALIAS */ - { yylhsminor.yy724 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy461, &yymsp[0].minor.yy0, createColumnNode(pCxt, &yymsp[-2].minor.yy461, &yymsp[0].minor.yy0)); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 552: /* pseudo_column ::= ROWTS */ - case 553: /* pseudo_column ::= TBNAME */ yytestcase(yyruleno==553); - case 555: /* pseudo_column ::= QSTART */ yytestcase(yyruleno==555); - case 556: /* pseudo_column ::= QEND */ yytestcase(yyruleno==556); - case 557: /* pseudo_column ::= QDURATION */ yytestcase(yyruleno==557); - case 558: /* pseudo_column ::= WSTART */ yytestcase(yyruleno==558); - case 559: /* pseudo_column ::= WEND */ yytestcase(yyruleno==559); - case 560: /* pseudo_column ::= WDURATION */ yytestcase(yyruleno==560); - case 561: /* pseudo_column ::= IROWTS */ yytestcase(yyruleno==561); - case 562: /* pseudo_column ::= ISFILLED */ yytestcase(yyruleno==562); - case 563: /* pseudo_column ::= QTAGS */ yytestcase(yyruleno==563); - case 580: /* literal_func ::= NOW */ yytestcase(yyruleno==580); - case 581: /* literal_func ::= TODAY */ yytestcase(yyruleno==581); - { yylhsminor.yy724 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createFunctionNode(pCxt, &yymsp[0].minor.yy0, NULL)); } - yymsp[0].minor.yy724 = yylhsminor.yy724; - break; - case 554: /* pseudo_column ::= table_name NK_DOT TBNAME */ - { yylhsminor.yy724 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy461, &yymsp[0].minor.yy0, createFunctionNode(pCxt, &yymsp[0].minor.yy0, createNodeList(pCxt, createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[-2].minor.yy461)))); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 564: /* function_expression ::= function_name NK_LP expression_list NK_RP */ - case 565: /* function_expression ::= star_func NK_LP star_func_para_list NK_RP */ yytestcase(yyruleno==565); - case 573: /* function_expression ::= substr_func NK_LP expression_list NK_RP */ yytestcase(yyruleno==573); - { yylhsminor.yy724 = createRawExprNodeExt(pCxt, &yymsp[-3].minor.yy461, &yymsp[0].minor.yy0, createFunctionNode(pCxt, &yymsp[-3].minor.yy461, yymsp[-1].minor.yy712)); } - yymsp[-3].minor.yy724 = yylhsminor.yy724; - break; - case 566: /* function_expression ::= CAST NK_LP expr_or_subquery AS type_name NK_RP */ - case 567: /* function_expression ::= CAST NK_LP expr_or_subquery AS type_name_default_len NK_RP */ yytestcase(yyruleno==567); - { yylhsminor.yy724 = createRawExprNodeExt(pCxt, &yymsp[-5].minor.yy0, &yymsp[0].minor.yy0, createCastFunctionNode(pCxt, releaseRawExprNode(pCxt, yymsp[-3].minor.yy724), yymsp[-1].minor.yy1016)); } - yymsp[-5].minor.yy724 = yylhsminor.yy724; - break; - case 568: /* function_expression ::= POSITION NK_LP expr_or_subquery IN expr_or_subquery NK_RP */ - { yylhsminor.yy724 = createRawExprNodeExt(pCxt, &yymsp[-5].minor.yy0, &yymsp[0].minor.yy0, createPositionFunctionNode(pCxt, releaseRawExprNode(pCxt, yymsp[-3].minor.yy724), releaseRawExprNode(pCxt, yymsp[-1].minor.yy724))); } - yymsp[-5].minor.yy724 = yylhsminor.yy724; - break; - case 569: /* function_expression ::= TRIM NK_LP expr_or_subquery NK_RP */ - { yylhsminor.yy724 = createRawExprNodeExt(pCxt, &yymsp[-3].minor.yy0, &yymsp[0].minor.yy0, createTrimFunctionNode(pCxt, releaseRawExprNode(pCxt, yymsp[-1].minor.yy724), TRIM_TYPE_BOTH)); } - yymsp[-3].minor.yy724 = yylhsminor.yy724; - break; - case 570: /* function_expression ::= TRIM NK_LP trim_specification_type FROM expr_or_subquery NK_RP */ - { yylhsminor.yy724 = createRawExprNodeExt(pCxt, &yymsp[-5].minor.yy0, &yymsp[0].minor.yy0, createTrimFunctionNode(pCxt, releaseRawExprNode(pCxt, yymsp[-1].minor.yy724), yymsp[-3].minor.yy796)); } - yymsp[-5].minor.yy724 = yylhsminor.yy724; - break; - case 571: /* function_expression ::= TRIM NK_LP expr_or_subquery FROM expr_or_subquery NK_RP */ - { yylhsminor.yy724 = createRawExprNodeExt(pCxt, &yymsp[-5].minor.yy0, &yymsp[0].minor.yy0, createTrimFunctionNodeExt(pCxt, releaseRawExprNode(pCxt, yymsp[-3].minor.yy724), releaseRawExprNode(pCxt, yymsp[-1].minor.yy724), TRIM_TYPE_BOTH)); } - yymsp[-5].minor.yy724 = yylhsminor.yy724; - break; - case 572: /* function_expression ::= TRIM NK_LP trim_specification_type expr_or_subquery FROM expr_or_subquery NK_RP */ - { yylhsminor.yy724 = createRawExprNodeExt(pCxt, &yymsp[-6].minor.yy0, &yymsp[0].minor.yy0, createTrimFunctionNodeExt(pCxt, releaseRawExprNode(pCxt, yymsp[-3].minor.yy724), releaseRawExprNode(pCxt, yymsp[-1].minor.yy724), yymsp[-4].minor.yy796)); } - yymsp[-6].minor.yy724 = yylhsminor.yy724; - break; - case 574: /* function_expression ::= substr_func NK_LP expr_or_subquery FROM expr_or_subquery NK_RP */ - { yylhsminor.yy724 = createRawExprNodeExt(pCxt, &yymsp[-5].minor.yy461, &yymsp[0].minor.yy0, createSubstrFunctionNode(pCxt, releaseRawExprNode(pCxt, yymsp[-3].minor.yy724), releaseRawExprNode(pCxt, yymsp[-1].minor.yy724))); } - yymsp[-5].minor.yy724 = yylhsminor.yy724; - break; - case 575: /* function_expression ::= substr_func NK_LP expr_or_subquery FROM expr_or_subquery FOR expr_or_subquery NK_RP */ - { yylhsminor.yy724 = createRawExprNodeExt(pCxt, &yymsp[-7].minor.yy461, &yymsp[0].minor.yy0, createSubstrFunctionNodeExt(pCxt, releaseRawExprNode(pCxt, yymsp[-5].minor.yy724), releaseRawExprNode(pCxt, yymsp[-3].minor.yy724), releaseRawExprNode(pCxt, yymsp[-1].minor.yy724))); } - yymsp[-7].minor.yy724 = yylhsminor.yy724; - break; - case 576: /* function_expression ::= REPLACE NK_LP expression_list NK_RP */ - case 583: /* rand_func ::= RAND NK_LP expression_list NK_RP */ yytestcase(yyruleno==583); - { yylhsminor.yy724 = createRawExprNodeExt(pCxt, &yymsp[-3].minor.yy0, &yymsp[0].minor.yy0, createFunctionNode(pCxt, &yymsp[-3].minor.yy0, yymsp[-1].minor.yy712)); } - yymsp[-3].minor.yy724 = yylhsminor.yy724; - break; - case 579: /* literal_func ::= noarg_func NK_LP NK_RP */ - { yylhsminor.yy724 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy461, &yymsp[0].minor.yy0, createFunctionNode(pCxt, &yymsp[-2].minor.yy461, NULL)); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 582: /* rand_func ::= RAND NK_LP NK_RP */ - { yylhsminor.yy724 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy0, &yymsp[0].minor.yy0, createFunctionNode(pCxt, &yymsp[-2].minor.yy0, NULL)); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 586: /* trim_specification_type ::= BOTH */ - { yymsp[0].minor.yy796 = TRIM_TYPE_BOTH; } - break; - case 587: /* trim_specification_type ::= TRAILING */ - { yymsp[0].minor.yy796 = TRIM_TYPE_TRAILING; } - break; - case 588: /* trim_specification_type ::= LEADING */ - { yymsp[0].minor.yy796 = TRIM_TYPE_LEADING; } - break; - case 603: /* star_func_para_list ::= NK_STAR */ - { yylhsminor.yy712 = createNodeList(pCxt, createColumnNode(pCxt, NULL, &yymsp[0].minor.yy0)); } - yymsp[0].minor.yy712 = yylhsminor.yy712; - break; - case 608: /* star_func_para ::= table_name NK_DOT NK_STAR */ - case 693: /* select_item ::= table_name NK_DOT NK_STAR */ yytestcase(yyruleno==693); - { yylhsminor.yy724 = createColumnNode(pCxt, &yymsp[-2].minor.yy461, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 609: /* case_when_expression ::= CASE when_then_list case_when_else_opt END */ - { yylhsminor.yy724 = createRawExprNodeExt(pCxt, &yymsp[-3].minor.yy0, &yymsp[0].minor.yy0, createCaseWhenNode(pCxt, NULL, yymsp[-2].minor.yy712, yymsp[-1].minor.yy724)); } - yymsp[-3].minor.yy724 = yylhsminor.yy724; - break; - case 610: /* case_when_expression ::= CASE common_expression when_then_list case_when_else_opt END */ - { yylhsminor.yy724 = createRawExprNodeExt(pCxt, &yymsp[-4].minor.yy0, &yymsp[0].minor.yy0, createCaseWhenNode(pCxt, releaseRawExprNode(pCxt, yymsp[-3].minor.yy724), yymsp[-2].minor.yy712, yymsp[-1].minor.yy724)); } - yymsp[-4].minor.yy724 = yylhsminor.yy724; - break; - case 613: /* when_then_expr ::= WHEN common_expression THEN common_expression */ - { yymsp[-3].minor.yy724 = createWhenThenNode(pCxt, releaseRawExprNode(pCxt, yymsp[-2].minor.yy724), releaseRawExprNode(pCxt, yymsp[0].minor.yy724)); } - break; - case 615: /* case_when_else_opt ::= ELSE common_expression */ - { yymsp[-1].minor.yy724 = releaseRawExprNode(pCxt, yymsp[0].minor.yy724); } - break; - case 616: /* predicate ::= expr_or_subquery compare_op expr_or_subquery */ - case 621: /* predicate ::= expr_or_subquery in_op in_predicate_value */ yytestcase(yyruleno==621); - { - SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy724); - SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy724); - yylhsminor.yy724 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, yymsp[-1].minor.yy164, releaseRawExprNode(pCxt, yymsp[-2].minor.yy724), releaseRawExprNode(pCxt, yymsp[0].minor.yy724))); - } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 617: /* predicate ::= expr_or_subquery BETWEEN expr_or_subquery AND expr_or_subquery */ - { - SToken s = getTokenFromRawExprNode(pCxt, yymsp[-4].minor.yy724); - SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy724); - yylhsminor.yy724 = createRawExprNodeExt(pCxt, &s, &e, createBetweenAnd(pCxt, releaseRawExprNode(pCxt, yymsp[-4].minor.yy724), releaseRawExprNode(pCxt, yymsp[-2].minor.yy724), releaseRawExprNode(pCxt, yymsp[0].minor.yy724))); - } - yymsp[-4].minor.yy724 = yylhsminor.yy724; - break; - case 618: /* predicate ::= expr_or_subquery NOT BETWEEN expr_or_subquery AND expr_or_subquery */ - { - SToken s = getTokenFromRawExprNode(pCxt, yymsp[-5].minor.yy724); - SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy724); - yylhsminor.yy724 = createRawExprNodeExt(pCxt, &s, &e, createNotBetweenAnd(pCxt, releaseRawExprNode(pCxt, yymsp[-5].minor.yy724), releaseRawExprNode(pCxt, yymsp[-2].minor.yy724), releaseRawExprNode(pCxt, yymsp[0].minor.yy724))); - } - yymsp[-5].minor.yy724 = yylhsminor.yy724; - break; - case 619: /* predicate ::= expr_or_subquery IS NULL */ - { - SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy724); - yylhsminor.yy724 = createRawExprNodeExt(pCxt, &s, &yymsp[0].minor.yy0, createOperatorNode(pCxt, OP_TYPE_IS_NULL, releaseRawExprNode(pCxt, yymsp[-2].minor.yy724), NULL)); - } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 620: /* predicate ::= expr_or_subquery IS NOT NULL */ - { - SToken s = getTokenFromRawExprNode(pCxt, yymsp[-3].minor.yy724); - yylhsminor.yy724 = createRawExprNodeExt(pCxt, &s, &yymsp[0].minor.yy0, createOperatorNode(pCxt, OP_TYPE_IS_NOT_NULL, releaseRawExprNode(pCxt, yymsp[-3].minor.yy724), NULL)); - } - yymsp[-3].minor.yy724 = yylhsminor.yy724; - break; - case 622: /* compare_op ::= NK_LT */ - { yymsp[0].minor.yy164 = OP_TYPE_LOWER_THAN; } - break; - case 623: /* compare_op ::= NK_GT */ - { yymsp[0].minor.yy164 = OP_TYPE_GREATER_THAN; } - break; - case 624: /* compare_op ::= NK_LE */ - { yymsp[0].minor.yy164 = OP_TYPE_LOWER_EQUAL; } - break; - case 625: /* compare_op ::= NK_GE */ - { yymsp[0].minor.yy164 = OP_TYPE_GREATER_EQUAL; } - break; - case 626: /* compare_op ::= NK_NE */ - { yymsp[0].minor.yy164 = OP_TYPE_NOT_EQUAL; } - break; - case 627: /* compare_op ::= NK_EQ */ - { yymsp[0].minor.yy164 = OP_TYPE_EQUAL; } - break; - case 628: /* compare_op ::= LIKE */ - { yymsp[0].minor.yy164 = OP_TYPE_LIKE; } - break; - case 629: /* compare_op ::= NOT LIKE */ - { yymsp[-1].minor.yy164 = OP_TYPE_NOT_LIKE; } - break; - case 630: /* compare_op ::= MATCH */ - { yymsp[0].minor.yy164 = OP_TYPE_MATCH; } - break; - case 631: /* compare_op ::= NMATCH */ - { yymsp[0].minor.yy164 = OP_TYPE_NMATCH; } - break; - case 632: /* compare_op ::= CONTAINS */ - { yymsp[0].minor.yy164 = OP_TYPE_JSON_CONTAINS; } - break; - case 633: /* in_op ::= IN */ - { yymsp[0].minor.yy164 = OP_TYPE_IN; } - break; - case 634: /* in_op ::= NOT IN */ - { yymsp[-1].minor.yy164 = OP_TYPE_NOT_IN; } - break; - case 635: /* in_predicate_value ::= NK_LP literal_list NK_RP */ - { yylhsminor.yy724 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy0, &yymsp[0].minor.yy0, createNodeListNode(pCxt, yymsp[-1].minor.yy712)); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 637: /* boolean_value_expression ::= NOT boolean_primary */ - { - SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy724); - yylhsminor.yy724 = createRawExprNodeExt(pCxt, &yymsp[-1].minor.yy0, &e, createLogicConditionNode(pCxt, LOGIC_COND_TYPE_NOT, releaseRawExprNode(pCxt, yymsp[0].minor.yy724), NULL)); - } - yymsp[-1].minor.yy724 = yylhsminor.yy724; - break; - case 638: /* boolean_value_expression ::= boolean_value_expression OR boolean_value_expression */ - { - SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy724); - SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy724); - yylhsminor.yy724 = createRawExprNodeExt(pCxt, &s, &e, createLogicConditionNode(pCxt, LOGIC_COND_TYPE_OR, releaseRawExprNode(pCxt, yymsp[-2].minor.yy724), releaseRawExprNode(pCxt, yymsp[0].minor.yy724))); - } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 639: /* boolean_value_expression ::= boolean_value_expression AND boolean_value_expression */ - { - SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy724); - SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy724); - yylhsminor.yy724 = createRawExprNodeExt(pCxt, &s, &e, createLogicConditionNode(pCxt, LOGIC_COND_TYPE_AND, releaseRawExprNode(pCxt, yymsp[-2].minor.yy724), releaseRawExprNode(pCxt, yymsp[0].minor.yy724))); - } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 647: /* table_reference_list ::= table_reference_list NK_COMMA table_reference */ - { yylhsminor.yy724 = createJoinTableNode(pCxt, JOIN_TYPE_INNER, JOIN_STYPE_NONE, yymsp[-2].minor.yy724, yymsp[0].minor.yy724, NULL); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 650: /* table_primary ::= table_name alias_opt */ - { yylhsminor.yy724 = createRealTableNode(pCxt, NULL, &yymsp[-1].minor.yy461, &yymsp[0].minor.yy461); } - yymsp[-1].minor.yy724 = yylhsminor.yy724; - break; - case 651: /* table_primary ::= db_name NK_DOT table_name alias_opt */ - { yylhsminor.yy724 = createRealTableNode(pCxt, &yymsp[-3].minor.yy461, &yymsp[-1].minor.yy461, &yymsp[0].minor.yy461); } - yymsp[-3].minor.yy724 = yylhsminor.yy724; - break; - case 652: /* table_primary ::= subquery alias_opt */ - { yylhsminor.yy724 = createTempTableNode(pCxt, releaseRawExprNode(pCxt, yymsp[-1].minor.yy724), &yymsp[0].minor.yy461); } - yymsp[-1].minor.yy724 = yylhsminor.yy724; - break; - case 654: /* alias_opt ::= */ - { yymsp[1].minor.yy461 = nil_token; } - break; - case 656: /* alias_opt ::= AS table_alias */ - { yymsp[-1].minor.yy461 = yymsp[0].minor.yy461; } - break; - case 657: /* parenthesized_joined_table ::= NK_LP joined_table NK_RP */ - case 658: /* parenthesized_joined_table ::= NK_LP parenthesized_joined_table NK_RP */ yytestcase(yyruleno==658); - { yymsp[-2].minor.yy724 = yymsp[-1].minor.yy724; } - break; - case 659: /* joined_table ::= table_reference join_type join_subtype JOIN table_reference join_on_clause_opt window_offset_clause_opt jlimit_clause_opt */ - { - yylhsminor.yy724 = createJoinTableNode(pCxt, yymsp[-6].minor.yy916, yymsp[-5].minor.yy798, yymsp[-7].minor.yy724, yymsp[-3].minor.yy724, yymsp[-2].minor.yy724); - yylhsminor.yy724 = addWindowOffsetClause(pCxt, yylhsminor.yy724, yymsp[-1].minor.yy724); - yylhsminor.yy724 = addJLimitClause(pCxt, yylhsminor.yy724, yymsp[0].minor.yy724); - } - yymsp[-7].minor.yy724 = yylhsminor.yy724; - break; - case 660: /* join_type ::= */ - { yymsp[1].minor.yy916 = JOIN_TYPE_INNER; } - break; - case 661: /* join_type ::= INNER */ - { yymsp[0].minor.yy916 = JOIN_TYPE_INNER; } - break; - case 662: /* join_type ::= LEFT */ - { yymsp[0].minor.yy916 = JOIN_TYPE_LEFT; } - break; - case 663: /* join_type ::= RIGHT */ - { yymsp[0].minor.yy916 = JOIN_TYPE_RIGHT; } - break; - case 664: /* join_type ::= FULL */ - { yymsp[0].minor.yy916 = JOIN_TYPE_FULL; } - break; - case 665: /* join_subtype ::= */ - { yymsp[1].minor.yy798 = JOIN_STYPE_NONE; } - break; - case 666: /* join_subtype ::= OUTER */ - { yymsp[0].minor.yy798 = JOIN_STYPE_OUTER; } - break; - case 667: /* join_subtype ::= SEMI */ - { yymsp[0].minor.yy798 = JOIN_STYPE_SEMI; } - break; - case 668: /* join_subtype ::= ANTI */ - { yymsp[0].minor.yy798 = JOIN_STYPE_ANTI; } - break; - case 669: /* join_subtype ::= ASOF */ - { yymsp[0].minor.yy798 = JOIN_STYPE_ASOF; } - break; - case 670: /* join_subtype ::= WINDOW */ - { yymsp[0].minor.yy798 = JOIN_STYPE_WIN; } - break; - case 674: /* window_offset_clause_opt ::= WINDOW_OFFSET NK_LP window_offset_literal NK_COMMA window_offset_literal NK_RP */ - { yymsp[-5].minor.yy724 = createWindowOffsetNode(pCxt, releaseRawExprNode(pCxt, yymsp[-3].minor.yy724), releaseRawExprNode(pCxt, yymsp[-1].minor.yy724)); } - break; - case 675: /* window_offset_literal ::= NK_VARIABLE */ - { yylhsminor.yy724 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createTimeOffsetValueNode(pCxt, &yymsp[0].minor.yy0)); } - yymsp[0].minor.yy724 = yylhsminor.yy724; - break; - case 676: /* window_offset_literal ::= NK_MINUS NK_VARIABLE */ - { - SToken t = yymsp[-1].minor.yy0; - t.n = (yymsp[0].minor.yy0.z + yymsp[0].minor.yy0.n) - yymsp[-1].minor.yy0.z; - yylhsminor.yy724 = createRawExprNode(pCxt, &t, createTimeOffsetValueNode(pCxt, &t)); - } - yymsp[-1].minor.yy724 = yylhsminor.yy724; - break; - case 678: /* jlimit_clause_opt ::= JLIMIT NK_INTEGER */ - case 749: /* slimit_clause_opt ::= SLIMIT NK_INTEGER */ yytestcase(yyruleno==749); - case 753: /* limit_clause_opt ::= LIMIT NK_INTEGER */ yytestcase(yyruleno==753); - { yymsp[-1].minor.yy724 = createLimitNode(pCxt, &yymsp[0].minor.yy0, NULL); } - break; - case 679: /* query_specification ::= SELECT hint_list set_quantifier_opt tag_mode_opt select_list from_clause_opt where_clause_opt partition_by_clause_opt range_opt every_opt fill_opt twindow_clause_opt group_by_clause_opt having_clause_opt */ - { - yymsp[-13].minor.yy724 = createSelectStmt(pCxt, yymsp[-11].minor.yy429, yymsp[-9].minor.yy712, yymsp[-8].minor.yy724, yymsp[-12].minor.yy712); - yymsp[-13].minor.yy724 = setSelectStmtTagMode(pCxt, yymsp[-13].minor.yy724, yymsp[-10].minor.yy429); - yymsp[-13].minor.yy724 = addWhereClause(pCxt, yymsp[-13].minor.yy724, yymsp[-7].minor.yy724); - yymsp[-13].minor.yy724 = addPartitionByClause(pCxt, yymsp[-13].minor.yy724, yymsp[-6].minor.yy712); - yymsp[-13].minor.yy724 = addWindowClauseClause(pCxt, yymsp[-13].minor.yy724, yymsp[-2].minor.yy724); - yymsp[-13].minor.yy724 = addGroupByClause(pCxt, yymsp[-13].minor.yy724, yymsp[-1].minor.yy712); - yymsp[-13].minor.yy724 = addHavingClause(pCxt, yymsp[-13].minor.yy724, yymsp[0].minor.yy724); - yymsp[-13].minor.yy724 = addRangeClause(pCxt, yymsp[-13].minor.yy724, yymsp[-5].minor.yy724); - yymsp[-13].minor.yy724 = addEveryClause(pCxt, yymsp[-13].minor.yy724, yymsp[-4].minor.yy724); - yymsp[-13].minor.yy724 = addFillClause(pCxt, yymsp[-13].minor.yy724, yymsp[-3].minor.yy724); - } - break; - case 680: /* hint_list ::= */ - { yymsp[1].minor.yy712 = createHintNodeList(pCxt, NULL); } - break; - case 681: /* hint_list ::= NK_HINT */ - { yylhsminor.yy712 = createHintNodeList(pCxt, &yymsp[0].minor.yy0); } - yymsp[0].minor.yy712 = yylhsminor.yy712; - break; - case 686: /* set_quantifier_opt ::= ALL */ - { yymsp[0].minor.yy429 = false; } - break; - case 689: /* select_item ::= NK_STAR */ - { yylhsminor.yy724 = createColumnNode(pCxt, NULL, &yymsp[0].minor.yy0); } - yymsp[0].minor.yy724 = yylhsminor.yy724; - break; - case 691: /* select_item ::= common_expression column_alias */ - case 701: /* partition_item ::= expr_or_subquery column_alias */ yytestcase(yyruleno==701); - { yylhsminor.yy724 = setProjectionAlias(pCxt, releaseRawExprNode(pCxt, yymsp[-1].minor.yy724), &yymsp[0].minor.yy461); } - yymsp[-1].minor.yy724 = yylhsminor.yy724; - break; - case 692: /* select_item ::= common_expression AS column_alias */ - case 702: /* partition_item ::= expr_or_subquery AS column_alias */ yytestcase(yyruleno==702); - { yylhsminor.yy724 = setProjectionAlias(pCxt, releaseRawExprNode(pCxt, yymsp[-2].minor.yy724), &yymsp[0].minor.yy461); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 697: /* partition_by_clause_opt ::= PARTITION BY partition_list */ - case 727: /* group_by_clause_opt ::= GROUP BY group_by_list */ yytestcase(yyruleno==727); - case 747: /* order_by_clause_opt ::= ORDER BY sort_specification_list */ yytestcase(yyruleno==747); - { yymsp[-2].minor.yy712 = yymsp[0].minor.yy712; } - break; - case 704: /* twindow_clause_opt ::= SESSION NK_LP column_reference NK_COMMA interval_sliding_duration_literal NK_RP */ - { yymsp[-5].minor.yy724 = createSessionWindowNode(pCxt, releaseRawExprNode(pCxt, yymsp[-3].minor.yy724), releaseRawExprNode(pCxt, yymsp[-1].minor.yy724)); } - break; - case 705: /* twindow_clause_opt ::= STATE_WINDOW NK_LP expr_or_subquery NK_RP */ - { yymsp[-3].minor.yy724 = createStateWindowNode(pCxt, releaseRawExprNode(pCxt, yymsp[-1].minor.yy724)); } - break; - case 706: /* twindow_clause_opt ::= INTERVAL NK_LP interval_sliding_duration_literal NK_RP sliding_opt fill_opt */ - { yymsp[-5].minor.yy724 = createIntervalWindowNode(pCxt, releaseRawExprNode(pCxt, yymsp[-3].minor.yy724), NULL, yymsp[-1].minor.yy724, yymsp[0].minor.yy724); } - break; - case 707: /* twindow_clause_opt ::= INTERVAL NK_LP interval_sliding_duration_literal NK_COMMA interval_sliding_duration_literal NK_RP sliding_opt fill_opt */ - { yymsp[-7].minor.yy724 = createIntervalWindowNode(pCxt, releaseRawExprNode(pCxt, yymsp[-5].minor.yy724), releaseRawExprNode(pCxt, yymsp[-3].minor.yy724), yymsp[-1].minor.yy724, yymsp[0].minor.yy724); } - break; - case 708: /* twindow_clause_opt ::= EVENT_WINDOW START WITH search_condition END WITH search_condition */ - { yymsp[-6].minor.yy724 = createEventWindowNode(pCxt, yymsp[-3].minor.yy724, yymsp[0].minor.yy724); } - break; - case 709: /* twindow_clause_opt ::= COUNT_WINDOW NK_LP NK_INTEGER NK_RP */ - { yymsp[-3].minor.yy724 = createCountWindowNode(pCxt, &yymsp[-1].minor.yy0, &yymsp[-1].minor.yy0); } - break; - case 710: /* twindow_clause_opt ::= COUNT_WINDOW NK_LP NK_INTEGER NK_COMMA NK_INTEGER NK_RP */ - { yymsp[-5].minor.yy724 = createCountWindowNode(pCxt, &yymsp[-3].minor.yy0, &yymsp[-1].minor.yy0); } - break; - case 717: /* fill_opt ::= FILL NK_LP fill_mode NK_RP */ - { yymsp[-3].minor.yy724 = createFillNode(pCxt, yymsp[-1].minor.yy58, NULL); } - break; - case 718: /* fill_opt ::= FILL NK_LP VALUE NK_COMMA expression_list NK_RP */ - { yymsp[-5].minor.yy724 = createFillNode(pCxt, FILL_MODE_VALUE, createNodeListNode(pCxt, yymsp[-1].minor.yy712)); } - break; - case 719: /* fill_opt ::= FILL NK_LP VALUE_F NK_COMMA expression_list NK_RP */ - { yymsp[-5].minor.yy724 = createFillNode(pCxt, FILL_MODE_VALUE_F, createNodeListNode(pCxt, yymsp[-1].minor.yy712)); } - break; - case 720: /* fill_mode ::= NONE */ - { yymsp[0].minor.yy58 = FILL_MODE_NONE; } - break; - case 721: /* fill_mode ::= PREV */ - { yymsp[0].minor.yy58 = FILL_MODE_PREV; } - break; - case 722: /* fill_mode ::= NULL */ - { yymsp[0].minor.yy58 = FILL_MODE_NULL; } - break; - case 723: /* fill_mode ::= NULL_F */ - { yymsp[0].minor.yy58 = FILL_MODE_NULL_F; } - break; - case 724: /* fill_mode ::= LINEAR */ - { yymsp[0].minor.yy58 = FILL_MODE_LINEAR; } - break; - case 725: /* fill_mode ::= NEXT */ - { yymsp[0].minor.yy58 = FILL_MODE_NEXT; } - break; - case 728: /* group_by_list ::= expr_or_subquery */ - { yylhsminor.yy712 = createNodeList(pCxt, createGroupingSetNode(pCxt, releaseRawExprNode(pCxt, yymsp[0].minor.yy724))); } - yymsp[0].minor.yy712 = yylhsminor.yy712; - break; - case 729: /* group_by_list ::= group_by_list NK_COMMA expr_or_subquery */ - { yylhsminor.yy712 = addNodeToList(pCxt, yymsp[-2].minor.yy712, createGroupingSetNode(pCxt, releaseRawExprNode(pCxt, yymsp[0].minor.yy724))); } - yymsp[-2].minor.yy712 = yylhsminor.yy712; - break; - case 733: /* range_opt ::= RANGE NK_LP expr_or_subquery NK_COMMA expr_or_subquery NK_RP */ - { yymsp[-5].minor.yy724 = createInterpTimeRange(pCxt, releaseRawExprNode(pCxt, yymsp[-3].minor.yy724), releaseRawExprNode(pCxt, yymsp[-1].minor.yy724)); } - break; - case 734: /* range_opt ::= RANGE NK_LP expr_or_subquery NK_RP */ - { yymsp[-3].minor.yy724 = createInterpTimePoint(pCxt, releaseRawExprNode(pCxt, yymsp[-1].minor.yy724)); } - break; - case 737: /* query_expression ::= query_simple order_by_clause_opt slimit_clause_opt limit_clause_opt */ - { - yylhsminor.yy724 = addOrderByClause(pCxt, yymsp[-3].minor.yy724, yymsp[-2].minor.yy712); - yylhsminor.yy724 = addSlimitClause(pCxt, yylhsminor.yy724, yymsp[-1].minor.yy724); - yylhsminor.yy724 = addLimitClause(pCxt, yylhsminor.yy724, yymsp[0].minor.yy724); - } - yymsp[-3].minor.yy724 = yylhsminor.yy724; - break; - case 740: /* union_query_expression ::= query_simple_or_subquery UNION ALL query_simple_or_subquery */ - { yylhsminor.yy724 = createSetOperator(pCxt, SET_OP_TYPE_UNION_ALL, yymsp[-3].minor.yy724, yymsp[0].minor.yy724); } - yymsp[-3].minor.yy724 = yylhsminor.yy724; - break; - case 741: /* union_query_expression ::= query_simple_or_subquery UNION query_simple_or_subquery */ - { yylhsminor.yy724 = createSetOperator(pCxt, SET_OP_TYPE_UNION, yymsp[-2].minor.yy724, yymsp[0].minor.yy724); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 750: /* slimit_clause_opt ::= SLIMIT NK_INTEGER SOFFSET NK_INTEGER */ - case 754: /* limit_clause_opt ::= LIMIT NK_INTEGER OFFSET NK_INTEGER */ yytestcase(yyruleno==754); - { yymsp[-3].minor.yy724 = createLimitNode(pCxt, &yymsp[-2].minor.yy0, &yymsp[0].minor.yy0); } - break; - case 751: /* slimit_clause_opt ::= SLIMIT NK_INTEGER NK_COMMA NK_INTEGER */ - case 755: /* limit_clause_opt ::= LIMIT NK_INTEGER NK_COMMA NK_INTEGER */ yytestcase(yyruleno==755); - { yymsp[-3].minor.yy724 = createLimitNode(pCxt, &yymsp[0].minor.yy0, &yymsp[-2].minor.yy0); } - break; - case 756: /* subquery ::= NK_LP query_expression NK_RP */ - { yylhsminor.yy724 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy0, &yymsp[0].minor.yy0, yymsp[-1].minor.yy724); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 761: /* sort_specification ::= expr_or_subquery ordering_specification_opt null_ordering_opt */ - { yylhsminor.yy724 = createOrderByExprNode(pCxt, releaseRawExprNode(pCxt, yymsp[-2].minor.yy724), yymsp[-1].minor.yy746, yymsp[0].minor.yy417); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - case 762: /* ordering_specification_opt ::= */ - { yymsp[1].minor.yy746 = ORDER_ASC; } - break; - case 763: /* ordering_specification_opt ::= ASC */ - { yymsp[0].minor.yy746 = ORDER_ASC; } - break; - case 764: /* ordering_specification_opt ::= DESC */ - { yymsp[0].minor.yy746 = ORDER_DESC; } - break; - case 765: /* null_ordering_opt ::= */ - { yymsp[1].minor.yy417 = NULL_ORDER_DEFAULT; } - break; - case 766: /* null_ordering_opt ::= NULLS FIRST */ - { yymsp[-1].minor.yy417 = NULL_ORDER_FIRST; } - break; - case 767: /* null_ordering_opt ::= NULLS LAST */ - { yymsp[-1].minor.yy417 = NULL_ORDER_LAST; } - break; - case 770: /* column_options ::= column_options NK_ID NK_STRING */ - { yylhsminor.yy724 = setColumnOptions(pCxt, yymsp[-2].minor.yy724, &yymsp[-1].minor.yy0, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy724 = yylhsminor.yy724; - break; - default: - break; - /********** End reduce actions ************************************************/ + */ +/********** Begin reduce actions **********************************************/ + YYMINORTYPE yylhsminor; + case 0: /* cmd ::= CREATE ACCOUNT NK_ID PASS NK_STRING account_options */ +{ pCxt->errCode = generateSyntaxErrMsg(&pCxt->msgBuf, TSDB_CODE_PAR_EXPRIE_STATEMENT); } + yy_destructor(yypParser,384,&yymsp[0].minor); + break; + case 1: /* cmd ::= ALTER ACCOUNT NK_ID alter_account_options */ +{ pCxt->errCode = generateSyntaxErrMsg(&pCxt->msgBuf, TSDB_CODE_PAR_EXPRIE_STATEMENT); } + yy_destructor(yypParser,385,&yymsp[0].minor); + break; + case 2: /* account_options ::= */ +{ } + break; + case 3: /* account_options ::= account_options PPS literal */ + case 4: /* account_options ::= account_options TSERIES literal */ yytestcase(yyruleno==4); + case 5: /* account_options ::= account_options STORAGE literal */ yytestcase(yyruleno==5); + case 6: /* account_options ::= account_options STREAMS literal */ yytestcase(yyruleno==6); + case 7: /* account_options ::= account_options QTIME literal */ yytestcase(yyruleno==7); + case 8: /* account_options ::= account_options DBS literal */ yytestcase(yyruleno==8); + case 9: /* account_options ::= account_options USERS literal */ yytestcase(yyruleno==9); + case 10: /* account_options ::= account_options CONNS literal */ yytestcase(yyruleno==10); + case 11: /* account_options ::= account_options STATE literal */ yytestcase(yyruleno==11); +{ yy_destructor(yypParser,384,&yymsp[-2].minor); +{ } + yy_destructor(yypParser,386,&yymsp[0].minor); +} + break; + case 12: /* alter_account_options ::= alter_account_option */ +{ yy_destructor(yypParser,387,&yymsp[0].minor); +{ } +} + break; + case 13: /* alter_account_options ::= alter_account_options alter_account_option */ +{ yy_destructor(yypParser,385,&yymsp[-1].minor); +{ } + yy_destructor(yypParser,387,&yymsp[0].minor); +} + break; + case 14: /* alter_account_option ::= PASS literal */ + case 15: /* alter_account_option ::= PPS literal */ yytestcase(yyruleno==15); + case 16: /* alter_account_option ::= TSERIES literal */ yytestcase(yyruleno==16); + case 17: /* alter_account_option ::= STORAGE literal */ yytestcase(yyruleno==17); + case 18: /* alter_account_option ::= STREAMS literal */ yytestcase(yyruleno==18); + case 19: /* alter_account_option ::= QTIME literal */ yytestcase(yyruleno==19); + case 20: /* alter_account_option ::= DBS literal */ yytestcase(yyruleno==20); + case 21: /* alter_account_option ::= USERS literal */ yytestcase(yyruleno==21); + case 22: /* alter_account_option ::= CONNS literal */ yytestcase(yyruleno==22); + case 23: /* alter_account_option ::= STATE literal */ yytestcase(yyruleno==23); +{ } + yy_destructor(yypParser,386,&yymsp[0].minor); + break; + case 24: /* ip_range_list ::= NK_STRING */ +{ yylhsminor.yy334 = createNodeList(pCxt, createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy0)); } + yymsp[0].minor.yy334 = yylhsminor.yy334; + break; + case 25: /* ip_range_list ::= ip_range_list NK_COMMA NK_STRING */ +{ yylhsminor.yy334 = addNodeToList(pCxt, yymsp[-2].minor.yy334, createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy0)); } + yymsp[-2].minor.yy334 = yylhsminor.yy334; + break; + case 26: /* white_list ::= HOST ip_range_list */ +{ yymsp[-1].minor.yy334 = yymsp[0].minor.yy334; } + break; + case 27: /* white_list_opt ::= */ + case 208: /* specific_cols_opt ::= */ yytestcase(yyruleno==208); + case 246: /* tags_def_opt ::= */ yytestcase(yyruleno==246); + case 337: /* tag_list_opt ::= */ yytestcase(yyruleno==337); + case 410: /* col_list_opt ::= */ yytestcase(yyruleno==410); + case 417: /* tag_def_or_ref_opt ::= */ yytestcase(yyruleno==417); + case 698: /* partition_by_clause_opt ::= */ yytestcase(yyruleno==698); + case 728: /* group_by_clause_opt ::= */ yytestcase(yyruleno==728); + case 748: /* order_by_clause_opt ::= */ yytestcase(yyruleno==748); +{ yymsp[1].minor.yy334 = NULL; } + break; + case 28: /* white_list_opt ::= white_list */ + case 247: /* tags_def_opt ::= tags_def */ yytestcase(yyruleno==247); + case 418: /* tag_def_or_ref_opt ::= tags_def */ yytestcase(yyruleno==418); + case 606: /* star_func_para_list ::= other_para_list */ yytestcase(yyruleno==606); +{ yylhsminor.yy334 = yymsp[0].minor.yy334; } + yymsp[0].minor.yy334 = yylhsminor.yy334; + break; + case 29: /* is_import_opt ::= */ + case 31: /* is_createdb_opt ::= */ yytestcase(yyruleno==31); +{ yymsp[1].minor.yy719 = 0; } + break; + case 30: /* is_import_opt ::= IS_IMPORT NK_INTEGER */ + case 32: /* is_createdb_opt ::= CREATEDB NK_INTEGER */ yytestcase(yyruleno==32); + case 42: /* sysinfo_opt ::= SYSINFO NK_INTEGER */ yytestcase(yyruleno==42); +{ yymsp[-1].minor.yy719 = taosStr2Int8(yymsp[0].minor.yy0.z, NULL, 10); } + break; + case 33: /* cmd ::= CREATE USER user_name PASS NK_STRING sysinfo_opt is_createdb_opt is_import_opt white_list_opt */ +{ + pCxt->pRootNode = createCreateUserStmt(pCxt, &yymsp[-6].minor.yy533, &yymsp[-4].minor.yy0, yymsp[-3].minor.yy719, yymsp[-1].minor.yy719, yymsp[-2].minor.yy719); + pCxt->pRootNode = addCreateUserStmtWhiteList(pCxt, pCxt->pRootNode, yymsp[0].minor.yy334); + } + break; + case 34: /* cmd ::= ALTER USER user_name PASS NK_STRING */ +{ pCxt->pRootNode = createAlterUserStmt(pCxt, &yymsp[-2].minor.yy533, TSDB_ALTER_USER_PASSWD, &yymsp[0].minor.yy0); } + break; + case 35: /* cmd ::= ALTER USER user_name ENABLE NK_INTEGER */ +{ pCxt->pRootNode = createAlterUserStmt(pCxt, &yymsp[-2].minor.yy533, TSDB_ALTER_USER_ENABLE, &yymsp[0].minor.yy0); } + break; + case 36: /* cmd ::= ALTER USER user_name SYSINFO NK_INTEGER */ +{ pCxt->pRootNode = createAlterUserStmt(pCxt, &yymsp[-2].minor.yy533, TSDB_ALTER_USER_SYSINFO, &yymsp[0].minor.yy0); } + break; + case 37: /* cmd ::= ALTER USER user_name CREATEDB NK_INTEGER */ +{ pCxt->pRootNode = createAlterUserStmt(pCxt, &yymsp[-2].minor.yy533, TSDB_ALTER_USER_CREATEDB, &yymsp[0].minor.yy0); } + break; + case 38: /* cmd ::= ALTER USER user_name ADD white_list */ +{ pCxt->pRootNode = createAlterUserStmt(pCxt, &yymsp[-2].minor.yy533, TSDB_ALTER_USER_ADD_WHITE_LIST, yymsp[0].minor.yy334); } + break; + case 39: /* cmd ::= ALTER USER user_name DROP white_list */ +{ pCxt->pRootNode = createAlterUserStmt(pCxt, &yymsp[-2].minor.yy533, TSDB_ALTER_USER_DROP_WHITE_LIST, yymsp[0].minor.yy334); } + break; + case 40: /* cmd ::= DROP USER user_name */ +{ pCxt->pRootNode = createDropUserStmt(pCxt, &yymsp[0].minor.yy533); } + break; + case 41: /* sysinfo_opt ::= */ +{ yymsp[1].minor.yy719 = 1; } + break; + case 43: /* cmd ::= GRANT privileges ON priv_level with_clause_opt TO user_name */ +{ pCxt->pRootNode = createGrantStmt(pCxt, yymsp[-5].minor.yy585, &yymsp[-3].minor.yy399, &yymsp[0].minor.yy533, yymsp[-2].minor.yy560); } + break; + case 44: /* cmd ::= REVOKE privileges ON priv_level with_clause_opt FROM user_name */ +{ pCxt->pRootNode = createRevokeStmt(pCxt, yymsp[-5].minor.yy585, &yymsp[-3].minor.yy399, &yymsp[0].minor.yy533, yymsp[-2].minor.yy560); } + break; + case 45: /* privileges ::= ALL */ +{ yymsp[0].minor.yy585 = PRIVILEGE_TYPE_ALL; } + break; + case 46: /* privileges ::= priv_type_list */ + case 48: /* priv_type_list ::= priv_type */ yytestcase(yyruleno==48); +{ yylhsminor.yy585 = yymsp[0].minor.yy585; } + yymsp[0].minor.yy585 = yylhsminor.yy585; + break; + case 47: /* privileges ::= SUBSCRIBE */ +{ yymsp[0].minor.yy585 = PRIVILEGE_TYPE_SUBSCRIBE; } + break; + case 49: /* priv_type_list ::= priv_type_list NK_COMMA priv_type */ +{ yylhsminor.yy585 = yymsp[-2].minor.yy585 | yymsp[0].minor.yy585; } + yymsp[-2].minor.yy585 = yylhsminor.yy585; + break; + case 50: /* priv_type ::= READ */ +{ yymsp[0].minor.yy585 = PRIVILEGE_TYPE_READ; } + break; + case 51: /* priv_type ::= WRITE */ +{ yymsp[0].minor.yy585 = PRIVILEGE_TYPE_WRITE; } + break; + case 52: /* priv_type ::= ALTER */ +{ yymsp[0].minor.yy585 = PRIVILEGE_TYPE_ALTER; } + break; + case 53: /* priv_level ::= NK_STAR NK_DOT NK_STAR */ +{ yylhsminor.yy399.first = yymsp[-2].minor.yy0; yylhsminor.yy399.second = yymsp[0].minor.yy0; } + yymsp[-2].minor.yy399 = yylhsminor.yy399; + break; + case 54: /* priv_level ::= db_name NK_DOT NK_STAR */ +{ yylhsminor.yy399.first = yymsp[-2].minor.yy533; yylhsminor.yy399.second = yymsp[0].minor.yy0; } + yymsp[-2].minor.yy399 = yylhsminor.yy399; + break; + case 55: /* priv_level ::= db_name NK_DOT table_name */ +{ yylhsminor.yy399.first = yymsp[-2].minor.yy533; yylhsminor.yy399.second = yymsp[0].minor.yy533; } + yymsp[-2].minor.yy399 = yylhsminor.yy399; + break; + case 56: /* priv_level ::= topic_name */ +{ yylhsminor.yy399.first = yymsp[0].minor.yy533; yylhsminor.yy399.second = nil_token; } + yymsp[0].minor.yy399 = yylhsminor.yy399; + break; + case 57: /* with_clause_opt ::= */ + case 173: /* start_opt ::= */ yytestcase(yyruleno==173); + case 177: /* end_opt ::= */ yytestcase(yyruleno==177); + case 332: /* like_pattern_opt ::= */ yytestcase(yyruleno==332); + case 429: /* subtable_opt ::= */ yytestcase(yyruleno==429); + case 616: /* case_when_else_opt ::= */ yytestcase(yyruleno==616); + case 646: /* from_clause_opt ::= */ yytestcase(yyruleno==646); + case 673: /* join_on_clause_opt ::= */ yytestcase(yyruleno==673); + case 675: /* window_offset_clause_opt ::= */ yytestcase(yyruleno==675); + case 679: /* jlimit_clause_opt ::= */ yytestcase(yyruleno==679); + case 696: /* where_clause_opt ::= */ yytestcase(yyruleno==696); + case 705: /* twindow_clause_opt ::= */ yytestcase(yyruleno==705); + case 713: /* sliding_opt ::= */ yytestcase(yyruleno==713); + case 718: /* fill_opt ::= */ yytestcase(yyruleno==718); + case 732: /* having_clause_opt ::= */ yytestcase(yyruleno==732); + case 734: /* range_opt ::= */ yytestcase(yyruleno==734); + case 737: /* every_opt ::= */ yytestcase(yyruleno==737); + case 750: /* slimit_clause_opt ::= */ yytestcase(yyruleno==750); + case 754: /* limit_clause_opt ::= */ yytestcase(yyruleno==754); +{ yymsp[1].minor.yy560 = NULL; } + break; + case 58: /* with_clause_opt ::= WITH search_condition */ + case 647: /* from_clause_opt ::= FROM table_reference_list */ yytestcase(yyruleno==647); + case 674: /* join_on_clause_opt ::= ON search_condition */ yytestcase(yyruleno==674); + case 697: /* where_clause_opt ::= WHERE search_condition */ yytestcase(yyruleno==697); + case 733: /* having_clause_opt ::= HAVING search_condition */ yytestcase(yyruleno==733); +{ yymsp[-1].minor.yy560 = yymsp[0].minor.yy560; } + break; + case 59: /* cmd ::= CREATE ENCRYPT_KEY NK_STRING */ +{ pCxt->pRootNode = createEncryptKeyStmt(pCxt, &yymsp[0].minor.yy0); } + break; + case 60: /* cmd ::= CREATE DNODE dnode_endpoint */ +{ pCxt->pRootNode = createCreateDnodeStmt(pCxt, &yymsp[0].minor.yy533, NULL); } + break; + case 61: /* cmd ::= CREATE DNODE dnode_endpoint PORT NK_INTEGER */ +{ pCxt->pRootNode = createCreateDnodeStmt(pCxt, &yymsp[-2].minor.yy533, &yymsp[0].minor.yy0); } + break; + case 62: /* cmd ::= DROP DNODE NK_INTEGER force_opt */ +{ pCxt->pRootNode = createDropDnodeStmt(pCxt, &yymsp[-1].minor.yy0, yymsp[0].minor.yy173, false); } + break; + case 63: /* cmd ::= DROP DNODE dnode_endpoint force_opt */ +{ pCxt->pRootNode = createDropDnodeStmt(pCxt, &yymsp[-1].minor.yy533, yymsp[0].minor.yy173, false); } + break; + case 64: /* cmd ::= DROP DNODE NK_INTEGER unsafe_opt */ +{ pCxt->pRootNode = createDropDnodeStmt(pCxt, &yymsp[-1].minor.yy0, false, yymsp[0].minor.yy173); } + break; + case 65: /* cmd ::= DROP DNODE dnode_endpoint unsafe_opt */ +{ pCxt->pRootNode = createDropDnodeStmt(pCxt, &yymsp[-1].minor.yy533, false, yymsp[0].minor.yy173); } + break; + case 66: /* cmd ::= ALTER DNODE NK_INTEGER NK_STRING */ +{ pCxt->pRootNode = createAlterDnodeStmt(pCxt, &yymsp[-1].minor.yy0, &yymsp[0].minor.yy0, NULL); } + break; + case 67: /* cmd ::= ALTER DNODE NK_INTEGER NK_STRING NK_STRING */ +{ pCxt->pRootNode = createAlterDnodeStmt(pCxt, &yymsp[-2].minor.yy0, &yymsp[-1].minor.yy0, &yymsp[0].minor.yy0); } + break; + case 68: /* cmd ::= ALTER ALL DNODES NK_STRING */ +{ pCxt->pRootNode = createAlterDnodeStmt(pCxt, NULL, &yymsp[0].minor.yy0, NULL); } + break; + case 69: /* cmd ::= ALTER ALL DNODES NK_STRING NK_STRING */ +{ pCxt->pRootNode = createAlterDnodeStmt(pCxt, NULL, &yymsp[-1].minor.yy0, &yymsp[0].minor.yy0); } + break; + case 70: /* cmd ::= RESTORE DNODE NK_INTEGER */ +{ pCxt->pRootNode = createRestoreComponentNodeStmt(pCxt, QUERY_NODE_RESTORE_DNODE_STMT, &yymsp[0].minor.yy0); } + break; + case 71: /* dnode_endpoint ::= NK_STRING */ + case 72: /* dnode_endpoint ::= NK_ID */ yytestcase(yyruleno==72); + case 73: /* dnode_endpoint ::= NK_IPTOKEN */ yytestcase(yyruleno==73); + case 366: /* sma_func_name ::= COUNT */ yytestcase(yyruleno==366); + case 367: /* sma_func_name ::= FIRST */ yytestcase(yyruleno==367); + case 368: /* sma_func_name ::= LAST */ yytestcase(yyruleno==368); + case 369: /* sma_func_name ::= LAST_ROW */ yytestcase(yyruleno==369); + case 517: /* db_name ::= NK_ID */ yytestcase(yyruleno==517); + case 518: /* table_name ::= NK_ID */ yytestcase(yyruleno==518); + case 519: /* column_name ::= NK_ID */ yytestcase(yyruleno==519); + case 520: /* function_name ::= NK_ID */ yytestcase(yyruleno==520); + case 521: /* view_name ::= NK_ID */ yytestcase(yyruleno==521); + case 522: /* table_alias ::= NK_ID */ yytestcase(yyruleno==522); + case 523: /* column_alias ::= NK_ID */ yytestcase(yyruleno==523); + case 524: /* column_alias ::= NK_ALIAS */ yytestcase(yyruleno==524); + case 525: /* user_name ::= NK_ID */ yytestcase(yyruleno==525); + case 526: /* topic_name ::= NK_ID */ yytestcase(yyruleno==526); + case 527: /* stream_name ::= NK_ID */ yytestcase(yyruleno==527); + case 528: /* cgroup_name ::= NK_ID */ yytestcase(yyruleno==528); + case 529: /* index_name ::= NK_ID */ yytestcase(yyruleno==529); + case 530: /* tsma_name ::= NK_ID */ yytestcase(yyruleno==530); + case 586: /* substr_func ::= SUBSTR */ yytestcase(yyruleno==586); + case 587: /* substr_func ::= SUBSTRING */ yytestcase(yyruleno==587); + case 591: /* noarg_func ::= NOW */ yytestcase(yyruleno==591); + case 592: /* noarg_func ::= TODAY */ yytestcase(yyruleno==592); + case 593: /* noarg_func ::= TIMEZONE */ yytestcase(yyruleno==593); + case 594: /* noarg_func ::= DATABASE */ yytestcase(yyruleno==594); + case 595: /* noarg_func ::= CLIENT_VERSION */ yytestcase(yyruleno==595); + case 596: /* noarg_func ::= SERVER_VERSION */ yytestcase(yyruleno==596); + case 597: /* noarg_func ::= SERVER_STATUS */ yytestcase(yyruleno==597); + case 598: /* noarg_func ::= CURRENT_USER */ yytestcase(yyruleno==598); + case 599: /* noarg_func ::= USER */ yytestcase(yyruleno==599); + case 600: /* noarg_func ::= PI */ yytestcase(yyruleno==600); + case 601: /* star_func ::= COUNT */ yytestcase(yyruleno==601); + case 602: /* star_func ::= FIRST */ yytestcase(yyruleno==602); + case 603: /* star_func ::= LAST */ yytestcase(yyruleno==603); + case 604: /* star_func ::= LAST_ROW */ yytestcase(yyruleno==604); +{ yylhsminor.yy533 = yymsp[0].minor.yy0; } + yymsp[0].minor.yy533 = yylhsminor.yy533; + break; + case 74: /* force_opt ::= */ + case 101: /* not_exists_opt ::= */ yytestcase(yyruleno==101); + case 103: /* exists_opt ::= */ yytestcase(yyruleno==103); + case 206: /* with_opt ::= */ yytestcase(yyruleno==206); + case 387: /* analyze_opt ::= */ yytestcase(yyruleno==387); + case 394: /* agg_func_opt ::= */ yytestcase(yyruleno==394); + case 400: /* or_replace_opt ::= */ yytestcase(yyruleno==400); + case 431: /* ignore_opt ::= */ yytestcase(yyruleno==431); + case 684: /* tag_mode_opt ::= */ yytestcase(yyruleno==684); + case 686: /* set_quantifier_opt ::= */ yytestcase(yyruleno==686); +{ yymsp[1].minor.yy173 = false; } + break; + case 75: /* force_opt ::= FORCE */ + case 76: /* unsafe_opt ::= UNSAFE */ yytestcase(yyruleno==76); + case 207: /* with_opt ::= WITH */ yytestcase(yyruleno==207); + case 388: /* analyze_opt ::= ANALYZE */ yytestcase(yyruleno==388); + case 395: /* agg_func_opt ::= AGGREGATE */ yytestcase(yyruleno==395); + case 685: /* tag_mode_opt ::= TAGS */ yytestcase(yyruleno==685); + case 687: /* set_quantifier_opt ::= DISTINCT */ yytestcase(yyruleno==687); +{ yymsp[0].minor.yy173 = true; } + break; + case 77: /* cmd ::= ALTER CLUSTER NK_STRING */ +{ pCxt->pRootNode = createAlterClusterStmt(pCxt, &yymsp[0].minor.yy0, NULL); } + break; + case 78: /* cmd ::= ALTER CLUSTER NK_STRING NK_STRING */ +{ pCxt->pRootNode = createAlterClusterStmt(pCxt, &yymsp[-1].minor.yy0, &yymsp[0].minor.yy0); } + break; + case 79: /* cmd ::= ALTER LOCAL NK_STRING */ +{ pCxt->pRootNode = createAlterLocalStmt(pCxt, &yymsp[0].minor.yy0, NULL); } + break; + case 80: /* cmd ::= ALTER LOCAL NK_STRING NK_STRING */ +{ pCxt->pRootNode = createAlterLocalStmt(pCxt, &yymsp[-1].minor.yy0, &yymsp[0].minor.yy0); } + break; + case 81: /* cmd ::= CREATE QNODE ON DNODE NK_INTEGER */ +{ pCxt->pRootNode = createCreateComponentNodeStmt(pCxt, QUERY_NODE_CREATE_QNODE_STMT, &yymsp[0].minor.yy0); } + break; + case 82: /* cmd ::= DROP QNODE ON DNODE NK_INTEGER */ +{ pCxt->pRootNode = createDropComponentNodeStmt(pCxt, QUERY_NODE_DROP_QNODE_STMT, &yymsp[0].minor.yy0); } + break; + case 83: /* cmd ::= RESTORE QNODE ON DNODE NK_INTEGER */ +{ pCxt->pRootNode = createRestoreComponentNodeStmt(pCxt, QUERY_NODE_RESTORE_QNODE_STMT, &yymsp[0].minor.yy0); } + break; + case 84: /* cmd ::= CREATE BNODE ON DNODE NK_INTEGER */ +{ pCxt->pRootNode = createCreateComponentNodeStmt(pCxt, QUERY_NODE_CREATE_BNODE_STMT, &yymsp[0].minor.yy0); } + break; + case 85: /* cmd ::= DROP BNODE ON DNODE NK_INTEGER */ +{ pCxt->pRootNode = createDropComponentNodeStmt(pCxt, QUERY_NODE_DROP_BNODE_STMT, &yymsp[0].minor.yy0); } + break; + case 86: /* cmd ::= CREATE SNODE ON DNODE NK_INTEGER */ +{ pCxt->pRootNode = createCreateComponentNodeStmt(pCxt, QUERY_NODE_CREATE_SNODE_STMT, &yymsp[0].minor.yy0); } + break; + case 87: /* cmd ::= DROP SNODE ON DNODE NK_INTEGER */ +{ pCxt->pRootNode = createDropComponentNodeStmt(pCxt, QUERY_NODE_DROP_SNODE_STMT, &yymsp[0].minor.yy0); } + break; + case 88: /* cmd ::= CREATE MNODE ON DNODE NK_INTEGER */ +{ pCxt->pRootNode = createCreateComponentNodeStmt(pCxt, QUERY_NODE_CREATE_MNODE_STMT, &yymsp[0].minor.yy0); } + break; + case 89: /* cmd ::= DROP MNODE ON DNODE NK_INTEGER */ +{ pCxt->pRootNode = createDropComponentNodeStmt(pCxt, QUERY_NODE_DROP_MNODE_STMT, &yymsp[0].minor.yy0); } + break; + case 90: /* cmd ::= RESTORE MNODE ON DNODE NK_INTEGER */ +{ pCxt->pRootNode = createRestoreComponentNodeStmt(pCxt, QUERY_NODE_RESTORE_MNODE_STMT, &yymsp[0].minor.yy0); } + break; + case 91: /* cmd ::= RESTORE VNODE ON DNODE NK_INTEGER */ +{ pCxt->pRootNode = createRestoreComponentNodeStmt(pCxt, QUERY_NODE_RESTORE_VNODE_STMT, &yymsp[0].minor.yy0); } + break; + case 92: /* cmd ::= CREATE DATABASE not_exists_opt db_name db_options */ +{ pCxt->pRootNode = createCreateDatabaseStmt(pCxt, yymsp[-2].minor.yy173, &yymsp[-1].minor.yy533, yymsp[0].minor.yy560); } + break; + case 93: /* cmd ::= DROP DATABASE exists_opt db_name */ +{ pCxt->pRootNode = createDropDatabaseStmt(pCxt, yymsp[-1].minor.yy173, &yymsp[0].minor.yy533); } + break; + case 94: /* cmd ::= USE db_name */ +{ pCxt->pRootNode = createUseDatabaseStmt(pCxt, &yymsp[0].minor.yy533); } + break; + case 95: /* cmd ::= ALTER DATABASE db_name alter_db_options */ +{ pCxt->pRootNode = createAlterDatabaseStmt(pCxt, &yymsp[-1].minor.yy533, yymsp[0].minor.yy560); } + break; + case 96: /* cmd ::= FLUSH DATABASE db_name */ +{ pCxt->pRootNode = createFlushDatabaseStmt(pCxt, &yymsp[0].minor.yy533); } + break; + case 97: /* cmd ::= TRIM DATABASE db_name speed_opt */ +{ pCxt->pRootNode = createTrimDatabaseStmt(pCxt, &yymsp[-1].minor.yy533, yymsp[0].minor.yy802); } + break; + case 98: /* cmd ::= S3MIGRATE DATABASE db_name */ +{ pCxt->pRootNode = createS3MigrateDatabaseStmt(pCxt, &yymsp[0].minor.yy533); } + break; + case 99: /* cmd ::= COMPACT DATABASE db_name start_opt end_opt */ +{ pCxt->pRootNode = createCompactStmt(pCxt, &yymsp[-2].minor.yy533, yymsp[-1].minor.yy560, yymsp[0].minor.yy560); } + break; + case 100: /* not_exists_opt ::= IF NOT EXISTS */ +{ yymsp[-2].minor.yy173 = true; } + break; + case 102: /* exists_opt ::= IF EXISTS */ + case 401: /* or_replace_opt ::= OR REPLACE */ yytestcase(yyruleno==401); + case 432: /* ignore_opt ::= IGNORE UNTREATED */ yytestcase(yyruleno==432); +{ yymsp[-1].minor.yy173 = true; } + break; + case 104: /* db_options ::= */ +{ yymsp[1].minor.yy560 = createDefaultDatabaseOptions(pCxt); } + break; + case 105: /* db_options ::= db_options BUFFER NK_INTEGER */ +{ yylhsminor.yy560 = setDatabaseOption(pCxt, yymsp[-2].minor.yy560, DB_OPTION_BUFFER, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 106: /* db_options ::= db_options CACHEMODEL NK_STRING */ +{ yylhsminor.yy560 = setDatabaseOption(pCxt, yymsp[-2].minor.yy560, DB_OPTION_CACHEMODEL, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 107: /* db_options ::= db_options CACHESIZE NK_INTEGER */ +{ yylhsminor.yy560 = setDatabaseOption(pCxt, yymsp[-2].minor.yy560, DB_OPTION_CACHESIZE, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 108: /* db_options ::= db_options COMP NK_INTEGER */ +{ yylhsminor.yy560 = setDatabaseOption(pCxt, yymsp[-2].minor.yy560, DB_OPTION_COMP, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 109: /* db_options ::= db_options DURATION NK_INTEGER */ + case 110: /* db_options ::= db_options DURATION NK_VARIABLE */ yytestcase(yyruleno==110); +{ yylhsminor.yy560 = setDatabaseOption(pCxt, yymsp[-2].minor.yy560, DB_OPTION_DAYS, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 111: /* db_options ::= db_options MAXROWS NK_INTEGER */ +{ yylhsminor.yy560 = setDatabaseOption(pCxt, yymsp[-2].minor.yy560, DB_OPTION_MAXROWS, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 112: /* db_options ::= db_options MINROWS NK_INTEGER */ +{ yylhsminor.yy560 = setDatabaseOption(pCxt, yymsp[-2].minor.yy560, DB_OPTION_MINROWS, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 113: /* db_options ::= db_options KEEP integer_list */ + case 114: /* db_options ::= db_options KEEP variable_list */ yytestcase(yyruleno==114); +{ yylhsminor.yy560 = setDatabaseOption(pCxt, yymsp[-2].minor.yy560, DB_OPTION_KEEP, yymsp[0].minor.yy334); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 115: /* db_options ::= db_options PAGES NK_INTEGER */ +{ yylhsminor.yy560 = setDatabaseOption(pCxt, yymsp[-2].minor.yy560, DB_OPTION_PAGES, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 116: /* db_options ::= db_options PAGESIZE NK_INTEGER */ +{ yylhsminor.yy560 = setDatabaseOption(pCxt, yymsp[-2].minor.yy560, DB_OPTION_PAGESIZE, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 117: /* db_options ::= db_options TSDB_PAGESIZE NK_INTEGER */ +{ yylhsminor.yy560 = setDatabaseOption(pCxt, yymsp[-2].minor.yy560, DB_OPTION_TSDB_PAGESIZE, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 118: /* db_options ::= db_options PRECISION NK_STRING */ +{ yylhsminor.yy560 = setDatabaseOption(pCxt, yymsp[-2].minor.yy560, DB_OPTION_PRECISION, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 119: /* db_options ::= db_options REPLICA NK_INTEGER */ +{ yylhsminor.yy560 = setDatabaseOption(pCxt, yymsp[-2].minor.yy560, DB_OPTION_REPLICA, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 120: /* db_options ::= db_options VGROUPS NK_INTEGER */ +{ yylhsminor.yy560 = setDatabaseOption(pCxt, yymsp[-2].minor.yy560, DB_OPTION_VGROUPS, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 121: /* db_options ::= db_options SINGLE_STABLE NK_INTEGER */ +{ yylhsminor.yy560 = setDatabaseOption(pCxt, yymsp[-2].minor.yy560, DB_OPTION_SINGLE_STABLE, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 122: /* db_options ::= db_options RETENTIONS retention_list */ +{ yylhsminor.yy560 = setDatabaseOption(pCxt, yymsp[-2].minor.yy560, DB_OPTION_RETENTIONS, yymsp[0].minor.yy334); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 123: /* db_options ::= db_options SCHEMALESS NK_INTEGER */ +{ yylhsminor.yy560 = setDatabaseOption(pCxt, yymsp[-2].minor.yy560, DB_OPTION_SCHEMALESS, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 124: /* db_options ::= db_options WAL_LEVEL NK_INTEGER */ +{ yylhsminor.yy560 = setDatabaseOption(pCxt, yymsp[-2].minor.yy560, DB_OPTION_WAL, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 125: /* db_options ::= db_options WAL_FSYNC_PERIOD NK_INTEGER */ +{ yylhsminor.yy560 = setDatabaseOption(pCxt, yymsp[-2].minor.yy560, DB_OPTION_FSYNC, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 126: /* db_options ::= db_options WAL_RETENTION_PERIOD NK_INTEGER */ +{ yylhsminor.yy560 = setDatabaseOption(pCxt, yymsp[-2].minor.yy560, DB_OPTION_WAL_RETENTION_PERIOD, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 127: /* db_options ::= db_options WAL_RETENTION_PERIOD NK_MINUS NK_INTEGER */ +{ + SToken t = yymsp[-1].minor.yy0; + t.n = (yymsp[0].minor.yy0.z + yymsp[0].minor.yy0.n) - yymsp[-1].minor.yy0.z; + yylhsminor.yy560 = setDatabaseOption(pCxt, yymsp[-3].minor.yy560, DB_OPTION_WAL_RETENTION_PERIOD, &t); + } + yymsp[-3].minor.yy560 = yylhsminor.yy560; + break; + case 128: /* db_options ::= db_options WAL_RETENTION_SIZE NK_INTEGER */ +{ yylhsminor.yy560 = setDatabaseOption(pCxt, yymsp[-2].minor.yy560, DB_OPTION_WAL_RETENTION_SIZE, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 129: /* db_options ::= db_options WAL_RETENTION_SIZE NK_MINUS NK_INTEGER */ +{ + SToken t = yymsp[-1].minor.yy0; + t.n = (yymsp[0].minor.yy0.z + yymsp[0].minor.yy0.n) - yymsp[-1].minor.yy0.z; + yylhsminor.yy560 = setDatabaseOption(pCxt, yymsp[-3].minor.yy560, DB_OPTION_WAL_RETENTION_SIZE, &t); + } + yymsp[-3].minor.yy560 = yylhsminor.yy560; + break; + case 130: /* db_options ::= db_options WAL_ROLL_PERIOD NK_INTEGER */ +{ yylhsminor.yy560 = setDatabaseOption(pCxt, yymsp[-2].minor.yy560, DB_OPTION_WAL_ROLL_PERIOD, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 131: /* db_options ::= db_options WAL_SEGMENT_SIZE NK_INTEGER */ +{ yylhsminor.yy560 = setDatabaseOption(pCxt, yymsp[-2].minor.yy560, DB_OPTION_WAL_SEGMENT_SIZE, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 132: /* db_options ::= db_options STT_TRIGGER NK_INTEGER */ +{ yylhsminor.yy560 = setDatabaseOption(pCxt, yymsp[-2].minor.yy560, DB_OPTION_STT_TRIGGER, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 133: /* db_options ::= db_options TABLE_PREFIX signed */ +{ yylhsminor.yy560 = setDatabaseOption(pCxt, yymsp[-2].minor.yy560, DB_OPTION_TABLE_PREFIX, yymsp[0].minor.yy560); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 134: /* db_options ::= db_options TABLE_SUFFIX signed */ +{ yylhsminor.yy560 = setDatabaseOption(pCxt, yymsp[-2].minor.yy560, DB_OPTION_TABLE_SUFFIX, yymsp[0].minor.yy560); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 135: /* db_options ::= db_options S3_CHUNKSIZE NK_INTEGER */ +{ yylhsminor.yy560 = setDatabaseOption(pCxt, yymsp[-2].minor.yy560, DB_OPTION_S3_CHUNKSIZE, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 136: /* db_options ::= db_options S3_KEEPLOCAL NK_INTEGER */ + case 137: /* db_options ::= db_options S3_KEEPLOCAL NK_VARIABLE */ yytestcase(yyruleno==137); +{ yylhsminor.yy560 = setDatabaseOption(pCxt, yymsp[-2].minor.yy560, DB_OPTION_S3_KEEPLOCAL, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 138: /* db_options ::= db_options S3_COMPACT NK_INTEGER */ +{ yylhsminor.yy560 = setDatabaseOption(pCxt, yymsp[-2].minor.yy560, DB_OPTION_S3_COMPACT, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 139: /* db_options ::= db_options KEEP_TIME_OFFSET NK_INTEGER */ +{ yylhsminor.yy560 = setDatabaseOption(pCxt, yymsp[-2].minor.yy560, DB_OPTION_KEEP_TIME_OFFSET, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 140: /* db_options ::= db_options ENCRYPT_ALGORITHM NK_STRING */ +{ yylhsminor.yy560 = setDatabaseOption(pCxt, yymsp[-2].minor.yy560, DB_OPTION_ENCRYPT_ALGORITHM, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 141: /* alter_db_options ::= alter_db_option */ +{ yylhsminor.yy560 = createAlterDatabaseOptions(pCxt); yylhsminor.yy560 = setAlterDatabaseOption(pCxt, yylhsminor.yy560, &yymsp[0].minor.yy389); } + yymsp[0].minor.yy560 = yylhsminor.yy560; + break; + case 142: /* alter_db_options ::= alter_db_options alter_db_option */ +{ yylhsminor.yy560 = setAlterDatabaseOption(pCxt, yymsp[-1].minor.yy560, &yymsp[0].minor.yy389); } + yymsp[-1].minor.yy560 = yylhsminor.yy560; + break; + case 143: /* alter_db_option ::= BUFFER NK_INTEGER */ +{ yymsp[-1].minor.yy389.type = DB_OPTION_BUFFER; yymsp[-1].minor.yy389.val = yymsp[0].minor.yy0; } + break; + case 144: /* alter_db_option ::= CACHEMODEL NK_STRING */ +{ yymsp[-1].minor.yy389.type = DB_OPTION_CACHEMODEL; yymsp[-1].minor.yy389.val = yymsp[0].minor.yy0; } + break; + case 145: /* alter_db_option ::= CACHESIZE NK_INTEGER */ +{ yymsp[-1].minor.yy389.type = DB_OPTION_CACHESIZE; yymsp[-1].minor.yy389.val = yymsp[0].minor.yy0; } + break; + case 146: /* alter_db_option ::= WAL_FSYNC_PERIOD NK_INTEGER */ +{ yymsp[-1].minor.yy389.type = DB_OPTION_FSYNC; yymsp[-1].minor.yy389.val = yymsp[0].minor.yy0; } + break; + case 147: /* alter_db_option ::= KEEP integer_list */ + case 148: /* alter_db_option ::= KEEP variable_list */ yytestcase(yyruleno==148); +{ yymsp[-1].minor.yy389.type = DB_OPTION_KEEP; yymsp[-1].minor.yy389.pList = yymsp[0].minor.yy334; } + break; + case 149: /* alter_db_option ::= PAGES NK_INTEGER */ +{ yymsp[-1].minor.yy389.type = DB_OPTION_PAGES; yymsp[-1].minor.yy389.val = yymsp[0].minor.yy0; } + break; + case 150: /* alter_db_option ::= REPLICA NK_INTEGER */ +{ yymsp[-1].minor.yy389.type = DB_OPTION_REPLICA; yymsp[-1].minor.yy389.val = yymsp[0].minor.yy0; } + break; + case 151: /* alter_db_option ::= WAL_LEVEL NK_INTEGER */ +{ yymsp[-1].minor.yy389.type = DB_OPTION_WAL; yymsp[-1].minor.yy389.val = yymsp[0].minor.yy0; } + break; + case 152: /* alter_db_option ::= STT_TRIGGER NK_INTEGER */ +{ yymsp[-1].minor.yy389.type = DB_OPTION_STT_TRIGGER; yymsp[-1].minor.yy389.val = yymsp[0].minor.yy0; } + break; + case 153: /* alter_db_option ::= MINROWS NK_INTEGER */ +{ yymsp[-1].minor.yy389.type = DB_OPTION_MINROWS; yymsp[-1].minor.yy389.val = yymsp[0].minor.yy0; } + break; + case 154: /* alter_db_option ::= WAL_RETENTION_PERIOD NK_INTEGER */ +{ yymsp[-1].minor.yy389.type = DB_OPTION_WAL_RETENTION_PERIOD; yymsp[-1].minor.yy389.val = yymsp[0].minor.yy0; } + break; + case 155: /* alter_db_option ::= WAL_RETENTION_PERIOD NK_MINUS NK_INTEGER */ +{ + SToken t = yymsp[-1].minor.yy0; + t.n = (yymsp[0].minor.yy0.z + yymsp[0].minor.yy0.n) - yymsp[-1].minor.yy0.z; + yymsp[-2].minor.yy389.type = DB_OPTION_WAL_RETENTION_PERIOD; yymsp[-2].minor.yy389.val = t; + } + break; + case 156: /* alter_db_option ::= WAL_RETENTION_SIZE NK_INTEGER */ +{ yymsp[-1].minor.yy389.type = DB_OPTION_WAL_RETENTION_SIZE; yymsp[-1].minor.yy389.val = yymsp[0].minor.yy0; } + break; + case 157: /* alter_db_option ::= WAL_RETENTION_SIZE NK_MINUS NK_INTEGER */ +{ + SToken t = yymsp[-1].minor.yy0; + t.n = (yymsp[0].minor.yy0.z + yymsp[0].minor.yy0.n) - yymsp[-1].minor.yy0.z; + yymsp[-2].minor.yy389.type = DB_OPTION_WAL_RETENTION_SIZE; yymsp[-2].minor.yy389.val = t; + } + break; + case 158: /* alter_db_option ::= S3_KEEPLOCAL NK_INTEGER */ + case 159: /* alter_db_option ::= S3_KEEPLOCAL NK_VARIABLE */ yytestcase(yyruleno==159); +{ yymsp[-1].minor.yy389.type = DB_OPTION_S3_KEEPLOCAL; yymsp[-1].minor.yy389.val = yymsp[0].minor.yy0; } + break; + case 160: /* alter_db_option ::= S3_COMPACT NK_INTEGER */ +{ yymsp[-1].minor.yy389.type = DB_OPTION_S3_COMPACT, yymsp[-1].minor.yy389.val = yymsp[0].minor.yy0; } + break; + case 161: /* alter_db_option ::= KEEP_TIME_OFFSET NK_INTEGER */ +{ yymsp[-1].minor.yy389.type = DB_OPTION_KEEP_TIME_OFFSET; yymsp[-1].minor.yy389.val = yymsp[0].minor.yy0; } + break; + case 162: /* alter_db_option ::= ENCRYPT_ALGORITHM NK_STRING */ +{ yymsp[-1].minor.yy389.type = DB_OPTION_ENCRYPT_ALGORITHM; yymsp[-1].minor.yy389.val = yymsp[0].minor.yy0; } + break; + case 163: /* integer_list ::= NK_INTEGER */ +{ yylhsminor.yy334 = createNodeList(pCxt, createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0)); } + yymsp[0].minor.yy334 = yylhsminor.yy334; + break; + case 164: /* integer_list ::= integer_list NK_COMMA NK_INTEGER */ + case 446: /* dnode_list ::= dnode_list DNODE NK_INTEGER */ yytestcase(yyruleno==446); +{ yylhsminor.yy334 = addNodeToList(pCxt, yymsp[-2].minor.yy334, createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0)); } + yymsp[-2].minor.yy334 = yylhsminor.yy334; + break; + case 165: /* variable_list ::= NK_VARIABLE */ +{ yylhsminor.yy334 = createNodeList(pCxt, createDurationValueNode(pCxt, &yymsp[0].minor.yy0)); } + yymsp[0].minor.yy334 = yylhsminor.yy334; + break; + case 166: /* variable_list ::= variable_list NK_COMMA NK_VARIABLE */ +{ yylhsminor.yy334 = addNodeToList(pCxt, yymsp[-2].minor.yy334, createDurationValueNode(pCxt, &yymsp[0].minor.yy0)); } + yymsp[-2].minor.yy334 = yylhsminor.yy334; + break; + case 167: /* retention_list ::= retention */ + case 200: /* multi_create_clause ::= create_subtable_clause */ yytestcase(yyruleno==200); + case 203: /* multi_drop_clause ::= drop_table_clause */ yytestcase(yyruleno==203); + case 212: /* tag_def_list ::= tag_def */ yytestcase(yyruleno==212); + case 215: /* column_def_list ::= column_def */ yytestcase(yyruleno==215); + case 263: /* rollup_func_list ::= rollup_func_name */ yytestcase(yyruleno==263); + case 268: /* col_name_list ::= col_name */ yytestcase(yyruleno==268); + case 338: /* tag_list_opt ::= tag_item */ yytestcase(yyruleno==338); + case 362: /* func_list ::= func */ yytestcase(yyruleno==362); + case 412: /* column_stream_def_list ::= column_stream_def */ yytestcase(yyruleno==412); + case 490: /* tags_literal_list ::= tags_literal */ yytestcase(yyruleno==490); + case 515: /* literal_list ::= signed_literal */ yytestcase(yyruleno==515); + case 607: /* other_para_list ::= star_func_para */ yytestcase(yyruleno==607); + case 613: /* when_then_list ::= when_then_expr */ yytestcase(yyruleno==613); + case 689: /* select_list ::= select_item */ yytestcase(yyruleno==689); + case 700: /* partition_list ::= partition_item */ yytestcase(yyruleno==700); + case 761: /* sort_specification_list ::= sort_specification */ yytestcase(yyruleno==761); +{ yylhsminor.yy334 = createNodeList(pCxt, yymsp[0].minor.yy560); } + yymsp[0].minor.yy334 = yylhsminor.yy334; + break; + case 168: /* retention_list ::= retention_list NK_COMMA retention */ + case 204: /* multi_drop_clause ::= multi_drop_clause NK_COMMA drop_table_clause */ yytestcase(yyruleno==204); + case 213: /* tag_def_list ::= tag_def_list NK_COMMA tag_def */ yytestcase(yyruleno==213); + case 216: /* column_def_list ::= column_def_list NK_COMMA column_def */ yytestcase(yyruleno==216); + case 264: /* rollup_func_list ::= rollup_func_list NK_COMMA rollup_func_name */ yytestcase(yyruleno==264); + case 269: /* col_name_list ::= col_name_list NK_COMMA col_name */ yytestcase(yyruleno==269); + case 339: /* tag_list_opt ::= tag_list_opt NK_COMMA tag_item */ yytestcase(yyruleno==339); + case 363: /* func_list ::= func_list NK_COMMA func */ yytestcase(yyruleno==363); + case 413: /* column_stream_def_list ::= column_stream_def_list NK_COMMA column_stream_def */ yytestcase(yyruleno==413); + case 491: /* tags_literal_list ::= tags_literal_list NK_COMMA tags_literal */ yytestcase(yyruleno==491); + case 516: /* literal_list ::= literal_list NK_COMMA signed_literal */ yytestcase(yyruleno==516); + case 608: /* other_para_list ::= other_para_list NK_COMMA star_func_para */ yytestcase(yyruleno==608); + case 690: /* select_list ::= select_list NK_COMMA select_item */ yytestcase(yyruleno==690); + case 701: /* partition_list ::= partition_list NK_COMMA partition_item */ yytestcase(yyruleno==701); + case 762: /* sort_specification_list ::= sort_specification_list NK_COMMA sort_specification */ yytestcase(yyruleno==762); +{ yylhsminor.yy334 = addNodeToList(pCxt, yymsp[-2].minor.yy334, yymsp[0].minor.yy560); } + yymsp[-2].minor.yy334 = yylhsminor.yy334; + break; + case 169: /* retention ::= NK_VARIABLE NK_COLON NK_VARIABLE */ + case 170: /* retention ::= NK_MINUS NK_COLON NK_VARIABLE */ yytestcase(yyruleno==170); +{ yylhsminor.yy560 = createNodeListNodeEx(pCxt, createDurationValueNode(pCxt, &yymsp[-2].minor.yy0), createDurationValueNode(pCxt, &yymsp[0].minor.yy0)); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 171: /* speed_opt ::= */ + case 396: /* bufsize_opt ::= */ yytestcase(yyruleno==396); +{ yymsp[1].minor.yy802 = 0; } + break; + case 172: /* speed_opt ::= BWLIMIT NK_INTEGER */ + case 397: /* bufsize_opt ::= BUFSIZE NK_INTEGER */ yytestcase(yyruleno==397); +{ yymsp[-1].minor.yy802 = taosStr2Int32(yymsp[0].minor.yy0.z, NULL, 10); } + break; + case 174: /* start_opt ::= START WITH NK_INTEGER */ + case 178: /* end_opt ::= END WITH NK_INTEGER */ yytestcase(yyruleno==178); +{ yymsp[-2].minor.yy560 = createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0); } + break; + case 175: /* start_opt ::= START WITH NK_STRING */ + case 179: /* end_opt ::= END WITH NK_STRING */ yytestcase(yyruleno==179); +{ yymsp[-2].minor.yy560 = createValueNode(pCxt, TSDB_DATA_TYPE_TIMESTAMP, &yymsp[0].minor.yy0); } + break; + case 176: /* start_opt ::= START WITH TIMESTAMP NK_STRING */ + case 180: /* end_opt ::= END WITH TIMESTAMP NK_STRING */ yytestcase(yyruleno==180); +{ yymsp[-3].minor.yy560 = createValueNode(pCxt, TSDB_DATA_TYPE_TIMESTAMP, &yymsp[0].minor.yy0); } + break; + case 181: /* cmd ::= CREATE TABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def_opt table_options */ + case 184: /* cmd ::= CREATE STABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def table_options */ yytestcase(yyruleno==184); +{ pCxt->pRootNode = createCreateTableStmt(pCxt, yymsp[-6].minor.yy173, yymsp[-5].minor.yy560, yymsp[-3].minor.yy334, yymsp[-1].minor.yy334, yymsp[0].minor.yy560); } + break; + case 182: /* cmd ::= CREATE TABLE multi_create_clause */ +{ pCxt->pRootNode = createCreateMultiTableStmt(pCxt, yymsp[0].minor.yy334); } + break; + case 183: /* cmd ::= CREATE TABLE not_exists_opt USING full_table_name NK_LP tag_list_opt NK_RP FILE NK_STRING */ +{ pCxt->pRootNode = createCreateSubTableFromFileClause(pCxt, yymsp[-7].minor.yy173, yymsp[-5].minor.yy560, yymsp[-3].minor.yy334, &yymsp[0].minor.yy0); } + break; + case 185: /* cmd ::= DROP TABLE with_opt multi_drop_clause */ +{ pCxt->pRootNode = createDropTableStmt(pCxt, yymsp[-1].minor.yy173, yymsp[0].minor.yy334); } + break; + case 186: /* cmd ::= DROP STABLE with_opt exists_opt full_table_name */ +{ pCxt->pRootNode = createDropSuperTableStmt(pCxt, yymsp[-2].minor.yy173, yymsp[-1].minor.yy173, yymsp[0].minor.yy560); } + break; + case 187: /* cmd ::= ALTER TABLE alter_table_clause */ + case 448: /* cmd ::= query_or_subquery */ yytestcase(yyruleno==448); + case 449: /* cmd ::= insert_query */ yytestcase(yyruleno==449); +{ pCxt->pRootNode = yymsp[0].minor.yy560; } + break; + case 188: /* cmd ::= ALTER STABLE alter_table_clause */ +{ pCxt->pRootNode = setAlterSuperTableType(yymsp[0].minor.yy560); } + break; + case 189: /* alter_table_clause ::= full_table_name alter_table_options */ +{ yylhsminor.yy560 = createAlterTableModifyOptions(pCxt, yymsp[-1].minor.yy560, yymsp[0].minor.yy560); } + yymsp[-1].minor.yy560 = yylhsminor.yy560; + break; + case 190: /* alter_table_clause ::= full_table_name ADD COLUMN column_name type_name column_options */ +{ yylhsminor.yy560 = createAlterTableAddModifyColOptions2(pCxt, yymsp[-5].minor.yy560, TSDB_ALTER_TABLE_ADD_COLUMN, &yymsp[-2].minor.yy533, yymsp[-1].minor.yy952, yymsp[0].minor.yy560); } + yymsp[-5].minor.yy560 = yylhsminor.yy560; + break; + case 191: /* alter_table_clause ::= full_table_name DROP COLUMN column_name */ +{ yylhsminor.yy560 = createAlterTableDropCol(pCxt, yymsp[-3].minor.yy560, TSDB_ALTER_TABLE_DROP_COLUMN, &yymsp[0].minor.yy533); } + yymsp[-3].minor.yy560 = yylhsminor.yy560; + break; + case 192: /* alter_table_clause ::= full_table_name MODIFY COLUMN column_name type_name */ +{ yylhsminor.yy560 = createAlterTableAddModifyCol(pCxt, yymsp[-4].minor.yy560, TSDB_ALTER_TABLE_UPDATE_COLUMN_BYTES, &yymsp[-1].minor.yy533, yymsp[0].minor.yy952); } + yymsp[-4].minor.yy560 = yylhsminor.yy560; + break; + case 193: /* alter_table_clause ::= full_table_name MODIFY COLUMN column_name column_options */ +{ yylhsminor.yy560 = createAlterTableAddModifyColOptions(pCxt, yymsp[-4].minor.yy560, TSDB_ALTER_TABLE_UPDATE_COLUMN_COMPRESS, &yymsp[-1].minor.yy533, yymsp[0].minor.yy560); } + yymsp[-4].minor.yy560 = yylhsminor.yy560; + break; + case 194: /* alter_table_clause ::= full_table_name RENAME COLUMN column_name column_name */ +{ yylhsminor.yy560 = createAlterTableRenameCol(pCxt, yymsp[-4].minor.yy560, TSDB_ALTER_TABLE_UPDATE_COLUMN_NAME, &yymsp[-1].minor.yy533, &yymsp[0].minor.yy533); } + yymsp[-4].minor.yy560 = yylhsminor.yy560; + break; + case 195: /* alter_table_clause ::= full_table_name ADD TAG column_name type_name */ +{ yylhsminor.yy560 = createAlterTableAddModifyCol(pCxt, yymsp[-4].minor.yy560, TSDB_ALTER_TABLE_ADD_TAG, &yymsp[-1].minor.yy533, yymsp[0].minor.yy952); } + yymsp[-4].minor.yy560 = yylhsminor.yy560; + break; + case 196: /* alter_table_clause ::= full_table_name DROP TAG column_name */ +{ yylhsminor.yy560 = createAlterTableDropCol(pCxt, yymsp[-3].minor.yy560, TSDB_ALTER_TABLE_DROP_TAG, &yymsp[0].minor.yy533); } + yymsp[-3].minor.yy560 = yylhsminor.yy560; + break; + case 197: /* alter_table_clause ::= full_table_name MODIFY TAG column_name type_name */ +{ yylhsminor.yy560 = createAlterTableAddModifyCol(pCxt, yymsp[-4].minor.yy560, TSDB_ALTER_TABLE_UPDATE_TAG_BYTES, &yymsp[-1].minor.yy533, yymsp[0].minor.yy952); } + yymsp[-4].minor.yy560 = yylhsminor.yy560; + break; + case 198: /* alter_table_clause ::= full_table_name RENAME TAG column_name column_name */ +{ yylhsminor.yy560 = createAlterTableRenameCol(pCxt, yymsp[-4].minor.yy560, TSDB_ALTER_TABLE_UPDATE_TAG_NAME, &yymsp[-1].minor.yy533, &yymsp[0].minor.yy533); } + yymsp[-4].minor.yy560 = yylhsminor.yy560; + break; + case 199: /* alter_table_clause ::= full_table_name SET TAG column_name NK_EQ tags_literal */ +{ yylhsminor.yy560 = createAlterTableSetTag(pCxt, yymsp[-5].minor.yy560, &yymsp[-2].minor.yy533, yymsp[0].minor.yy560); } + yymsp[-5].minor.yy560 = yylhsminor.yy560; + break; + case 201: /* multi_create_clause ::= multi_create_clause create_subtable_clause */ + case 614: /* when_then_list ::= when_then_list when_then_expr */ yytestcase(yyruleno==614); +{ yylhsminor.yy334 = addNodeToList(pCxt, yymsp[-1].minor.yy334, yymsp[0].minor.yy560); } + yymsp[-1].minor.yy334 = yylhsminor.yy334; + break; + case 202: /* create_subtable_clause ::= not_exists_opt full_table_name USING full_table_name specific_cols_opt TAGS NK_LP tags_literal_list NK_RP table_options */ +{ yylhsminor.yy560 = createCreateSubTableClause(pCxt, yymsp[-9].minor.yy173, yymsp[-8].minor.yy560, yymsp[-6].minor.yy560, yymsp[-5].minor.yy334, yymsp[-2].minor.yy334, yymsp[0].minor.yy560); } + yymsp[-9].minor.yy560 = yylhsminor.yy560; + break; + case 205: /* drop_table_clause ::= exists_opt full_table_name */ +{ yylhsminor.yy560 = createDropTableClause(pCxt, yymsp[-1].minor.yy173, yymsp[0].minor.yy560); } + yymsp[-1].minor.yy560 = yylhsminor.yy560; + break; + case 209: /* specific_cols_opt ::= NK_LP col_name_list NK_RP */ + case 411: /* col_list_opt ::= NK_LP column_stream_def_list NK_RP */ yytestcase(yyruleno==411); +{ yymsp[-2].minor.yy334 = yymsp[-1].minor.yy334; } + break; + case 210: /* full_table_name ::= table_name */ + case 352: /* full_tsma_name ::= tsma_name */ yytestcase(yyruleno==352); +{ yylhsminor.yy560 = createRealTableNode(pCxt, NULL, &yymsp[0].minor.yy533, NULL); } + yymsp[0].minor.yy560 = yylhsminor.yy560; + break; + case 211: /* full_table_name ::= db_name NK_DOT table_name */ + case 353: /* full_tsma_name ::= db_name NK_DOT tsma_name */ yytestcase(yyruleno==353); +{ yylhsminor.yy560 = createRealTableNode(pCxt, &yymsp[-2].minor.yy533, &yymsp[0].minor.yy533, NULL); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 214: /* tag_def ::= column_name type_name */ +{ yylhsminor.yy560 = createColumnDefNode(pCxt, &yymsp[-1].minor.yy533, yymsp[0].minor.yy952, NULL); } + yymsp[-1].minor.yy560 = yylhsminor.yy560; + break; + case 217: /* column_def ::= column_name type_name column_options */ +{ yylhsminor.yy560 = createColumnDefNode(pCxt, &yymsp[-2].minor.yy533, yymsp[-1].minor.yy952, yymsp[0].minor.yy560); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 218: /* type_name ::= BOOL */ +{ yymsp[0].minor.yy952 = createDataType(TSDB_DATA_TYPE_BOOL); } + break; + case 219: /* type_name ::= TINYINT */ +{ yymsp[0].minor.yy952 = createDataType(TSDB_DATA_TYPE_TINYINT); } + break; + case 220: /* type_name ::= SMALLINT */ +{ yymsp[0].minor.yy952 = createDataType(TSDB_DATA_TYPE_SMALLINT); } + break; + case 221: /* type_name ::= INT */ + case 222: /* type_name ::= INTEGER */ yytestcase(yyruleno==222); +{ yymsp[0].minor.yy952 = createDataType(TSDB_DATA_TYPE_INT); } + break; + case 223: /* type_name ::= BIGINT */ +{ yymsp[0].minor.yy952 = createDataType(TSDB_DATA_TYPE_BIGINT); } + break; + case 224: /* type_name ::= FLOAT */ +{ yymsp[0].minor.yy952 = createDataType(TSDB_DATA_TYPE_FLOAT); } + break; + case 225: /* type_name ::= DOUBLE */ +{ yymsp[0].minor.yy952 = createDataType(TSDB_DATA_TYPE_DOUBLE); } + break; + case 226: /* type_name ::= BINARY NK_LP NK_INTEGER NK_RP */ +{ yymsp[-3].minor.yy952 = createVarLenDataType(TSDB_DATA_TYPE_BINARY, &yymsp[-1].minor.yy0); } + break; + case 227: /* type_name ::= TIMESTAMP */ +{ yymsp[0].minor.yy952 = createDataType(TSDB_DATA_TYPE_TIMESTAMP); } + break; + case 228: /* type_name ::= NCHAR NK_LP NK_INTEGER NK_RP */ +{ yymsp[-3].minor.yy952 = createVarLenDataType(TSDB_DATA_TYPE_NCHAR, &yymsp[-1].minor.yy0); } + break; + case 229: /* type_name ::= TINYINT UNSIGNED */ +{ yymsp[-1].minor.yy952 = createDataType(TSDB_DATA_TYPE_UTINYINT); } + break; + case 230: /* type_name ::= SMALLINT UNSIGNED */ +{ yymsp[-1].minor.yy952 = createDataType(TSDB_DATA_TYPE_USMALLINT); } + break; + case 231: /* type_name ::= INT UNSIGNED */ +{ yymsp[-1].minor.yy952 = createDataType(TSDB_DATA_TYPE_UINT); } + break; + case 232: /* type_name ::= BIGINT UNSIGNED */ +{ yymsp[-1].minor.yy952 = createDataType(TSDB_DATA_TYPE_UBIGINT); } + break; + case 233: /* type_name ::= JSON */ +{ yymsp[0].minor.yy952 = createDataType(TSDB_DATA_TYPE_JSON); } + break; + case 234: /* type_name ::= VARCHAR NK_LP NK_INTEGER NK_RP */ +{ yymsp[-3].minor.yy952 = createVarLenDataType(TSDB_DATA_TYPE_VARCHAR, &yymsp[-1].minor.yy0); } + break; + case 235: /* type_name ::= MEDIUMBLOB */ +{ yymsp[0].minor.yy952 = createDataType(TSDB_DATA_TYPE_MEDIUMBLOB); } + break; + case 236: /* type_name ::= BLOB */ +{ yymsp[0].minor.yy952 = createDataType(TSDB_DATA_TYPE_BLOB); } + break; + case 237: /* type_name ::= VARBINARY NK_LP NK_INTEGER NK_RP */ +{ yymsp[-3].minor.yy952 = createVarLenDataType(TSDB_DATA_TYPE_VARBINARY, &yymsp[-1].minor.yy0); } + break; + case 238: /* type_name ::= GEOMETRY NK_LP NK_INTEGER NK_RP */ +{ yymsp[-3].minor.yy952 = createVarLenDataType(TSDB_DATA_TYPE_GEOMETRY, &yymsp[-1].minor.yy0); } + break; + case 239: /* type_name ::= DECIMAL */ +{ yymsp[0].minor.yy952 = createDataType(TSDB_DATA_TYPE_DECIMAL); } + break; + case 240: /* type_name ::= DECIMAL NK_LP NK_INTEGER NK_RP */ +{ yymsp[-3].minor.yy952 = createDataType(TSDB_DATA_TYPE_DECIMAL); } + break; + case 241: /* type_name ::= DECIMAL NK_LP NK_INTEGER NK_COMMA NK_INTEGER NK_RP */ +{ yymsp[-5].minor.yy952 = createDataType(TSDB_DATA_TYPE_DECIMAL); } + break; + case 242: /* type_name_default_len ::= BINARY */ +{ yymsp[0].minor.yy952 = createVarLenDataType(TSDB_DATA_TYPE_BINARY, NULL); } + break; + case 243: /* type_name_default_len ::= NCHAR */ +{ yymsp[0].minor.yy952 = createVarLenDataType(TSDB_DATA_TYPE_NCHAR, NULL); } + break; + case 244: /* type_name_default_len ::= VARCHAR */ +{ yymsp[0].minor.yy952 = createVarLenDataType(TSDB_DATA_TYPE_VARCHAR, NULL); } + break; + case 245: /* type_name_default_len ::= VARBINARY */ +{ yymsp[0].minor.yy952 = createVarLenDataType(TSDB_DATA_TYPE_VARBINARY, NULL); } + break; + case 248: /* tags_def ::= TAGS NK_LP tag_def_list NK_RP */ + case 419: /* tag_def_or_ref_opt ::= TAGS NK_LP column_stream_def_list NK_RP */ yytestcase(yyruleno==419); +{ yymsp[-3].minor.yy334 = yymsp[-1].minor.yy334; } + break; + case 249: /* table_options ::= */ +{ yymsp[1].minor.yy560 = createDefaultTableOptions(pCxt); } + break; + case 250: /* table_options ::= table_options COMMENT NK_STRING */ +{ yylhsminor.yy560 = setTableOption(pCxt, yymsp[-2].minor.yy560, TABLE_OPTION_COMMENT, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 251: /* table_options ::= table_options MAX_DELAY duration_list */ +{ yylhsminor.yy560 = setTableOption(pCxt, yymsp[-2].minor.yy560, TABLE_OPTION_MAXDELAY, yymsp[0].minor.yy334); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 252: /* table_options ::= table_options WATERMARK duration_list */ +{ yylhsminor.yy560 = setTableOption(pCxt, yymsp[-2].minor.yy560, TABLE_OPTION_WATERMARK, yymsp[0].minor.yy334); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 253: /* table_options ::= table_options ROLLUP NK_LP rollup_func_list NK_RP */ +{ yylhsminor.yy560 = setTableOption(pCxt, yymsp[-4].minor.yy560, TABLE_OPTION_ROLLUP, yymsp[-1].minor.yy334); } + yymsp[-4].minor.yy560 = yylhsminor.yy560; + break; + case 254: /* table_options ::= table_options TTL NK_INTEGER */ +{ yylhsminor.yy560 = setTableOption(pCxt, yymsp[-2].minor.yy560, TABLE_OPTION_TTL, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 255: /* table_options ::= table_options SMA NK_LP col_name_list NK_RP */ +{ yylhsminor.yy560 = setTableOption(pCxt, yymsp[-4].minor.yy560, TABLE_OPTION_SMA, yymsp[-1].minor.yy334); } + yymsp[-4].minor.yy560 = yylhsminor.yy560; + break; + case 256: /* table_options ::= table_options DELETE_MARK duration_list */ +{ yylhsminor.yy560 = setTableOption(pCxt, yymsp[-2].minor.yy560, TABLE_OPTION_DELETE_MARK, yymsp[0].minor.yy334); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 257: /* alter_table_options ::= alter_table_option */ +{ yylhsminor.yy560 = createAlterTableOptions(pCxt); yylhsminor.yy560 = setTableOption(pCxt, yylhsminor.yy560, yymsp[0].minor.yy389.type, &yymsp[0].minor.yy389.val); } + yymsp[0].minor.yy560 = yylhsminor.yy560; + break; + case 258: /* alter_table_options ::= alter_table_options alter_table_option */ +{ yylhsminor.yy560 = setTableOption(pCxt, yymsp[-1].minor.yy560, yymsp[0].minor.yy389.type, &yymsp[0].minor.yy389.val); } + yymsp[-1].minor.yy560 = yylhsminor.yy560; + break; + case 259: /* alter_table_option ::= COMMENT NK_STRING */ +{ yymsp[-1].minor.yy389.type = TABLE_OPTION_COMMENT; yymsp[-1].minor.yy389.val = yymsp[0].minor.yy0; } + break; + case 260: /* alter_table_option ::= TTL NK_INTEGER */ +{ yymsp[-1].minor.yy389.type = TABLE_OPTION_TTL; yymsp[-1].minor.yy389.val = yymsp[0].minor.yy0; } + break; + case 261: /* duration_list ::= duration_literal */ + case 548: /* expression_list ::= expr_or_subquery */ yytestcase(yyruleno==548); +{ yylhsminor.yy334 = createNodeList(pCxt, releaseRawExprNode(pCxt, yymsp[0].minor.yy560)); } + yymsp[0].minor.yy334 = yylhsminor.yy334; + break; + case 262: /* duration_list ::= duration_list NK_COMMA duration_literal */ + case 549: /* expression_list ::= expression_list NK_COMMA expr_or_subquery */ yytestcase(yyruleno==549); +{ yylhsminor.yy334 = addNodeToList(pCxt, yymsp[-2].minor.yy334, releaseRawExprNode(pCxt, yymsp[0].minor.yy560)); } + yymsp[-2].minor.yy334 = yylhsminor.yy334; + break; + case 265: /* rollup_func_name ::= function_name */ +{ yylhsminor.yy560 = createFunctionNode(pCxt, &yymsp[0].minor.yy533, NULL); } + yymsp[0].minor.yy560 = yylhsminor.yy560; + break; + case 266: /* rollup_func_name ::= FIRST */ + case 267: /* rollup_func_name ::= LAST */ yytestcase(yyruleno==267); + case 341: /* tag_item ::= QTAGS */ yytestcase(yyruleno==341); +{ yylhsminor.yy560 = createFunctionNode(pCxt, &yymsp[0].minor.yy0, NULL); } + yymsp[0].minor.yy560 = yylhsminor.yy560; + break; + case 270: /* col_name ::= column_name */ + case 342: /* tag_item ::= column_name */ yytestcase(yyruleno==342); +{ yylhsminor.yy560 = createColumnNode(pCxt, NULL, &yymsp[0].minor.yy533); } + yymsp[0].minor.yy560 = yylhsminor.yy560; + break; + case 271: /* cmd ::= SHOW DNODES */ +{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_DNODES_STMT); } + break; + case 272: /* cmd ::= SHOW USERS */ +{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_USERS_STMT); } + break; + case 273: /* cmd ::= SHOW USERS FULL */ +{ pCxt->pRootNode = createShowStmtWithFull(pCxt, QUERY_NODE_SHOW_USERS_FULL_STMT); } + break; + case 274: /* cmd ::= SHOW USER PRIVILEGES */ +{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_USER_PRIVILEGES_STMT); } + break; + case 275: /* cmd ::= SHOW db_kind_opt DATABASES */ +{ + pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_DATABASES_STMT); + (void)setShowKind(pCxt, pCxt->pRootNode, yymsp[-1].minor.yy537); + } + break; + case 276: /* cmd ::= SHOW table_kind_db_name_cond_opt TABLES like_pattern_opt */ +{ + pCxt->pRootNode = createShowTablesStmt(pCxt, yymsp[-2].minor.yy709, yymsp[0].minor.yy560, OP_TYPE_LIKE); + } + break; + case 277: /* cmd ::= SHOW db_name_cond_opt STABLES like_pattern_opt */ +{ pCxt->pRootNode = createShowStmtWithCond(pCxt, QUERY_NODE_SHOW_STABLES_STMT, yymsp[-2].minor.yy560, yymsp[0].minor.yy560, OP_TYPE_LIKE); } + break; + case 278: /* cmd ::= SHOW db_name_cond_opt VGROUPS */ +{ pCxt->pRootNode = createShowStmtWithCond(pCxt, QUERY_NODE_SHOW_VGROUPS_STMT, yymsp[-1].minor.yy560, NULL, OP_TYPE_LIKE); } + break; + case 279: /* cmd ::= SHOW MNODES */ +{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_MNODES_STMT); } + break; + case 280: /* cmd ::= SHOW QNODES */ +{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_QNODES_STMT); } + break; + case 281: /* cmd ::= SHOW ARBGROUPS */ +{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_ARBGROUPS_STMT); } + break; + case 282: /* cmd ::= SHOW FUNCTIONS */ +{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_FUNCTIONS_STMT); } + break; + case 283: /* cmd ::= SHOW INDEXES FROM table_name_cond from_db_opt */ +{ pCxt->pRootNode = createShowStmtWithCond(pCxt, QUERY_NODE_SHOW_INDEXES_STMT, yymsp[0].minor.yy560, yymsp[-1].minor.yy560, OP_TYPE_EQUAL); } + break; + case 284: /* cmd ::= SHOW INDEXES FROM db_name NK_DOT table_name */ +{ pCxt->pRootNode = createShowStmtWithCond(pCxt, QUERY_NODE_SHOW_INDEXES_STMT, createIdentifierValueNode(pCxt, &yymsp[-2].minor.yy533), createIdentifierValueNode(pCxt, &yymsp[0].minor.yy533), OP_TYPE_EQUAL); } + break; + case 285: /* cmd ::= SHOW STREAMS */ +{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_STREAMS_STMT); } + break; + case 286: /* cmd ::= SHOW ACCOUNTS */ +{ pCxt->errCode = generateSyntaxErrMsg(&pCxt->msgBuf, TSDB_CODE_PAR_EXPRIE_STATEMENT); } + break; + case 287: /* cmd ::= SHOW APPS */ +{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_APPS_STMT); } + break; + case 288: /* cmd ::= SHOW CONNECTIONS */ +{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_CONNECTIONS_STMT); } + break; + case 289: /* cmd ::= SHOW LICENCES */ + case 290: /* cmd ::= SHOW GRANTS */ yytestcase(yyruleno==290); +{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_LICENCES_STMT); } + break; + case 291: /* cmd ::= SHOW GRANTS FULL */ +{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_GRANTS_FULL_STMT); } + break; + case 292: /* cmd ::= SHOW GRANTS LOGS */ +{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_GRANTS_LOGS_STMT); } + break; + case 293: /* cmd ::= SHOW CLUSTER MACHINES */ +{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_CLUSTER_MACHINES_STMT); } + break; + case 294: /* cmd ::= SHOW CREATE DATABASE db_name */ +{ pCxt->pRootNode = createShowCreateDatabaseStmt(pCxt, &yymsp[0].minor.yy533); } + break; + case 295: /* cmd ::= SHOW CREATE TABLE full_table_name */ +{ pCxt->pRootNode = createShowCreateTableStmt(pCxt, QUERY_NODE_SHOW_CREATE_TABLE_STMT, yymsp[0].minor.yy560); } + break; + case 296: /* cmd ::= SHOW CREATE STABLE full_table_name */ +{ pCxt->pRootNode = createShowCreateTableStmt(pCxt, QUERY_NODE_SHOW_CREATE_STABLE_STMT, +yymsp[0].minor.yy560); } + break; + case 297: /* cmd ::= SHOW ENCRYPTIONS */ +{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_ENCRYPTIONS_STMT); } + break; + case 298: /* cmd ::= SHOW QUERIES */ +{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_QUERIES_STMT); } + break; + case 299: /* cmd ::= SHOW SCORES */ +{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_SCORES_STMT); } + break; + case 300: /* cmd ::= SHOW TOPICS */ +{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_TOPICS_STMT); } + break; + case 301: /* cmd ::= SHOW VARIABLES */ + case 302: /* cmd ::= SHOW CLUSTER VARIABLES */ yytestcase(yyruleno==302); +{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_VARIABLES_STMT); } + break; + case 303: /* cmd ::= SHOW LOCAL VARIABLES */ +{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_LOCAL_VARIABLES_STMT); } + break; + case 304: /* cmd ::= SHOW DNODE NK_INTEGER VARIABLES like_pattern_opt */ +{ pCxt->pRootNode = createShowDnodeVariablesStmt(pCxt, createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[-2].minor.yy0), yymsp[0].minor.yy560); } + break; + case 305: /* cmd ::= SHOW BNODES */ +{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_BNODES_STMT); } + break; + case 306: /* cmd ::= SHOW SNODES */ +{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_SNODES_STMT); } + break; + case 307: /* cmd ::= SHOW CLUSTER */ +{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_CLUSTER_STMT); } + break; + case 308: /* cmd ::= SHOW TRANSACTIONS */ +{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_TRANSACTIONS_STMT); } + break; + case 309: /* cmd ::= SHOW TABLE DISTRIBUTED full_table_name */ +{ pCxt->pRootNode = createShowTableDistributedStmt(pCxt, yymsp[0].minor.yy560); } + break; + case 310: /* cmd ::= SHOW CONSUMERS */ +{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_CONSUMERS_STMT); } + break; + case 311: /* cmd ::= SHOW SUBSCRIPTIONS */ +{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_SUBSCRIPTIONS_STMT); } + break; + case 312: /* cmd ::= SHOW TAGS FROM table_name_cond from_db_opt */ +{ pCxt->pRootNode = createShowStmtWithCond(pCxt, QUERY_NODE_SHOW_TAGS_STMT, yymsp[0].minor.yy560, yymsp[-1].minor.yy560, OP_TYPE_EQUAL); } + break; + case 313: /* cmd ::= SHOW TAGS FROM db_name NK_DOT table_name */ +{ pCxt->pRootNode = createShowStmtWithCond(pCxt, QUERY_NODE_SHOW_TAGS_STMT, createIdentifierValueNode(pCxt, &yymsp[-2].minor.yy533), createIdentifierValueNode(pCxt, &yymsp[0].minor.yy533), OP_TYPE_EQUAL); } + break; + case 314: /* cmd ::= SHOW TABLE TAGS tag_list_opt FROM table_name_cond from_db_opt */ +{ pCxt->pRootNode = createShowTableTagsStmt(pCxt, yymsp[-1].minor.yy560, yymsp[0].minor.yy560, yymsp[-3].minor.yy334); } + break; + case 315: /* cmd ::= SHOW TABLE TAGS tag_list_opt FROM db_name NK_DOT table_name */ +{ pCxt->pRootNode = createShowTableTagsStmt(pCxt, createIdentifierValueNode(pCxt, &yymsp[0].minor.yy533), createIdentifierValueNode(pCxt, &yymsp[-2].minor.yy533), yymsp[-4].minor.yy334); } + break; + case 316: /* cmd ::= SHOW VNODES ON DNODE NK_INTEGER */ +{ pCxt->pRootNode = createShowVnodesStmt(pCxt, createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0), NULL); } + break; + case 317: /* cmd ::= SHOW VNODES */ +{ pCxt->pRootNode = createShowVnodesStmt(pCxt, NULL, NULL); } + break; + case 318: /* cmd ::= SHOW db_name_cond_opt ALIVE */ +{ pCxt->pRootNode = createShowAliveStmt(pCxt, yymsp[-1].minor.yy560, QUERY_NODE_SHOW_DB_ALIVE_STMT); } + break; + case 319: /* cmd ::= SHOW CLUSTER ALIVE */ +{ pCxt->pRootNode = createShowAliveStmt(pCxt, NULL, QUERY_NODE_SHOW_CLUSTER_ALIVE_STMT); } + break; + case 320: /* cmd ::= SHOW db_name_cond_opt VIEWS like_pattern_opt */ +{ pCxt->pRootNode = createShowStmtWithCond(pCxt, QUERY_NODE_SHOW_VIEWS_STMT, yymsp[-2].minor.yy560, yymsp[0].minor.yy560, OP_TYPE_LIKE); } + break; + case 321: /* cmd ::= SHOW CREATE VIEW full_table_name */ +{ pCxt->pRootNode = createShowCreateViewStmt(pCxt, QUERY_NODE_SHOW_CREATE_VIEW_STMT, yymsp[0].minor.yy560); } + break; + case 322: /* cmd ::= SHOW COMPACTS */ +{ pCxt->pRootNode = createShowCompactsStmt(pCxt, QUERY_NODE_SHOW_COMPACTS_STMT); } + break; + case 323: /* cmd ::= SHOW COMPACT NK_INTEGER */ +{ pCxt->pRootNode = createShowCompactDetailsStmt(pCxt, createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0)); } + break; + case 324: /* table_kind_db_name_cond_opt ::= */ +{ yymsp[1].minor.yy709.kind = SHOW_KIND_ALL; yymsp[1].minor.yy709.dbName = nil_token; } + break; + case 325: /* table_kind_db_name_cond_opt ::= table_kind */ +{ yylhsminor.yy709.kind = yymsp[0].minor.yy537; yylhsminor.yy709.dbName = nil_token; } + yymsp[0].minor.yy709 = yylhsminor.yy709; + break; + case 326: /* table_kind_db_name_cond_opt ::= db_name NK_DOT */ +{ yylhsminor.yy709.kind = SHOW_KIND_ALL; yylhsminor.yy709.dbName = yymsp[-1].minor.yy533; } + yymsp[-1].minor.yy709 = yylhsminor.yy709; + break; + case 327: /* table_kind_db_name_cond_opt ::= table_kind db_name NK_DOT */ +{ yylhsminor.yy709.kind = yymsp[-2].minor.yy537; yylhsminor.yy709.dbName = yymsp[-1].minor.yy533; } + yymsp[-2].minor.yy709 = yylhsminor.yy709; + break; + case 328: /* table_kind ::= NORMAL */ +{ yymsp[0].minor.yy537 = SHOW_KIND_TABLES_NORMAL; } + break; + case 329: /* table_kind ::= CHILD */ +{ yymsp[0].minor.yy537 = SHOW_KIND_TABLES_CHILD; } + break; + case 330: /* db_name_cond_opt ::= */ + case 335: /* from_db_opt ::= */ yytestcase(yyruleno==335); +{ yymsp[1].minor.yy560 = createDefaultDatabaseCondValue(pCxt); } + break; + case 331: /* db_name_cond_opt ::= db_name NK_DOT */ +{ yylhsminor.yy560 = createIdentifierValueNode(pCxt, &yymsp[-1].minor.yy533); } + yymsp[-1].minor.yy560 = yylhsminor.yy560; + break; + case 333: /* like_pattern_opt ::= LIKE NK_STRING */ +{ yymsp[-1].minor.yy560 = createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy0); } + break; + case 334: /* table_name_cond ::= table_name */ +{ yylhsminor.yy560 = createIdentifierValueNode(pCxt, &yymsp[0].minor.yy533); } + yymsp[0].minor.yy560 = yylhsminor.yy560; + break; + case 336: /* from_db_opt ::= FROM db_name */ +{ yymsp[-1].minor.yy560 = createIdentifierValueNode(pCxt, &yymsp[0].minor.yy533); } + break; + case 340: /* tag_item ::= TBNAME */ +{ yylhsminor.yy560 = setProjectionAlias(pCxt, createFunctionNode(pCxt, &yymsp[0].minor.yy0, NULL), &yymsp[0].minor.yy0); } + yymsp[0].minor.yy560 = yylhsminor.yy560; + break; + case 343: /* tag_item ::= column_name column_alias */ +{ yylhsminor.yy560 = setProjectionAlias(pCxt, createColumnNode(pCxt, NULL, &yymsp[-1].minor.yy533), &yymsp[0].minor.yy533); } + yymsp[-1].minor.yy560 = yylhsminor.yy560; + break; + case 344: /* tag_item ::= column_name AS column_alias */ +{ yylhsminor.yy560 = setProjectionAlias(pCxt, createColumnNode(pCxt, NULL, &yymsp[-2].minor.yy533), &yymsp[0].minor.yy533); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 345: /* db_kind_opt ::= */ +{ yymsp[1].minor.yy537 = SHOW_KIND_ALL; } + break; + case 346: /* db_kind_opt ::= USER */ +{ yymsp[0].minor.yy537 = SHOW_KIND_DATABASES_USER; } + break; + case 347: /* db_kind_opt ::= SYSTEM */ +{ yymsp[0].minor.yy537 = SHOW_KIND_DATABASES_SYSTEM; } + break; + case 348: /* cmd ::= CREATE TSMA not_exists_opt tsma_name ON full_table_name tsma_func_list INTERVAL NK_LP duration_literal NK_RP */ +{ pCxt->pRootNode = createCreateTSMAStmt(pCxt, yymsp[-8].minor.yy173, &yymsp[-7].minor.yy533, yymsp[-4].minor.yy560, yymsp[-5].minor.yy560, releaseRawExprNode(pCxt, yymsp[-1].minor.yy560)); } + break; + case 349: /* cmd ::= CREATE RECURSIVE TSMA not_exists_opt tsma_name ON full_table_name INTERVAL NK_LP duration_literal NK_RP */ +{ pCxt->pRootNode = createCreateTSMAStmt(pCxt, yymsp[-7].minor.yy173, &yymsp[-6].minor.yy533, NULL, yymsp[-4].minor.yy560, releaseRawExprNode(pCxt, yymsp[-1].minor.yy560)); } + break; + case 350: /* cmd ::= DROP TSMA exists_opt full_tsma_name */ +{ pCxt->pRootNode = createDropTSMAStmt(pCxt, yymsp[-1].minor.yy173, yymsp[0].minor.yy560); } + break; + case 351: /* cmd ::= SHOW db_name_cond_opt TSMAS */ +{ pCxt->pRootNode = createShowTSMASStmt(pCxt, yymsp[-1].minor.yy560); } + break; + case 354: /* tsma_func_list ::= FUNCTION NK_LP func_list NK_RP */ +{ yymsp[-3].minor.yy560 = createTSMAOptions(pCxt, yymsp[-1].minor.yy334); } + break; + case 355: /* cmd ::= CREATE SMA INDEX not_exists_opt col_name ON full_table_name index_options */ +{ pCxt->pRootNode = createCreateIndexStmt(pCxt, INDEX_TYPE_SMA, yymsp[-4].minor.yy173, yymsp[-3].minor.yy560, yymsp[-1].minor.yy560, NULL, yymsp[0].minor.yy560); } + break; + case 356: /* cmd ::= CREATE INDEX not_exists_opt col_name ON full_table_name NK_LP col_name_list NK_RP */ +{ pCxt->pRootNode = createCreateIndexStmt(pCxt, INDEX_TYPE_NORMAL, yymsp[-6].minor.yy173, yymsp[-5].minor.yy560, yymsp[-3].minor.yy560, yymsp[-1].minor.yy334, NULL); } + break; + case 357: /* cmd ::= DROP INDEX exists_opt full_index_name */ +{ pCxt->pRootNode = createDropIndexStmt(pCxt, yymsp[-1].minor.yy173, yymsp[0].minor.yy560); } + break; + case 358: /* full_index_name ::= index_name */ +{ yylhsminor.yy560 = createRealTableNodeForIndexName(pCxt, NULL, &yymsp[0].minor.yy533); } + yymsp[0].minor.yy560 = yylhsminor.yy560; + break; + case 359: /* full_index_name ::= db_name NK_DOT index_name */ +{ yylhsminor.yy560 = createRealTableNodeForIndexName(pCxt, &yymsp[-2].minor.yy533, &yymsp[0].minor.yy533); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 360: /* index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_RP sliding_opt sma_stream_opt */ +{ yymsp[-9].minor.yy560 = createIndexOption(pCxt, yymsp[-7].minor.yy334, releaseRawExprNode(pCxt, yymsp[-3].minor.yy560), NULL, yymsp[-1].minor.yy560, yymsp[0].minor.yy560); } + break; + case 361: /* index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_COMMA duration_literal NK_RP sliding_opt sma_stream_opt */ +{ yymsp[-11].minor.yy560 = createIndexOption(pCxt, yymsp[-9].minor.yy334, releaseRawExprNode(pCxt, yymsp[-5].minor.yy560), releaseRawExprNode(pCxt, yymsp[-3].minor.yy560), yymsp[-1].minor.yy560, yymsp[0].minor.yy560); } + break; + case 364: /* func ::= sma_func_name NK_LP expression_list NK_RP */ +{ yylhsminor.yy560 = createFunctionNode(pCxt, &yymsp[-3].minor.yy533, yymsp[-1].minor.yy334); } + yymsp[-3].minor.yy560 = yylhsminor.yy560; + break; + case 365: /* sma_func_name ::= function_name */ + case 657: /* alias_opt ::= table_alias */ yytestcase(yyruleno==657); +{ yylhsminor.yy533 = yymsp[0].minor.yy533; } + yymsp[0].minor.yy533 = yylhsminor.yy533; + break; + case 370: /* sma_stream_opt ::= */ + case 420: /* stream_options ::= */ yytestcase(yyruleno==420); +{ yymsp[1].minor.yy560 = createStreamOptions(pCxt); } + break; + case 371: /* sma_stream_opt ::= sma_stream_opt WATERMARK duration_literal */ +{ ((SStreamOptions*)yymsp[-2].minor.yy560)->pWatermark = releaseRawExprNode(pCxt, yymsp[0].minor.yy560); yylhsminor.yy560 = yymsp[-2].minor.yy560; } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 372: /* sma_stream_opt ::= sma_stream_opt MAX_DELAY duration_literal */ +{ ((SStreamOptions*)yymsp[-2].minor.yy560)->pDelay = releaseRawExprNode(pCxt, yymsp[0].minor.yy560); yylhsminor.yy560 = yymsp[-2].minor.yy560; } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 373: /* sma_stream_opt ::= sma_stream_opt DELETE_MARK duration_literal */ +{ ((SStreamOptions*)yymsp[-2].minor.yy560)->pDeleteMark = releaseRawExprNode(pCxt, yymsp[0].minor.yy560); yylhsminor.yy560 = yymsp[-2].minor.yy560; } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 374: /* with_meta ::= AS */ +{ yymsp[0].minor.yy802 = 0; } + break; + case 375: /* with_meta ::= WITH META AS */ +{ yymsp[-2].minor.yy802 = 1; } + break; + case 376: /* with_meta ::= ONLY META AS */ +{ yymsp[-2].minor.yy802 = 2; } + break; + case 377: /* cmd ::= CREATE TOPIC not_exists_opt topic_name AS query_or_subquery */ +{ pCxt->pRootNode = createCreateTopicStmtUseQuery(pCxt, yymsp[-3].minor.yy173, &yymsp[-2].minor.yy533, yymsp[0].minor.yy560); } + break; + case 378: /* cmd ::= CREATE TOPIC not_exists_opt topic_name with_meta DATABASE db_name */ +{ pCxt->pRootNode = createCreateTopicStmtUseDb(pCxt, yymsp[-4].minor.yy173, &yymsp[-3].minor.yy533, &yymsp[0].minor.yy533, yymsp[-2].minor.yy802); } + break; + case 379: /* cmd ::= CREATE TOPIC not_exists_opt topic_name with_meta STABLE full_table_name where_clause_opt */ +{ pCxt->pRootNode = createCreateTopicStmtUseTable(pCxt, yymsp[-5].minor.yy173, &yymsp[-4].minor.yy533, yymsp[-1].minor.yy560, yymsp[-3].minor.yy802, yymsp[0].minor.yy560); } + break; + case 380: /* cmd ::= DROP TOPIC exists_opt topic_name */ +{ pCxt->pRootNode = createDropTopicStmt(pCxt, yymsp[-1].minor.yy173, &yymsp[0].minor.yy533); } + break; + case 381: /* cmd ::= DROP CONSUMER GROUP exists_opt cgroup_name ON topic_name */ +{ pCxt->pRootNode = createDropCGroupStmt(pCxt, yymsp[-3].minor.yy173, &yymsp[-2].minor.yy533, &yymsp[0].minor.yy533); } + break; + case 382: /* cmd ::= DESC full_table_name */ + case 383: /* cmd ::= DESCRIBE full_table_name */ yytestcase(yyruleno==383); +{ pCxt->pRootNode = createDescribeStmt(pCxt, yymsp[0].minor.yy560); } + break; + case 384: /* cmd ::= RESET QUERY CACHE */ +{ pCxt->pRootNode = createResetQueryCacheStmt(pCxt); } + break; + case 385: /* cmd ::= EXPLAIN analyze_opt explain_options query_or_subquery */ + case 386: /* cmd ::= EXPLAIN analyze_opt explain_options insert_query */ yytestcase(yyruleno==386); +{ pCxt->pRootNode = createExplainStmt(pCxt, yymsp[-2].minor.yy173, yymsp[-1].minor.yy560, yymsp[0].minor.yy560); } + break; + case 389: /* explain_options ::= */ +{ yymsp[1].minor.yy560 = createDefaultExplainOptions(pCxt); } + break; + case 390: /* explain_options ::= explain_options VERBOSE NK_BOOL */ +{ yylhsminor.yy560 = setExplainVerbose(pCxt, yymsp[-2].minor.yy560, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 391: /* explain_options ::= explain_options RATIO NK_FLOAT */ +{ yylhsminor.yy560 = setExplainRatio(pCxt, yymsp[-2].minor.yy560, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 392: /* cmd ::= CREATE or_replace_opt agg_func_opt FUNCTION not_exists_opt function_name AS NK_STRING OUTPUTTYPE type_name bufsize_opt language_opt */ +{ pCxt->pRootNode = createCreateFunctionStmt(pCxt, yymsp[-7].minor.yy173, yymsp[-9].minor.yy173, &yymsp[-6].minor.yy533, &yymsp[-4].minor.yy0, yymsp[-2].minor.yy952, yymsp[-1].minor.yy802, &yymsp[0].minor.yy533, yymsp[-10].minor.yy173); } + break; + case 393: /* cmd ::= DROP FUNCTION exists_opt function_name */ +{ pCxt->pRootNode = createDropFunctionStmt(pCxt, yymsp[-1].minor.yy173, &yymsp[0].minor.yy533); } + break; + case 398: /* language_opt ::= */ + case 443: /* on_vgroup_id ::= */ yytestcase(yyruleno==443); +{ yymsp[1].minor.yy533 = nil_token; } + break; + case 399: /* language_opt ::= LANGUAGE NK_STRING */ + case 444: /* on_vgroup_id ::= ON NK_INTEGER */ yytestcase(yyruleno==444); +{ yymsp[-1].minor.yy533 = yymsp[0].minor.yy0; } + break; + case 402: /* cmd ::= CREATE or_replace_opt VIEW full_view_name AS query_or_subquery */ +{ pCxt->pRootNode = createCreateViewStmt(pCxt, yymsp[-4].minor.yy173, yymsp[-2].minor.yy560, &yymsp[-1].minor.yy0, yymsp[0].minor.yy560); } + break; + case 403: /* cmd ::= DROP VIEW exists_opt full_view_name */ +{ pCxt->pRootNode = createDropViewStmt(pCxt, yymsp[-1].minor.yy173, yymsp[0].minor.yy560); } + break; + case 404: /* full_view_name ::= view_name */ +{ yylhsminor.yy560 = createViewNode(pCxt, NULL, &yymsp[0].minor.yy533); } + yymsp[0].minor.yy560 = yylhsminor.yy560; + break; + case 405: /* full_view_name ::= db_name NK_DOT view_name */ +{ yylhsminor.yy560 = createViewNode(pCxt, &yymsp[-2].minor.yy533, &yymsp[0].minor.yy533); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 406: /* cmd ::= CREATE STREAM not_exists_opt stream_name stream_options INTO full_table_name col_list_opt tag_def_or_ref_opt subtable_opt AS query_or_subquery */ +{ pCxt->pRootNode = createCreateStreamStmt(pCxt, yymsp[-9].minor.yy173, &yymsp[-8].minor.yy533, yymsp[-5].minor.yy560, yymsp[-7].minor.yy560, yymsp[-3].minor.yy334, yymsp[-2].minor.yy560, yymsp[0].minor.yy560, yymsp[-4].minor.yy334); } + break; + case 407: /* cmd ::= DROP STREAM exists_opt stream_name */ +{ pCxt->pRootNode = createDropStreamStmt(pCxt, yymsp[-1].minor.yy173, &yymsp[0].minor.yy533); } + break; + case 408: /* cmd ::= PAUSE STREAM exists_opt stream_name */ +{ pCxt->pRootNode = createPauseStreamStmt(pCxt, yymsp[-1].minor.yy173, &yymsp[0].minor.yy533); } + break; + case 409: /* cmd ::= RESUME STREAM exists_opt ignore_opt stream_name */ +{ pCxt->pRootNode = createResumeStreamStmt(pCxt, yymsp[-2].minor.yy173, yymsp[-1].minor.yy173, &yymsp[0].minor.yy533); } + break; + case 414: /* column_stream_def ::= column_name stream_col_options */ +{ yylhsminor.yy560 = createColumnDefNode(pCxt, &yymsp[-1].minor.yy533, createDataType(TSDB_DATA_TYPE_NULL), yymsp[0].minor.yy560); } + yymsp[-1].minor.yy560 = yylhsminor.yy560; + break; + case 415: /* stream_col_options ::= */ + case 770: /* column_options ::= */ yytestcase(yyruleno==770); +{ yymsp[1].minor.yy560 = createDefaultColumnOptions(pCxt); } + break; + case 416: /* stream_col_options ::= stream_col_options PRIMARY KEY */ + case 771: /* column_options ::= column_options PRIMARY KEY */ yytestcase(yyruleno==771); +{ yylhsminor.yy560 = setColumnOptionsPK(pCxt, yymsp[-2].minor.yy560); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 421: /* stream_options ::= stream_options TRIGGER AT_ONCE */ + case 422: /* stream_options ::= stream_options TRIGGER WINDOW_CLOSE */ yytestcase(yyruleno==422); +{ yylhsminor.yy560 = setStreamOptions(pCxt, yymsp[-2].minor.yy560, SOPT_TRIGGER_TYPE_SET, &yymsp[0].minor.yy0, NULL); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 423: /* stream_options ::= stream_options TRIGGER MAX_DELAY duration_literal */ +{ yylhsminor.yy560 = setStreamOptions(pCxt, yymsp[-3].minor.yy560, SOPT_TRIGGER_TYPE_SET, &yymsp[-1].minor.yy0, releaseRawExprNode(pCxt, yymsp[0].minor.yy560)); } + yymsp[-3].minor.yy560 = yylhsminor.yy560; + break; + case 424: /* stream_options ::= stream_options WATERMARK duration_literal */ +{ yylhsminor.yy560 = setStreamOptions(pCxt, yymsp[-2].minor.yy560, SOPT_WATERMARK_SET, NULL, releaseRawExprNode(pCxt, yymsp[0].minor.yy560)); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 425: /* stream_options ::= stream_options IGNORE EXPIRED NK_INTEGER */ +{ yylhsminor.yy560 = setStreamOptions(pCxt, yymsp[-3].minor.yy560, SOPT_IGNORE_EXPIRED_SET, &yymsp[0].minor.yy0, NULL); } + yymsp[-3].minor.yy560 = yylhsminor.yy560; + break; + case 426: /* stream_options ::= stream_options FILL_HISTORY NK_INTEGER */ +{ yylhsminor.yy560 = setStreamOptions(pCxt, yymsp[-2].minor.yy560, SOPT_FILL_HISTORY_SET, &yymsp[0].minor.yy0, NULL); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 427: /* stream_options ::= stream_options DELETE_MARK duration_literal */ +{ yylhsminor.yy560 = setStreamOptions(pCxt, yymsp[-2].minor.yy560, SOPT_DELETE_MARK_SET, NULL, releaseRawExprNode(pCxt, yymsp[0].minor.yy560)); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 428: /* stream_options ::= stream_options IGNORE UPDATE NK_INTEGER */ +{ yylhsminor.yy560 = setStreamOptions(pCxt, yymsp[-3].minor.yy560, SOPT_IGNORE_UPDATE_SET, &yymsp[0].minor.yy0, NULL); } + yymsp[-3].minor.yy560 = yylhsminor.yy560; + break; + case 430: /* subtable_opt ::= SUBTABLE NK_LP expression NK_RP */ + case 714: /* sliding_opt ::= SLIDING NK_LP interval_sliding_duration_literal NK_RP */ yytestcase(yyruleno==714); + case 738: /* every_opt ::= EVERY NK_LP duration_literal NK_RP */ yytestcase(yyruleno==738); +{ yymsp[-3].minor.yy560 = releaseRawExprNode(pCxt, yymsp[-1].minor.yy560); } + break; + case 433: /* cmd ::= KILL CONNECTION NK_INTEGER */ +{ pCxt->pRootNode = createKillStmt(pCxt, QUERY_NODE_KILL_CONNECTION_STMT, &yymsp[0].minor.yy0); } + break; + case 434: /* cmd ::= KILL QUERY NK_STRING */ +{ pCxt->pRootNode = createKillQueryStmt(pCxt, &yymsp[0].minor.yy0); } + break; + case 435: /* cmd ::= KILL TRANSACTION NK_INTEGER */ +{ pCxt->pRootNode = createKillStmt(pCxt, QUERY_NODE_KILL_TRANSACTION_STMT, &yymsp[0].minor.yy0); } + break; + case 436: /* cmd ::= KILL COMPACT NK_INTEGER */ +{ pCxt->pRootNode = createKillStmt(pCxt, QUERY_NODE_KILL_COMPACT_STMT, &yymsp[0].minor.yy0); } + break; + case 437: /* cmd ::= BALANCE VGROUP */ +{ pCxt->pRootNode = createBalanceVgroupStmt(pCxt); } + break; + case 438: /* cmd ::= BALANCE VGROUP LEADER on_vgroup_id */ +{ pCxt->pRootNode = createBalanceVgroupLeaderStmt(pCxt, &yymsp[0].minor.yy533); } + break; + case 439: /* cmd ::= BALANCE VGROUP LEADER DATABASE db_name */ +{ pCxt->pRootNode = createBalanceVgroupLeaderDBNameStmt(pCxt, &yymsp[0].minor.yy533); } + break; + case 440: /* cmd ::= MERGE VGROUP NK_INTEGER NK_INTEGER */ +{ pCxt->pRootNode = createMergeVgroupStmt(pCxt, &yymsp[-1].minor.yy0, &yymsp[0].minor.yy0); } + break; + case 441: /* cmd ::= REDISTRIBUTE VGROUP NK_INTEGER dnode_list */ +{ pCxt->pRootNode = createRedistributeVgroupStmt(pCxt, &yymsp[-1].minor.yy0, yymsp[0].minor.yy334); } + break; + case 442: /* cmd ::= SPLIT VGROUP NK_INTEGER */ +{ pCxt->pRootNode = createSplitVgroupStmt(pCxt, &yymsp[0].minor.yy0); } + break; + case 445: /* dnode_list ::= DNODE NK_INTEGER */ +{ yymsp[-1].minor.yy334 = createNodeList(pCxt, createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0)); } + break; + case 447: /* cmd ::= DELETE FROM full_table_name where_clause_opt */ +{ pCxt->pRootNode = createDeleteStmt(pCxt, yymsp[-1].minor.yy560, yymsp[0].minor.yy560); } + break; + case 450: /* insert_query ::= INSERT INTO full_table_name NK_LP col_name_list NK_RP query_or_subquery */ +{ yymsp[-6].minor.yy560 = createInsertStmt(pCxt, yymsp[-4].minor.yy560, yymsp[-2].minor.yy334, yymsp[0].minor.yy560); } + break; + case 451: /* insert_query ::= INSERT INTO full_table_name query_or_subquery */ +{ yymsp[-3].minor.yy560 = createInsertStmt(pCxt, yymsp[-1].minor.yy560, NULL, yymsp[0].minor.yy560); } + break; + case 452: /* tags_literal ::= NK_INTEGER */ + case 464: /* tags_literal ::= NK_BIN */ yytestcase(yyruleno==464); + case 473: /* tags_literal ::= NK_HEX */ yytestcase(yyruleno==473); +{ yylhsminor.yy560 = createRawValueNode(pCxt, TSDB_DATA_TYPE_UBIGINT, &yymsp[0].minor.yy0, NULL); } + yymsp[0].minor.yy560 = yylhsminor.yy560; + break; + case 453: /* tags_literal ::= NK_INTEGER NK_PLUS duration_literal */ + case 454: /* tags_literal ::= NK_INTEGER NK_MINUS duration_literal */ yytestcase(yyruleno==454); + case 465: /* tags_literal ::= NK_BIN NK_PLUS duration_literal */ yytestcase(yyruleno==465); + case 466: /* tags_literal ::= NK_BIN NK_MINUS duration_literal */ yytestcase(yyruleno==466); + case 474: /* tags_literal ::= NK_HEX NK_PLUS duration_literal */ yytestcase(yyruleno==474); + case 475: /* tags_literal ::= NK_HEX NK_MINUS duration_literal */ yytestcase(yyruleno==475); + case 483: /* tags_literal ::= NK_STRING NK_PLUS duration_literal */ yytestcase(yyruleno==483); + case 484: /* tags_literal ::= NK_STRING NK_MINUS duration_literal */ yytestcase(yyruleno==484); +{ + SToken l = yymsp[-2].minor.yy0; + SToken r = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy560); + l.n = (r.z + r.n) - l.z; + yylhsminor.yy560 = createRawValueNodeExt(pCxt, TSDB_DATA_TYPE_BINARY, &l, NULL, yymsp[0].minor.yy560); + } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 455: /* tags_literal ::= NK_PLUS NK_INTEGER */ + case 458: /* tags_literal ::= NK_MINUS NK_INTEGER */ yytestcase(yyruleno==458); + case 467: /* tags_literal ::= NK_PLUS NK_BIN */ yytestcase(yyruleno==467); + case 470: /* tags_literal ::= NK_MINUS NK_BIN */ yytestcase(yyruleno==470); + case 476: /* tags_literal ::= NK_PLUS NK_HEX */ yytestcase(yyruleno==476); + case 479: /* tags_literal ::= NK_MINUS NK_HEX */ yytestcase(yyruleno==479); +{ + SToken t = yymsp[-1].minor.yy0; + t.n = (yymsp[0].minor.yy0.z + yymsp[0].minor.yy0.n) - yymsp[-1].minor.yy0.z; + yylhsminor.yy560 = createRawValueNode(pCxt, TSDB_DATA_TYPE_UBIGINT, &t, NULL); + } + yymsp[-1].minor.yy560 = yylhsminor.yy560; + break; + case 456: /* tags_literal ::= NK_PLUS NK_INTEGER NK_PLUS duration_literal */ + case 457: /* tags_literal ::= NK_PLUS NK_INTEGER NK_MINUS duration_literal */ yytestcase(yyruleno==457); + case 459: /* tags_literal ::= NK_MINUS NK_INTEGER NK_PLUS duration_literal */ yytestcase(yyruleno==459); + case 460: /* tags_literal ::= NK_MINUS NK_INTEGER NK_MINUS duration_literal */ yytestcase(yyruleno==460); + case 468: /* tags_literal ::= NK_PLUS NK_BIN NK_PLUS duration_literal */ yytestcase(yyruleno==468); + case 469: /* tags_literal ::= NK_PLUS NK_BIN NK_MINUS duration_literal */ yytestcase(yyruleno==469); + case 471: /* tags_literal ::= NK_MINUS NK_BIN NK_PLUS duration_literal */ yytestcase(yyruleno==471); + case 472: /* tags_literal ::= NK_MINUS NK_BIN NK_MINUS duration_literal */ yytestcase(yyruleno==472); + case 477: /* tags_literal ::= NK_PLUS NK_HEX NK_PLUS duration_literal */ yytestcase(yyruleno==477); + case 478: /* tags_literal ::= NK_PLUS NK_HEX NK_MINUS duration_literal */ yytestcase(yyruleno==478); + case 480: /* tags_literal ::= NK_MINUS NK_HEX NK_PLUS duration_literal */ yytestcase(yyruleno==480); + case 481: /* tags_literal ::= NK_MINUS NK_HEX NK_MINUS duration_literal */ yytestcase(yyruleno==481); +{ + SToken l = yymsp[-3].minor.yy0; + SToken r = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy560); + l.n = (r.z + r.n) - l.z; + yylhsminor.yy560 = createRawValueNodeExt(pCxt, TSDB_DATA_TYPE_BINARY, &l, NULL, yymsp[0].minor.yy560); + } + yymsp[-3].minor.yy560 = yylhsminor.yy560; + break; + case 461: /* tags_literal ::= NK_FLOAT */ +{ yylhsminor.yy560 = createRawValueNode(pCxt, TSDB_DATA_TYPE_DOUBLE, &yymsp[0].minor.yy0, NULL); } + yymsp[0].minor.yy560 = yylhsminor.yy560; + break; + case 462: /* tags_literal ::= NK_PLUS NK_FLOAT */ + case 463: /* tags_literal ::= NK_MINUS NK_FLOAT */ yytestcase(yyruleno==463); +{ + SToken t = yymsp[-1].minor.yy0; + t.n = (yymsp[0].minor.yy0.z + yymsp[0].minor.yy0.n) - yymsp[-1].minor.yy0.z; + yylhsminor.yy560 = createRawValueNode(pCxt, TSDB_DATA_TYPE_DOUBLE, &t, NULL); + } + yymsp[-1].minor.yy560 = yylhsminor.yy560; + break; + case 482: /* tags_literal ::= NK_STRING */ +{ yylhsminor.yy560 = createRawValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy0, NULL); } + yymsp[0].minor.yy560 = yylhsminor.yy560; + break; + case 485: /* tags_literal ::= NK_BOOL */ +{ yylhsminor.yy560 = createRawValueNode(pCxt, TSDB_DATA_TYPE_BOOL, &yymsp[0].minor.yy0, NULL); } + yymsp[0].minor.yy560 = yylhsminor.yy560; + break; + case 486: /* tags_literal ::= NULL */ +{ yylhsminor.yy560 = createRawValueNode(pCxt, TSDB_DATA_TYPE_NULL, &yymsp[0].minor.yy0, NULL); } + yymsp[0].minor.yy560 = yylhsminor.yy560; + break; + case 487: /* tags_literal ::= literal_func */ +{ yylhsminor.yy560 = createRawValueNode(pCxt, TSDB_DATA_TYPE_BINARY, NULL, yymsp[0].minor.yy560); } + yymsp[0].minor.yy560 = yylhsminor.yy560; + break; + case 488: /* tags_literal ::= literal_func NK_PLUS duration_literal */ + case 489: /* tags_literal ::= literal_func NK_MINUS duration_literal */ yytestcase(yyruleno==489); +{ + SToken l = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy560); + SToken r = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy560); + l.n = (r.z + r.n) - l.z; + yylhsminor.yy560 = createRawValueNodeExt(pCxt, TSDB_DATA_TYPE_BINARY, &l, yymsp[-2].minor.yy560, yymsp[0].minor.yy560); + } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 492: /* literal ::= NK_INTEGER */ +{ yylhsminor.yy560 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_UBIGINT, &yymsp[0].minor.yy0)); } + yymsp[0].minor.yy560 = yylhsminor.yy560; + break; + case 493: /* literal ::= NK_FLOAT */ +{ yylhsminor.yy560 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_DOUBLE, &yymsp[0].minor.yy0)); } + yymsp[0].minor.yy560 = yylhsminor.yy560; + break; + case 494: /* literal ::= NK_STRING */ +{ yylhsminor.yy560 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy0)); } + yymsp[0].minor.yy560 = yylhsminor.yy560; + break; + case 495: /* literal ::= NK_BOOL */ +{ yylhsminor.yy560 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_BOOL, &yymsp[0].minor.yy0)); } + yymsp[0].minor.yy560 = yylhsminor.yy560; + break; + case 496: /* literal ::= TIMESTAMP NK_STRING */ +{ yylhsminor.yy560 = createRawExprNodeExt(pCxt, &yymsp[-1].minor.yy0, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_TIMESTAMP, &yymsp[0].minor.yy0)); } + yymsp[-1].minor.yy560 = yylhsminor.yy560; + break; + case 497: /* literal ::= duration_literal */ + case 507: /* signed_literal ::= signed */ yytestcase(yyruleno==507); + case 531: /* expr_or_subquery ::= expression */ yytestcase(yyruleno==531); + case 532: /* expression ::= literal */ yytestcase(yyruleno==532); + case 534: /* expression ::= column_reference */ yytestcase(yyruleno==534); + case 535: /* expression ::= function_expression */ yytestcase(yyruleno==535); + case 536: /* expression ::= case_when_expression */ yytestcase(yyruleno==536); + case 579: /* function_expression ::= literal_func */ yytestcase(yyruleno==579); + case 580: /* function_expression ::= rand_func */ yytestcase(yyruleno==580); + case 638: /* boolean_value_expression ::= boolean_primary */ yytestcase(yyruleno==638); + case 642: /* boolean_primary ::= predicate */ yytestcase(yyruleno==642); + case 644: /* common_expression ::= expr_or_subquery */ yytestcase(yyruleno==644); + case 645: /* common_expression ::= boolean_value_expression */ yytestcase(yyruleno==645); + case 648: /* table_reference_list ::= table_reference */ yytestcase(yyruleno==648); + case 650: /* table_reference ::= table_primary */ yytestcase(yyruleno==650); + case 651: /* table_reference ::= joined_table */ yytestcase(yyruleno==651); + case 655: /* table_primary ::= parenthesized_joined_table */ yytestcase(yyruleno==655); + case 740: /* query_simple ::= query_specification */ yytestcase(yyruleno==740); + case 741: /* query_simple ::= union_query_expression */ yytestcase(yyruleno==741); + case 744: /* query_simple_or_subquery ::= query_simple */ yytestcase(yyruleno==744); + case 746: /* query_or_subquery ::= query_expression */ yytestcase(yyruleno==746); +{ yylhsminor.yy560 = yymsp[0].minor.yy560; } + yymsp[0].minor.yy560 = yylhsminor.yy560; + break; + case 498: /* literal ::= NULL */ +{ yylhsminor.yy560 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_NULL, &yymsp[0].minor.yy0)); } + yymsp[0].minor.yy560 = yylhsminor.yy560; + break; + case 499: /* literal ::= NK_QUESTION */ +{ yylhsminor.yy560 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createPlaceholderValueNode(pCxt, &yymsp[0].minor.yy0)); } + yymsp[0].minor.yy560 = yylhsminor.yy560; + break; + case 500: /* duration_literal ::= NK_VARIABLE */ + case 715: /* interval_sliding_duration_literal ::= NK_VARIABLE */ yytestcase(yyruleno==715); + case 716: /* interval_sliding_duration_literal ::= NK_STRING */ yytestcase(yyruleno==716); + case 717: /* interval_sliding_duration_literal ::= NK_INTEGER */ yytestcase(yyruleno==717); +{ yylhsminor.yy560 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createDurationValueNode(pCxt, &yymsp[0].minor.yy0)); } + yymsp[0].minor.yy560 = yylhsminor.yy560; + break; + case 501: /* signed ::= NK_INTEGER */ +{ yylhsminor.yy560 = createValueNode(pCxt, TSDB_DATA_TYPE_UBIGINT, &yymsp[0].minor.yy0); } + yymsp[0].minor.yy560 = yylhsminor.yy560; + break; + case 502: /* signed ::= NK_PLUS NK_INTEGER */ +{ yymsp[-1].minor.yy560 = createValueNode(pCxt, TSDB_DATA_TYPE_UBIGINT, &yymsp[0].minor.yy0); } + break; + case 503: /* signed ::= NK_MINUS NK_INTEGER */ +{ + SToken t = yymsp[-1].minor.yy0; + t.n = (yymsp[0].minor.yy0.z + yymsp[0].minor.yy0.n) - yymsp[-1].minor.yy0.z; + yylhsminor.yy560 = createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &t); + } + yymsp[-1].minor.yy560 = yylhsminor.yy560; + break; + case 504: /* signed ::= NK_FLOAT */ +{ yylhsminor.yy560 = createValueNode(pCxt, TSDB_DATA_TYPE_DOUBLE, &yymsp[0].minor.yy0); } + yymsp[0].minor.yy560 = yylhsminor.yy560; + break; + case 505: /* signed ::= NK_PLUS NK_FLOAT */ +{ yymsp[-1].minor.yy560 = createValueNode(pCxt, TSDB_DATA_TYPE_DOUBLE, &yymsp[0].minor.yy0); } + break; + case 506: /* signed ::= NK_MINUS NK_FLOAT */ +{ + SToken t = yymsp[-1].minor.yy0; + t.n = (yymsp[0].minor.yy0.z + yymsp[0].minor.yy0.n) - yymsp[-1].minor.yy0.z; + yylhsminor.yy560 = createValueNode(pCxt, TSDB_DATA_TYPE_DOUBLE, &t); + } + yymsp[-1].minor.yy560 = yylhsminor.yy560; + break; + case 508: /* signed_literal ::= NK_STRING */ +{ yylhsminor.yy560 = createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy0); } + yymsp[0].minor.yy560 = yylhsminor.yy560; + break; + case 509: /* signed_literal ::= NK_BOOL */ +{ yylhsminor.yy560 = createValueNode(pCxt, TSDB_DATA_TYPE_BOOL, &yymsp[0].minor.yy0); } + yymsp[0].minor.yy560 = yylhsminor.yy560; + break; + case 510: /* signed_literal ::= TIMESTAMP NK_STRING */ +{ yymsp[-1].minor.yy560 = createValueNode(pCxt, TSDB_DATA_TYPE_TIMESTAMP, &yymsp[0].minor.yy0); } + break; + case 511: /* signed_literal ::= duration_literal */ + case 513: /* signed_literal ::= literal_func */ yytestcase(yyruleno==513); + case 609: /* star_func_para ::= expr_or_subquery */ yytestcase(yyruleno==609); + case 692: /* select_item ::= common_expression */ yytestcase(yyruleno==692); + case 702: /* partition_item ::= expr_or_subquery */ yytestcase(yyruleno==702); + case 745: /* query_simple_or_subquery ::= subquery */ yytestcase(yyruleno==745); + case 747: /* query_or_subquery ::= subquery */ yytestcase(yyruleno==747); + case 760: /* search_condition ::= common_expression */ yytestcase(yyruleno==760); +{ yylhsminor.yy560 = releaseRawExprNode(pCxt, yymsp[0].minor.yy560); } + yymsp[0].minor.yy560 = yylhsminor.yy560; + break; + case 512: /* signed_literal ::= NULL */ +{ yylhsminor.yy560 = createValueNode(pCxt, TSDB_DATA_TYPE_NULL, &yymsp[0].minor.yy0); } + yymsp[0].minor.yy560 = yylhsminor.yy560; + break; + case 514: /* signed_literal ::= NK_QUESTION */ +{ yylhsminor.yy560 = createPlaceholderValueNode(pCxt, &yymsp[0].minor.yy0); } + yymsp[0].minor.yy560 = yylhsminor.yy560; + break; + case 533: /* expression ::= pseudo_column */ +{ yylhsminor.yy560 = yymsp[0].minor.yy560; (void)setRawExprNodeIsPseudoColumn(pCxt, yylhsminor.yy560, true); } + yymsp[0].minor.yy560 = yylhsminor.yy560; + break; + case 537: /* expression ::= NK_LP expression NK_RP */ + case 643: /* boolean_primary ::= NK_LP boolean_value_expression NK_RP */ yytestcase(yyruleno==643); + case 759: /* subquery ::= NK_LP subquery NK_RP */ yytestcase(yyruleno==759); +{ yylhsminor.yy560 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy0, &yymsp[0].minor.yy0, releaseRawExprNode(pCxt, yymsp[-1].minor.yy560)); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 538: /* expression ::= NK_PLUS expr_or_subquery */ +{ + SToken t = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy560); + yylhsminor.yy560 = createRawExprNodeExt(pCxt, &yymsp[-1].minor.yy0, &t, releaseRawExprNode(pCxt, yymsp[0].minor.yy560)); + } + yymsp[-1].minor.yy560 = yylhsminor.yy560; + break; + case 539: /* expression ::= NK_MINUS expr_or_subquery */ +{ + SToken t = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy560); + yylhsminor.yy560 = createRawExprNodeExt(pCxt, &yymsp[-1].minor.yy0, &t, createOperatorNode(pCxt, OP_TYPE_MINUS, releaseRawExprNode(pCxt, yymsp[0].minor.yy560), NULL)); + } + yymsp[-1].minor.yy560 = yylhsminor.yy560; + break; + case 540: /* expression ::= expr_or_subquery NK_PLUS expr_or_subquery */ +{ + SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy560); + SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy560); + yylhsminor.yy560 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, OP_TYPE_ADD, releaseRawExprNode(pCxt, yymsp[-2].minor.yy560), releaseRawExprNode(pCxt, yymsp[0].minor.yy560))); + } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 541: /* expression ::= expr_or_subquery NK_MINUS expr_or_subquery */ +{ + SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy560); + SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy560); + yylhsminor.yy560 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, OP_TYPE_SUB, releaseRawExprNode(pCxt, yymsp[-2].minor.yy560), releaseRawExprNode(pCxt, yymsp[0].minor.yy560))); + } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 542: /* expression ::= expr_or_subquery NK_STAR expr_or_subquery */ +{ + SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy560); + SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy560); + yylhsminor.yy560 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, OP_TYPE_MULTI, releaseRawExprNode(pCxt, yymsp[-2].minor.yy560), releaseRawExprNode(pCxt, yymsp[0].minor.yy560))); + } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 543: /* expression ::= expr_or_subquery NK_SLASH expr_or_subquery */ +{ + SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy560); + SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy560); + yylhsminor.yy560 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, OP_TYPE_DIV, releaseRawExprNode(pCxt, yymsp[-2].minor.yy560), releaseRawExprNode(pCxt, yymsp[0].minor.yy560))); + } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 544: /* expression ::= expr_or_subquery NK_REM expr_or_subquery */ +{ + SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy560); + SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy560); + yylhsminor.yy560 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, OP_TYPE_REM, releaseRawExprNode(pCxt, yymsp[-2].minor.yy560), releaseRawExprNode(pCxt, yymsp[0].minor.yy560))); + } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 545: /* expression ::= column_reference NK_ARROW NK_STRING */ +{ + SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy560); + yylhsminor.yy560 = createRawExprNodeExt(pCxt, &s, &yymsp[0].minor.yy0, createOperatorNode(pCxt, OP_TYPE_JSON_GET_VALUE, releaseRawExprNode(pCxt, yymsp[-2].minor.yy560), createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy0))); + } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 546: /* expression ::= expr_or_subquery NK_BITAND expr_or_subquery */ +{ + SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy560); + SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy560); + yylhsminor.yy560 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, OP_TYPE_BIT_AND, releaseRawExprNode(pCxt, yymsp[-2].minor.yy560), releaseRawExprNode(pCxt, yymsp[0].minor.yy560))); + } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 547: /* expression ::= expr_or_subquery NK_BITOR expr_or_subquery */ +{ + SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy560); + SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy560); + yylhsminor.yy560 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, OP_TYPE_BIT_OR, releaseRawExprNode(pCxt, yymsp[-2].minor.yy560), releaseRawExprNode(pCxt, yymsp[0].minor.yy560))); + } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 550: /* column_reference ::= column_name */ +{ yylhsminor.yy560 = createRawExprNode(pCxt, &yymsp[0].minor.yy533, createColumnNode(pCxt, NULL, &yymsp[0].minor.yy533)); } + yymsp[0].minor.yy560 = yylhsminor.yy560; + break; + case 551: /* column_reference ::= table_name NK_DOT column_name */ +{ yylhsminor.yy560 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy533, &yymsp[0].minor.yy533, createColumnNode(pCxt, &yymsp[-2].minor.yy533, &yymsp[0].minor.yy533)); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 552: /* column_reference ::= NK_ALIAS */ +{ yylhsminor.yy560 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createColumnNode(pCxt, NULL, &yymsp[0].minor.yy0)); } + yymsp[0].minor.yy560 = yylhsminor.yy560; + break; + case 553: /* column_reference ::= table_name NK_DOT NK_ALIAS */ +{ yylhsminor.yy560 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy533, &yymsp[0].minor.yy0, createColumnNode(pCxt, &yymsp[-2].minor.yy533, &yymsp[0].minor.yy0)); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 554: /* pseudo_column ::= ROWTS */ + case 555: /* pseudo_column ::= TBNAME */ yytestcase(yyruleno==555); + case 557: /* pseudo_column ::= QSTART */ yytestcase(yyruleno==557); + case 558: /* pseudo_column ::= QEND */ yytestcase(yyruleno==558); + case 559: /* pseudo_column ::= QDURATION */ yytestcase(yyruleno==559); + case 560: /* pseudo_column ::= WSTART */ yytestcase(yyruleno==560); + case 561: /* pseudo_column ::= WEND */ yytestcase(yyruleno==561); + case 562: /* pseudo_column ::= WDURATION */ yytestcase(yyruleno==562); + case 563: /* pseudo_column ::= IROWTS */ yytestcase(yyruleno==563); + case 564: /* pseudo_column ::= ISFILLED */ yytestcase(yyruleno==564); + case 565: /* pseudo_column ::= QTAGS */ yytestcase(yyruleno==565); + case 582: /* literal_func ::= NOW */ yytestcase(yyruleno==582); + case 583: /* literal_func ::= TODAY */ yytestcase(yyruleno==583); +{ yylhsminor.yy560 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createFunctionNode(pCxt, &yymsp[0].minor.yy0, NULL)); } + yymsp[0].minor.yy560 = yylhsminor.yy560; + break; + case 556: /* pseudo_column ::= table_name NK_DOT TBNAME */ +{ yylhsminor.yy560 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy533, &yymsp[0].minor.yy0, createFunctionNode(pCxt, &yymsp[0].minor.yy0, createNodeList(pCxt, createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[-2].minor.yy533)))); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 566: /* function_expression ::= function_name NK_LP expression_list NK_RP */ + case 567: /* function_expression ::= star_func NK_LP star_func_para_list NK_RP */ yytestcase(yyruleno==567); + case 575: /* function_expression ::= substr_func NK_LP expression_list NK_RP */ yytestcase(yyruleno==575); +{ yylhsminor.yy560 = createRawExprNodeExt(pCxt, &yymsp[-3].minor.yy533, &yymsp[0].minor.yy0, createFunctionNode(pCxt, &yymsp[-3].minor.yy533, yymsp[-1].minor.yy334)); } + yymsp[-3].minor.yy560 = yylhsminor.yy560; + break; + case 568: /* function_expression ::= CAST NK_LP expr_or_subquery AS type_name NK_RP */ + case 569: /* function_expression ::= CAST NK_LP expr_or_subquery AS type_name_default_len NK_RP */ yytestcase(yyruleno==569); +{ yylhsminor.yy560 = createRawExprNodeExt(pCxt, &yymsp[-5].minor.yy0, &yymsp[0].minor.yy0, createCastFunctionNode(pCxt, releaseRawExprNode(pCxt, yymsp[-3].minor.yy560), yymsp[-1].minor.yy952)); } + yymsp[-5].minor.yy560 = yylhsminor.yy560; + break; + case 570: /* function_expression ::= POSITION NK_LP expr_or_subquery IN expr_or_subquery NK_RP */ +{ yylhsminor.yy560 = createRawExprNodeExt(pCxt, &yymsp[-5].minor.yy0, &yymsp[0].minor.yy0, createPositionFunctionNode(pCxt, releaseRawExprNode(pCxt, yymsp[-3].minor.yy560), releaseRawExprNode(pCxt, yymsp[-1].minor.yy560))); } + yymsp[-5].minor.yy560 = yylhsminor.yy560; + break; + case 571: /* function_expression ::= TRIM NK_LP expr_or_subquery NK_RP */ +{ yylhsminor.yy560 = createRawExprNodeExt(pCxt, &yymsp[-3].minor.yy0, &yymsp[0].minor.yy0, createTrimFunctionNode(pCxt, releaseRawExprNode(pCxt, yymsp[-1].minor.yy560), TRIM_TYPE_BOTH)); } + yymsp[-3].minor.yy560 = yylhsminor.yy560; + break; + case 572: /* function_expression ::= TRIM NK_LP trim_specification_type FROM expr_or_subquery NK_RP */ +{ yylhsminor.yy560 = createRawExprNodeExt(pCxt, &yymsp[-5].minor.yy0, &yymsp[0].minor.yy0, createTrimFunctionNode(pCxt, releaseRawExprNode(pCxt, yymsp[-1].minor.yy560), yymsp[-3].minor.yy672)); } + yymsp[-5].minor.yy560 = yylhsminor.yy560; + break; + case 573: /* function_expression ::= TRIM NK_LP expr_or_subquery FROM expr_or_subquery NK_RP */ +{ yylhsminor.yy560 = createRawExprNodeExt(pCxt, &yymsp[-5].minor.yy0, &yymsp[0].minor.yy0, createTrimFunctionNodeExt(pCxt, releaseRawExprNode(pCxt, yymsp[-3].minor.yy560), releaseRawExprNode(pCxt, yymsp[-1].minor.yy560), TRIM_TYPE_BOTH)); } + yymsp[-5].minor.yy560 = yylhsminor.yy560; + break; + case 574: /* function_expression ::= TRIM NK_LP trim_specification_type expr_or_subquery FROM expr_or_subquery NK_RP */ +{ yylhsminor.yy560 = createRawExprNodeExt(pCxt, &yymsp[-6].minor.yy0, &yymsp[0].minor.yy0, createTrimFunctionNodeExt(pCxt, releaseRawExprNode(pCxt, yymsp[-3].minor.yy560), releaseRawExprNode(pCxt, yymsp[-1].minor.yy560), yymsp[-4].minor.yy672)); } + yymsp[-6].minor.yy560 = yylhsminor.yy560; + break; + case 576: /* function_expression ::= substr_func NK_LP expr_or_subquery FROM expr_or_subquery NK_RP */ +{ yylhsminor.yy560 = createRawExprNodeExt(pCxt, &yymsp[-5].minor.yy533, &yymsp[0].minor.yy0, createSubstrFunctionNode(pCxt, releaseRawExprNode(pCxt, yymsp[-3].minor.yy560), releaseRawExprNode(pCxt, yymsp[-1].minor.yy560))); } + yymsp[-5].minor.yy560 = yylhsminor.yy560; + break; + case 577: /* function_expression ::= substr_func NK_LP expr_or_subquery FROM expr_or_subquery FOR expr_or_subquery NK_RP */ +{ yylhsminor.yy560 = createRawExprNodeExt(pCxt, &yymsp[-7].minor.yy533, &yymsp[0].minor.yy0, createSubstrFunctionNodeExt(pCxt, releaseRawExprNode(pCxt, yymsp[-5].minor.yy560), releaseRawExprNode(pCxt, yymsp[-3].minor.yy560), releaseRawExprNode(pCxt, yymsp[-1].minor.yy560))); } + yymsp[-7].minor.yy560 = yylhsminor.yy560; + break; + case 578: /* function_expression ::= REPLACE NK_LP expression_list NK_RP */ + case 585: /* rand_func ::= RAND NK_LP expression_list NK_RP */ yytestcase(yyruleno==585); +{ yylhsminor.yy560 = createRawExprNodeExt(pCxt, &yymsp[-3].minor.yy0, &yymsp[0].minor.yy0, createFunctionNode(pCxt, &yymsp[-3].minor.yy0, yymsp[-1].minor.yy334)); } + yymsp[-3].minor.yy560 = yylhsminor.yy560; + break; + case 581: /* literal_func ::= noarg_func NK_LP NK_RP */ +{ yylhsminor.yy560 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy533, &yymsp[0].minor.yy0, createFunctionNode(pCxt, &yymsp[-2].minor.yy533, NULL)); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 584: /* rand_func ::= RAND NK_LP NK_RP */ +{ yylhsminor.yy560 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy0, &yymsp[0].minor.yy0, createFunctionNode(pCxt, &yymsp[-2].minor.yy0, NULL)); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 588: /* trim_specification_type ::= BOTH */ +{ yymsp[0].minor.yy672 = TRIM_TYPE_BOTH; } + break; + case 589: /* trim_specification_type ::= TRAILING */ +{ yymsp[0].minor.yy672 = TRIM_TYPE_TRAILING; } + break; + case 590: /* trim_specification_type ::= LEADING */ +{ yymsp[0].minor.yy672 = TRIM_TYPE_LEADING; } + break; + case 605: /* star_func_para_list ::= NK_STAR */ +{ yylhsminor.yy334 = createNodeList(pCxt, createColumnNode(pCxt, NULL, &yymsp[0].minor.yy0)); } + yymsp[0].minor.yy334 = yylhsminor.yy334; + break; + case 610: /* star_func_para ::= table_name NK_DOT NK_STAR */ + case 695: /* select_item ::= table_name NK_DOT NK_STAR */ yytestcase(yyruleno==695); +{ yylhsminor.yy560 = createColumnNode(pCxt, &yymsp[-2].minor.yy533, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 611: /* case_when_expression ::= CASE when_then_list case_when_else_opt END */ +{ yylhsminor.yy560 = createRawExprNodeExt(pCxt, &yymsp[-3].minor.yy0, &yymsp[0].minor.yy0, createCaseWhenNode(pCxt, NULL, yymsp[-2].minor.yy334, yymsp[-1].minor.yy560)); } + yymsp[-3].minor.yy560 = yylhsminor.yy560; + break; + case 612: /* case_when_expression ::= CASE common_expression when_then_list case_when_else_opt END */ +{ yylhsminor.yy560 = createRawExprNodeExt(pCxt, &yymsp[-4].minor.yy0, &yymsp[0].minor.yy0, createCaseWhenNode(pCxt, releaseRawExprNode(pCxt, yymsp[-3].minor.yy560), yymsp[-2].minor.yy334, yymsp[-1].minor.yy560)); } + yymsp[-4].minor.yy560 = yylhsminor.yy560; + break; + case 615: /* when_then_expr ::= WHEN common_expression THEN common_expression */ +{ yymsp[-3].minor.yy560 = createWhenThenNode(pCxt, releaseRawExprNode(pCxt, yymsp[-2].minor.yy560), releaseRawExprNode(pCxt, yymsp[0].minor.yy560)); } + break; + case 617: /* case_when_else_opt ::= ELSE common_expression */ +{ yymsp[-1].minor.yy560 = releaseRawExprNode(pCxt, yymsp[0].minor.yy560); } + break; + case 618: /* predicate ::= expr_or_subquery compare_op expr_or_subquery */ + case 623: /* predicate ::= expr_or_subquery in_op in_predicate_value */ yytestcase(yyruleno==623); +{ + SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy560); + SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy560); + yylhsminor.yy560 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, yymsp[-1].minor.yy506, releaseRawExprNode(pCxt, yymsp[-2].minor.yy560), releaseRawExprNode(pCxt, yymsp[0].minor.yy560))); + } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 619: /* predicate ::= expr_or_subquery BETWEEN expr_or_subquery AND expr_or_subquery */ +{ + SToken s = getTokenFromRawExprNode(pCxt, yymsp[-4].minor.yy560); + SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy560); + yylhsminor.yy560 = createRawExprNodeExt(pCxt, &s, &e, createBetweenAnd(pCxt, releaseRawExprNode(pCxt, yymsp[-4].minor.yy560), releaseRawExprNode(pCxt, yymsp[-2].minor.yy560), releaseRawExprNode(pCxt, yymsp[0].minor.yy560))); + } + yymsp[-4].minor.yy560 = yylhsminor.yy560; + break; + case 620: /* predicate ::= expr_or_subquery NOT BETWEEN expr_or_subquery AND expr_or_subquery */ +{ + SToken s = getTokenFromRawExprNode(pCxt, yymsp[-5].minor.yy560); + SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy560); + yylhsminor.yy560 = createRawExprNodeExt(pCxt, &s, &e, createNotBetweenAnd(pCxt, releaseRawExprNode(pCxt, yymsp[-5].minor.yy560), releaseRawExprNode(pCxt, yymsp[-2].minor.yy560), releaseRawExprNode(pCxt, yymsp[0].minor.yy560))); + } + yymsp[-5].minor.yy560 = yylhsminor.yy560; + break; + case 621: /* predicate ::= expr_or_subquery IS NULL */ +{ + SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy560); + yylhsminor.yy560 = createRawExprNodeExt(pCxt, &s, &yymsp[0].minor.yy0, createOperatorNode(pCxt, OP_TYPE_IS_NULL, releaseRawExprNode(pCxt, yymsp[-2].minor.yy560), NULL)); + } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 622: /* predicate ::= expr_or_subquery IS NOT NULL */ +{ + SToken s = getTokenFromRawExprNode(pCxt, yymsp[-3].minor.yy560); + yylhsminor.yy560 = createRawExprNodeExt(pCxt, &s, &yymsp[0].minor.yy0, createOperatorNode(pCxt, OP_TYPE_IS_NOT_NULL, releaseRawExprNode(pCxt, yymsp[-3].minor.yy560), NULL)); + } + yymsp[-3].minor.yy560 = yylhsminor.yy560; + break; + case 624: /* compare_op ::= NK_LT */ +{ yymsp[0].minor.yy506 = OP_TYPE_LOWER_THAN; } + break; + case 625: /* compare_op ::= NK_GT */ +{ yymsp[0].minor.yy506 = OP_TYPE_GREATER_THAN; } + break; + case 626: /* compare_op ::= NK_LE */ +{ yymsp[0].minor.yy506 = OP_TYPE_LOWER_EQUAL; } + break; + case 627: /* compare_op ::= NK_GE */ +{ yymsp[0].minor.yy506 = OP_TYPE_GREATER_EQUAL; } + break; + case 628: /* compare_op ::= NK_NE */ +{ yymsp[0].minor.yy506 = OP_TYPE_NOT_EQUAL; } + break; + case 629: /* compare_op ::= NK_EQ */ +{ yymsp[0].minor.yy506 = OP_TYPE_EQUAL; } + break; + case 630: /* compare_op ::= LIKE */ +{ yymsp[0].minor.yy506 = OP_TYPE_LIKE; } + break; + case 631: /* compare_op ::= NOT LIKE */ +{ yymsp[-1].minor.yy506 = OP_TYPE_NOT_LIKE; } + break; + case 632: /* compare_op ::= MATCH */ +{ yymsp[0].minor.yy506 = OP_TYPE_MATCH; } + break; + case 633: /* compare_op ::= NMATCH */ +{ yymsp[0].minor.yy506 = OP_TYPE_NMATCH; } + break; + case 634: /* compare_op ::= CONTAINS */ +{ yymsp[0].minor.yy506 = OP_TYPE_JSON_CONTAINS; } + break; + case 635: /* in_op ::= IN */ +{ yymsp[0].minor.yy506 = OP_TYPE_IN; } + break; + case 636: /* in_op ::= NOT IN */ +{ yymsp[-1].minor.yy506 = OP_TYPE_NOT_IN; } + break; + case 637: /* in_predicate_value ::= NK_LP literal_list NK_RP */ +{ yylhsminor.yy560 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy0, &yymsp[0].minor.yy0, createNodeListNode(pCxt, yymsp[-1].minor.yy334)); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 639: /* boolean_value_expression ::= NOT boolean_primary */ +{ + SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy560); + yylhsminor.yy560 = createRawExprNodeExt(pCxt, &yymsp[-1].minor.yy0, &e, createLogicConditionNode(pCxt, LOGIC_COND_TYPE_NOT, releaseRawExprNode(pCxt, yymsp[0].minor.yy560), NULL)); + } + yymsp[-1].minor.yy560 = yylhsminor.yy560; + break; + case 640: /* boolean_value_expression ::= boolean_value_expression OR boolean_value_expression */ +{ + SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy560); + SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy560); + yylhsminor.yy560 = createRawExprNodeExt(pCxt, &s, &e, createLogicConditionNode(pCxt, LOGIC_COND_TYPE_OR, releaseRawExprNode(pCxt, yymsp[-2].minor.yy560), releaseRawExprNode(pCxt, yymsp[0].minor.yy560))); + } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 641: /* boolean_value_expression ::= boolean_value_expression AND boolean_value_expression */ +{ + SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy560); + SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy560); + yylhsminor.yy560 = createRawExprNodeExt(pCxt, &s, &e, createLogicConditionNode(pCxt, LOGIC_COND_TYPE_AND, releaseRawExprNode(pCxt, yymsp[-2].minor.yy560), releaseRawExprNode(pCxt, yymsp[0].minor.yy560))); + } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 649: /* table_reference_list ::= table_reference_list NK_COMMA table_reference */ +{ yylhsminor.yy560 = createJoinTableNode(pCxt, JOIN_TYPE_INNER, JOIN_STYPE_NONE, yymsp[-2].minor.yy560, yymsp[0].minor.yy560, NULL); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 652: /* table_primary ::= table_name alias_opt */ +{ yylhsminor.yy560 = createRealTableNode(pCxt, NULL, &yymsp[-1].minor.yy533, &yymsp[0].minor.yy533); } + yymsp[-1].minor.yy560 = yylhsminor.yy560; + break; + case 653: /* table_primary ::= db_name NK_DOT table_name alias_opt */ +{ yylhsminor.yy560 = createRealTableNode(pCxt, &yymsp[-3].minor.yy533, &yymsp[-1].minor.yy533, &yymsp[0].minor.yy533); } + yymsp[-3].minor.yy560 = yylhsminor.yy560; + break; + case 654: /* table_primary ::= subquery alias_opt */ +{ yylhsminor.yy560 = createTempTableNode(pCxt, releaseRawExprNode(pCxt, yymsp[-1].minor.yy560), &yymsp[0].minor.yy533); } + yymsp[-1].minor.yy560 = yylhsminor.yy560; + break; + case 656: /* alias_opt ::= */ +{ yymsp[1].minor.yy533 = nil_token; } + break; + case 658: /* alias_opt ::= AS table_alias */ +{ yymsp[-1].minor.yy533 = yymsp[0].minor.yy533; } + break; + case 659: /* parenthesized_joined_table ::= NK_LP joined_table NK_RP */ + case 660: /* parenthesized_joined_table ::= NK_LP parenthesized_joined_table NK_RP */ yytestcase(yyruleno==660); +{ yymsp[-2].minor.yy560 = yymsp[-1].minor.yy560; } + break; + case 661: /* joined_table ::= table_reference join_type join_subtype JOIN table_reference join_on_clause_opt window_offset_clause_opt jlimit_clause_opt */ +{ + yylhsminor.yy560 = createJoinTableNode(pCxt, yymsp[-6].minor.yy36, yymsp[-5].minor.yy648, yymsp[-7].minor.yy560, yymsp[-3].minor.yy560, yymsp[-2].minor.yy560); + yylhsminor.yy560 = addWindowOffsetClause(pCxt, yylhsminor.yy560, yymsp[-1].minor.yy560); + yylhsminor.yy560 = addJLimitClause(pCxt, yylhsminor.yy560, yymsp[0].minor.yy560); + } + yymsp[-7].minor.yy560 = yylhsminor.yy560; + break; + case 662: /* join_type ::= */ +{ yymsp[1].minor.yy36 = JOIN_TYPE_INNER; } + break; + case 663: /* join_type ::= INNER */ +{ yymsp[0].minor.yy36 = JOIN_TYPE_INNER; } + break; + case 664: /* join_type ::= LEFT */ +{ yymsp[0].minor.yy36 = JOIN_TYPE_LEFT; } + break; + case 665: /* join_type ::= RIGHT */ +{ yymsp[0].minor.yy36 = JOIN_TYPE_RIGHT; } + break; + case 666: /* join_type ::= FULL */ +{ yymsp[0].minor.yy36 = JOIN_TYPE_FULL; } + break; + case 667: /* join_subtype ::= */ +{ yymsp[1].minor.yy648 = JOIN_STYPE_NONE; } + break; + case 668: /* join_subtype ::= OUTER */ +{ yymsp[0].minor.yy648 = JOIN_STYPE_OUTER; } + break; + case 669: /* join_subtype ::= SEMI */ +{ yymsp[0].minor.yy648 = JOIN_STYPE_SEMI; } + break; + case 670: /* join_subtype ::= ANTI */ +{ yymsp[0].minor.yy648 = JOIN_STYPE_ANTI; } + break; + case 671: /* join_subtype ::= ASOF */ +{ yymsp[0].minor.yy648 = JOIN_STYPE_ASOF; } + break; + case 672: /* join_subtype ::= WINDOW */ +{ yymsp[0].minor.yy648 = JOIN_STYPE_WIN; } + break; + case 676: /* window_offset_clause_opt ::= WINDOW_OFFSET NK_LP window_offset_literal NK_COMMA window_offset_literal NK_RP */ +{ yymsp[-5].minor.yy560 = createWindowOffsetNode(pCxt, releaseRawExprNode(pCxt, yymsp[-3].minor.yy560), releaseRawExprNode(pCxt, yymsp[-1].minor.yy560)); } + break; + case 677: /* window_offset_literal ::= NK_VARIABLE */ +{ yylhsminor.yy560 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createTimeOffsetValueNode(pCxt, &yymsp[0].minor.yy0)); } + yymsp[0].minor.yy560 = yylhsminor.yy560; + break; + case 678: /* window_offset_literal ::= NK_MINUS NK_VARIABLE */ +{ + SToken t = yymsp[-1].minor.yy0; + t.n = (yymsp[0].minor.yy0.z + yymsp[0].minor.yy0.n) - yymsp[-1].minor.yy0.z; + yylhsminor.yy560 = createRawExprNode(pCxt, &t, createTimeOffsetValueNode(pCxt, &t)); + } + yymsp[-1].minor.yy560 = yylhsminor.yy560; + break; + case 680: /* jlimit_clause_opt ::= JLIMIT NK_INTEGER */ + case 751: /* slimit_clause_opt ::= SLIMIT NK_INTEGER */ yytestcase(yyruleno==751); + case 755: /* limit_clause_opt ::= LIMIT NK_INTEGER */ yytestcase(yyruleno==755); +{ yymsp[-1].minor.yy560 = createLimitNode(pCxt, &yymsp[0].minor.yy0, NULL); } + break; + case 681: /* query_specification ::= SELECT hint_list set_quantifier_opt tag_mode_opt select_list from_clause_opt where_clause_opt partition_by_clause_opt range_opt every_opt fill_opt twindow_clause_opt group_by_clause_opt having_clause_opt */ +{ + yymsp[-13].minor.yy560 = createSelectStmt(pCxt, yymsp[-11].minor.yy173, yymsp[-9].minor.yy334, yymsp[-8].minor.yy560, yymsp[-12].minor.yy334); + yymsp[-13].minor.yy560 = setSelectStmtTagMode(pCxt, yymsp[-13].minor.yy560, yymsp[-10].minor.yy173); + yymsp[-13].minor.yy560 = addWhereClause(pCxt, yymsp[-13].minor.yy560, yymsp[-7].minor.yy560); + yymsp[-13].minor.yy560 = addPartitionByClause(pCxt, yymsp[-13].minor.yy560, yymsp[-6].minor.yy334); + yymsp[-13].minor.yy560 = addWindowClauseClause(pCxt, yymsp[-13].minor.yy560, yymsp[-2].minor.yy560); + yymsp[-13].minor.yy560 = addGroupByClause(pCxt, yymsp[-13].minor.yy560, yymsp[-1].minor.yy334); + yymsp[-13].minor.yy560 = addHavingClause(pCxt, yymsp[-13].minor.yy560, yymsp[0].minor.yy560); + yymsp[-13].minor.yy560 = addRangeClause(pCxt, yymsp[-13].minor.yy560, yymsp[-5].minor.yy560); + yymsp[-13].minor.yy560 = addEveryClause(pCxt, yymsp[-13].minor.yy560, yymsp[-4].minor.yy560); + yymsp[-13].minor.yy560 = addFillClause(pCxt, yymsp[-13].minor.yy560, yymsp[-3].minor.yy560); + } + break; + case 682: /* hint_list ::= */ +{ yymsp[1].minor.yy334 = createHintNodeList(pCxt, NULL); } + break; + case 683: /* hint_list ::= NK_HINT */ +{ yylhsminor.yy334 = createHintNodeList(pCxt, &yymsp[0].minor.yy0); } + yymsp[0].minor.yy334 = yylhsminor.yy334; + break; + case 688: /* set_quantifier_opt ::= ALL */ +{ yymsp[0].minor.yy173 = false; } + break; + case 691: /* select_item ::= NK_STAR */ +{ yylhsminor.yy560 = createColumnNode(pCxt, NULL, &yymsp[0].minor.yy0); } + yymsp[0].minor.yy560 = yylhsminor.yy560; + break; + case 693: /* select_item ::= common_expression column_alias */ + case 703: /* partition_item ::= expr_or_subquery column_alias */ yytestcase(yyruleno==703); +{ yylhsminor.yy560 = setProjectionAlias(pCxt, releaseRawExprNode(pCxt, yymsp[-1].minor.yy560), &yymsp[0].minor.yy533); } + yymsp[-1].minor.yy560 = yylhsminor.yy560; + break; + case 694: /* select_item ::= common_expression AS column_alias */ + case 704: /* partition_item ::= expr_or_subquery AS column_alias */ yytestcase(yyruleno==704); +{ yylhsminor.yy560 = setProjectionAlias(pCxt, releaseRawExprNode(pCxt, yymsp[-2].minor.yy560), &yymsp[0].minor.yy533); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 699: /* partition_by_clause_opt ::= PARTITION BY partition_list */ + case 729: /* group_by_clause_opt ::= GROUP BY group_by_list */ yytestcase(yyruleno==729); + case 749: /* order_by_clause_opt ::= ORDER BY sort_specification_list */ yytestcase(yyruleno==749); +{ yymsp[-2].minor.yy334 = yymsp[0].minor.yy334; } + break; + case 706: /* twindow_clause_opt ::= SESSION NK_LP column_reference NK_COMMA interval_sliding_duration_literal NK_RP */ +{ yymsp[-5].minor.yy560 = createSessionWindowNode(pCxt, releaseRawExprNode(pCxt, yymsp[-3].minor.yy560), releaseRawExprNode(pCxt, yymsp[-1].minor.yy560)); } + break; + case 707: /* twindow_clause_opt ::= STATE_WINDOW NK_LP expr_or_subquery NK_RP */ +{ yymsp[-3].minor.yy560 = createStateWindowNode(pCxt, releaseRawExprNode(pCxt, yymsp[-1].minor.yy560)); } + break; + case 708: /* twindow_clause_opt ::= INTERVAL NK_LP interval_sliding_duration_literal NK_RP sliding_opt fill_opt */ +{ yymsp[-5].minor.yy560 = createIntervalWindowNode(pCxt, releaseRawExprNode(pCxt, yymsp[-3].minor.yy560), NULL, yymsp[-1].minor.yy560, yymsp[0].minor.yy560); } + break; + case 709: /* twindow_clause_opt ::= INTERVAL NK_LP interval_sliding_duration_literal NK_COMMA interval_sliding_duration_literal NK_RP sliding_opt fill_opt */ +{ yymsp[-7].minor.yy560 = createIntervalWindowNode(pCxt, releaseRawExprNode(pCxt, yymsp[-5].minor.yy560), releaseRawExprNode(pCxt, yymsp[-3].minor.yy560), yymsp[-1].minor.yy560, yymsp[0].minor.yy560); } + break; + case 710: /* twindow_clause_opt ::= EVENT_WINDOW START WITH search_condition END WITH search_condition */ +{ yymsp[-6].minor.yy560 = createEventWindowNode(pCxt, yymsp[-3].minor.yy560, yymsp[0].minor.yy560); } + break; + case 711: /* twindow_clause_opt ::= COUNT_WINDOW NK_LP NK_INTEGER NK_RP */ +{ yymsp[-3].minor.yy560 = createCountWindowNode(pCxt, &yymsp[-1].minor.yy0, &yymsp[-1].minor.yy0); } + break; + case 712: /* twindow_clause_opt ::= COUNT_WINDOW NK_LP NK_INTEGER NK_COMMA NK_INTEGER NK_RP */ +{ yymsp[-5].minor.yy560 = createCountWindowNode(pCxt, &yymsp[-3].minor.yy0, &yymsp[-1].minor.yy0); } + break; + case 719: /* fill_opt ::= FILL NK_LP fill_mode NK_RP */ +{ yymsp[-3].minor.yy560 = createFillNode(pCxt, yymsp[-1].minor.yy18, NULL); } + break; + case 720: /* fill_opt ::= FILL NK_LP VALUE NK_COMMA expression_list NK_RP */ +{ yymsp[-5].minor.yy560 = createFillNode(pCxt, FILL_MODE_VALUE, createNodeListNode(pCxt, yymsp[-1].minor.yy334)); } + break; + case 721: /* fill_opt ::= FILL NK_LP VALUE_F NK_COMMA expression_list NK_RP */ +{ yymsp[-5].minor.yy560 = createFillNode(pCxt, FILL_MODE_VALUE_F, createNodeListNode(pCxt, yymsp[-1].minor.yy334)); } + break; + case 722: /* fill_mode ::= NONE */ +{ yymsp[0].minor.yy18 = FILL_MODE_NONE; } + break; + case 723: /* fill_mode ::= PREV */ +{ yymsp[0].minor.yy18 = FILL_MODE_PREV; } + break; + case 724: /* fill_mode ::= NULL */ +{ yymsp[0].minor.yy18 = FILL_MODE_NULL; } + break; + case 725: /* fill_mode ::= NULL_F */ +{ yymsp[0].minor.yy18 = FILL_MODE_NULL_F; } + break; + case 726: /* fill_mode ::= LINEAR */ +{ yymsp[0].minor.yy18 = FILL_MODE_LINEAR; } + break; + case 727: /* fill_mode ::= NEXT */ +{ yymsp[0].minor.yy18 = FILL_MODE_NEXT; } + break; + case 730: /* group_by_list ::= expr_or_subquery */ +{ yylhsminor.yy334 = createNodeList(pCxt, createGroupingSetNode(pCxt, releaseRawExprNode(pCxt, yymsp[0].minor.yy560))); } + yymsp[0].minor.yy334 = yylhsminor.yy334; + break; + case 731: /* group_by_list ::= group_by_list NK_COMMA expr_or_subquery */ +{ yylhsminor.yy334 = addNodeToList(pCxt, yymsp[-2].minor.yy334, createGroupingSetNode(pCxt, releaseRawExprNode(pCxt, yymsp[0].minor.yy560))); } + yymsp[-2].minor.yy334 = yylhsminor.yy334; + break; + case 735: /* range_opt ::= RANGE NK_LP expr_or_subquery NK_COMMA expr_or_subquery NK_RP */ +{ yymsp[-5].minor.yy560 = createInterpTimeRange(pCxt, releaseRawExprNode(pCxt, yymsp[-3].minor.yy560), releaseRawExprNode(pCxt, yymsp[-1].minor.yy560)); } + break; + case 736: /* range_opt ::= RANGE NK_LP expr_or_subquery NK_RP */ +{ yymsp[-3].minor.yy560 = createInterpTimePoint(pCxt, releaseRawExprNode(pCxt, yymsp[-1].minor.yy560)); } + break; + case 739: /* query_expression ::= query_simple order_by_clause_opt slimit_clause_opt limit_clause_opt */ +{ + yylhsminor.yy560 = addOrderByClause(pCxt, yymsp[-3].minor.yy560, yymsp[-2].minor.yy334); + yylhsminor.yy560 = addSlimitClause(pCxt, yylhsminor.yy560, yymsp[-1].minor.yy560); + yylhsminor.yy560 = addLimitClause(pCxt, yylhsminor.yy560, yymsp[0].minor.yy560); + } + yymsp[-3].minor.yy560 = yylhsminor.yy560; + break; + case 742: /* union_query_expression ::= query_simple_or_subquery UNION ALL query_simple_or_subquery */ +{ yylhsminor.yy560 = createSetOperator(pCxt, SET_OP_TYPE_UNION_ALL, yymsp[-3].minor.yy560, yymsp[0].minor.yy560); } + yymsp[-3].minor.yy560 = yylhsminor.yy560; + break; + case 743: /* union_query_expression ::= query_simple_or_subquery UNION query_simple_or_subquery */ +{ yylhsminor.yy560 = createSetOperator(pCxt, SET_OP_TYPE_UNION, yymsp[-2].minor.yy560, yymsp[0].minor.yy560); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 752: /* slimit_clause_opt ::= SLIMIT NK_INTEGER SOFFSET NK_INTEGER */ + case 756: /* limit_clause_opt ::= LIMIT NK_INTEGER OFFSET NK_INTEGER */ yytestcase(yyruleno==756); +{ yymsp[-3].minor.yy560 = createLimitNode(pCxt, &yymsp[-2].minor.yy0, &yymsp[0].minor.yy0); } + break; + case 753: /* slimit_clause_opt ::= SLIMIT NK_INTEGER NK_COMMA NK_INTEGER */ + case 757: /* limit_clause_opt ::= LIMIT NK_INTEGER NK_COMMA NK_INTEGER */ yytestcase(yyruleno==757); +{ yymsp[-3].minor.yy560 = createLimitNode(pCxt, &yymsp[0].minor.yy0, &yymsp[-2].minor.yy0); } + break; + case 758: /* subquery ::= NK_LP query_expression NK_RP */ +{ yylhsminor.yy560 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy0, &yymsp[0].minor.yy0, yymsp[-1].minor.yy560); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 763: /* sort_specification ::= expr_or_subquery ordering_specification_opt null_ordering_opt */ +{ yylhsminor.yy560 = createOrderByExprNode(pCxt, releaseRawExprNode(pCxt, yymsp[-2].minor.yy560), yymsp[-1].minor.yy974, yymsp[0].minor.yy109); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + case 764: /* ordering_specification_opt ::= */ +{ yymsp[1].minor.yy974 = ORDER_ASC; } + break; + case 765: /* ordering_specification_opt ::= ASC */ +{ yymsp[0].minor.yy974 = ORDER_ASC; } + break; + case 766: /* ordering_specification_opt ::= DESC */ +{ yymsp[0].minor.yy974 = ORDER_DESC; } + break; + case 767: /* null_ordering_opt ::= */ +{ yymsp[1].minor.yy109 = NULL_ORDER_DEFAULT; } + break; + case 768: /* null_ordering_opt ::= NULLS FIRST */ +{ yymsp[-1].minor.yy109 = NULL_ORDER_FIRST; } + break; + case 769: /* null_ordering_opt ::= NULLS LAST */ +{ yymsp[-1].minor.yy109 = NULL_ORDER_LAST; } + break; + case 772: /* column_options ::= column_options NK_ID NK_STRING */ +{ yylhsminor.yy560 = setColumnOptions(pCxt, yymsp[-2].minor.yy560, &yymsp[-1].minor.yy0, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy560 = yylhsminor.yy560; + break; + default: + break; +/********** End reduce actions ************************************************/ }; assert( yyrulenoyytos>yypParser->yystack ) yy_pop_parser_stack(yypParser); /* Here code is inserted which will be executed whenever the ** parser fails */ - /************ Begin %parse_failure code ***************************************/ - /************ End %parse_failure code *****************************************/ +/************ Begin %parse_failure code ***************************************/ +/************ End %parse_failure code *****************************************/ ParseARG_STORE /* Suppress warning about unused %extra_argument variable */ - ParseCTX_STORE + ParseCTX_STORE } #endif /* YYNOERRORRECOVERY */ @@ -8125,16 +7753,16 @@ static void yy_parse_failed( ** The following code executes when a syntax error first occurs. */ static void yy_syntax_error( - yyParser *yypParser, /* The parser */ - int yymajor, /* The major type of the error token */ - ParseTOKENTYPE yyminor /* The minor type of the error token */ + yyParser *yypParser, /* The parser */ + int yymajor, /* The major type of the error token */ + ParseTOKENTYPE yyminor /* The minor type of the error token */ ){ ParseARG_FETCH - ParseCTX_FETCH + ParseCTX_FETCH #define TOKEN yyminor - /************ Begin %syntax_error code ****************************************/ +/************ Begin %syntax_error code ****************************************/ - if (TSDB_CODE_SUCCESS == pCxt->errCode) { + if (TSDB_CODE_SUCCESS == pCxt->errCode) { if(TOKEN.z) { pCxt->errCode = generateSyntaxErrMsg(&pCxt->msgBuf, TSDB_CODE_PAR_SYNTAX_ERROR, TOKEN.z); } else { @@ -8143,21 +7771,21 @@ static void yy_syntax_error( } else if (TSDB_CODE_PAR_DB_NOT_SPECIFIED == pCxt->errCode && TK_NK_FLOAT == TOKEN.type) { pCxt->errCode = generateSyntaxErrMsg(&pCxt->msgBuf, TSDB_CODE_PAR_SYNTAX_ERROR, TOKEN.z); } - /************ End %syntax_error code ******************************************/ +/************ End %syntax_error code ******************************************/ ParseARG_STORE /* Suppress warning about unused %extra_argument variable */ - ParseCTX_STORE + ParseCTX_STORE } /* ** The following is executed when the parser accepts */ static void yy_accept( - yyParser *yypParser /* The parser */ + yyParser *yypParser /* The parser */ ){ ParseARG_FETCH - ParseCTX_FETCH + ParseCTX_FETCH #ifndef NDEBUG - if( yyTraceFILE ){ + if( yyTraceFILE ){ fprintf(yyTraceFILE,"%sAccept!\n",yyTracePrompt); } #endif @@ -8167,10 +7795,10 @@ static void yy_accept( assert( yypParser->yytos==yypParser->yystack ); /* Here code is inserted which will be executed whenever the ** parser accepts */ - /*********** Begin %parse_accept code *****************************************/ - /*********** End %parse_accept code *******************************************/ +/*********** Begin %parse_accept code *****************************************/ +/*********** End %parse_accept code *******************************************/ ParseARG_STORE /* Suppress warning about unused %extra_argument variable */ - ParseCTX_STORE + ParseCTX_STORE } /* The main parser program. @@ -8193,10 +7821,10 @@ static void yy_accept( ** None. */ void Parse( - void *yyp, /* The parser */ - int yymajor, /* The major token code number */ - ParseTOKENTYPE yyminor /* The value for the token */ - ParseARG_PDECL /* Optional %extra_argument parameter */ + void *yyp, /* The parser */ + int yymajor, /* The major token code number */ + ParseTOKENTYPE yyminor /* The value for the token */ + ParseARG_PDECL /* Optional %extra_argument parameter */ ){ YYMINORTYPE yyminorunion; YYACTIONTYPE yyact; /* The parser action. */ @@ -8208,9 +7836,9 @@ void Parse( #endif yyParser *yypParser = (yyParser*)yyp; /* The parser */ ParseCTX_FETCH - ParseARG_STORE + ParseARG_STORE - assert( yypParser->yytos!=0 ); + assert( yypParser->yytos!=0 ); #if !defined(YYERRORSYMBOL) && !defined(YYNOERRORRECOVERY) yyendofinput = (yymajor==0); #endif @@ -8228,49 +7856,12 @@ void Parse( } #endif - while(1){ /* Exit by "break" */ - assert( yypParser->yytos>=yypParser->yystack ); + do{ assert( yyact==yypParser->yytos->stateno ); yyact = yy_find_shift_action((YYCODETYPE)yymajor,yyact); if( yyact >= YY_MIN_REDUCE ){ - unsigned int yyruleno = yyact - YY_MIN_REDUCE; /* Reduce by this rule */ -#ifndef NDEBUG - assert( yyruleno<(int)(sizeof(yyRuleName)/sizeof(yyRuleName[0])) ); - if( yyTraceFILE ){ - int yysize = yyRuleInfoNRhs[yyruleno]; - if( yysize ){ - fprintf(yyTraceFILE, "%sReduce %d [%s]%s, pop back to state %d.\n", - yyTracePrompt, - yyruleno, yyRuleName[yyruleno], - yyrulenoyytos[yysize].stateno); - }else{ - fprintf(yyTraceFILE, "%sReduce %d [%s]%s.\n", - yyTracePrompt, yyruleno, yyRuleName[yyruleno], - yyrulenoyytos - yypParser->yystack)>yypParser->yyhwm ){ - yypParser->yyhwm++; - assert( yypParser->yyhwm == - (int)(yypParser->yytos - yypParser->yystack)); - } -#endif - if( yypParser->yytos>=yypParser->yystackEnd ){ - if( yyGrowStack(yypParser) ){ - yyStackOverflow(yypParser); - break; - } - } - } - yyact = yy_reduce(yypParser,yyruleno,yymajor,yyminor ParseCTX_PARAM); + yyact = yy_reduce(yypParser,yyact-YY_MIN_REDUCE,yymajor, + yyminor ParseCTX_PARAM); }else if( yyact <= YY_MAX_SHIFTREDUCE ){ yy_shift(yypParser,yyact,(YYCODETYPE)yymajor,yyminor); #ifndef YYNOERRORRECOVERY @@ -8295,7 +7886,7 @@ void Parse( #ifdef YYERRORSYMBOL /* A syntax error has occurred. ** The response to an error depends upon whether or not the - ** grammar defines an error token "ERROR". + ** grammar defines an error token "ERROR". ** ** This is what we do if the grammar does define ERROR: ** @@ -8320,19 +7911,20 @@ void Parse( #ifndef NDEBUG if( yyTraceFILE ){ fprintf(yyTraceFILE,"%sDiscard input token %s\n", - yyTracePrompt,yyTokenName[yymajor]); + yyTracePrompt,yyTokenName[yymajor]); } #endif yy_destructor(yypParser, (YYCODETYPE)yymajor, &yyminorunion); yymajor = YYNOCODE; }else{ - while( yypParser->yytos > yypParser->yystack ){ - yyact = yy_find_reduce_action(yypParser->yytos->stateno, - YYERRORSYMBOL); - if( yyact<=YY_MAX_SHIFTREDUCE ) break; + while( yypParser->yytos >= yypParser->yystack + && (yyact = yy_find_reduce_action( + yypParser->yytos->stateno, + YYERRORSYMBOL)) > YY_MAX_SHIFTREDUCE + ){ yy_pop_parser_stack(yypParser); } - if( yypParser->yytos <= yypParser->yystack || yymajor==0 ){ + if( yypParser->yytos < yypParser->yystack || yymajor==0 ){ yy_destructor(yypParser,(YYCODETYPE)yymajor,&yyminorunion); yy_parse_failed(yypParser); #ifndef YYNOERRORRECOVERY @@ -8382,7 +7974,7 @@ void Parse( break; #endif } - } + }while( yypParser->yytos>yypParser->yystack ); #ifndef NDEBUG if( yyTraceFILE ){ yyStackEntry *i; diff --git a/source/libs/qcom/src/querymsg.c b/source/libs/qcom/src/querymsg.c index 48f392ee53..542e549d40 100644 --- a/source/libs/qcom/src/querymsg.c +++ b/source/libs/qcom/src/querymsg.c @@ -77,6 +77,7 @@ int32_t queryBuildTableMetaReqMsg(void *input, char **msg, int32_t msgSize, int3 } STableInfoReq infoReq = {0}; + infoReq.option = pInput->option; infoReq.header.vgId = pInput->vgId; if (pInput->dbFName) { tstrncpy(infoReq.dbFName, pInput->dbFName, TSDB_DB_FNAME_LEN); @@ -603,6 +604,64 @@ int32_t queryCreateTableMetaFromMsg(STableMetaRsp *msg, bool isStb, STableMeta * return TSDB_CODE_SUCCESS; } +int32_t queryCreateTableMetaExFromMsg(STableMetaRsp *msg, bool isStb, STableMeta **pMeta) { + int32_t total = msg->numOfColumns + msg->numOfTags; + int32_t metaSize = sizeof(STableMeta) + sizeof(SSchema) * total; + int32_t schemaExtSize = (useCompress(msg->tableType) && msg->pSchemaExt) ? sizeof(SSchemaExt) * msg->numOfColumns : 0; + int32_t tbNameSize = strlen(msg->tbName) + 1; + + STableMeta *pTableMeta = taosMemoryCalloc(1, metaSize + schemaExtSize + tbNameSize); + if (NULL == pTableMeta) { + qError("calloc size[%d] failed", metaSize); + return terrno; + } + SSchemaExt *pSchemaExt = (SSchemaExt *)((char *)pTableMeta + metaSize); + + pTableMeta->vgId = isStb ? 0 : msg->vgId; + pTableMeta->tableType = isStb ? TSDB_SUPER_TABLE : msg->tableType; + pTableMeta->uid = isStb ? msg->suid : msg->tuid; + pTableMeta->suid = msg->suid; + pTableMeta->sversion = msg->sversion; + pTableMeta->tversion = msg->tversion; + + pTableMeta->tableInfo.numOfTags = msg->numOfTags; + pTableMeta->tableInfo.precision = msg->precision; + pTableMeta->tableInfo.numOfColumns = msg->numOfColumns; + + TAOS_MEMCPY(pTableMeta->schema, msg->pSchemas, sizeof(SSchema) * total); + if (useCompress(msg->tableType) && msg->pSchemaExt) { + pTableMeta->schemaExt = pSchemaExt; + TAOS_MEMCPY(pSchemaExt, msg->pSchemaExt, schemaExtSize); + } else { + pTableMeta->schemaExt = NULL; + } + + bool hasPK = (msg->numOfColumns > 1) && (pTableMeta->schema[1].flags & COL_IS_KEY); + for (int32_t i = 0; i < msg->numOfColumns; ++i) { + pTableMeta->tableInfo.rowSize += pTableMeta->schema[i].bytes; + if (hasPK && (i > 0)) { + if ((pTableMeta->schema[i].flags & COL_IS_KEY)) { + ++pTableMeta->tableInfo.numOfPKs; + } else { + hasPK = false; + } + } + } + + char *pTbName = (char *)pTableMeta + metaSize + schemaExtSize; + tstrncpy(pTbName, msg->tbName, tbNameSize); + + qDebug("table %s uid %" PRIx64 " meta returned, type %d vgId:%d db %s stb %s suid %" PRIx64 + " sver %d tver %d" + " tagNum %d colNum %d precision %d rowSize %d", + msg->tbName, pTableMeta->uid, pTableMeta->tableType, pTableMeta->vgId, msg->dbFName, msg->stbName, + pTableMeta->suid, pTableMeta->sversion, pTableMeta->tversion, pTableMeta->tableInfo.numOfTags, + pTableMeta->tableInfo.numOfColumns, pTableMeta->tableInfo.precision, pTableMeta->tableInfo.rowSize); + + *pMeta = pTableMeta; + return TSDB_CODE_SUCCESS; +} + int32_t queryProcessTableMetaRsp(void *output, char *msg, int32_t msgSize) { int32_t code = 0; STableMetaRsp metaRsp = {0}; @@ -659,6 +718,62 @@ PROCESS_META_OVER: return code; } +static int32_t queryProcessTableNameRsp(void *output, char *msg, int32_t msgSize) { + int32_t code = 0; + STableMetaRsp metaRsp = {0}; + + if (NULL == output || NULL == msg || msgSize <= 0) { + code = TSDB_CODE_TSC_INVALID_INPUT; + goto PROCESS_NAME_OVER; + } + + if (tDeserializeSTableMetaRsp(msg, msgSize, &metaRsp) != 0) { + code = TSDB_CODE_INVALID_MSG; + goto PROCESS_NAME_OVER; + } + + code = queryConvertTableMetaMsg(&metaRsp); + if (code != TSDB_CODE_SUCCESS) { + goto PROCESS_NAME_OVER; + } + + if (!IS_SYS_DBNAME(metaRsp.dbFName) && + !tIsValidSchema(metaRsp.pSchemas, metaRsp.numOfColumns, metaRsp.numOfTags)) { + code = TSDB_CODE_TSC_INVALID_VALUE; + goto PROCESS_NAME_OVER; + } + + STableMetaOutput *pOut = output; + strcpy(pOut->dbFName, metaRsp.dbFName); + pOut->dbId = metaRsp.dbId; + + if (metaRsp.tableType == TSDB_CHILD_TABLE) { + SET_META_TYPE_BOTH_TABLE(pOut->metaType); + + strcpy(pOut->ctbName, metaRsp.tbName); + strcpy(pOut->tbName, metaRsp.stbName); + + pOut->ctbMeta.vgId = metaRsp.vgId; + pOut->ctbMeta.tableType = metaRsp.tableType; + pOut->ctbMeta.uid = metaRsp.tuid; + pOut->ctbMeta.suid = metaRsp.suid; + + code = queryCreateTableMetaExFromMsg(&metaRsp, true, &pOut->tbMeta); + } else { + SET_META_TYPE_TABLE(pOut->metaType); + strcpy(pOut->tbName, metaRsp.tbName); + code = queryCreateTableMetaExFromMsg(&metaRsp, (metaRsp.tableType == TSDB_SUPER_TABLE), &pOut->tbMeta); + } + +PROCESS_NAME_OVER: + if (code != 0) { + qError("failed to process table name rsp since %s", tstrerror(code)); + } + + tFreeSTableMetaRsp(&metaRsp); + return code; +} + int32_t queryProcessQnodeListRsp(void *output, char *msg, int32_t msgSize) { SQnodeListRsp out = {0}; int32_t code = 0; @@ -880,6 +995,7 @@ int32_t queryProcessStreamProgressRsp(void* output, char* msg, int32_t msgSize) void initQueryModuleMsgHandle() { queryBuildMsg[TMSG_INDEX(TDMT_VND_TABLE_META)] = queryBuildTableMetaReqMsg; + queryBuildMsg[TMSG_INDEX(TDMT_VND_TABLE_NAME)] = queryBuildTableMetaReqMsg; queryBuildMsg[TMSG_INDEX(TDMT_MND_TABLE_META)] = queryBuildTableMetaReqMsg; queryBuildMsg[TMSG_INDEX(TDMT_MND_USE_DB)] = queryBuildUseDbMsg; queryBuildMsg[TMSG_INDEX(TDMT_MND_QNODE_LIST)] = queryBuildQnodeListMsg; @@ -898,6 +1014,7 @@ void initQueryModuleMsgHandle() { queryBuildMsg[TMSG_INDEX(TDMT_VND_GET_STREAM_PROGRESS)] = queryBuildGetStreamProgressMsg; queryProcessMsgRsp[TMSG_INDEX(TDMT_VND_TABLE_META)] = queryProcessTableMetaRsp; + queryProcessMsgRsp[TMSG_INDEX(TDMT_VND_TABLE_NAME)] = queryProcessTableNameRsp; queryProcessMsgRsp[TMSG_INDEX(TDMT_MND_TABLE_META)] = queryProcessTableMetaRsp; queryProcessMsgRsp[TMSG_INDEX(TDMT_MND_USE_DB)] = queryProcessUseDBRsp; queryProcessMsgRsp[TMSG_INDEX(TDMT_MND_QNODE_LIST)] = queryProcessQnodeListRsp; diff --git a/source/libs/stream/src/streamBackendRocksdb.c b/source/libs/stream/src/streamBackendRocksdb.c index 0a28f28943..1b80635f0c 100644 --- a/source/libs/stream/src/streamBackendRocksdb.c +++ b/source/libs/stream/src/streamBackendRocksdb.c @@ -4348,7 +4348,7 @@ int32_t streamDefaultIterGet_rocksdb(SStreamState* pState, const void* start, co int64_t checkPoint = 0; if (sscanf(key + strlen(key), ":%" PRId64 "", &checkPoint) == 1) { if (taosArrayPush(result, &checkPoint) == NULL) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; break; } } @@ -4568,7 +4568,7 @@ int32_t compareHashTableImpl(SHashObj* p1, SHashObj* p2, SArray* diff) { (void)strncpy(fname, name, len); if (taosArrayPush(diff, &fname) == NULL) { taosMemoryFree(fname); - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } } pIter = taosHashIterate(p2, pIter); @@ -4687,7 +4687,7 @@ int32_t dbChkpGetDelta(SDbChkp* p, int64_t chkpId, SArray* list) { p->pCurrent = taosStrdup(name); if (p->pCurrent == NULL) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; break; } continue; @@ -4697,7 +4697,7 @@ int32_t dbChkpGetDelta(SDbChkp* p, int64_t chkpId, SArray* list) { taosMemoryFreeClear(p->pManifest); p->pManifest = taosStrdup(name); if (p->pManifest == NULL) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; break; } continue; @@ -4731,7 +4731,7 @@ int32_t dbChkpGetDelta(SDbChkp* p, int64_t chkpId, SArray* list) { if (taosArrayPush(p->pAdd, &fname) == NULL) { taosMemoryFree(fname); (void)taosThreadRwlockUnlock(&p->rwLock); - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } } pIter = taosHashIterate(p->pSstTbl[1 - p->idx], pIter); @@ -4783,7 +4783,7 @@ int32_t dbChkpCreate(char* path, int64_t initChkpId, SDbChkp** ppChkp) { p->preCkptId = -1; p->pSST = taosArrayInit(64, sizeof(void*)); if (p->pSST == NULL) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; dbChkpDestroy(p); return code; } @@ -4799,25 +4799,25 @@ int32_t dbChkpCreate(char* path, int64_t initChkpId, SDbChkp** ppChkp) { p->idx = 0; p->pSstTbl[0] = taosHashInit(64, taosGetDefaultHashFunction(TSDB_DATA_TYPE_BINARY), false, HASH_ENTRY_LOCK); if (p->pSstTbl[0] == NULL) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; goto _EXIT; } p->pSstTbl[1] = taosHashInit(64, taosGetDefaultHashFunction(TSDB_DATA_TYPE_BINARY), false, HASH_ENTRY_LOCK); if (p->pSstTbl[1] == NULL) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; goto _EXIT; } p->pAdd = taosArrayInit(64, sizeof(void*)); if (p->pAdd == NULL) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; goto _EXIT; } p->pDel = taosArrayInit(64, sizeof(void*)); if (p->pDel == NULL) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; goto _EXIT; } diff --git a/source/libs/stream/src/streamSessionState.c b/source/libs/stream/src/streamSessionState.c index a192f03947..23598cf717 100644 --- a/source/libs/stream/src/streamSessionState.c +++ b/source/libs/stream/src/streamSessionState.c @@ -101,7 +101,7 @@ static int32_t addNewSessionWindow(SStreamFileState* pFileState, SArray* pWinInf memcpy(pNewPos->pKey, pKey, sizeof(SSessionKey)); void* tmp = taosArrayPush(pWinInfos, &pNewPos); if (!tmp) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; QUERY_CHECK_CODE(code, lino, _end); } (*ppPos) = pNewPos; @@ -126,7 +126,7 @@ static int32_t insertNewSessionWindow(SStreamFileState* pFileState, SArray* pWin memcpy(pNewPos->pKey, pKey, sizeof(SSessionKey)); void* tmp = taosArrayInsert(pWinInfos, index, &pNewPos); if (!tmp) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; QUERY_CHECK_CODE(code, lino, _end); } @@ -180,7 +180,7 @@ int32_t getSessionWinResultBuff(SStreamFileState* pFileState, SSessionKey* pKey, } else { pWinStates = taosArrayInit(16, POINTER_BYTES); if (!pWinStates) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; QUERY_CHECK_CODE(code, lino, _end); } code = tSimpleHashPut(pSessionBuff, &pKey->groupId, sizeof(uint64_t), &pWinStates, POINTER_BYTES); @@ -301,7 +301,7 @@ int32_t putSessionWinResultBuff(SStreamFileState* pFileState, SRowBuffPos* pPos) } else { pWinStates = taosArrayInit(16, POINTER_BYTES); if (!pWinStates) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; QUERY_CHECK_CODE(code, lino, _end); } @@ -313,7 +313,7 @@ int32_t putSessionWinResultBuff(SStreamFileState* pFileState, SRowBuffPos* pPos) if (size == 0) { void* tmp = taosArrayPush(pWinStates, &pPos); if (!tmp) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; QUERY_CHECK_CODE(code, lino, _end); } goto _end; @@ -324,13 +324,13 @@ int32_t putSessionWinResultBuff(SStreamFileState* pFileState, SRowBuffPos* pPos) if (index >= 0) { void* tmp = taosArrayInsert(pWinStates, index, &pPos); if (!tmp) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; QUERY_CHECK_CODE(code, lino, _end); } } else { void* tmp = taosArrayInsert(pWinStates, 0, &pPos); if (!tmp) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; QUERY_CHECK_CODE(code, lino, _end); } } @@ -421,7 +421,7 @@ int32_t allocSessioncWinBuffByNextPosition(SStreamFileState* pFileState, SStream if (!ppBuff) { pWinStates = taosArrayInit(16, POINTER_BYTES); if (!pWinStates) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; QUERY_CHECK_CODE(code, lino, _end); } @@ -804,7 +804,7 @@ int32_t getStateWinResultBuff(SStreamFileState* pFileState, SSessionKey* key, ch } else { pWinStates = taosArrayInit(16, POINTER_BYTES); if (!pWinStates) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; QUERY_CHECK_CODE(code, lino, _end); } @@ -944,7 +944,7 @@ int32_t getCountWinResultBuff(SStreamFileState* pFileState, SSessionKey* pKey, C } else { pWinStates = taosArrayInit(16, POINTER_BYTES); if (!pWinStates) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; QUERY_CHECK_CODE(code, lino, _end); } diff --git a/source/libs/stream/src/streamSnapshot.c b/source/libs/stream/src/streamSnapshot.c index 2742798a04..ae8a71d988 100644 --- a/source/libs/stream/src/streamSnapshot.c +++ b/source/libs/stream/src/streamSnapshot.c @@ -204,7 +204,7 @@ int32_t snapFileGenMeta(SBackendSnapFile2* pSnapFile) { p = taosArrayPush(pSnapFile->pFileList, &item); if (p == NULL) { - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } // mainfest @@ -217,7 +217,7 @@ int32_t snapFileGenMeta(SBackendSnapFile2* pSnapFile) { p = taosArrayPush(pSnapFile->pFileList, &item); if (p == NULL) { - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } // options @@ -230,7 +230,7 @@ int32_t snapFileGenMeta(SBackendSnapFile2* pSnapFile) { p = taosArrayPush(pSnapFile->pFileList, &item); if (p == NULL) { - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } // sst @@ -245,7 +245,7 @@ int32_t snapFileGenMeta(SBackendSnapFile2* pSnapFile) { p = taosArrayPush(pSnapFile->pFileList, &item); if (p == NULL) { - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } } @@ -255,7 +255,7 @@ int32_t snapFileGenMeta(SBackendSnapFile2* pSnapFile) { if (streamGetFileSize(pSnapFile->path, item.name, &item.size) == 0) { p = taosArrayPush(pSnapFile->pFileList, &item); if (p == NULL) { - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } } @@ -265,7 +265,7 @@ int32_t snapFileGenMeta(SBackendSnapFile2* pSnapFile) { if (streamGetFileSize(pSnapFile->path, item.name, &item.size) == 0) { p = taosArrayPush(pSnapFile->pFileList, &item); if (p == NULL) { - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } } @@ -287,7 +287,7 @@ int32_t snapFileReadMeta(SBackendSnapFile2* pSnapFile) { if (strlen(name) >= strlen(ROCKSDB_CURRENT) && 0 == strncmp(name, ROCKSDB_CURRENT, strlen(ROCKSDB_CURRENT))) { pSnapFile->pCurrent = taosStrdup(name); if (pSnapFile->pCurrent == NULL) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; break; } continue; @@ -295,7 +295,7 @@ int32_t snapFileReadMeta(SBackendSnapFile2* pSnapFile) { if (strlen(name) >= strlen(ROCKSDB_MAINFEST) && 0 == strncmp(name, ROCKSDB_MAINFEST, strlen(ROCKSDB_MAINFEST))) { pSnapFile->pMainfest = taosStrdup(name); if (pSnapFile->pMainfest == NULL) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; break; } continue; @@ -303,7 +303,7 @@ int32_t snapFileReadMeta(SBackendSnapFile2* pSnapFile) { if (strlen(name) >= strlen(ROCKSDB_OPTIONS) && 0 == strncmp(name, ROCKSDB_OPTIONS, strlen(ROCKSDB_OPTIONS))) { pSnapFile->pOptions = taosStrdup(name); if (pSnapFile->pOptions == NULL) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; break; } continue; @@ -312,7 +312,7 @@ int32_t snapFileReadMeta(SBackendSnapFile2* pSnapFile) { 0 == strncmp(name, ROCKSDB_CHECKPOINT_META, strlen(ROCKSDB_CHECKPOINT_META))) { pSnapFile->pCheckpointMeta = taosStrdup(name); if (pSnapFile->pCheckpointMeta == NULL) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; break; } continue; @@ -321,7 +321,7 @@ int32_t snapFileReadMeta(SBackendSnapFile2* pSnapFile) { 0 == strncmp(name, ROCKSDB_CHECKPOINT_SELF_CHECK, strlen(ROCKSDB_CHECKPOINT_SELF_CHECK))) { pSnapFile->pCheckpointSelfcheck = taosStrdup(name); if (pSnapFile->pCheckpointSelfcheck == NULL) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; break; } continue; @@ -330,13 +330,13 @@ int32_t snapFileReadMeta(SBackendSnapFile2* pSnapFile) { 0 == strncmp(name + strlen(name) - strlen(ROCKSDB_SST), ROCKSDB_SST, strlen(ROCKSDB_SST))) { char* sst = taosStrdup(name); if (sst == NULL) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; break; } void* p = taosArrayPush(pSnapFile->pSst, &sst); if (p == NULL) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; break; } } @@ -370,7 +370,7 @@ int32_t streamBackendSnapInitFile(char* metaPath, SStreamTaskSnap* pSnap, SBacke pSnapFile->pSst = taosArrayInit(16, sizeof(void*)); pSnapFile->pFileList = taosArrayInit(64, sizeof(SBackendFileItem)); if (pSnapFile->pSst == NULL || pSnapFile->pFileList == NULL) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; goto _ERROR; } @@ -426,7 +426,7 @@ int32_t streamSnapHandleInit(SStreamSnapHandle* pHandle, char* path, void* pMeta SArray* pSnapInfoSet = taosArrayInit(4, sizeof(SStreamTaskSnap)); if (pSnapInfoSet == NULL) { - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } code = streamCreateTaskDbSnapInfo(pMeta, path, pSnapInfoSet); @@ -437,7 +437,7 @@ int32_t streamSnapHandleInit(SStreamSnapHandle* pHandle, char* path, void* pMeta pDbSnapSet = taosArrayInit(8, sizeof(SBackendSnapFile2)); if (pDbSnapSet == NULL) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; goto _err; } @@ -452,7 +452,7 @@ int32_t streamSnapHandleInit(SStreamSnapHandle* pHandle, char* path, void* pMeta void* p = taosArrayPush(pDbSnapSet, &snapFile); if (p == NULL) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; goto _err; } } @@ -651,7 +651,7 @@ int32_t streamSnapWriterOpen(void* pMeta, int64_t sver, int64_t ever, char* path pHandle->metaPath = taosStrdup(path); if (pHandle->metaPath == NULL) { taosMemoryFree(pWriter); - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; return code; } @@ -673,7 +673,7 @@ int32_t streamSnapWriterOpen(void* pMeta, int64_t sver, int64_t ever, char* path stError("failed close snaphost writer"); } - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; return code; } @@ -726,12 +726,12 @@ int32_t streamSnapWriteImpl(SStreamSnapWriter* pWriter, uint8_t* pData, uint32_t item.name = taosStrdup(pHdr->name); item.type = pHdr->type; if (item.name == NULL) { - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } void* p = taosArrayPush(pSnapFile->pFileList, &item); if (p == NULL) { // can NOT goto _err here. - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } SBackendFileItem* pItem2 = taosArrayGet(pSnapFile->pFileList, pSnapFile->currFileIdx); @@ -810,7 +810,7 @@ int32_t streamSnapWrite(SStreamSnapWriter* pWriter, uint8_t* pData, uint32_t nDa void* p = taosArrayPush(pDbSnapFile->pFileList, &item); if (p == NULL) { - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } pDbSnapFile->inited = 1; @@ -822,7 +822,7 @@ int32_t streamSnapWrite(SStreamSnapWriter* pWriter, uint8_t* pData, uint32_t nDa SBackendSnapFile2 snapFile = {0}; void* p = taosArrayPush(pHandle->pDbSnapSet, &snapFile); if (p == NULL) { - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } pHandle->currIdx += 1; diff --git a/source/libs/stream/src/streamStartHistory.c b/source/libs/stream/src/streamStartHistory.c index 1290aef6a3..b376dbd16b 100644 --- a/source/libs/stream/src/streamStartHistory.c +++ b/source/libs/stream/src/streamStartHistory.c @@ -70,7 +70,7 @@ int32_t streamStartScanHistoryAsync(SStreamTask* pTask, int8_t igUntreated) { int32_t len = sizeof(SStreamScanHistoryReq); void* serializedReq = rpcMallocCont(len); if (serializedReq == NULL) { - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } memcpy(serializedReq, &req, len); diff --git a/source/libs/stream/src/streamState.c b/source/libs/stream/src/streamState.c index e1edebc861..eb7254acba 100644 --- a/source/libs/stream/src/streamState.c +++ b/source/libs/stream/src/streamState.c @@ -106,14 +106,14 @@ SStreamState* streamStateOpen(const char* path, void* pTask, int64_t streamId, i stDebug("open stream state %p, %s", pState, path); if (pState == NULL) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; QUERY_CHECK_CODE(code, lino, _end); } pState->pTdbState = taosMemoryCalloc(1, sizeof(STdbState)); if (pState->pTdbState == NULL) { streamStateDestroy(pState, true); - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; QUERY_CHECK_CODE(code, lino, _end); } diff --git a/source/libs/stream/src/streamTask.c b/source/libs/stream/src/streamTask.c index 3319c7c74f..71a2ed3e4a 100644 --- a/source/libs/stream/src/streamTask.c +++ b/source/libs/stream/src/streamTask.c @@ -32,7 +32,7 @@ static int32_t addToTaskset(SArray* pArray, SStreamTask* pTask) { int32_t childId = taosArrayGetSize(pArray); pTask->info.selfChildId = childId; void* p = taosArrayPush(pArray, &pTask); - return (p == NULL) ? TSDB_CODE_OUT_OF_MEMORY : TSDB_CODE_SUCCESS; + return (p == NULL) ? terrno : TSDB_CODE_SUCCESS; } static int32_t doUpdateTaskEpset(SStreamTask* pTask, int32_t nodeId, SEpSet* pEpSet, bool* pUpdated) { @@ -409,7 +409,7 @@ int32_t streamTaskSetBackendPath(SStreamTask* pTask) { int32_t len = strlen(pTask->pMeta->path); pTask->backendPath = (char*)taosMemoryMalloc(len + nBytes + 2); if (pTask->backendPath == NULL) { - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } (void)sprintf(pTask->backendPath, "%s%s%s", pTask->pMeta->path, TD_DIRSEP, id); @@ -547,7 +547,7 @@ int32_t streamTaskGetNumOfUpstream(const SStreamTask* pTask) { return taosArrayG int32_t streamTaskSetUpstreamInfo(SStreamTask* pTask, const SStreamTask* pUpstreamTask) { SStreamUpstreamEpInfo* pEpInfo = createStreamTaskEpInfo(pUpstreamTask); if (pEpInfo == NULL) { - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } if (pTask->upstreamInfo.pList == NULL) { @@ -555,7 +555,7 @@ int32_t streamTaskSetUpstreamInfo(SStreamTask* pTask, const SStreamTask* pUpstre } void* p = taosArrayPush(pTask->upstreamInfo.pList, &pEpInfo); - return (p == NULL) ? TSDB_CODE_OUT_OF_MEMORY : TSDB_CODE_SUCCESS; + return (p == NULL) ? terrno : TSDB_CODE_SUCCESS; } int32_t streamTaskUpdateUpstreamInfo(SStreamTask* pTask, int32_t nodeId, const SEpSet* pEpSet, bool* pUpdated) { @@ -1131,7 +1131,7 @@ int32_t createStreamTaskIdStr(int64_t streamId, int32_t taskId, const char** pId *pId = taosStrdup(buf); if (*pId == NULL) { - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } else { return TSDB_CODE_SUCCESS; } diff --git a/source/libs/stream/src/streamTaskSm.c b/source/libs/stream/src/streamTaskSm.c index 3709c4dfbd..3501d30be4 100644 --- a/source/libs/stream/src/streamTaskSm.c +++ b/source/libs/stream/src/streamTaskSm.c @@ -88,7 +88,7 @@ static int32_t attachWaitedEvent(SStreamTask* pTask, SFutureHandleEventInfo* pEv if (px == NULL) { stError("s-task:%s failed to add into waiting list, total waiting events:%d, code: out of memory", pTask->id.idStr, (int32_t)taosArrayGetSize(pList)); - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } else { stDebug("s-task:%s add into waiting list, total waiting events:%d", pTask->id.idStr, (int32_t)taosArrayGetSize(pList)); @@ -298,7 +298,7 @@ int32_t streamCreateStateMachine(SStreamTask* pTask) { taosMemoryFree(pSM); stError("s-task:%s failed to create task stateMachine, size:%d, code:%s", id, (int32_t)sizeof(SStreamTaskSM), tstrerror(terrno)); - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } // set the initial state for the state-machine of stream task diff --git a/source/libs/stream/src/streamUpdate.c b/source/libs/stream/src/streamUpdate.c index d5adbcee77..60f2294c20 100644 --- a/source/libs/stream/src/streamUpdate.c +++ b/source/libs/stream/src/streamUpdate.c @@ -80,7 +80,7 @@ int32_t windowSBfAdd(SUpdateInfo* pInfo, uint64_t count) { QUERY_CHECK_CODE(code, lino, _error); void* res = taosArrayPush(pInfo->pTsSBFs, &tsSBF); if (!res) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; QUERY_CHECK_CODE(code, lino, _error); } } @@ -168,7 +168,7 @@ int32_t updateInfoInit(int64_t interval, int32_t precision, int64_t watermark, b pInfo->pTsSBFs = taosArrayInit(bfSize, sizeof(void*)); if (pInfo->pTsSBFs == NULL) { updateInfoDestroy(pInfo); - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; QUERY_CHECK_CODE(code, lino, _end); } code = windowSBfAdd(pInfo, bfSize); @@ -177,7 +177,7 @@ int32_t updateInfoInit(int64_t interval, int32_t precision, int64_t watermark, b pInfo->pTsBuckets = taosArrayInit(DEFAULT_BUCKET_SIZE, sizeof(TSKEY)); if (pInfo->pTsBuckets == NULL) { updateInfoDestroy(pInfo); - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; QUERY_CHECK_CODE(code, lino, _end); } @@ -185,7 +185,7 @@ int32_t updateInfoInit(int64_t interval, int32_t precision, int64_t watermark, b for (uint64_t i = 0; i < DEFAULT_BUCKET_SIZE; ++i) { void* tmp = taosArrayPush(pInfo->pTsBuckets, &dumy); if (!tmp) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; QUERY_CHECK_CODE(code, lino, _end); } } @@ -195,7 +195,7 @@ int32_t updateInfoInit(int64_t interval, int32_t precision, int64_t watermark, b _hash_fn_t hashFn = taosGetDefaultHashFunction(TSDB_DATA_TYPE_UBIGINT); pInfo->pMap = taosHashInit(DEFAULT_MAP_CAPACITY, hashFn, true, HASH_NO_LOCK); if (!pInfo->pMap) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; QUERY_CHECK_CODE(code, lino, _end); } pInfo->maxDataVersion = 0; @@ -255,7 +255,7 @@ static int32_t getSBf(SUpdateInfo* pInfo, TSKEY ts, SScalableBf** ppSBf) { void* tmp = taosArrayPush(pInfo->pTsSBFs, &res); if (!tmp) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; QUERY_CHECK_CODE(code, lino, _end); } } @@ -575,7 +575,7 @@ int32_t updateInfoDeserialize(void* buf, int32_t bufLen, SUpdateInfo* pInfo) { if (tDecodeI64(&decoder, &ts) < 0) return -1; void* tmp = taosArrayPush(pInfo->pTsBuckets, &ts); if (!tmp) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; QUERY_CHECK_CODE(code, lino, _error); } } @@ -594,7 +594,7 @@ int32_t updateInfoDeserialize(void* buf, int32_t bufLen, SUpdateInfo* pInfo) { void* tmp = taosArrayPush(pInfo->pTsSBFs, &pSBf); if (!tmp) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; QUERY_CHECK_CODE(code, lino, _error); } } diff --git a/source/libs/stream/src/tstreamFileState.c b/source/libs/stream/src/tstreamFileState.c index 5626aa29da..9f8523b040 100644 --- a/source/libs/stream/src/tstreamFileState.c +++ b/source/libs/stream/src/tstreamFileState.c @@ -476,13 +476,13 @@ SRowBuffPos* getNewRowPos(SStreamFileState* pFileState) { int32_t lino = 0; SRowBuffPos* pPos = taosMemoryCalloc(1, sizeof(SRowBuffPos)); if (!pPos) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; QUERY_CHECK_CODE(code, lino, _error); } pPos->pKey = taosMemoryCalloc(1, pFileState->keyLen); if (!pPos->pKey) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; QUERY_CHECK_CODE(code, lino, _error); } @@ -699,7 +699,7 @@ void flushSnapshot(SStreamFileState* pFileState, SStreamSnapshot* pSnapshot, boo int32_t len = pFileState->rowSize + sizeof(uint64_t) + sizeof(int32_t) + 64; char* buf = taosMemoryCalloc(1, len); if (!buf) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; QUERY_CHECK_CODE(code, lino, _end); } diff --git a/source/libs/sync/src/syncMain.c b/source/libs/sync/src/syncMain.c index b19d4df1d4..eb7501981b 100644 --- a/source/libs/sync/src/syncMain.c +++ b/source/libs/sync/src/syncMain.c @@ -367,7 +367,7 @@ int32_t syncBecomeAssignedLeader(SSyncNode* ths, SRpcMsg* pRpcMsg) { } pHead = rpcMallocCont(contLen); if (!pHead) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; sError("vgId:%d, failed to malloc memory for SVArbSetAssignedLeaderRsp", ths->vgId); goto _OVER; } @@ -2965,7 +2965,7 @@ int32_t syncNodeRebuildAndCopyIfExist(SSyncNode* ths, int32_t oldtotalReplicaNum SSyncLogReplMgr* oldLogReplMgrs = NULL; int64_t length = sizeof(SSyncLogReplMgr) * (TSDB_MAX_REPLICA + TSDB_MAX_LEARNER_REPLICA); oldLogReplMgrs = taosMemoryMalloc(length); - if (NULL == oldLogReplMgrs) return TSDB_CODE_OUT_OF_MEMORY; + if (NULL == oldLogReplMgrs) return terrno; memset(oldLogReplMgrs, 0, length); for (int i = 0; i < oldtotalReplicaNum; i++) { diff --git a/source/libs/sync/src/syncMessage.c b/source/libs/sync/src/syncMessage.c index 1c67c12a98..e4caf69845 100644 --- a/source/libs/sync/src/syncMessage.c +++ b/source/libs/sync/src/syncMessage.c @@ -25,7 +25,7 @@ int32_t syncBuildTimeout(SRpcMsg* pMsg, ESyncTimeoutType timeoutType, uint64_t l pMsg->msgType = (timeoutType == SYNC_TIMEOUT_ELECTION) ? TDMT_SYNC_TIMEOUT_ELECTION : TDMT_SYNC_TIMEOUT; pMsg->contLen = bytes; if (pMsg->pCont == NULL) { - return terrno = TSDB_CODE_OUT_OF_MEMORY; + return terrno; } SyncTimeout* pTimeout = pMsg->pCont; @@ -45,7 +45,7 @@ int32_t syncBuildClientRequest(SRpcMsg* pMsg, const SRpcMsg* pOriginal, uint64_t pMsg->pCont = rpcMallocCont(bytes); if (pMsg->pCont == NULL) { - return terrno = TSDB_CODE_OUT_OF_MEMORY; + return terrno; } pMsg->msgType = TDMT_SYNC_CLIENT_REQUEST; pMsg->contLen = bytes; @@ -69,7 +69,7 @@ int32_t syncBuildClientRequestFromNoopEntry(SRpcMsg* pMsg, const SSyncRaftEntry* pMsg->msgType = TDMT_SYNC_CLIENT_REQUEST; pMsg->contLen = bytes; if (pMsg->pCont == NULL) { - return terrno = TSDB_CODE_OUT_OF_MEMORY; + return terrno; } SyncClientRequest* pClientRequest = pMsg->pCont; @@ -89,7 +89,7 @@ int32_t syncBuildRequestVote(SRpcMsg* pMsg, int32_t vgId) { pMsg->msgType = TDMT_SYNC_REQUEST_VOTE; pMsg->contLen = bytes; if (pMsg->pCont == NULL) { - return terrno = TSDB_CODE_OUT_OF_MEMORY; + return terrno; } SyncRequestVote* pRequestVote = pMsg->pCont; @@ -105,7 +105,7 @@ int32_t syncBuildRequestVoteReply(SRpcMsg* pMsg, int32_t vgId) { pMsg->msgType = TDMT_SYNC_REQUEST_VOTE_REPLY; pMsg->contLen = bytes; if (pMsg->pCont == NULL) { - return terrno = TSDB_CODE_OUT_OF_MEMORY; + return terrno; } SyncRequestVoteReply* pRequestVoteReply = pMsg->pCont; @@ -121,7 +121,7 @@ int32_t syncBuildAppendEntries(SRpcMsg* pMsg, int32_t dataLen, int32_t vgId) { pMsg->msgType = TDMT_SYNC_APPEND_ENTRIES; pMsg->contLen = bytes; if (pMsg->pCont == NULL) { - return terrno = TSDB_CODE_OUT_OF_MEMORY; + return terrno; } SyncAppendEntries* pAppendEntries = pMsg->pCont; @@ -138,7 +138,7 @@ int32_t syncBuildAppendEntriesReply(SRpcMsg* pMsg, int32_t vgId) { pMsg->msgType = TDMT_SYNC_APPEND_ENTRIES_REPLY; pMsg->contLen = bytes; if (pMsg->pCont == NULL) { - return terrno = TSDB_CODE_OUT_OF_MEMORY; + return terrno; } SyncAppendEntriesReply* pAppendEntriesReply = pMsg->pCont; @@ -155,7 +155,7 @@ int32_t syncBuildAppendEntriesFromRaftEntry(SSyncNode* pNode, SSyncRaftEntry* pE pRpcMsg->contLen = bytes; pRpcMsg->pCont = rpcMallocCont(pRpcMsg->contLen); if (pRpcMsg->pCont == NULL) { - return terrno = TSDB_CODE_OUT_OF_MEMORY; + return terrno; } SyncAppendEntries* pMsg = pRpcMsg->pCont; @@ -181,7 +181,7 @@ int32_t syncBuildHeartbeat(SRpcMsg* pMsg, int32_t vgId) { pMsg->msgType = TDMT_SYNC_HEARTBEAT; pMsg->contLen = bytes; if (pMsg->pCont == NULL) { - return terrno = TSDB_CODE_OUT_OF_MEMORY; + return terrno; } SyncHeartbeat* pHeartbeat = pMsg->pCont; @@ -197,7 +197,7 @@ int32_t syncBuildHeartbeatReply(SRpcMsg* pMsg, int32_t vgId) { pMsg->msgType = TDMT_SYNC_HEARTBEAT_REPLY; pMsg->contLen = bytes; if (pMsg->pCont == NULL) { - return terrno = TSDB_CODE_OUT_OF_MEMORY; + return terrno; } SyncHeartbeatReply* pHeartbeatReply = pMsg->pCont; @@ -213,7 +213,7 @@ int32_t syncBuildSnapshotSend(SRpcMsg* pMsg, int32_t dataLen, int32_t vgId) { pMsg->msgType = TDMT_SYNC_SNAPSHOT_SEND; pMsg->contLen = bytes; if (pMsg->pCont == NULL) { - return terrno = TSDB_CODE_OUT_OF_MEMORY; + return terrno; } SyncSnapshotSend* pSnapshotSend = pMsg->pCont; @@ -230,7 +230,7 @@ int32_t syncBuildSnapshotSendRsp(SRpcMsg* pMsg, int32_t dataLen, int32_t vgId) { pMsg->msgType = TDMT_SYNC_SNAPSHOT_RSP; pMsg->contLen = bytes; if (pMsg->pCont == NULL) { - return terrno = TSDB_CODE_OUT_OF_MEMORY; + return terrno; } SyncSnapshotRsp* pPreSnapshotRsp = pMsg->pCont; @@ -246,7 +246,7 @@ int32_t syncBuildLeaderTransfer(SRpcMsg* pMsg, int32_t vgId) { pMsg->msgType = TDMT_SYNC_LEADER_TRANSFER; pMsg->contLen = bytes; if (pMsg->pCont == NULL) { - return terrno = TSDB_CODE_OUT_OF_MEMORY; + return terrno; } SyncLeaderTransfer* pLeaderTransfer = pMsg->pCont; @@ -262,7 +262,7 @@ int32_t syncBuildLocalCmd(SRpcMsg* pMsg, int32_t vgId) { pMsg->msgType = TDMT_SYNC_LOCAL_CMD; pMsg->contLen = bytes; if (pMsg->pCont == NULL) { - return terrno = TSDB_CODE_OUT_OF_MEMORY; + return terrno; } SyncLocalCmd* pLocalCmd = pMsg->pCont; diff --git a/source/libs/sync/src/syncPipeline.c b/source/libs/sync/src/syncPipeline.c index 347fd0cf00..de83c51211 100644 --- a/source/libs/sync/src/syncPipeline.c +++ b/source/libs/sync/src/syncPipeline.c @@ -1304,7 +1304,7 @@ int32_t syncNodeLogReplInit(SSyncNode* pNode) { if (pNode->logReplMgrs[i] != NULL) return TSDB_CODE_SYN_INTERNAL_ERROR; pNode->logReplMgrs[i] = syncLogReplCreate(); if (pNode->logReplMgrs[i] == NULL) { - TAOS_RETURN(TSDB_CODE_OUT_OF_MEMORY); + TAOS_RETURN(terrno); } pNode->logReplMgrs[i]->peerId = i; } diff --git a/source/libs/sync/src/syncRaftCfg.c b/source/libs/sync/src/syncRaftCfg.c index e8ed73b089..bccd76b243 100644 --- a/source/libs/sync/src/syncRaftCfg.c +++ b/source/libs/sync/src/syncRaftCfg.c @@ -49,7 +49,7 @@ static int32_t syncEncodeSyncCfg(const void *pObj, SJson *pJson) { SJson *nodeInfo = tjsonCreateArray(); if (nodeInfo == NULL) { - TAOS_CHECK_EXIT(TSDB_CODE_OUT_OF_MEMORY); + TAOS_CHECK_EXIT(terrno); } if ((code = tjsonAddItemToObject(pJson, "nodeInfo", nodeInfo)) < 0) { @@ -60,7 +60,7 @@ static int32_t syncEncodeSyncCfg(const void *pObj, SJson *pJson) { for (int32_t i = 0; i < pCfg->totalReplicaNum; ++i) { SJson *info = tjsonCreateObject(); if (info == NULL) { - TAOS_CHECK_EXIT(TSDB_CODE_OUT_OF_MEMORY); + TAOS_CHECK_EXIT(terrno); } TAOS_CHECK_GOTO(tjsonAddDoubleToObject(info, "nodePort", pCfg->nodeInfo[i].nodePort), NULL, _err); TAOS_CHECK_GOTO(tjsonAddStringToObject(info, "nodeFqdn", pCfg->nodeInfo[i].nodeFqdn), NULL, _err); @@ -97,7 +97,7 @@ static int32_t syncEncodeRaftCfg(const void *pObj, SJson *pJson) { SJson *configIndexArr = tjsonCreateArray(); if (configIndexArr == NULL) { - TAOS_CHECK_EXIT(TSDB_CODE_OUT_OF_MEMORY); + TAOS_CHECK_EXIT(terrno); } if ((code = tjsonAddItemToObject(pJson, "configIndexArr", configIndexArr)) < 0) { @@ -108,7 +108,7 @@ static int32_t syncEncodeRaftCfg(const void *pObj, SJson *pJson) { for (int32_t i = 0; i < pCfg->configIndexCount; ++i) { SJson *configIndex = tjsonCreateObject(); if (configIndex == NULL) { - TAOS_CHECK_EXIT(TSDB_CODE_OUT_OF_MEMORY); + TAOS_CHECK_EXIT(terrno); } TAOS_CHECK_EXIT(tjsonAddIntegerToObject(configIndex, "index", pCfg->configIndexArr[i])); TAOS_CHECK_EXIT(tjsonAddItemToArray(configIndexArr, configIndex)); @@ -139,13 +139,13 @@ int32_t syncWriteCfgFile(SSyncNode *pNode) { (void)snprintf(file, sizeof(file), "%s.bak", realfile); if ((pJson = tjsonCreateObject()) == NULL) { - TAOS_CHECK_EXIT(TSDB_CODE_OUT_OF_MEMORY); + TAOS_CHECK_EXIT(terrno); } TAOS_CHECK_EXIT(tjsonAddObject(pJson, "RaftCfg", syncEncodeRaftCfg, pCfg)); buffer = tjsonToString(pJson); if (buffer == NULL) { - TAOS_CHECK_EXIT(TSDB_CODE_OUT_OF_MEMORY); + TAOS_CHECK_EXIT(terrno); } pFile = taosOpenFile(file, TD_FILE_CREATE | TD_FILE_WRITE | TD_FILE_TRUNC | TD_FILE_WRITE_THROUGH); @@ -273,7 +273,7 @@ int32_t syncReadCfgFile(SSyncNode *pNode) { pData = taosMemoryMalloc(size + 1); if (pData == NULL) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; goto _OVER; } diff --git a/source/libs/sync/src/syncRaftEntry.c b/source/libs/sync/src/syncRaftEntry.c index 56a702a9d5..f4301fa167 100644 --- a/source/libs/sync/src/syncRaftEntry.c +++ b/source/libs/sync/src/syncRaftEntry.c @@ -107,7 +107,7 @@ int32_t syncEntry2OriginalRpc(const SSyncRaftEntry* pEntry, SRpcMsg* pRpcMsg) { pRpcMsg->contLen = (int32_t)(pEntry->dataLen); pRpcMsg->pCont = rpcMallocCont(pRpcMsg->contLen); if (pRpcMsg->pCont == NULL) { - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } memcpy(pRpcMsg->pCont, pEntry->data, pRpcMsg->contLen); diff --git a/source/libs/sync/src/syncRaftStore.c b/source/libs/sync/src/syncRaftStore.c index 3bb40286bc..60cef7b5c0 100644 --- a/source/libs/sync/src/syncRaftStore.c +++ b/source/libs/sync/src/syncRaftStore.c @@ -66,7 +66,7 @@ int32_t raftStoreReadFile(SSyncNode *pNode) { pData = taosMemoryMalloc(size + 1); if (pData == NULL) { - TAOS_CHECK_GOTO(TSDB_CODE_OUT_OF_MEMORY, &lino, _OVER); + TAOS_CHECK_GOTO(terrno, &lino, _OVER); } if (taosReadFile(pFile, pData, size) != size) { @@ -120,11 +120,11 @@ int32_t raftStoreWriteFile(SSyncNode *pNode) { snprintf(file, sizeof(file), "%s.bak", realfile); pJson = tjsonCreateObject(); - if (pJson == NULL) TAOS_CHECK_GOTO(TSDB_CODE_OUT_OF_MEMORY, &lino, _OVER); + if (pJson == NULL) TAOS_CHECK_GOTO(terrno, &lino, _OVER); if (raftStoreEncode(pJson, pStore) != 0) TAOS_CHECK_GOTO(TSDB_CODE_OUT_OF_MEMORY, &lino, _OVER); buffer = tjsonToString(pJson); - if (buffer == NULL) TAOS_CHECK_GOTO(TSDB_CODE_OUT_OF_MEMORY, &lino, _OVER); + if (buffer == NULL) TAOS_CHECK_GOTO(terrno, &lino, _OVER); pFile = taosOpenFile(file, TD_FILE_CREATE | TD_FILE_WRITE | TD_FILE_TRUNC | TD_FILE_WRITE_THROUGH); if (pFile == NULL) TAOS_CHECK_GOTO(terrno, &lino, _OVER); diff --git a/source/libs/sync/src/syncRespMgr.c b/source/libs/sync/src/syncRespMgr.c index 46773af654..59825ef91e 100644 --- a/source/libs/sync/src/syncRespMgr.c +++ b/source/libs/sync/src/syncRespMgr.c @@ -32,7 +32,7 @@ int32_t syncRespMgrCreate(void *data, int64_t ttl, SSyncRespMgr **ppObj) { taosHashInit(sizeof(uint64_t), taosGetDefaultHashFunction(TSDB_DATA_TYPE_BINARY), true, HASH_NO_LOCK); if (pObj->pRespHash == NULL) { taosMemoryFree(pObj); - TAOS_RETURN(TSDB_CODE_OUT_OF_MEMORY); + TAOS_RETURN(terrno); } pObj->ttl = ttl; @@ -132,7 +132,7 @@ static int32_t syncRespCleanByTTL(SSyncRespMgr *pObj, int64_t ttl, bool rsp) { SArray *delIndexArray = taosArrayInit(4, sizeof(uint64_t)); if (delIndexArray == NULL) { - TAOS_RETURN(TSDB_CODE_OUT_OF_MEMORY); + TAOS_RETURN(terrno); } sDebug("vgId:%d, resp manager begin clean by ttl", pNode->vgId); diff --git a/source/libs/sync/src/syncSnapshot.c b/source/libs/sync/src/syncSnapshot.c index 48673b36fb..78fda6b093 100644 --- a/source/libs/sync/src/syncSnapshot.c +++ b/source/libs/sync/src/syncSnapshot.c @@ -720,7 +720,7 @@ static int32_t syncSnapReceiverExchgSnapInfo(SSyncNode *pSyncNode, SSyncSnapshot SSnapshotParam *pParam = &pReceiver->snapshotParam; data = taosMemoryRealloc(pParam->data, dataLen); if (data == NULL) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; sError("vgId:%d, failed to realloc memory for snapshot prep due to %s. dataLen:%d", pSyncNode->vgId, tstrerror(code), dataLen); goto _exit; @@ -1094,7 +1094,7 @@ static int32_t syncSnapSenderExchgSnapInfo(SSyncNode *pSyncNode, SSyncSnapshotSe SSnapshotParam *pParam = &pSender->snapshotParam; void *data = taosMemoryRealloc(pParam->data, dataLen); if (data == NULL) { - TAOS_RETURN(TSDB_CODE_OUT_OF_MEMORY); + TAOS_RETURN(terrno); } (void)memcpy(data, pMsg->data, dataLen); diff --git a/source/libs/sync/src/syncUtil.c b/source/libs/sync/src/syncUtil.c index 553560f089..6f7ea9375c 100644 --- a/source/libs/sync/src/syncUtil.c +++ b/source/libs/sync/src/syncUtil.c @@ -499,7 +499,7 @@ void syncLogSendRequestVoteReply(SSyncNode* pSyncNode, const SyncRequestVoteRepl int32_t syncSnapInfoDataRealloc(SSnapshot* pSnap, int32_t size) { void* data = taosMemoryRealloc(pSnap->data, size); if (data == NULL) { - return terrno = TSDB_CODE_OUT_OF_MEMORY; + return terrno; } pSnap->data = data; return 0; diff --git a/source/libs/tdb/src/db/tdbBtree.c b/source/libs/tdb/src/db/tdbBtree.c index 7c342c0527..a7bce24aa4 100644 --- a/source/libs/tdb/src/db/tdbBtree.c +++ b/source/libs/tdb/src/db/tdbBtree.c @@ -79,7 +79,7 @@ int tdbBtreeOpen(int keyLen, int valLen, SPager *pPager, char const *tbname, SPg pBt = (SBTree *)tdbOsCalloc(1, sizeof(*pBt)); if (pBt == NULL) { - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } // pBt->keyLen diff --git a/source/libs/tdb/src/db/tdbPCache.c b/source/libs/tdb/src/db/tdbPCache.c index 53c1284faa..6fcc8deb12 100644 --- a/source/libs/tdb/src/db/tdbPCache.c +++ b/source/libs/tdb/src/db/tdbPCache.c @@ -58,14 +58,14 @@ int tdbPCacheOpen(int pageSize, int cacheSize, SPCache **ppCache) { pCache = (SPCache *)tdbOsCalloc(1, sizeof(*pCache) + sizeof(SPage *) * cacheSize); if (pCache == NULL) { - TSDB_CHECK_CODE(code = TSDB_CODE_OUT_OF_MEMORY, lino, _exit); + TSDB_CHECK_CODE(code = terrno, lino, _exit); } pCache->szPage = pageSize; pCache->nPages = cacheSize; pCache->aPage = (SPage **)tdbOsCalloc(cacheSize, sizeof(SPage *)); if (pCache->aPage == NULL) { - TSDB_CHECK_CODE(code = TSDB_CODE_OUT_OF_MEMORY, lino, _exit); + TSDB_CHECK_CODE(code = terrno, lino, _exit); } code = tdbPCacheOpenImpl(pCache); @@ -105,7 +105,7 @@ static int tdbPCacheAlterImpl(SPCache *pCache, int32_t nPage) { } else if (pCache->nPages < nPage) { SPage **aPage = tdbOsCalloc(nPage, sizeof(SPage *)); if (aPage == NULL) { - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } for (int32_t iPage = pCache->nPages; iPage < nPage; iPage++) { @@ -502,7 +502,7 @@ static int tdbPCacheOpenImpl(SPCache *pCache) { pCache->nHash = pCache->nPages < 8 ? 8 : pCache->nPages; pCache->pgHash = (SPage **)tdbOsCalloc(pCache->nHash, sizeof(SPage *)); if (pCache->pgHash == NULL) { - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } // Open LRU list diff --git a/source/libs/tdb/src/db/tdbPage.c b/source/libs/tdb/src/db/tdbPage.c index 7888a08bb3..abc7fb5858 100644 --- a/source/libs/tdb/src/db/tdbPage.c +++ b/source/libs/tdb/src/db/tdbPage.c @@ -322,7 +322,7 @@ int32_t tdbPageCopy(SPage *pFromPage, SPage *pToPage, int deepCopyOvfl) { pNewCell = (SCell *)tdbOsMalloc(szCell); if (pNewCell == NULL) { tdbError("tdb/page-copy: out of memory, size: %d", szCell); - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } memcpy(pNewCell, pFromPage->apOvfl[iOvfl], szCell); tdbTrace("tdbPage/copy/new ovfl cell: %p/%p/%p", pNewCell, pToPage, pFromPage); @@ -524,7 +524,7 @@ static int tdbPageDefragment(SPage *pPage) { SCellIdx *aCellIdx = (SCellIdx *)tdbOsMalloc(sizeof(SCellIdx) * nCell); if (aCellIdx == NULL) { - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } for (int32_t iCell = 0; iCell < nCell; iCell++) { aCellIdx[iCell].iCell = iCell; diff --git a/source/libs/tdb/src/db/tdbPager.c b/source/libs/tdb/src/db/tdbPager.c index 64b892692d..7d9e70cfaa 100644 --- a/source/libs/tdb/src/db/tdbPager.c +++ b/source/libs/tdb/src/db/tdbPager.c @@ -167,7 +167,7 @@ int tdbPagerOpen(SPCache *pCache, const char *fileName, SPager **ppPager) { + fsize + 8 + 1; /* jFileName */ pPtr = (uint8_t *)tdbOsCalloc(1, zsize); if (pPtr == NULL) { - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } pPager = (SPager *)pPtr; @@ -508,7 +508,7 @@ int tdbPagerAbort(SPager *pPager, TXN *pTxn) { u8 *pageBuf = tdbOsCalloc(1, pPager->pageSize); if (pageBuf == NULL) { - return terrno = TSDB_CODE_OUT_OF_MEMORY; + return terrno; } tdbDebug("pager/abort: %p, %d/%d, txnId:%" PRId64, pPager, pPager->dbOrigSize, pPager->dbFileSize, pTxn->txnId); @@ -741,7 +741,7 @@ int tdbPagerInsertFreePage(SPager *pPager, SPage *pPage, TXN *pTxn) { if (pPager->frps) { if (taosArrayPush(pPager->frps, &pgno) == NULL) { - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } pPage->pPager = NULL; return code; @@ -749,7 +749,7 @@ int tdbPagerInsertFreePage(SPager *pPager, SPage *pPage, TXN *pTxn) { pPager->frps = taosArrayInit(8, sizeof(SPgno)); if (pPager->frps == NULL) { - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } // memset(pPage->pData, 0, pPage->pageSize); tdbTrace("tdb/insert-free-page: tbc recycle page: %d.", pgno); @@ -1056,7 +1056,7 @@ static int tdbPagerRestore(SPager *pPager, const char *jFileName) { pageBuf = tdbOsCalloc(1, pPager->pageSize); if (pageBuf == NULL) { - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } tdbDebug("pager/restore: %p, %d/%d, txnId:%s", pPager, pPager->dbOrigSize, pPager->dbFileSize, jFileName); @@ -1141,7 +1141,7 @@ int tdbPagerRestoreJournals(SPager *pPager) { SArray *pTxnList = taosArrayInit(16, sizeof(int64_t)); if (pTxnList == NULL) { - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } while ((pDirEntry = tdbReadDir(pDir)) != NULL) { @@ -1150,7 +1150,7 @@ int tdbPagerRestoreJournals(SPager *pPager) { int64_t txnId = -1; (void)sscanf(name, TDB_MAINDB_NAME "-journal.%" PRId64, &txnId); if (taosArrayPush(pTxnList, &txnId) == NULL) { - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } } } diff --git a/source/libs/tdb/src/db/tdbTable.c b/source/libs/tdb/src/db/tdbTable.c index f62e211586..e7a25c7fee 100644 --- a/source/libs/tdb/src/db/tdbTable.c +++ b/source/libs/tdb/src/db/tdbTable.c @@ -41,7 +41,7 @@ int tdbTbOpen(const char *tbname, int keyLen, int valLen, tdb_cmpr_fn_t keyCmprF pTb = (TTB *)tdbOsCalloc(1, sizeof(*pTb)); if (pTb == NULL) { - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } // pTb->pEnv @@ -221,7 +221,7 @@ int tdbTbcOpen(TTB *pTb, TBC **ppTbc, TXN *pTxn) { *ppTbc = NULL; pTbc = (TBC *)tdbOsMalloc(sizeof(*pTbc)); if (pTbc == NULL) { - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } if ((ret = tdbBtcOpen(&pTbc->btc, pTb->pBt, pTxn)) != 0) { diff --git a/source/libs/tfs/src/tfs.c b/source/libs/tfs/src/tfs.c index 3ea45fbacd..a353bd7941 100644 --- a/source/libs/tfs/src/tfs.c +++ b/source/libs/tfs/src/tfs.c @@ -50,7 +50,7 @@ int32_t tfsOpen(SDiskCfg *pCfg, int32_t ndisk, STfs **ppTfs) { pTfs->hash = taosHashInit(TFS_MAX_DISKS * 2, taosGetDefaultHashFunction(TSDB_DATA_TYPE_BINARY), false, HASH_NO_LOCK); if (pTfs->hash == NULL) { - TAOS_CHECK_GOTO(TSDB_CODE_OUT_OF_MEMORY, &lino, _exit); + TAOS_CHECK_GOTO(terrno, &lino, _exit); } for (int32_t idisk = 0; idisk < ndisk; idisk++) { @@ -284,7 +284,7 @@ int32_t tfsMkdirRecurAt(STfs *pTfs, const char *rname, SDiskID diskId) { if (errno == ENOENT) { // Try to create upper if ((s = taosStrdup(rname)) == NULL) { - TAOS_CHECK_GOTO(TSDB_CODE_OUT_OF_MEMORY, &lino, _exit); + TAOS_CHECK_GOTO(terrno, &lino, _exit); } // Make a copy of dirname(s) because the implementation of 'dirname' differs on different platforms. @@ -693,7 +693,7 @@ static STfsDisk *tfsNextDisk(STfs *pTfs, SDiskIter *pIter) { int32_t tfsGetMonitorInfo(STfs *pTfs, SMonDiskInfo *pInfo) { pInfo->datadirs = taosArrayInit(32, sizeof(SMonDiskDesc)); if (pInfo->datadirs == NULL) { - TAOS_RETURN(TSDB_CODE_OUT_OF_MEMORY); + TAOS_RETURN(terrno); } tfsUpdateSize(pTfs); @@ -711,7 +711,7 @@ int32_t tfsGetMonitorInfo(STfs *pTfs, SMonDiskInfo *pInfo) { TAOS_UNUSED(tfsUnLock(pTfs)); taosArrayDestroy(pInfo->datadirs); pInfo->datadirs = NULL; - TAOS_RETURN(TSDB_CODE_OUT_OF_MEMORY); + TAOS_RETURN(terrno); } } } diff --git a/source/libs/tfs/src/tfsDisk.c b/source/libs/tfs/src/tfsDisk.c index 6041f68f6f..14dd7f5b07 100644 --- a/source/libs/tfs/src/tfsDisk.c +++ b/source/libs/tfs/src/tfsDisk.c @@ -26,7 +26,7 @@ int32_t tfsNewDisk(int32_t level, int32_t id, int8_t disable, const char *path, } if ((pDisk->path = taosStrdup(path)) == NULL) { - TAOS_CHECK_GOTO(TSDB_CODE_OUT_OF_MEMORY, &lino, _exit); + TAOS_CHECK_GOTO(terrno, &lino, _exit); } pDisk->level = level; diff --git a/source/libs/transport/src/thttp.c b/source/libs/transport/src/thttp.c index d4c973926e..573b59e30c 100644 --- a/source/libs/transport/src/thttp.c +++ b/source/libs/transport/src/thttp.c @@ -154,7 +154,7 @@ static int32_t taosCompressHttpRport(char* pSrc, int32_t srcLen) { void* pDest = taosMemoryMalloc(destLen); if (pDest == NULL) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; goto _OVER; } @@ -258,7 +258,7 @@ static int32_t httpCreateMsg(const char* server, const char* uri, uint16_t port, SHttpMsg* msg = taosMemoryMalloc(sizeof(SHttpMsg)); if (msg == NULL) { *httpMsg = NULL; - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } msg->seq = seqNum; @@ -273,7 +273,7 @@ static int32_t httpCreateMsg(const char* server, const char* uri, uint16_t port, if (msg->server == NULL || msg->uri == NULL || msg->cont == NULL) { httpDestroyMsg(msg); *httpMsg = NULL; - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } memcpy(msg->cont, pCont, contLen); @@ -585,7 +585,7 @@ static void httpHandleReq(SHttpMsg* msg) { int32_t cap = 2048; header = taosMemoryCalloc(1, cap); if (header == NULL) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; goto END; } @@ -597,7 +597,7 @@ static void httpHandleReq(SHttpMsg* msg) { uv_buf_t* wb = taosMemoryCalloc(2, sizeof(uv_buf_t)); if (wb == NULL) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; goto END; } @@ -607,7 +607,7 @@ static void httpHandleReq(SHttpMsg* msg) { SHttpClient* cli = taosMemoryCalloc(1, sizeof(SHttpClient)); if (cli == NULL) { taosMemoryFree(wb); - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; goto END; } cli->seq = msg->seq; @@ -784,13 +784,13 @@ int64_t transInitHttpChanImpl() { http->connStatusTable = taosHashInit(4, taosGetDefaultHashFunction(TSDB_DATA_TYPE_BINARY), true, HASH_ENTRY_LOCK); if (http->connStatusTable == NULL) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; goto _ERROR; } http->loop = taosMemoryMalloc(sizeof(uv_loop_t)); if (http->loop == NULL) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; goto _ERROR; } diff --git a/source/libs/transport/src/trans.c b/source/libs/transport/src/trans.c index bebbcb68d6..08fa25db08 100644 --- a/source/libs/transport/src/trans.c +++ b/source/libs/transport/src/trans.c @@ -40,7 +40,7 @@ void* rpcOpen(const SRpcInit* pInit) { SRpcInfo* pRpc = taosMemoryCalloc(1, sizeof(SRpcInfo)); if (pRpc == NULL) { - TAOS_CHECK_GOTO(TSDB_CODE_OUT_OF_MEMORY, NULL, _end); + TAOS_CHECK_GOTO(terrno, NULL, _end); } pRpc->startReadTimer = pInit->startReadTimer; diff --git a/source/libs/transport/src/transCli.c b/source/libs/transport/src/transCli.c index 25badedd2d..b4a998c88d 100644 --- a/source/libs/transport/src/transCli.c +++ b/source/libs/transport/src/transCli.c @@ -987,7 +987,7 @@ static int32_t cliCreateConn(SCliThrd* pThrd, SCliConn** pCliConn, char* ip, int // read/write stream handle conn->stream = (uv_stream_t*)taosMemoryMalloc(sizeof(uv_tcp_t)); if (conn->stream == NULL) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; TAOS_CHECK_GOTO(code, NULL, _failed); } @@ -1862,7 +1862,7 @@ static int32_t createBatchList(SCliBatchList** ppBatchList, char* key, char* ip, taosMemoryFree(pBatchList->dst); taosMemoryFree(pBatchList); tError("failed to create batch list, reason:%s", tstrerror(TSDB_CODE_OUT_OF_MEMORY)); - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } *ppBatchList = pBatchList; return 0; @@ -1975,7 +1975,7 @@ void* transInitClient(uint32_t ip, uint32_t port, char* label, int numOfThreads, int32_t code = 0; SCliObj* cli = taosMemoryCalloc(1, sizeof(SCliObj)); if (cli == NULL) { - TAOS_CHECK_GOTO(TSDB_CODE_OUT_OF_MEMORY, NULL, _err); + TAOS_CHECK_GOTO(terrno, NULL, _err); } STrans* pInst = pInstRef; @@ -1984,7 +1984,7 @@ void* transInitClient(uint32_t ip, uint32_t port, char* label, int numOfThreads, cli->pThreadObj = (SCliThrd**)taosMemoryCalloc(cli->numOfThreads, sizeof(SCliThrd*)); if (cli->pThreadObj == NULL) { - TAOS_CHECK_GOTO(TSDB_CODE_OUT_OF_MEMORY, NULL, _err); + TAOS_CHECK_GOTO(terrno, NULL, _err); } for (int i = 0; i < cli->numOfThreads; i++) { @@ -2114,12 +2114,12 @@ static int32_t createThrdObj(void* trans, SCliThrd** ppThrd) { pThrd->fqdn2ipCache = taosHashInit(8, taosGetDefaultHashFunction(TSDB_DATA_TYPE_BINARY), true, HASH_NO_LOCK); if (pThrd->fqdn2ipCache == NULL) { - TAOS_CHECK_GOTO(TSDB_CODE_OUT_OF_MEMORY, NULL, _end); + TAOS_CHECK_GOTO(terrno, NULL, _end); } pThrd->batchCache = taosHashInit(8, taosGetDefaultHashFunction(TSDB_DATA_TYPE_BINARY), true, HASH_NO_LOCK); if (pThrd->batchCache == NULL) { - TAOS_CHECK_GOTO(TSDB_CODE_OUT_OF_MEMORY, NULL, _end); + TAOS_CHECK_GOTO(terrno, NULL, _end); } pThrd->connHeapCache = taosHashInit(8, taosGetDefaultHashFunction(TSDB_DATA_TYPE_BINARY), true, HASH_NO_LOCK); diff --git a/source/libs/transport/src/transComm.c b/source/libs/transport/src/transComm.c index 78c2f07b76..cdd8eea12c 100644 --- a/source/libs/transport/src/transComm.c +++ b/source/libs/transport/src/transComm.c @@ -130,7 +130,7 @@ int32_t transClearBuffer(SConnBuffer* buf) { p->cap = BUFFER_CAP; p->buf = taosMemoryRealloc(p->buf, BUFFER_CAP); if (p->buf == NULL) { - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } } p->left = -1; @@ -181,7 +181,7 @@ int32_t transResetBuffer(SConnBuffer* connBuf, int8_t resetBuf) { p->cap = BUFFER_CAP; p->buf = taosMemoryRealloc(p->buf, p->cap); if (p->buf == NULL) { - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } } } @@ -211,7 +211,7 @@ int32_t transAllocBuffer(SConnBuffer* connBuf, uv_buf_t* uvBuf) { if (p->buf == NULL) { uvBuf->base = NULL; uvBuf->len = 0; - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } uvBuf->base = p->buf + p->len; uvBuf->len = p->left; @@ -581,12 +581,12 @@ int32_t transDQCreate(uv_loop_t* loop, SDelayQueue** queue) { heap = heapCreate(timeCompare); if (heap == NULL) { - TAOS_CHECK_GOTO(TSDB_CODE_OUT_OF_MEMORY, NULL, _return1); + TAOS_CHECK_GOTO(terrno, NULL, _return1); } q = taosMemoryCalloc(1, sizeof(SDelayQueue)); if (q == NULL) { - TAOS_CHECK_GOTO(TSDB_CODE_OUT_OF_MEMORY, NULL, _return1); + TAOS_CHECK_GOTO(terrno, NULL, _return1); } q->heap = heap; q->timer = timer; diff --git a/source/libs/transport/src/transSvr.c b/source/libs/transport/src/transSvr.c index 31da79ada8..f14d136ac8 100644 --- a/source/libs/transport/src/transSvr.c +++ b/source/libs/transport/src/transSvr.c @@ -714,7 +714,7 @@ static int uvPrepareSendData(SSvrRespMsg* smsg, uv_buf_t* wb) { if (pMsg->pCont == 0) { pMsg->pCont = (void*)rpcMallocCont(0); if (pMsg->pCont == NULL) { - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } pMsg->contLen = 0; } @@ -1121,7 +1121,7 @@ static int32_t addHandleToWorkloop(SWorkThrd* pThrd, char* pipeName) { int32_t code = 0; pThrd->loop = (uv_loop_t*)taosMemoryMalloc(sizeof(uv_loop_t)); if (pThrd->loop == NULL) { - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } if ((code = uv_loop_init(pThrd->loop)) != 0) { @@ -1429,7 +1429,7 @@ void* transInitServer(uint32_t ip, uint32_t port, char* label, int numOfThreads, SServerObj* srv = taosMemoryCalloc(1, sizeof(SServerObj)); if (srv == NULL) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; tError("failed to init server since: %s", tstrerror(code)); return NULL; } @@ -1443,7 +1443,7 @@ void* transInitServer(uint32_t ip, uint32_t port, char* label, int numOfThreads, srv->pThreadObj = (SWorkThrd**)taosMemoryCalloc(srv->numOfThreads, sizeof(SWorkThrd*)); srv->pipe = (uv_pipe_t**)taosMemoryCalloc(srv->numOfThreads, sizeof(uv_pipe_t*)); if (srv->loop == NULL || srv->pThreadObj == NULL || srv->pipe == NULL) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; goto End; } @@ -1494,7 +1494,7 @@ void* transInitServer(uint32_t ip, uint32_t port, char* label, int numOfThreads, thrd->pWhiteList = uvWhiteListCreate(); if (thrd->pWhiteList == NULL) { destroyWorkThrdObj(thrd); - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; goto End; } thrd->connRefMgt = transOpenRefMgt(50000, transDestroyExHandle); @@ -1506,7 +1506,7 @@ void* transInitServer(uint32_t ip, uint32_t port, char* label, int numOfThreads, srv->pipe[i] = (uv_pipe_t*)taosMemoryCalloc(2, sizeof(uv_pipe_t)); if (srv->pipe[i] == NULL) { destroyWorkThrdObj(thrd); - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; goto End; } @@ -1532,7 +1532,7 @@ void* transInitServer(uint32_t ip, uint32_t port, char* label, int numOfThreads, for (int i = 0; i < srv->numOfThreads; i++) { SWorkThrd* thrd = (SWorkThrd*)taosMemoryCalloc(1, sizeof(SWorkThrd)); if (thrd == NULL) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; goto End; } @@ -1542,7 +1542,7 @@ void* transInitServer(uint32_t ip, uint32_t port, char* label, int numOfThreads, thrd->pWhiteList = uvWhiteListCreate(); if (thrd->pWhiteList == NULL) { destroyWorkThrdObj(thrd); - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; goto End; } @@ -1554,7 +1554,7 @@ void* transInitServer(uint32_t ip, uint32_t port, char* label, int numOfThreads, srv->pipe[i] = (uv_pipe_t*)taosMemoryCalloc(2, sizeof(uv_pipe_t)); if (srv->pipe[i] == NULL) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; goto End; } @@ -1699,7 +1699,7 @@ void uvHandleUpdate(SSvrRespMsg* msg, SWorkThrd* thrd) { SIpWhiteList* pList = taosMemoryCalloc(1, sz + sizeof(SIpWhiteList)); if (pList == NULL) { tError("failed to create ip-white-list since %s", tstrerror(code)); - code = TSDB_CODE_OUT_OF_MEMORY; + code = terrno; break; } pList->num = pUser->numOfRange; diff --git a/source/libs/wal/src/walMeta.c b/source/libs/wal/src/walMeta.c index 0dd55aacdb..08188af38c 100644 --- a/source/libs/wal/src/walMeta.c +++ b/source/libs/wal/src/walMeta.c @@ -99,7 +99,7 @@ static FORCE_INLINE int32_t walScanLogGetLastVer(SWal* pWal, int32_t fileIdx, in ptr = taosMemoryRealloc(buf, capacity); if (ptr == NULL) { - TAOS_CHECK_GOTO(TSDB_CODE_OUT_OF_MEMORY, &lino, _err); + TAOS_CHECK_GOTO(terrno, &lino, _err); } buf = ptr; @@ -163,7 +163,7 @@ static FORCE_INLINE int32_t walScanLogGetLastVer(SWal* pWal, int32_t fileIdx, in capacity += extraSize; void* ptr = taosMemoryRealloc(buf, capacity); if (ptr == NULL) { - TAOS_CHECK_GOTO(TSDB_CODE_OUT_OF_MEMORY, &lino, _err); + TAOS_CHECK_GOTO(terrno, &lino, _err); } buf = ptr; } @@ -270,7 +270,7 @@ static int32_t walRebuildFileInfoSet(SArray* metaLogList, SArray* actualLogList) for (int i = 0; i < actualFileNum; i++) { SWalFileInfo* pFileInfo = taosArrayGet(actualLogList, i); if (NULL == taosArrayPush(metaLogList, pFileInfo)) { - TAOS_RETURN(TSDB_CODE_OUT_OF_MEMORY); + TAOS_RETURN(terrno); } } @@ -728,7 +728,7 @@ int32_t walRollFileInfo(SWal* pWal) { // TODO: change to emplace back SWalFileInfo* pNewInfo = taosMemoryMalloc(sizeof(SWalFileInfo)); if (pNewInfo == NULL) { - TAOS_RETURN(TSDB_CODE_OUT_OF_MEMORY); + TAOS_RETURN(terrno); } pNewInfo->firstVer = pWal->vers.lastVer + 1; pNewInfo->lastVer = -1; @@ -738,7 +738,7 @@ int32_t walRollFileInfo(SWal* pWal) { pNewInfo->syncedOffset = 0; if (!taosArrayPush(pArray, pNewInfo)) { taosMemoryFree(pNewInfo); - TAOS_RETURN(TSDB_CODE_OUT_OF_MEMORY); + TAOS_RETURN(terrno); } taosMemoryFree(pNewInfo); @@ -1015,7 +1015,7 @@ int32_t walLoadMeta(SWal* pWal) { int size = (int)fileSize; char* buf = taosMemoryMalloc(size + 5); if (buf == NULL) { - TAOS_RETURN(TSDB_CODE_OUT_OF_MEMORY); + TAOS_RETURN(terrno); } (void)memset(buf, 0, size + 5); TdFilePtr pFile = taosOpenFile(fnameStr, TD_FILE_READ); diff --git a/source/libs/wal/src/walRead.c b/source/libs/wal/src/walRead.c index 321a47d678..9cf5bcbf09 100644 --- a/source/libs/wal/src/walRead.c +++ b/source/libs/wal/src/walRead.c @@ -212,7 +212,7 @@ static int32_t walReadSeekVerImpl(SWalReader *pReader, int64_t ver) { if (pRet == NULL) { wError("failed to allocate memory for localRet"); TAOS_UNUSED(taosThreadRwlockUnlock(&pWal->mutex)); - TAOS_RETURN(TSDB_CODE_OUT_OF_MEMORY); + TAOS_RETURN(terrno); } TAOS_MEMCPY(pRet, gloablPRet, sizeof(SWalFileInfo)); TAOS_UNUSED(taosThreadRwlockUnlock(&pWal->mutex)); @@ -341,7 +341,7 @@ int32_t walFetchBody(SWalReader *pRead) { if (pRead->capacity < cryptedBodyLen) { SWalCkHead *ptr = (SWalCkHead *)taosMemoryRealloc(pRead->pHead, sizeof(SWalCkHead) + cryptedBodyLen); if (ptr == NULL) { - TAOS_RETURN(TSDB_CODE_OUT_OF_MEMORY); + TAOS_RETURN(terrno); } pRead->pHead = ptr; pReadHead = &pRead->pHead->head; @@ -463,7 +463,7 @@ int32_t walReadVer(SWalReader *pReader, int64_t ver) { if (ptr == NULL) { TAOS_UNUSED(taosThreadMutexUnlock(&pReader->mutex)); - TAOS_RETURN(TSDB_CODE_OUT_OF_MEMORY); + TAOS_RETURN(terrno); } pReader->pHead = ptr; pReader->capacity = cryptedBodyLen; @@ -523,7 +523,7 @@ int32_t decryptBody(SWalCfg *cfg, SWalCkHead *pHead, int32_t plainBodyLen, const int32_t cryptedBodyLen = ENCRYPTED_LEN(plainBodyLen); char *newBody = taosMemoryMalloc(cryptedBodyLen); if (!newBody) { - TAOS_RETURN(TSDB_CODE_OUT_OF_MEMORY); + TAOS_RETURN(terrno); } SCryptOpts opts; diff --git a/source/util/src/tconfig.c b/source/util/src/tconfig.c index 6868e6d0eb..ee55243415 100644 --- a/source/util/src/tconfig.c +++ b/source/util/src/tconfig.c @@ -51,7 +51,7 @@ int32_t cfgInit(SConfig **ppCfg) { pCfg->array = taosArrayInit(32, sizeof(SConfigItem)); if (pCfg->array == NULL) { taosMemoryFree(pCfg); - TAOS_RETURN(TSDB_CODE_OUT_OF_MEMORY); + TAOS_RETURN(terrno); } TAOS_CHECK_RETURN(taosThreadMutexInit(&pCfg->lock, NULL)); @@ -127,7 +127,7 @@ static int32_t cfgCheckAndSetConf(SConfigItem *pItem, const char *conf) { pItem->str = taosStrdup(conf); if (pItem->str == NULL) { - TAOS_RETURN(TSDB_CODE_OUT_OF_MEMORY); + TAOS_RETURN(terrno); } TAOS_RETURN(TSDB_CODE_SUCCESS); @@ -144,7 +144,7 @@ static int32_t cfgCheckAndSetDir(SConfigItem *pItem, const char *inputDir) { taosMemoryFreeClear(pItem->str); pItem->str = taosStrdup(fullDir); if (pItem->str == NULL) { - TAOS_RETURN(TSDB_CODE_OUT_OF_MEMORY); + TAOS_RETURN(terrno); } TAOS_RETURN(TSDB_CODE_SUCCESS); @@ -211,7 +211,7 @@ static int32_t cfgSetString(SConfigItem *pItem, const char *value, ECfgSrcType s if (tmp == NULL) { uError("cfg:%s, type:%s src:%s value:%s failed to dup since %s", pItem->name, cfgDtypeStr(pItem->dtype), cfgStypeStr(stype), value, tstrerror(TSDB_CODE_OUT_OF_MEMORY)); - TAOS_RETURN(TSDB_CODE_OUT_OF_MEMORY); + TAOS_RETURN(terrno); } taosMemoryFreeClear(pItem->str); @@ -272,7 +272,7 @@ static int32_t cfgSetTfsItem(SConfig *pCfg, const char *name, const char *value, if (pItem->array == NULL) { (void)taosThreadMutexUnlock(&pCfg->lock); - TAOS_RETURN(TSDB_CODE_OUT_OF_MEMORY); + TAOS_RETURN(terrno); } } @@ -285,7 +285,7 @@ static int32_t cfgSetTfsItem(SConfig *pCfg, const char *name, const char *value, if (ret == NULL) { (void)taosThreadMutexUnlock(&pCfg->lock); - TAOS_RETURN(TSDB_CODE_OUT_OF_MEMORY); + TAOS_RETURN(terrno); } pItem->stype = stype; @@ -304,7 +304,7 @@ static int32_t cfgUpdateDebugFlagItem(SConfig *pCfg, const char *name, bool rese if (pDebugFlagItem->array == NULL) { pDebugFlagItem->array = taosArrayInit(16, sizeof(SLogVar)); if (pDebugFlagItem->array == NULL) { - TAOS_RETURN(TSDB_CODE_OUT_OF_MEMORY); + TAOS_RETURN(terrno); } } taosArrayClear(pDebugFlagItem->array); @@ -317,7 +317,7 @@ static int32_t cfgUpdateDebugFlagItem(SConfig *pCfg, const char *name, bool rese SLogVar logVar = {0}; (void)strncpy(logVar.name, name, TSDB_LOG_VAR_LEN - 1); if (NULL == taosArrayPush(pDebugFlagItem->array, &logVar)) { - TAOS_RETURN(TSDB_CODE_OUT_OF_MEMORY); + TAOS_RETURN(terrno); } } TAOS_RETURN(TSDB_CODE_SUCCESS); @@ -505,7 +505,7 @@ static int32_t cfgAddItem(SConfig *pCfg, SConfigItem *pItem, const char *name) { pItem->stype = CFG_STYPE_DEFAULT; pItem->name = taosStrdup(name); if (pItem->name == NULL) { - TAOS_RETURN(TSDB_CODE_OUT_OF_MEMORY); + TAOS_RETURN(terrno); } int32_t size = taosArrayGetSize(pCfg->array); @@ -527,7 +527,7 @@ static int32_t cfgAddItem(SConfig *pCfg, SConfigItem *pItem, const char *name) { } taosMemoryFree(pItem->name); - TAOS_RETURN(TSDB_CODE_OUT_OF_MEMORY); + TAOS_RETURN(terrno); } TAOS_RETURN(TSDB_CODE_SUCCESS); @@ -587,7 +587,7 @@ int32_t cfgAddString(SConfig *pCfg, const char *name, const char *defaultVal, in SConfigItem item = {.dtype = CFG_DTYPE_STRING, .scope = scope, .dynScope = dynScope}; item.str = taosStrdup(defaultVal); if (item.str == NULL) { - TAOS_RETURN(TSDB_CODE_OUT_OF_MEMORY); + TAOS_RETURN(terrno); } return cfgAddItem(pCfg, &item, name); } @@ -1309,7 +1309,7 @@ int32_t cfgLoadFromApollUrl(SConfig *pConfig, const char *url) { size_t itemValueStringLen = strlen(itemValueString); void *px = taosMemoryRealloc(cfgLineBuf, itemNameLen + itemValueStringLen + 3); if (NULL == px) { - TAOS_CHECK_EXIT(TSDB_CODE_OUT_OF_MEMORY); + TAOS_CHECK_EXIT(terrno); } cfgLineBuf = px; diff --git a/source/util/src/thash.c b/source/util/src/thash.c index 758e283bc3..2ef9d9e903 100644 --- a/source/util/src/thash.c +++ b/source/util/src/thash.c @@ -352,7 +352,7 @@ int32_t taosHashPut(SHashObj *pHashObj, const void *key, size_t keyLen, const vo // no data in hash table with the specified key, add it into hash table SHashNode *pNewNode = doCreateHashNode(key, keyLen, data, size, hashVal); if (pNewNode == NULL) { - terrno = TSDB_CODE_OUT_OF_MEMORY; + // terrno = TSDB_CODE_OUT_OF_MEMORY; code = terrno; goto _exit; } @@ -364,7 +364,7 @@ int32_t taosHashPut(SHashObj *pHashObj, const void *key, size_t keyLen, const vo if (pHashObj->enableUpdate) { SHashNode *pNewNode = doCreateHashNode(key, keyLen, data, size, hashVal); if (pNewNode == NULL) { - terrno = TSDB_CODE_OUT_OF_MEMORY; + // terrno = TSDB_CODE_OUT_OF_MEMORY; code = terrno; goto _exit; } diff --git a/source/util/src/tjson.c b/source/util/src/tjson.c index 4cf5917f7c..0f2504ff5e 100644 --- a/source/util/src/tjson.c +++ b/source/util/src/tjson.c @@ -131,7 +131,7 @@ int32_t tjsonAddArray(SJson* pJson, const char* pName, FToJson func, const void* if (num > 0) { SJson* pJsonArray = tjsonAddArrayToObject(pJson, pName); if (NULL == pJsonArray) { - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } for (size_t i = 0; i < num; ++i) { int32_t code = tjsonAddItem(pJsonArray, func, (const char*)pArray + itemSize * i); @@ -148,7 +148,7 @@ int32_t tjsonAddTArray(SJson* pJson, const char* pName, FToJson func, const SArr if (num > 0) { SJson* pJsonArray = tjsonAddArrayToObject(pJson, pName); if (NULL == pJsonArray) { - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } for (int32_t i = 0; i < num; ++i) { int32_t code = tjsonAddItem(pJsonArray, func, taosArrayGet(pArray, i)); @@ -343,7 +343,7 @@ int32_t tjsonToTArray(const SJson* pJson, const char* pName, FToObject func, SAr if (size > 0) { *pArray = taosArrayInit_s(itemSize, size); if (NULL == *pArray) { - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } for (int32_t i = 0; i < size; ++i) { int32_t code = func(tjsonGetArrayItem(jArray, i), taosArrayGet(*pArray, i)); diff --git a/source/util/src/tpagedbuf.c b/source/util/src/tpagedbuf.c index 46f2fdc647..25e10a17df 100644 --- a/source/util/src/tpagedbuf.c +++ b/source/util/src/tpagedbuf.c @@ -57,7 +57,7 @@ static int32_t createDiskFile(SDiskbasedBuf* pBuf) { taosGetTmpfilePath(pBuf->prefix, "paged-buf", path); pBuf->path = taosStrdup(path); if (pBuf->path == NULL) { - return TSDB_CODE_OUT_OF_MEMORY; + return terrno; } } diff --git a/source/util/src/tworker.c b/source/util/src/tworker.c index c2757dcabc..493d51e32a 100644 --- a/source/util/src/tworker.c +++ b/source/util/src/tworker.c @@ -803,11 +803,11 @@ int32_t tQueryAutoQWorkerInit(SQueryAutoQWorkerPool *pool) { code = taosOpenQset(&pool->qset); if (code) return terrno = code; pool->workers = tdListNew(sizeof(SQueryAutoQWorker)); - if (!pool->workers) return TSDB_CODE_OUT_OF_MEMORY; + if (!pool->workers) return terrno; pool->backupWorkers = tdListNew(sizeof(SQueryAutoQWorker)); - if (!pool->backupWorkers) return TSDB_CODE_OUT_OF_MEMORY; + if (!pool->backupWorkers) return terrno; pool->exitedWorkers = tdListNew(sizeof(SQueryAutoQWorker)); - if (!pool->exitedWorkers) return TSDB_CODE_OUT_OF_MEMORY; + if (!pool->exitedWorkers) return terrno; pool->maxInUse = pool->max * 2 + 2; if (!pool->pCb) { diff --git a/tests/system-test/0-others/information_schema.py b/tests/system-test/0-others/information_schema.py index b342bc7b0e..f59410b552 100644 --- a/tests/system-test/0-others/information_schema.py +++ b/tests/system-test/0-others/information_schema.py @@ -222,7 +222,7 @@ class TDTestCase: tdSql.query("select * from information_schema.ins_columns where db_name ='information_schema'") tdLog.info(len(tdSql.queryResult)) - tdSql.checkEqual(True, len(tdSql.queryResult) in range(271, 272)) + tdSql.checkEqual(True, len(tdSql.queryResult) in range(272, 273)) tdSql.query("select * from information_schema.ins_columns where db_name ='performance_schema'") tdSql.checkEqual(56, len(tdSql.queryResult)) diff --git a/tests/system-test/1-insert/drop.py b/tests/system-test/1-insert/drop.py index bd5e4cab49..7e41aad4a8 100644 --- a/tests/system-test/1-insert/drop.py +++ b/tests/system-test/1-insert/drop.py @@ -49,6 +49,11 @@ class TDTestCase: 'col12': 'binary(20)', 'col13': 'nchar(20)' } + self.db_names = [ f'dbtest_0', f'dbtest_1'] + self.stb_names = [ f'aa\u00bf\u200bstb0'] + self.ctb_names = [ f'ctb0', 'ctb1', f'aa\u00bf\u200bctb0', f'aa\u00bf\u200bctb1'] + self.ntb_names = [ f'ntb0', f'aa\u00bf\u200bntb0', f'ntb1', f'aa\u00bf\u200bntb1'] + self.vgroups_opt = f'vgroups 4' def insert_data(self,column_dict,tbname,row_num): insert_sql = self.setsql.set_insertsql(column_dict,tbname,self.binary_str,self.nchar_str) for i in range(row_num): @@ -116,6 +121,121 @@ class TDTestCase: tdSql.query(f'select * from {stbname} where {k} = {self.ts}') tdSql.checkRows(self.tbnum) tdSql.execute(f'drop database {self.dbname}') + def drop_table_check_init(self): + for db_name in self.db_names: + tdSql.execute(f'create database if not exists {db_name} {self.vgroups_opt}') + tdSql.execute(f'use {db_name}') + for stb_name in self.stb_names: + tdSql.execute(f'create table `{stb_name}` (ts timestamp,c0 int) tags(t0 int)') + for ctb_name in self.ctb_names: + tdSql.execute(f'create table `{ctb_name}` using `{stb_name}` tags(0)') + tdSql.execute(f'insert into `{ctb_name}` values (now,1)') + for ntb_name in self.ntb_names: + tdSql.execute(f'create table `{ntb_name}` (ts timestamp,c0 int)') + tdSql.execute(f'insert into `{ntb_name}` values (now,1)') + def drop_table_check_end(self): + for db_name in self.db_names: + tdSql.execute(f'drop database {db_name}') + def drop_stable_with_check(self): + self.drop_table_check_init() + tdSql.query(f'select * from information_schema.ins_stables where db_name like "dbtest_%"') + result = tdSql.queryResult + print(result) + tdSql.checkEqual(len(result),2) + i = 0 + for stb_result in result: + if i == 0: + dropTable = f'drop table with `{stb_result[1]}`.`{stb_result[10]}`,' + dropStable = f'drop stable with `{stb_result[1]}`.`{stb_result[10]}`,' + else: + dropTable += f'`{stb_result[1]}`.`{stb_result[10]}`,' + dropStable += f'`{stb_result[1]}`.`{stb_result[10]}`,' + tdLog.info(dropTable[:-1]) + tdLog.info(dropStable[:-1]) + tdSql.error(dropTable[:-1]) + tdSql.error(dropStable[:-1]) + i += 1 + i = 0 + for stb_result in result: + if i == 0: + tdSql.execute(f'drop table with `{stb_result[1]}`.`{stb_result[10]}`') + else: + tdSql.execute(f'drop stable with `{stb_result[1]}`.`{stb_result[10]}`') + i += 1 + for i in range(30): + tdSql.query(f'select * from information_schema.ins_stables where db_name like "dbtest_%"') + if(len(tdSql.queryResult) == 0): + break + tdLog.info(f'ins_stables not empty, sleep 1s') + time.sleep(1) + tdSql.query(f'select * from information_schema.ins_stables where db_name like "dbtest_%"') + tdSql.checkRows(0) + tdSql.query(f'select * from information_schema.ins_tables where db_name like "dbtest_%"') + tdSql.checkRows(8) + tdSql.error(f'drop stable with information_schema.`ins_tables`;') + tdSql.error(f'drop stable with performance_schema.`perf_connections`;') + self.drop_table_check_end() + def drop_table_with_check(self): + self.drop_table_check_init() + tdSql.query(f'select * from information_schema.ins_tables where db_name like "dbtest_%"') + result = tdSql.queryResult + print(result) + tdSql.checkEqual(len(result),16) + dropTable = f'drop table with ' + for tb_result in result: + dropTable += f'`{tb_result[1]}`.`{tb_result[5]}`,' + tdLog.info(dropTable[:-1]) + tdSql.execute(dropTable[:-1]) + for i in range(30): + tdSql.query(f'select * from information_schema.ins_tables where db_name like "dbtest_%"') + if(len(tdSql.queryResult) == 0): + break + tdLog.info(f'ins_tables not empty, sleep 1s') + time.sleep(1) + tdSql.query(f'select * from information_schema.ins_tables where db_name like "dbtest_%"') + tdSql.checkRows(0) + tdSql.query(f'select * from information_schema.ins_stables where db_name like "dbtest_%"') + tdSql.checkRows(2) + tdSql.error(f'drop table with information_schema.`ins_tables`;') + tdSql.error(f'drop table with performance_schema.`perf_connections`;') + self.drop_table_check_end() + def drop_table_with_check_tsma(self): + tdSql.execute(f'create database if not exists {self.dbname} {self.vgroups_opt}') + tdSql.execute(f'use {self.dbname}') + tdSql.execute(f'create table {self.dbname}.stb (ts timestamp,c0 int) tags(t0 int)') + tdSql.execute(f'create tsma stb_tsma on {self.dbname}.stb function(avg(c0),count(c0)) interval(1d)') + tdSql.execute(f'create table {self.dbname}.ctb using {self.dbname}.stb tags(0)') + tdSql.execute(f'insert into {self.dbname}.ctb values (now,1)') + tdSql.execute(f'create table {self.dbname}.ntb (ts timestamp,c0 int)') + tdSql.execute(f'create tsma ntb_tsma on {self.dbname}.ntb function(avg(c0),count(c0)) interval(1d)') + tdSql.execute(f'insert into {self.dbname}.ntb values (now,1)') + tdSql.query(f'select * from information_schema.ins_tsmas where db_name = "{self.dbname}"') + tdSql.checkRows(2) + tdSql.query(f'select * from information_schema.ins_tables where db_name = "{self.dbname}" and type="CHILD_TABLE"') + tdSql.checkRows(1) + tdSql.execute(f'drop table with {tdSql.queryResult[0][1]}.`{tdSql.queryResult[0][5]}`') + tdSql.query(f'select * from information_schema.ins_tables where db_name = "{self.dbname}" and type="CHILD_TABLE"') + tdSql.checkRows(0) + tdSql.query(f'select * from information_schema.ins_stables where db_name = "{self.dbname}"') + tdSql.checkRows(1) + tdSql.error(f'drop table with {tdSql.queryResult[0][1]}.`{tdSql.queryResult[0][10]}`') + tdSql.query(f'select * from information_schema.ins_stables where db_name = "{self.dbname}"') + tdSql.error(f'drop stable with {tdSql.queryResult[0][1]}.`{tdSql.queryResult[0][10]}`') + tdSql.query(f'select * from information_schema.ins_stables where db_name = "{self.dbname}"') + tdSql.checkRows(1) + tdSql.query(f'select * from information_schema.ins_tables where db_name = "{self.dbname}" and type="NORMAL_TABLE"') + tdSql.checkRows(1) + tdSql.execute(f'drop table with {tdSql.queryResult[0][1]}.`{tdSql.queryResult[0][5]}`') + tdSql.query(f'select * from information_schema.ins_tables where db_name = "{self.dbname}" and type="NORMAL_TABLE"') + tdSql.checkRows(0) + tdSql.query(f'select * from information_schema.ins_tsmas where db_name = "{self.dbname}"') + tsmas = tdSql.queryResult + tdSql.checkEqual(len(tsmas),2) + for tsma in tsmas: + tdSql.execute(f'drop tsma {tsma[1]}.{tsma[0]}') + tdSql.query(f'show tsmas') + tdSql.checkRows(0) + tdSql.execute(f'drop database {self.dbname}') def drop_topic_check(self): tdSql.execute(f'create database {self.dbname} replica {self.replicaVar} wal_retention_period 3600') tdSql.execute(f'use {self.dbname}') @@ -161,6 +281,9 @@ class TDTestCase: def run(self): self.drop_ntb_check() self.drop_stb_ctb_check() + self.drop_stable_with_check() + self.drop_table_with_check() + self.drop_table_with_check_tsma() self.drop_topic_check() if platform.system().lower() == 'windows': self.drop_stream_check()