diff --git a/docs/en/12-taos-sql/05-insert.md b/docs/en/12-taos-sql/05-insert.md index 462e7fc0ae..32227a2214 100644 --- a/docs/en/12-taos-sql/05-insert.md +++ b/docs/en/12-taos-sql/05-insert.md @@ -1,7 +1,7 @@ --- title: Insert sidebar_label: Insert -description: This document describes how to insert data into TDengine. +description: This document describes the SQL commands and syntax for inserting data into TDengine. --- ## Syntax diff --git a/docs/en/12-taos-sql/13-tmq.md b/docs/en/12-taos-sql/13-tmq.md index d14b6da2d3..16dc9efd62 100644 --- a/docs/en/12-taos-sql/13-tmq.md +++ b/docs/en/12-taos-sql/13-tmq.md @@ -1,5 +1,5 @@ --- -title: Data Subscription +title: Data Subscription SQL Reference sidebar_label: Data Subscription description: This document describes the SQL statements related to the data subscription component of TDengine. --- diff --git a/docs/en/12-taos-sql/14-stream.md b/docs/en/12-taos-sql/14-stream.md index e1bf18c854..c41839390f 100644 --- a/docs/en/12-taos-sql/14-stream.md +++ b/docs/en/12-taos-sql/14-stream.md @@ -1,5 +1,5 @@ --- -title: Stream Processing +title: Stream Processing SQL Reference sidebar_label: Stream Processing description: This document describes the SQL statements related to the stream processing component of TDengine. --- diff --git a/docs/en/12-taos-sql/26-udf.md b/docs/en/12-taos-sql/26-udf.md index f86b535927..dec9ca217d 100644 --- a/docs/en/12-taos-sql/26-udf.md +++ b/docs/en/12-taos-sql/26-udf.md @@ -1,5 +1,5 @@ --- -title: User-Defined Functions (UDF) +title: User-Defined Functions (UDF) SQL Reference sidebar_label: User-Defined Functions description: This document describes the SQL statements related to user-defined functions (UDF) in TDengine. --- diff --git a/docs/en/14-reference/07-tdinsight/index.md b/docs/en/14-reference/07-tdinsight/index.md index cada05d738..1bc983262e 100644 --- a/docs/en/14-reference/07-tdinsight/index.md +++ b/docs/en/14-reference/07-tdinsight/index.md @@ -1,5 +1,5 @@ --- -title: TDinsight - Grafana-based Zero-Dependency Monitoring Solution for TDengine +title: TDinsight sidebar_label: TDinsight description: This document describes TDinsight, a monitoring solution for TDengine. --- diff --git a/docs/en/25-application/01-telegraf.md b/docs/en/25-application/01-telegraf.md index a6db826fa3..f8784e9ab9 100644 --- a/docs/en/25-application/01-telegraf.md +++ b/docs/en/25-application/01-telegraf.md @@ -1,5 +1,5 @@ --- -title: Quickly Build IT DevOps Visualization System with TDengine + Telegraf + Grafana +title: IT Visualization with TDengine + Telegraf + Grafana sidebar_label: TDengine + Telegraf + Grafana description: This document describes how to create an IT visualization system by integrating TDengine with Telegraf and Grafana. --- diff --git a/docs/examples/rust/nativeexample/examples/query.rs b/docs/examples/rust/nativeexample/examples/query.rs new file mode 100644 index 0000000000..dfe55e8749 --- /dev/null +++ b/docs/examples/rust/nativeexample/examples/query.rs @@ -0,0 +1,66 @@ +use taos::*; + +#[tokio::main] +async fn main() -> anyhow::Result<()> { + let dsn = "taos://localhost:6030"; + let builder = TaosBuilder::from_dsn(dsn)?; + + let taos = builder.build()?; + + // ANCHOR: create_db_and_table + let db = "power"; + // create database + taos.exec_many([ + format!("DROP DATABASE IF EXISTS `{db}`"), + format!("CREATE DATABASE `{db}`"), + format!("USE `{db}`"), + ]) + .await?; + + // create table + taos.exec_many([ + // create super table + "CREATE TABLE `meters` (`ts` TIMESTAMP, `current` FLOAT, `voltage` INT, `phase` FLOAT) \ + TAGS (`groupid` INT, `location` BINARY(24))", + ]).await?; + // ANCHOR_END: create_db_and_table + + // ANCHOR: insert_data + let inserted = taos.exec("INSERT INTO " + + "power.d1001 USING power.meters TAGS(2,'California.SanFrancisco') " + + "VALUES " + + "(NOW + 1a, 10.30000, 219, 0.31000) " + + "(NOW + 2a, 12.60000, 218, 0.33000) " + + "(NOW + 3a, 12.30000, 221, 0.31000) " + + "power.d1002 USING power.meters TAGS(3, 'California.SanFrancisco') " + + "VALUES " + + "(NOW + 1a, 10.30000, 218, 0.25000) ").await?; + + println!("inserted: {} rows", inserted); + // ANCHOR_END: insert_data + + // ANCHOR: query_data + let mut result = taos.query("SELECT * FROM power.meters").await?; + + for field in result.fields() { + println!("got field: {}", field.name()); + } + + let mut rows = result.rows(); + let mut nrows = 0; + while let Some(row) = rows.try_next().await? { + for (col, (name, value)) in row.enumerate() { + println!( + "[{}] got value in col {} (named `{:>8}`): {}", + nrows, col, name, value + ); + } + nrows += 1; + } + // ANCHOR_END: query_data + + // ANCHOR: query_with_req_id + let result = taos.query_with_req_id("SELECT * FROM power.meters", 0).await?; + // ANCHOR_END: query_with_req_id + +} diff --git a/docs/examples/rust/nativeexample/examples/schemaless.rs b/docs/examples/rust/nativeexample/examples/schemaless.rs new file mode 100644 index 0000000000..44ce0fe694 --- /dev/null +++ b/docs/examples/rust/nativeexample/examples/schemaless.rs @@ -0,0 +1,80 @@ +use taos_query::common::SchemalessPrecision; +use taos_query::common::SchemalessProtocol; +use taos_query::common::SmlDataBuilder; + +use crate::AsyncQueryable; +use crate::AsyncTBuilder; +use crate::TaosBuilder; + +async fn put() -> anyhow::Result<()> { + std::env::set_var("RUST_LOG", "taos=debug"); + pretty_env_logger::init(); + let dsn = + std::env::var("TDENGINE_ClOUD_DSN").unwrap_or("http://localhost:6041".to_string()); + log::debug!("dsn: {:?}", &dsn); + + let client = TaosBuilder::from_dsn(dsn)?.build().await?; + + let db = "power"; + + client.exec(format!("drop database if exists {db}")).await?; + + client + .exec(format!("create database if not exists {db}")) + .await?; + + // should specify database before insert + client.exec(format!("use {db}")).await?; + + // SchemalessProtocol::Line + let data = [ + "meters,groupid=2,location=California.SanFrancisco current=10.3000002f64,voltage=219i32,phase=0.31f64 1626006833639000000", + ] + .map(String::from) + .to_vec(); + + let sml_data = SmlDataBuilder::default() + .protocol(SchemalessProtocol::Line) + .precision(SchemalessPrecision::Millisecond) + .data(data.clone()) + .ttl(1000) + .req_id(100u64) + .build()?; + assert_eq!(client.put(&sml_data).await?, ()); + + // SchemalessProtocol::Telnet + let data = [ + "meters.current 1648432611249 10.3 location=California.SanFrancisco group=2", + ] + .map(String::from) + .to_vec(); + + let sml_data = SmlDataBuilder::default() + .protocol(SchemalessProtocol::Telnet) + .precision(SchemalessPrecision::Millisecond) + .data(data.clone()) + .ttl(1000) + .req_id(200u64) + .build()?; + assert_eq!(client.put(&sml_data).await?, ()); + + // SchemalessProtocol::Json + let data = [ + r#"[{"metric": "meters.current", "timestamp": 1681345954000, "value": 10.3, "tags": {"location": "California.SanFrancisco", "groupid": 2}}, {"metric": "meters.voltage", "timestamp": 1648432611249, "value": 219, "tags": {"location": "California.LosAngeles", "groupid": 1}}, {"metric": "meters.current", "timestamp": 1648432611250, "value": 12.6, "tags": {"location": "California.SanFrancisco", "groupid": 2}}, {"metric": "meters.voltage", "timestamp": 1648432611250, "value": 221, "tags": {"location": "California.LosAngeles", "groupid": 1}}]"# + ] + .map(String::from) + .to_vec(); + + let sml_data = SmlDataBuilder::default() + .protocol(SchemalessProtocol::Json) + .precision(SchemalessPrecision::Millisecond) + .data(data.clone()) + .ttl(1000) + .req_id(300u64) + .build()?; + assert_eq!(client.put(&sml_data).await?, ()); + + client.exec(format!("drop database if exists {db}")).await?; + + Ok(()) +} diff --git a/docs/examples/rust/nativeexample/examples/stmt.rs b/docs/examples/rust/nativeexample/examples/stmt.rs new file mode 100644 index 0000000000..0194eccdf1 --- /dev/null +++ b/docs/examples/rust/nativeexample/examples/stmt.rs @@ -0,0 +1,37 @@ +use taos::*; + +#[tokio::main] +async fn main() -> anyhow::Result<()> { + let taos = TaosBuilder::from_dsn("taos://")?.build().await?; + + taos.exec("DROP DATABASE IF EXISTS power").await?; + taos.create_database("power").await?; + taos.use_database("power").await?; + taos.exec("CREATE STABLE IF NOT EXISTS meters (ts TIMESTAMP, current FLOAT, voltage INT, phase FLOAT) TAGS (location BINARY(64), groupId INT)").await?; + + let mut stmt = Stmt::init(&taos).await?; + stmt.prepare("INSERT INTO ? USING meters TAGS(?, ?) VALUES(?, ?, ?, ?)").await?; + + const NUM_TABLES: usize = 10; + const NUM_ROWS: usize = 10; + for i in 0..NUM_TABLES { + let table_name = format!("d{}", i); + let tags = vec![Value::VarChar("California.SanFransico".into()), Value::Int(2)]; + stmt.set_tbname_tags(&table_name, &tags).await?; + for j in 0..NUM_ROWS { + let values = vec![ + ColumnView::from_millis_timestamp(vec![1648432611249 + j as i64]), + ColumnView::from_floats(vec![10.3 + j as f32]), + ColumnView::from_ints(vec![219 + j as i32]), + ColumnView::from_floats(vec![0.31 + j as f32]), + ]; + stmt.bind(&values).await?; + } + stmt.add_batch().await?; + } + + // execute. + let rows = stmt.execute().await?; + assert_eq!(rows, NUM_TABLES * NUM_ROWS); + Ok(()) +} diff --git a/docs/examples/rust/nativeexample/examples/tmq.rs b/docs/examples/rust/nativeexample/examples/tmq.rs new file mode 100644 index 0000000000..764c0c1fc8 --- /dev/null +++ b/docs/examples/rust/nativeexample/examples/tmq.rs @@ -0,0 +1,166 @@ +use std::time::Duration; +use std::str::FromStr; + +use taos::*; + +#[tokio::main] +async fn main() -> anyhow::Result<()> { + pretty_env_logger::formatted_timed_builder() + .filter_level(log::LevelFilter::Info) + .init(); + use taos_query::prelude::*; + let dsn = "taos://localhost:6030".to_string(); + log::info!("dsn: {}", dsn); + let mut dsn = Dsn::from_str(&dsn)?; + + let taos = TaosBuilder::from_dsn(&dsn)?.build().await?; + + // prepare database and table + taos.exec_many([ + "drop topic if exists topic_meters", + "drop database if exists power", + "create database if not exists power WAL_RETENTION_PERIOD 86400", + "use power", + + "CREATE STABLE IF NOT EXISTS power.meters (ts TIMESTAMP, current FLOAT, voltage INT, phase FLOAT) TAGS (groupId INT, location BINARY(24))", + + "create table if not exists power.d001 using power.meters tags(1,'location')", + + ]) + .await?; + + taos.exec_many([ + "drop database if exists db2", + "create database if not exists db2 wal_retention_period 3600", + "use db2", + ]) + .await?; + + // ANCHOR: create_topic + taos.exec_many([ + "CREATE TOPIC IF NOT EXISTS topic_meters AS SELECT ts, current, voltage, phase, groupid, location FROM power.meters", + ]) + .await?; + // ANCHOR_END: create_topic + + // ANCHOR: create_consumer + dsn.params.insert("group.id".to_string(), "abc".to_string()); + dsn.params.insert("auto.offset.reset".to_string(), "earliest".to_string()); + + let builder = TmqBuilder::from_dsn(&dsn)?; + let mut consumer = builder.build().await?; + // ANCHOR_END: create_consumer + + // ANCHOR: subscribe + consumer.subscribe(["topic_meters"]).await?; + // ANCHOR_END: subscribe + + // ANCHOR: consume + { + let mut stream = consumer.stream_with_timeout(Timeout::from_secs(1)); + + while let Some((offset, message)) = stream.try_next().await? { + + let topic: &str = offset.topic(); + let database = offset.database(); + let vgroup_id = offset.vgroup_id(); + log::debug!( + "topic: {}, database: {}, vgroup_id: {}", + topic, + database, + vgroup_id + ); + + match message { + MessageSet::Meta(meta) => { + log::info!("Meta"); + let raw = meta.as_raw_meta().await?; + taos.write_raw_meta(&raw).await?; + + let json = meta.as_json_meta().await?; + let sql = json.to_string(); + if let Err(err) = taos.exec(sql).await { + println!("maybe error: {}", err); + } + } + MessageSet::Data(data) => { + log::info!("Data"); + while let Some(data) = data.fetch_raw_block().await? { + log::debug!("data: {:?}", data); + } + } + MessageSet::MetaData(meta, data) => { + log::info!("MetaData"); + let raw = meta.as_raw_meta().await?; + taos.write_raw_meta(&raw).await?; + + let json = meta.as_json_meta().await?; + let sql = json.to_string(); + if let Err(err) = taos.exec(sql).await { + println!("maybe error: {}", err); + } + + while let Some(data) = data.fetch_raw_block().await? { + log::debug!("data: {:?}", data); + } + } + } + consumer.commit(offset).await?; + } + } + // ANCHOR_END: consume + + // ANCHOR: assignments + let assignments = consumer.assignments().await.unwrap(); + log::info!("assignments: {:?}", assignments); + // ANCHOR_END: assignments + + // seek offset + for topic_vec_assignment in assignments { + let topic = &topic_vec_assignment.0; + let vec_assignment = topic_vec_assignment.1; + for assignment in vec_assignment { + let vgroup_id = assignment.vgroup_id(); + let current = assignment.current_offset(); + let begin = assignment.begin(); + let end = assignment.end(); + log::debug!( + "topic: {}, vgroup_id: {}, current offset: {} begin {}, end: {}", + topic, + vgroup_id, + current, + begin, + end + ); + // ANCHOR: seek_offset + let res = consumer.offset_seek(topic, vgroup_id, end).await; + if res.is_err() { + log::error!("seek offset error: {:?}", res); + let a = consumer.assignments().await.unwrap(); + log::error!("assignments: {:?}", a); + } + // ANCHOR_END: seek_offset + } + + let topic_assignment = consumer.topic_assignment(topic).await; + log::debug!("topic assignment: {:?}", topic_assignment); + } + + // after seek offset + let assignments = consumer.assignments().await.unwrap(); + log::info!("after seek offset assignments: {:?}", assignments); + + // ANCHOR: unsubscribe + consumer.unsubscribe().await; + // ANCHOR_END: unsubscribe + + tokio::time::sleep(Duration::from_secs(1)).await; + + taos.exec_many([ + "drop database db2", + "drop topic topic_meters", + "drop database power", + ]) + .await?; + Ok(()) +} diff --git a/include/common/tdatablock.h b/include/common/tdatablock.h index 290c90fde9..d13cc1405b 100644 --- a/include/common/tdatablock.h +++ b/include/common/tdatablock.h @@ -268,7 +268,7 @@ int32_t buildSubmitReqFromDataBlock(SSubmitReq2** pReq, const SSDataBlock* pData bool alreadyAddGroupId(char* ctbName); bool isAutoTableName(char* ctbName); -void buildCtbNameAddGroupId(char* ctbName, uint64_t groupId); +void buildCtbNameAddGroupId(const char* stbName, char* ctbName, uint64_t groupId); char* buildCtbNameByGroupId(const char* stbName, uint64_t groupId); int32_t buildCtbNameByGroupIdImpl(const char* stbName, uint64_t groupId, char* pBuf); diff --git a/include/libs/stream/tstream.h b/include/libs/stream/tstream.h index 5f3761d7b7..e7c6491b9d 100644 --- a/include/libs/stream/tstream.h +++ b/include/libs/stream/tstream.h @@ -61,7 +61,7 @@ typedef struct SStreamTask SStreamTask; typedef struct SStreamQueue SStreamQueue; typedef struct SStreamTaskSM SStreamTaskSM; -#define SSTREAM_TASK_VER 3 +#define SSTREAM_TASK_VER 4 #define SSTREAM_TASK_INCOMPATIBLE_VER 1 #define SSTREAM_TASK_NEED_CONVERT_VER 2 #define SSTREAM_TASK_SUBTABLE_CHANGED_VER 3 diff --git a/source/common/src/tdatablock.c b/source/common/src/tdatablock.c index d2164b024b..e748cce643 100644 --- a/source/common/src/tdatablock.c +++ b/source/common/src/tdatablock.c @@ -2188,10 +2188,14 @@ _end: return TSDB_CODE_SUCCESS; } -void buildCtbNameAddGroupId(char* ctbName, uint64_t groupId) { +void buildCtbNameAddGroupId(const char* stbName, char* ctbName, uint64_t groupId){ char tmp[TSDB_TABLE_NAME_LEN] = {0}; - snprintf(tmp, TSDB_TABLE_NAME_LEN, "_%" PRIu64, groupId); - ctbName[TSDB_TABLE_NAME_LEN - strlen(tmp) - 1] = 0; // put groupId to the end + if (stbName == NULL){ + snprintf(tmp, TSDB_TABLE_NAME_LEN, "_%"PRIu64, groupId); + }else{ + snprintf(tmp, TSDB_TABLE_NAME_LEN, "_%s_%"PRIu64, stbName, groupId); + } + ctbName[TSDB_TABLE_NAME_LEN - strlen(tmp) - 1] = 0; // put stbname + groupId to the end strcat(ctbName, tmp); } @@ -2201,6 +2205,7 @@ bool isAutoTableName(char* ctbName) { return (strlen(ctbName) == 34 && ctbName[0 bool alreadyAddGroupId(char* ctbName) { size_t len = strlen(ctbName); + if (len == 0) return false; size_t _location = len - 1; while (_location > 0) { if (ctbName[_location] < '0' || ctbName[_location] > '9') { diff --git a/source/common/src/tmsg.c b/source/common/src/tmsg.c index ff424ee558..8430c67321 100644 --- a/source/common/src/tmsg.c +++ b/source/common/src/tmsg.c @@ -51,8 +51,8 @@ #define ENCODESQL() \ do { \ + if (tEncodeI32(&encoder, pReq->sqlLen) < 0) return -1; \ if (pReq->sqlLen > 0 && pReq->sql != NULL) { \ - if (tEncodeI32(&encoder, pReq->sqlLen) < 0) return -1; \ if (tEncodeBinary(&encoder, pReq->sql, pReq->sqlLen) < 0) return -1; \ } \ } while (0) @@ -3025,7 +3025,7 @@ int32_t tSerializeSCreateDbReq(void *buf, int32_t bufLen, SCreateDbReq *pReq) { ENCODESQL(); - if (tEncodeI32(&encoder, pReq->withArbitrator) < 0) return -1; + if (tEncodeI8(&encoder, pReq->withArbitrator) < 0) return -1; tEndEncode(&encoder); @@ -3140,7 +3140,7 @@ int32_t tSerializeSAlterDbReq(void *buf, int32_t bufLen, SAlterDbReq *pReq) { if (tEncodeI32(&encoder, pReq->walRetentionSize) < 0) return -1; if (tEncodeI32(&encoder, pReq->keepTimeOffset) < 0) return -1; ENCODESQL(); - if (tEncodeI32(&encoder, pReq->withArbitrator) < 0) return -1; + if (tEncodeI8(&encoder, pReq->withArbitrator) < 0) return -1; tEndEncode(&encoder); int32_t tlen = encoder.pos; diff --git a/source/dnode/mnode/impl/inc/mndArbGroup.h b/source/dnode/mnode/impl/inc/mndArbGroup.h index ed852cf581..fcd11310e7 100644 --- a/source/dnode/mnode/impl/inc/mndArbGroup.h +++ b/source/dnode/mnode/impl/inc/mndArbGroup.h @@ -35,6 +35,7 @@ int32_t mndSetCreateArbGroupRedoLogs(STrans *pTrans, SArbGroup *pGroup); int32_t mndSetCreateArbGroupUndoLogs(STrans *pTrans, SArbGroup *pGroup); int32_t mndSetCreateArbGroupCommitLogs(STrans *pTrans, SArbGroup *pGroup); +int32_t mndSetDropArbGroupPrepareLogs(STrans *pTrans, SArbGroup *pGroup); int32_t mndSetDropArbGroupCommitLogs(STrans *pTrans, SArbGroup *pGroup); bool mndUpdateArbGroupByHeartBeat(SArbGroup *pGroup, SVArbHbRspMember *pRspMember, int64_t nowMs, int32_t dnodeId, diff --git a/source/dnode/mnode/impl/src/mndArbGroup.c b/source/dnode/mnode/impl/src/mndArbGroup.c index e056e698f3..92ab5274e4 100644 --- a/source/dnode/mnode/impl/src/mndArbGroup.c +++ b/source/dnode/mnode/impl/src/mndArbGroup.c @@ -260,6 +260,14 @@ int32_t mndSetCreateArbGroupCommitLogs(STrans *pTrans, SArbGroup *pGroup) { return 0; } +int32_t mndSetDropArbGroupPrepareLogs(STrans *pTrans, SArbGroup *pGroup) { + SSdbRaw *pRedoRaw = mndArbGroupActionEncode(pGroup); + if (pRedoRaw == NULL) return -1; + if (mndTransAppendPrepareLog(pTrans, pRedoRaw) != 0) return -1; + if (sdbSetRawStatus(pRedoRaw, SDB_STATUS_DROPPING) != 0) return -1; + return 0; +} + static int32_t mndSetDropArbGroupRedoLogs(STrans *pTrans, SArbGroup *pGroup) { SSdbRaw *pRedoRaw = mndArbGroupActionEncode(pGroup); if (pRedoRaw == NULL) return -1; @@ -535,10 +543,10 @@ static int32_t mndProcessArbCheckSyncTimer(SRpcMsg *pReq) { int32_t vgId = arbGroupDup.vgId; int64_t nowMs = taosGetTimestampMs(); - bool member0IsTimeout = mndCheckArbMemberHbTimeout(&arbGroupDup, 0, nowMs); - bool member1IsTimeout = mndCheckArbMemberHbTimeout(&arbGroupDup, 1, nowMs); - SArbAssignedLeader* pAssignedLeader = &arbGroupDup.assignedLeader; - int32_t currentAssignedDnodeId = pAssignedLeader->dnodeId; + bool member0IsTimeout = mndCheckArbMemberHbTimeout(&arbGroupDup, 0, nowMs); + bool member1IsTimeout = mndCheckArbMemberHbTimeout(&arbGroupDup, 1, nowMs); + SArbAssignedLeader *pAssignedLeader = &arbGroupDup.assignedLeader; + int32_t currentAssignedDnodeId = pAssignedLeader->dnodeId; // 1. has assigned && is sync => send req if (currentAssignedDnodeId != 0 && arbGroupDup.isSync == true) { @@ -667,9 +675,16 @@ static int32_t mndProcessArbUpdateGroupReq(SRpcMsg *pReq) { memcpy(newGroup.assignedLeader.token, req.assignedLeader.token, TSDB_ARB_TOKEN_SIZE); newGroup.version = req.version; - SMnode *pMnode = pReq->info.node; + SMnode *pMnode = pReq->info.node; + SArbGroup *pOldGroup = sdbAcquire(pMnode->pSdb, SDB_ARBGROUP, &newGroup.vgId); + if (!pOldGroup) { + mInfo("vgId:%d, arb skip to update arbgroup, since no obj found", newGroup.vgId); + return 0; + } + sdbRelease(pMnode->pSdb, pOldGroup); + if (mndArbGroupUpdateTrans(pMnode, &newGroup) != 0) { - mError("vgId:%d, arb failed to update arbgroup, since %s", req.vgId, terrstr()); + mError("vgId:%d, arb failed to update arbgroup, since %s", newGroup.vgId, terrstr()); ret = -1; } diff --git a/source/dnode/mnode/impl/src/mndConsumer.c b/source/dnode/mnode/impl/src/mndConsumer.c index 52671f6b66..ed9333f480 100644 --- a/source/dnode/mnode/impl/src/mndConsumer.c +++ b/source/dnode/mnode/impl/src/mndConsumer.c @@ -292,16 +292,16 @@ static void storeOffsetRows(SMnode *pMnode, SMqHbReq *req, SMqConsumerObj *pCons static int32_t buildMqHbRsp(SRpcMsg *pMsg, SMqHbRsp *rsp){ int32_t tlen = tSerializeSMqHbRsp(NULL, 0, rsp); if (tlen <= 0){ - return TSDB_CODE_OUT_OF_MEMORY; + return TSDB_CODE_TMQ_INVALID_MSG; } void *buf = rpcMallocCont(tlen); if (buf == NULL) { return TSDB_CODE_OUT_OF_MEMORY; } - if(tSerializeSMqHbRsp(buf, tlen, rsp) != 0){ + if(tSerializeSMqHbRsp(buf, tlen, rsp) <= 0){ rpcFreeCont(buf); - return TSDB_CODE_OUT_OF_MEMORY; + return TSDB_CODE_TMQ_INVALID_MSG; } pMsg->info.rsp = buf; pMsg->info.rspLen = tlen; @@ -316,7 +316,7 @@ static int32_t mndProcessMqHbReq(SRpcMsg *pMsg) { SMqConsumerObj *pConsumer = NULL; if (tDeserializeSMqHbReq(pMsg->pCont, pMsg->contLen, &req) < 0) { - code = TSDB_CODE_OUT_OF_MEMORY; + code = TSDB_CODE_TMQ_INVALID_MSG; goto end; } diff --git a/source/dnode/mnode/impl/src/mndDb.c b/source/dnode/mnode/impl/src/mndDb.c index a1f3a24661..527105a7b8 100644 --- a/source/dnode/mnode/impl/src/mndDb.c +++ b/source/dnode/mnode/impl/src/mndDb.c @@ -1209,6 +1209,25 @@ static int32_t mndSetDropDbPrepareLogs(SMnode *pMnode, STrans *pTrans, SDbObj *p if (mndTransAppendPrepareLog(pTrans, pRedoRaw) != 0) return -1; if (sdbSetRawStatus(pRedoRaw, SDB_STATUS_DROPPING) != 0) return -1; + SSdb *pSdb = pMnode->pSdb; + void *pIter = NULL; + + while (1) { + SArbGroup *pArbGroup = NULL; + pIter = sdbFetch(pSdb, SDB_ARBGROUP, pIter, (void **)&pArbGroup); + if (pIter == NULL) break; + + if (pArbGroup->dbUid == pDb->uid) { + if (mndSetDropArbGroupPrepareLogs(pTrans,pArbGroup) != 0) { + sdbCancelFetch(pSdb, pIter); + sdbRelease(pSdb, pArbGroup); + return -1; + } + } + + sdbRelease(pSdb, pArbGroup); + } + return 0; } diff --git a/source/dnode/mnode/impl/src/mndDef.c b/source/dnode/mnode/impl/src/mndDef.c index 3f69c7def3..091edc6ab0 100644 --- a/source/dnode/mnode/impl/src/mndDef.c +++ b/source/dnode/mnode/impl/src/mndDef.c @@ -72,7 +72,9 @@ int32_t tEncodeSStreamObj(SEncoder *pEncoder, const SStreamObj *pObj) { if (tEncodeI32(pEncoder, innerSz) < 0) return -1; for (int32_t j = 0; j < innerSz; j++) { SStreamTask *pTask = taosArrayGetP(pArray, j); - pTask->ver = SSTREAM_TASK_VER; + if (pTask->ver < SSTREAM_TASK_SUBTABLE_CHANGED_VER){ + pTask->ver = SSTREAM_TASK_VER; + } if (tEncodeStreamTask(pEncoder, pTask) < 0) return -1; } } diff --git a/source/dnode/mnode/impl/src/mndStb.c b/source/dnode/mnode/impl/src/mndStb.c index 7ee1b36916..79c62df766 100644 --- a/source/dnode/mnode/impl/src/mndStb.c +++ b/source/dnode/mnode/impl/src/mndStb.c @@ -1104,14 +1104,16 @@ static int32_t mndProcessCreateStbReq(SRpcMsg *pReq) { } else if (createReq.tagVer > 0 || createReq.colVer > 0) { int32_t tagDelta = createReq.tagVer - pStb->tagVer; int32_t colDelta = createReq.colVer - pStb->colVer; - int32_t verDelta = tagDelta + colDelta; mInfo("stb:%s, already exist while create, input tagVer:%d colVer:%d, exist tagVer:%d colVer:%d", createReq.name, createReq.tagVer, createReq.colVer, pStb->tagVer, pStb->colVer); if (tagDelta <= 0 && colDelta <= 0) { mInfo("stb:%s, schema version is not incremented and nothing needs to be done", createReq.name); code = 0; goto _OVER; - } else if ((tagDelta == 1 || colDelta == 1) && (verDelta == 1)) { + } else if ((tagDelta == 1 && colDelta == 0) || + (tagDelta == 0 && colDelta == 1) || + (pStb->colVer == 1 && createReq.colVer > 1) || + (pStb->tagVer == 1 && createReq.tagVer > 1)) { isAlter = true; mInfo("stb:%s, schema version is only increased by 1 number, do alter operation", createReq.name); } else { diff --git a/source/dnode/mnode/impl/src/mndStream.c b/source/dnode/mnode/impl/src/mndStream.c index 60b522f6fa..ff05db417e 100644 --- a/source/dnode/mnode/impl/src/mndStream.c +++ b/source/dnode/mnode/impl/src/mndStream.c @@ -434,7 +434,9 @@ int32_t mndPersistTaskDeployReq(STrans *pTrans, SStreamTask *pTask) { SEncoder encoder; tEncoderInit(&encoder, NULL, 0); - pTask->ver = SSTREAM_TASK_VER; + if (pTask->ver < SSTREAM_TASK_SUBTABLE_CHANGED_VER){ + pTask->ver = SSTREAM_TASK_VER; + } tEncodeStreamTask(&encoder, pTask); int32_t size = encoder.pos; @@ -2153,41 +2155,60 @@ int32_t mndProcessStreamReqCheckpoint(SRpcMsg *pReq) { SStreamObj *pStream = mndGetStreamObj(pMnode, req.streamId); if (pStream == NULL) { - mError("failed to find the stream:0x%" PRIx64 " not handle the checkpoint req", req.streamId); - terrno = TSDB_CODE_MND_STREAM_NOT_EXIST; - taosThreadMutexUnlock(&execInfo.lock); + mWarn("failed to find the stream:0x%" PRIx64 ", not handle the checkpoint req, try to acquire in buf", req.streamId); - return -1; + // not in meta-store yet, try to acquire the task in exec buffer + // the checkpoint req arrives too soon before the completion of the create stream trans. + STaskId id = {.streamId = req.streamId, .taskId = req.taskId}; + void* p = taosHashGet(execInfo.pTaskMap, &id, sizeof(id)); + if (p == NULL) { + mError("failed to find the stream:0x%" PRIx64 " in buf, not handle the checkpoint req", req.streamId); + terrno = TSDB_CODE_MND_STREAM_NOT_EXIST; + taosThreadMutexUnlock(&execInfo.lock); + return -1; + } else { + mDebug("s-task:0x%" PRIx64 "-0x%x in buf not in mnode/meta, create stream trans may not complete yet", + req.streamId, req.taskId); + } } - int32_t numOfTasks = mndGetNumOfStreamTasks(pStream); + int32_t numOfTasks = (pStream == NULL)? 0: mndGetNumOfStreamTasks(pStream); + SArray **pReqTaskList = (SArray **)taosHashGet(execInfo.pTransferStateStreams, &req.streamId, sizeof(req.streamId)); if (pReqTaskList == NULL) { SArray *pList = taosArrayInit(4, sizeof(int32_t)); - doAddTaskId(pList, req.taskId, pStream->uid, numOfTasks); + doAddTaskId(pList, req.taskId, req.streamId, numOfTasks); taosHashPut(execInfo.pTransferStateStreams, &req.streamId, sizeof(int64_t), &pList, sizeof(void *)); pReqTaskList = (SArray **)taosHashGet(execInfo.pTransferStateStreams, &req.streamId, sizeof(req.streamId)); } else { - doAddTaskId(*pReqTaskList, req.taskId, pStream->uid, numOfTasks); + doAddTaskId(*pReqTaskList, req.taskId, req.streamId, numOfTasks); } int32_t total = taosArrayGetSize(*pReqTaskList); if (total == numOfTasks) { // all tasks has send the reqs int64_t checkpointId = mndStreamGenChkpId(pMnode); - mDebug("stream:0x%" PRIx64 " all tasks req, start checkpointId:%" PRId64, pStream->uid, checkpointId); + mInfo("stream:0x%" PRIx64 " all tasks req checkpoint, start checkpointId:%" PRId64, req.streamId, checkpointId); - // TODO:handle error - int32_t code = mndProcessStreamCheckpointTrans(pMnode, pStream, checkpointId, 0, false); + if (pStream != NULL) { // TODO:handle error + int32_t code = mndProcessStreamCheckpointTrans(pMnode, pStream, checkpointId, 0, false); + } else { + // todo: wait for the create stream trans completed, and launch the checkpoint trans + // SStreamObj *pStream = mndGetStreamObj(pMnode, req.streamId); + // sleep(500ms) + } // remove this entry taosHashRemove(execInfo.pTransferStateStreams, &req.streamId, sizeof(int64_t)); int32_t numOfStreams = taosHashGetSize(execInfo.pTransferStateStreams); - mDebug("stream:0x%" PRIx64 " removed, remain streams:%d fill-history not completed", pStream->uid, numOfStreams); + mDebug("stream:0x%" PRIx64 " removed, remain streams:%d fill-history not completed", req.streamId, numOfStreams); + } + + if (pStream != NULL) { + mndReleaseStream(pMnode, pStream); } - mndReleaseStream(pMnode, pStream); taosThreadMutexUnlock(&execInfo.lock); { diff --git a/source/dnode/vnode/src/meta/metaSnapshot.c b/source/dnode/vnode/src/meta/metaSnapshot.c index e86ed3b657..5850e794fa 100644 --- a/source/dnode/vnode/src/meta/metaSnapshot.c +++ b/source/dnode/vnode/src/meta/metaSnapshot.c @@ -79,6 +79,7 @@ int32_t metaSnapRead(SMetaSnapReader* pReader, uint8_t** ppData) { int32_t nKey = 0; int32_t nData = 0; STbDbKey key; + SMetaInfo info; *ppData = NULL; for (;;) { @@ -91,7 +92,8 @@ int32_t metaSnapRead(SMetaSnapReader* pReader, uint8_t** ppData) { goto _exit; } - if (key.version < pReader->sver) { + if (key.version < pReader->sver // + || metaGetInfo(pReader->pMeta, key.uid, &info, NULL) == TSDB_CODE_NOT_FOUND) { tdbTbcMoveToNext(pReader->pTbc); continue; } diff --git a/source/dnode/vnode/src/tq/tq.c b/source/dnode/vnode/src/tq/tq.c index 141fe88339..3a321fef79 100644 --- a/source/dnode/vnode/src/tq/tq.c +++ b/source/dnode/vnode/src/tq/tq.c @@ -101,10 +101,7 @@ int32_t tqInitialize(STQ* pTq) { return -1; } - if (streamMetaLoadAllTasks(pTq->pStreamMeta) < 0) { - return -1; - } - + /*int32_t code = */streamMetaLoadAllTasks(pTq->pStreamMeta); return 0; } diff --git a/source/dnode/vnode/src/tq/tqSink.c b/source/dnode/vnode/src/tq/tqSink.c index ade7958f8a..7f5ddf4f1e 100644 --- a/source/dnode/vnode/src/tq/tqSink.c +++ b/source/dnode/vnode/src/tq/tqSink.c @@ -71,8 +71,8 @@ int32_t tqBuildDeleteReq(STQ* pTq, const char* stbFullName, const SSDataBlock* p if (varTbName != NULL && varTbName != (void*)-1) { name = taosMemoryCalloc(1, TSDB_TABLE_NAME_LEN); memcpy(name, varDataVal(varTbName), varDataLen(varTbName)); - if (newSubTableRule && !isAutoTableName(name) && !alreadyAddGroupId(name) && groupId != 0) { - buildCtbNameAddGroupId(name, groupId); + if (newSubTableRule && !isAutoTableName(name) && !alreadyAddGroupId(name) && groupId != 0 && stbFullName) { + buildCtbNameAddGroupId(stbFullName, name, groupId); } } else if (stbFullName) { name = buildCtbNameByGroupId(stbFullName, groupId); @@ -182,10 +182,10 @@ void setCreateTableMsgTableName(SVCreateTbReq* pCreateTableReq, SSDataBlock* pDa int64_t gid, bool newSubTableRule) { if (pDataBlock->info.parTbName[0]) { if (newSubTableRule && !isAutoTableName(pDataBlock->info.parTbName) && - !alreadyAddGroupId(pDataBlock->info.parTbName) && gid != 0) { + !alreadyAddGroupId(pDataBlock->info.parTbName) && gid != 0 && stbFullName) { pCreateTableReq->name = taosMemoryCalloc(1, TSDB_TABLE_NAME_LEN); strcpy(pCreateTableReq->name, pDataBlock->info.parTbName); - buildCtbNameAddGroupId(pCreateTableReq->name, gid); + buildCtbNameAddGroupId(stbFullName, pCreateTableReq->name, gid); // tqDebug("gen name from:%s", pDataBlock->info.parTbName); } else { pCreateTableReq->name = taosStrdup(pDataBlock->info.parTbName); @@ -672,10 +672,14 @@ int32_t setDstTableDataUid(SVnode* pVnode, SStreamTask* pTask, SSDataBlock* pDat memset(dstTableName, 0, TSDB_TABLE_NAME_LEN); buildCtbNameByGroupIdImpl(stbFullName, groupId, dstTableName); } else { - if (pTask->ver >= SSTREAM_TASK_SUBTABLE_CHANGED_VER && pTask->subtableWithoutMd5 != 1 && - !isAutoTableName(dstTableName) && !alreadyAddGroupId(dstTableName) && groupId != 0) { + if (pTask->subtableWithoutMd5 != 1 && !isAutoTableName(dstTableName) && + !alreadyAddGroupId(dstTableName) && groupId != 0) { tqDebug("s-task:%s append groupId:%" PRId64 " for generated dstTable:%s", id, groupId, dstTableName); - buildCtbNameAddGroupId(dstTableName, groupId); + if(pTask->ver == SSTREAM_TASK_SUBTABLE_CHANGED_VER){ + buildCtbNameAddGroupId(NULL, dstTableName, groupId); + }else if(pTask->ver > SSTREAM_TASK_SUBTABLE_CHANGED_VER && stbFullName) { + buildCtbNameAddGroupId(stbFullName, dstTableName, groupId); + } } } diff --git a/source/dnode/vnode/src/tsdb/tsdbUtil.c b/source/dnode/vnode/src/tsdb/tsdbUtil.c index 2b8de9aff3..201425cf89 100644 --- a/source/dnode/vnode/src/tsdb/tsdbUtil.c +++ b/source/dnode/vnode/src/tsdb/tsdbUtil.c @@ -695,8 +695,8 @@ SColVal *tsdbRowIterNext(STSDBRowIter *pIter) { return &pIter->cv; } - if (pIter->iColData < pIter->pRow->pBlockData->nColData) { - tColDataGetValue(&pIter->pRow->pBlockData->aColData[pIter->iColData], pIter->pRow->iRow, &pIter->cv); + if (pIter->iColData <= pIter->pRow->pBlockData->nColData) { + tColDataGetValue(&pIter->pRow->pBlockData->aColData[pIter->iColData - 1], pIter->pRow->iRow, &pIter->cv); ++pIter->iColData; return &pIter->cv; } else { diff --git a/source/libs/executor/src/sysscanoperator.c b/source/libs/executor/src/sysscanoperator.c index 69a90f03ed..a5e27e1910 100644 --- a/source/libs/executor/src/sysscanoperator.c +++ b/source/libs/executor/src/sysscanoperator.c @@ -879,7 +879,7 @@ static int32_t sysTableGetGeomText(char* iGeom, int32_t nGeom, char** output, in char* outputWKT = NULL; if (nGeom == 0) { - if (!(*output = strdup(""))) code = TSDB_CODE_OUT_OF_MEMORY; + if (!(*output = taosStrdup(""))) code = TSDB_CODE_OUT_OF_MEMORY; *nOutput = 0; return code; } diff --git a/source/libs/executor/src/timewindowoperator.c b/source/libs/executor/src/timewindowoperator.c index 57cc0e82d2..51bfe716c8 100644 --- a/source/libs/executor/src/timewindowoperator.c +++ b/source/libs/executor/src/timewindowoperator.c @@ -496,7 +496,6 @@ static void doWindowBorderInterpolation(SIntervalAggOperatorInfo* pInfo, SSDataB ASSERT(pBlock != NULL); if (pBlock->pDataBlock == NULL) { - // tscError("pBlock->pDataBlock == NULL"); return; } @@ -514,10 +513,6 @@ static void doWindowBorderInterpolation(SIntervalAggOperatorInfo* pInfo, SSDataB } // point interpolation does not require the end key time window interpolation. - // if (pointInterpQuery) { - // return; - // } - // interpolation query does not generate the time window end interpolation done = isResultRowInterpolated(pResult, RESULT_ROW_END_INTERP); if (!done) { diff --git a/source/libs/parser/inc/sql.y b/source/libs/parser/inc/sql.y index 2cac8ee411..7b6b7bb734 100755 --- a/source/libs/parser/inc/sql.y +++ b/source/libs/parser/inc/sql.y @@ -748,16 +748,52 @@ insert_query(A) ::= INSERT INTO full_table_name(C) query_or_subquery(B). /************************************************ tags_literal *************************************************************/ tags_literal(A) ::= NK_INTEGER(B). { A = createRawValueNode(pCxt, TSDB_DATA_TYPE_UBIGINT, &B, NULL); } +tags_literal(A) ::= NK_INTEGER(B) NK_PLUS duration_literal(C). { + SToken l = B; + SToken r = getTokenFromRawExprNode(pCxt, C); + l.n = (r.z + r.n) - l.z; + A = createRawValueNodeExt(pCxt, TSDB_DATA_TYPE_BINARY, &l, NULL, C); + } +tags_literal(A) ::= NK_INTEGER(B) NK_MINUS duration_literal(C). { + SToken l = B; + SToken r = getTokenFromRawExprNode(pCxt, C); + l.n = (r.z + r.n) - l.z; + A = createRawValueNodeExt(pCxt, TSDB_DATA_TYPE_BINARY, &l, NULL, C); + } tags_literal(A) ::= NK_PLUS(B) NK_INTEGER(C). { SToken t = B; t.n = (C.z + C.n) - B.z; A = createRawValueNode(pCxt, TSDB_DATA_TYPE_UBIGINT, &t, NULL); } +tags_literal(A) ::= NK_PLUS(B) NK_INTEGER NK_PLUS duration_literal(C). { + SToken l = B; + SToken r = getTokenFromRawExprNode(pCxt, C); + l.n = (r.z + r.n) - l.z; + A = createRawValueNodeExt(pCxt, TSDB_DATA_TYPE_BINARY, &l, NULL, C); + } +tags_literal(A) ::= NK_PLUS(B) NK_INTEGER NK_MINUS duration_literal(C). { + SToken l = B; + SToken r = getTokenFromRawExprNode(pCxt, C); + l.n = (r.z + r.n) - l.z; + A = createRawValueNodeExt(pCxt, TSDB_DATA_TYPE_BINARY, &l, NULL, C); + } tags_literal(A) ::= NK_MINUS(B) NK_INTEGER(C). { SToken t = B; t.n = (C.z + C.n) - B.z; A = createRawValueNode(pCxt, TSDB_DATA_TYPE_UBIGINT, &t, NULL); } +tags_literal(A) ::= NK_MINUS(B) NK_INTEGER NK_PLUS duration_literal(C). { + SToken l = B; + SToken r = getTokenFromRawExprNode(pCxt, C); + l.n = (r.z + r.n) - l.z; + A = createRawValueNodeExt(pCxt, TSDB_DATA_TYPE_BINARY, &l, NULL, C); + } +tags_literal(A) ::= NK_MINUS(B) NK_INTEGER NK_MINUS duration_literal(C). { + SToken l = B; + SToken r = getTokenFromRawExprNode(pCxt, C); + l.n = (r.z + r.n) - l.z; + A = createRawValueNodeExt(pCxt, TSDB_DATA_TYPE_BINARY, &l, NULL, C); + } tags_literal(A) ::= NK_FLOAT(B). { A = createRawValueNode(pCxt, TSDB_DATA_TYPE_DOUBLE, &B, NULL); } tags_literal(A) ::= NK_PLUS(B) NK_FLOAT(C). { SToken t = B; @@ -771,29 +807,113 @@ tags_literal(A) ::= NK_MINUS(B) NK_FLOAT(C). } tags_literal(A) ::= NK_BIN(B). { A = createRawValueNode(pCxt, TSDB_DATA_TYPE_UBIGINT, &B, NULL); } +tags_literal(A) ::= NK_BIN(B) NK_PLUS duration_literal(C). { + SToken l = B; + SToken r = getTokenFromRawExprNode(pCxt, C); + l.n = (r.z + r.n) - l.z; + A = createRawValueNodeExt(pCxt, TSDB_DATA_TYPE_BINARY, &l, NULL, C); + } +tags_literal(A) ::= NK_BIN(B) NK_MINUS duration_literal(C). { + SToken l = B; + SToken r = getTokenFromRawExprNode(pCxt, C); + l.n = (r.z + r.n) - l.z; + A = createRawValueNodeExt(pCxt, TSDB_DATA_TYPE_BINARY, &l, NULL, C); + } tags_literal(A) ::= NK_PLUS(B) NK_BIN(C). { SToken t = B; t.n = (C.z + C.n) - B.z; A = createRawValueNode(pCxt, TSDB_DATA_TYPE_UBIGINT, &t, NULL); } +tags_literal(A) ::= NK_PLUS(B) NK_BIN NK_PLUS duration_literal(C). { + SToken l = B; + SToken r = getTokenFromRawExprNode(pCxt, C); + l.n = (r.z + r.n) - l.z; + A = createRawValueNodeExt(pCxt, TSDB_DATA_TYPE_BINARY, &l, NULL, C); + } +tags_literal(A) ::= NK_PLUS(B) NK_BIN NK_MINUS duration_literal(C). { + SToken l = B; + SToken r = getTokenFromRawExprNode(pCxt, C); + l.n = (r.z + r.n) - l.z; + A = createRawValueNodeExt(pCxt, TSDB_DATA_TYPE_BINARY, &l, NULL, C); + } tags_literal(A) ::= NK_MINUS(B) NK_BIN(C). { SToken t = B; t.n = (C.z + C.n) - B.z; A = createRawValueNode(pCxt, TSDB_DATA_TYPE_UBIGINT, &t, NULL); } +tags_literal(A) ::= NK_MINUS(B) NK_BIN NK_PLUS duration_literal(C). { + SToken l = B; + SToken r = getTokenFromRawExprNode(pCxt, C); + l.n = (r.z + r.n) - l.z; + A = createRawValueNodeExt(pCxt, TSDB_DATA_TYPE_BINARY, &l, NULL, C); + } +tags_literal(A) ::= NK_MINUS(B) NK_BIN NK_MINUS duration_literal(C). { + SToken l = B; + SToken r = getTokenFromRawExprNode(pCxt, C); + l.n = (r.z + r.n) - l.z; + A = createRawValueNodeExt(pCxt, TSDB_DATA_TYPE_BINARY, &l, NULL, C); + } tags_literal(A) ::= NK_HEX(B). { A = createRawValueNode(pCxt, TSDB_DATA_TYPE_UBIGINT, &B, NULL); } +tags_literal(A) ::= NK_HEX(B) NK_PLUS duration_literal(C). { + SToken l = B; + SToken r = getTokenFromRawExprNode(pCxt, C); + l.n = (r.z + r.n) - l.z; + A = createRawValueNodeExt(pCxt, TSDB_DATA_TYPE_BINARY, &l, NULL, C); + } +tags_literal(A) ::= NK_HEX(B) NK_MINUS duration_literal(C). { + SToken l = B; + SToken r = getTokenFromRawExprNode(pCxt, C); + l.n = (r.z + r.n) - l.z; + A = createRawValueNodeExt(pCxt, TSDB_DATA_TYPE_BINARY, &l, NULL, C); + } tags_literal(A) ::= NK_PLUS(B) NK_HEX(C). { SToken t = B; t.n = (C.z + C.n) - B.z; A = createRawValueNode(pCxt, TSDB_DATA_TYPE_UBIGINT, &t, NULL); } +tags_literal(A) ::= NK_PLUS(B) NK_HEX NK_PLUS duration_literal(C). { + SToken l = B; + SToken r = getTokenFromRawExprNode(pCxt, C); + l.n = (r.z + r.n) - l.z; + A = createRawValueNodeExt(pCxt, TSDB_DATA_TYPE_BINARY, &l, NULL, C); + } +tags_literal(A) ::= NK_PLUS(B) NK_HEX NK_MINUS duration_literal(C). { + SToken l = B; + SToken r = getTokenFromRawExprNode(pCxt, C); + l.n = (r.z + r.n) - l.z; + A = createRawValueNodeExt(pCxt, TSDB_DATA_TYPE_BINARY, &l, NULL, C); + } tags_literal(A) ::= NK_MINUS(B) NK_HEX(C). { SToken t = B; t.n = (C.z + C.n) - B.z; A = createRawValueNode(pCxt, TSDB_DATA_TYPE_UBIGINT, &t, NULL); } +tags_literal(A) ::= NK_MINUS(B) NK_HEX NK_PLUS duration_literal(C). { + SToken l = B; + SToken r = getTokenFromRawExprNode(pCxt, C); + l.n = (r.z + r.n) - l.z; + A = createRawValueNodeExt(pCxt, TSDB_DATA_TYPE_BINARY, &l, NULL, C); + } +tags_literal(A) ::= NK_MINUS(B) NK_HEX NK_MINUS duration_literal(C). { + SToken l = B; + SToken r = getTokenFromRawExprNode(pCxt, C); + l.n = (r.z + r.n) - l.z; + A = createRawValueNodeExt(pCxt, TSDB_DATA_TYPE_BINARY, &l, NULL, C); + } tags_literal(A) ::= NK_STRING(B). { A = createRawValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &B, NULL); } +tags_literal(A) ::= NK_STRING(B) NK_PLUS duration_literal(C). { + SToken l = B; + SToken r = getTokenFromRawExprNode(pCxt, C); + l.n = (r.z + r.n) - l.z; + A = createRawValueNodeExt(pCxt, TSDB_DATA_TYPE_BINARY, &l, NULL, C); + } +tags_literal(A) ::= NK_STRING(B) NK_MINUS duration_literal(C). { + SToken l = B; + SToken r = getTokenFromRawExprNode(pCxt, C); + l.n = (r.z + r.n) - l.z; + A = createRawValueNodeExt(pCxt, TSDB_DATA_TYPE_BINARY, &l, NULL, C); + } tags_literal(A) ::= NK_BOOL(B). { A = createRawValueNode(pCxt, TSDB_DATA_TYPE_BOOL, &B, NULL); } tags_literal(A) ::= NULL(B). { A = createRawValueNode(pCxt, TSDB_DATA_TYPE_NULL, &B, NULL); } diff --git a/source/libs/parser/src/sql.c b/source/libs/parser/src/sql.c index 326168b5c1..b7012e6293 100644 --- a/source/libs/parser/src/sql.c +++ b/source/libs/parser/src/sql.c @@ -142,18 +142,18 @@ typedef union { #define ParseCTX_FETCH #define ParseCTX_STORE #define YYFALLBACK 1 -#define YYNSTATE 862 -#define YYNRULE 672 -#define YYNRULE_WITH_ACTION 672 +#define YYNSTATE 892 +#define YYNRULE 692 +#define YYNRULE_WITH_ACTION 692 #define YYNTOKEN 355 -#define YY_MAX_SHIFT 861 -#define YY_MIN_SHIFTREDUCE 1284 -#define YY_MAX_SHIFTREDUCE 1955 -#define YY_ERROR_ACTION 1956 -#define YY_ACCEPT_ACTION 1957 -#define YY_NO_ACTION 1958 -#define YY_MIN_REDUCE 1959 -#define YY_MAX_REDUCE 2630 +#define YY_MAX_SHIFT 891 +#define YY_MIN_SHIFTREDUCE 1324 +#define YY_MAX_SHIFTREDUCE 2015 +#define YY_ERROR_ACTION 2016 +#define YY_ACCEPT_ACTION 2017 +#define YY_NO_ACTION 2018 +#define YY_MIN_REDUCE 2019 +#define YY_MAX_REDUCE 2710 /************* End control #defines *******************************************/ #define YY_NLOOKAHEAD ((int)(sizeof(yy_lookahead)/sizeof(yy_lookahead[0]))) @@ -222,323 +222,323 @@ typedef union { *********** Begin parsing tables **********************************************/ #define YY_ACTTAB_COUNT (3163) static const YYACTIONTYPE yy_action[] = { - /* 0 */ 2289, 174, 239, 2405, 761, 2149, 577, 711, 2010, 2088, - /* 10 */ 2601, 2140, 47, 45, 1877, 422, 474, 2535, 2286, 748, - /* 20 */ 419, 473, 1717, 1960, 138, 723, 147, 2409, 710, 204, - /* 30 */ 2389, 617, 1742, 2602, 712, 1803, 2045, 1715, 46, 44, - /* 40 */ 43, 42, 41, 2532, 128, 2429, 1431, 127, 126, 125, - /* 50 */ 124, 123, 122, 121, 120, 119, 40, 39, 726, 1742, - /* 60 */ 46, 44, 43, 42, 41, 1798, 425, 682, 185, 705, - /* 70 */ 2601, 19, 2411, 2413, 416, 761, 2149, 765, 1723, 2606, - /* 80 */ 760, 29, 2601, 765, 2203, 425, 2447, 1433, 2607, 204, - /* 90 */ 390, 388, 2269, 2602, 712, 138, 765, 2447, 2395, 2201, - /* 100 */ 743, 2605, 622, 665, 858, 2602, 2604, 15, 1881, 833, - /* 110 */ 832, 831, 830, 437, 1742, 829, 828, 152, 823, 822, - /* 120 */ 821, 820, 819, 818, 817, 151, 811, 810, 809, 436, - /* 130 */ 435, 806, 805, 804, 184, 183, 803, 302, 2528, 722, - /* 140 */ 2428, 139, 721, 2466, 2601, 1805, 1806, 115, 2430, 747, - /* 150 */ 2432, 2433, 742, 173, 765, 175, 1922, 1971, 344, 187, - /* 160 */ 704, 2520, 710, 204, 579, 415, 2516, 2602, 712, 2388, - /* 170 */ 576, 711, 426, 571, 2601, 342, 75, 66, 816, 74, - /* 180 */ 206, 2110, 569, 1777, 1787, 565, 561, 590, 2550, 371, - /* 190 */ 1804, 1807, 710, 204, 1324, 1596, 1597, 2602, 712, 723, - /* 200 */ 147, 237, 556, 554, 551, 1718, 423, 1716, 197, 723, - /* 210 */ 147, 40, 39, 1331, 172, 46, 44, 43, 42, 41, - /* 220 */ 2190, 760, 2151, 128, 425, 2368, 127, 126, 125, 124, - /* 230 */ 123, 122, 121, 120, 119, 765, 1326, 1329, 1330, 1721, - /* 240 */ 1722, 1774, 62, 1776, 1779, 1780, 1781, 1782, 1783, 1784, - /* 250 */ 1785, 1786, 739, 763, 762, 1797, 1799, 1800, 1801, 1802, - /* 260 */ 2, 47, 45, 1959, 2337, 1742, 368, 2605, 1740, 419, - /* 270 */ 1350, 1717, 1349, 760, 380, 524, 682, 1778, 544, 2601, - /* 280 */ 62, 594, 63, 543, 1803, 2369, 1715, 137, 136, 135, - /* 290 */ 134, 133, 132, 131, 130, 129, 1745, 2607, 204, 504, - /* 300 */ 1743, 545, 2602, 712, 802, 1351, 369, 506, 50, 663, - /* 310 */ 725, 202, 2528, 2529, 1798, 145, 2533, 484, 1832, 276, - /* 320 */ 19, 203, 2528, 2529, 241, 145, 2533, 1723, 577, 2125, - /* 330 */ 2010, 706, 85, 84, 477, 1775, 682, 217, 1874, 2601, - /* 340 */ 574, 40, 39, 575, 2002, 46, 44, 43, 42, 41, - /* 350 */ 469, 467, 62, 858, 391, 2606, 15, 2607, 204, 1489, - /* 360 */ 50, 367, 2602, 712, 456, 492, 2416, 453, 449, 445, - /* 370 */ 442, 470, 1745, 761, 2149, 1480, 790, 789, 788, 1484, - /* 380 */ 787, 1486, 1487, 786, 783, 1833, 1495, 780, 1497, 1498, - /* 390 */ 777, 774, 771, 209, 1805, 1806, 1723, 2276, 2255, 802, - /* 400 */ 532, 531, 530, 529, 528, 523, 522, 521, 520, 374, - /* 410 */ 434, 433, 306, 510, 509, 508, 507, 501, 500, 499, - /* 420 */ 701, 494, 493, 389, 2418, 1524, 1525, 485, 1584, 1585, - /* 430 */ 1910, 96, 1777, 1787, 1603, 1724, 1746, 40, 39, 1804, - /* 440 */ 1807, 46, 44, 43, 42, 41, 314, 315, 392, 1746, - /* 450 */ 306, 313, 396, 395, 1718, 185, 1716, 2144, 40, 39, - /* 460 */ 1945, 304, 46, 44, 43, 42, 41, 36, 417, 1827, - /* 470 */ 1828, 1829, 1830, 1831, 1835, 1836, 1837, 1838, 306, 2270, - /* 480 */ 698, 697, 1908, 1909, 1911, 1912, 1913, 100, 1721, 1722, - /* 490 */ 1774, 12, 1776, 1779, 1780, 1781, 1782, 1783, 1784, 1785, - /* 500 */ 1786, 739, 763, 762, 1797, 1799, 1800, 1801, 1802, 2, - /* 510 */ 12, 47, 45, 2429, 707, 702, 695, 691, 1644, 419, - /* 520 */ 2238, 1717, 306, 1982, 394, 393, 744, 619, 582, 2405, - /* 530 */ 1952, 575, 2002, 33, 1803, 2606, 1715, 304, 2601, 40, - /* 540 */ 39, 643, 813, 46, 44, 43, 42, 41, 1350, 793, - /* 550 */ 1349, 621, 1774, 2409, 2447, 620, 655, 2605, 1921, 2126, - /* 560 */ 2289, 2602, 2603, 714, 1798, 143, 2395, 2048, 743, 2124, - /* 570 */ 19, 2429, 272, 636, 635, 634, 2395, 1723, 2287, 748, - /* 580 */ 626, 144, 630, 1351, 726, 107, 629, 666, 646, 37, - /* 590 */ 310, 628, 633, 398, 397, 640, 638, 627, 2411, 2414, - /* 600 */ 623, 195, 269, 858, 535, 1727, 15, 815, 2428, 765, - /* 610 */ 2142, 2466, 2447, 1873, 200, 115, 2430, 747, 2432, 2433, - /* 620 */ 742, 12, 765, 10, 2395, 149, 743, 156, 2491, 2520, - /* 630 */ 761, 2149, 329, 415, 2516, 2197, 2198, 1951, 1957, 1717, - /* 640 */ 636, 635, 634, 71, 1805, 1806, 70, 626, 144, 630, - /* 650 */ 55, 458, 430, 629, 1715, 2196, 2198, 1747, 628, 633, - /* 660 */ 398, 397, 584, 2328, 627, 737, 2428, 623, 229, 2466, - /* 670 */ 1747, 490, 2265, 115, 2430, 747, 2432, 2433, 742, 2138, - /* 680 */ 765, 224, 1777, 1787, 517, 187, 2134, 2520, 516, 1804, - /* 690 */ 1807, 415, 2516, 534, 228, 1723, 515, 800, 162, 161, - /* 700 */ 797, 796, 795, 159, 1718, 1697, 1716, 800, 162, 161, - /* 710 */ 797, 796, 795, 159, 2551, 2203, 761, 2149, 440, 481, - /* 720 */ 220, 858, 91, 439, 658, 90, 657, 40, 39, 1742, - /* 730 */ 730, 46, 44, 43, 42, 41, 478, 274, 1721, 1722, - /* 740 */ 1774, 273, 1776, 1779, 1780, 1781, 1782, 1783, 1784, 1785, - /* 750 */ 1786, 739, 763, 762, 1797, 1799, 1800, 1801, 1802, 2, - /* 760 */ 47, 45, 1808, 2429, 541, 539, 2136, 370, 419, 682, - /* 770 */ 1717, 218, 2601, 723, 147, 160, 744, 2203, 2012, 496, - /* 780 */ 2265, 172, 462, 1803, 404, 1715, 2535, 761, 2149, 2152, - /* 790 */ 2607, 204, 2201, 2429, 89, 2602, 712, 800, 162, 161, - /* 800 */ 797, 796, 795, 159, 2447, 198, 744, 479, 2558, 464, - /* 810 */ 460, 99, 2531, 1798, 377, 62, 2395, 403, 743, 656, - /* 820 */ 62, 732, 1718, 2492, 1716, 35, 1723, 1893, 222, 761, - /* 830 */ 2149, 40, 39, 1824, 2447, 46, 44, 43, 42, 41, - /* 840 */ 761, 2149, 761, 2149, 761, 2149, 2395, 1813, 743, 498, - /* 850 */ 54, 1696, 858, 1742, 591, 48, 1721, 1722, 2428, 666, - /* 860 */ 511, 2466, 512, 2429, 513, 115, 2430, 747, 2432, 2433, - /* 870 */ 742, 1981, 765, 1980, 661, 1700, 744, 2621, 2571, 2520, - /* 880 */ 526, 2265, 2535, 415, 2516, 205, 2528, 2529, 2428, 145, - /* 890 */ 2533, 2466, 1778, 1805, 1806, 115, 2430, 747, 2432, 2433, - /* 900 */ 742, 96, 765, 667, 2447, 1703, 1706, 2621, 2530, 2520, - /* 910 */ 592, 2282, 1331, 415, 2516, 2089, 2395, 472, 743, 471, - /* 920 */ 434, 433, 761, 2149, 2395, 682, 2395, 2145, 2601, 227, - /* 930 */ 1731, 1777, 1787, 1746, 668, 2328, 1329, 1330, 1804, 1807, - /* 940 */ 761, 2149, 593, 1803, 2132, 1724, 2607, 204, 428, 470, - /* 950 */ 1775, 2602, 712, 1718, 682, 1716, 169, 2601, 2428, 1902, - /* 960 */ 2146, 2466, 2222, 405, 2151, 115, 2430, 747, 2432, 2433, - /* 970 */ 742, 2201, 765, 1798, 1903, 2607, 204, 2621, 792, 2520, - /* 980 */ 2602, 712, 727, 415, 2516, 306, 1723, 1721, 1722, 1774, - /* 990 */ 306, 1776, 1779, 1780, 1781, 1782, 1783, 1784, 1785, 1786, - /* 1000 */ 739, 763, 762, 1797, 1799, 1800, 1801, 1802, 2, 47, - /* 1010 */ 45, 654, 736, 51, 282, 1901, 1778, 419, 738, 1717, - /* 1020 */ 2203, 1699, 2203, 428, 1743, 2429, 652, 414, 650, 271, - /* 1030 */ 270, 172, 1803, 682, 1715, 2201, 2601, 756, 744, 2151, - /* 1040 */ 693, 40, 39, 2203, 1746, 46, 44, 43, 42, 41, - /* 1050 */ 424, 1702, 1705, 2564, 2607, 204, 761, 2149, 2201, 2602, - /* 1060 */ 712, 621, 1798, 40, 39, 620, 2447, 46, 44, 43, - /* 1070 */ 42, 41, 761, 2149, 1775, 1723, 277, 1742, 2395, 681, - /* 1080 */ 743, 431, 761, 2149, 1979, 761, 2149, 761, 2149, 172, - /* 1090 */ 761, 2149, 285, 2203, 761, 2149, 1443, 2151, 199, 1978, - /* 1100 */ 429, 858, 729, 2429, 48, 318, 275, 758, 2201, 148, - /* 1110 */ 759, 1442, 2491, 1732, 325, 1727, 744, 734, 2594, 2492, - /* 1120 */ 2428, 1834, 1977, 2466, 519, 518, 1976, 115, 2430, 747, - /* 1130 */ 2432, 2433, 742, 699, 765, 761, 2149, 2395, 1447, 2621, - /* 1140 */ 9, 2520, 1805, 1806, 2447, 415, 2516, 1735, 1737, 1616, - /* 1150 */ 1617, 113, 2395, 1446, 1747, 432, 2395, 2356, 743, 1353, - /* 1160 */ 1354, 763, 762, 1797, 1799, 1800, 1801, 1802, 150, 43, - /* 1170 */ 42, 41, 14, 13, 1975, 2395, 2141, 1974, 546, 2395, - /* 1180 */ 1777, 1787, 299, 306, 2203, 1665, 1666, 1804, 1807, 715, - /* 1190 */ 613, 612, 615, 614, 1615, 1618, 632, 631, 2428, 2202, - /* 1200 */ 718, 2466, 1718, 34, 1716, 115, 2430, 747, 2432, 2433, - /* 1210 */ 742, 1973, 765, 1839, 60, 1972, 1970, 2621, 171, 2520, - /* 1220 */ 548, 293, 679, 415, 2516, 1969, 142, 2395, 2448, 1968, - /* 1230 */ 2395, 1967, 1966, 1965, 1964, 1963, 1721, 1722, 1774, 1962, - /* 1240 */ 1776, 1779, 1780, 1781, 1782, 1783, 1784, 1785, 1786, 739, - /* 1250 */ 763, 762, 1797, 1799, 1800, 1801, 1802, 2, 47, 45, - /* 1260 */ 2274, 2429, 827, 825, 2395, 1747, 419, 794, 1717, 2395, - /* 1270 */ 2194, 2359, 798, 2248, 744, 2194, 2539, 799, 2395, 1846, - /* 1280 */ 2194, 1803, 2395, 1715, 2395, 2395, 2395, 2395, 2395, 3, - /* 1290 */ 338, 2429, 2395, 2180, 1333, 1987, 853, 140, 1775, 77, - /* 1300 */ 1741, 53, 2447, 2127, 744, 2540, 1866, 262, 2032, 87, - /* 1310 */ 260, 1798, 2030, 624, 2395, 488, 743, 264, 266, 625, - /* 1320 */ 263, 265, 447, 268, 1723, 2021, 267, 2019, 160, 160, - /* 1330 */ 637, 689, 2447, 2086, 639, 286, 153, 1428, 1954, 1955, - /* 1340 */ 14, 13, 49, 1426, 2395, 2085, 743, 641, 49, 644, - /* 1350 */ 858, 188, 160, 15, 88, 2003, 2428, 64, 2013, 2466, - /* 1360 */ 2429, 324, 323, 115, 2430, 747, 2432, 2433, 742, 49, - /* 1370 */ 765, 49, 1726, 744, 1866, 2621, 2554, 2520, 1386, 101, - /* 1380 */ 1725, 415, 2516, 696, 312, 76, 2428, 410, 211, 2466, - /* 1390 */ 112, 1805, 1806, 115, 2430, 747, 2432, 2433, 742, 109, - /* 1400 */ 765, 2447, 158, 1660, 1663, 2495, 1897, 2520, 373, 372, - /* 1410 */ 851, 415, 2516, 2395, 703, 743, 406, 1907, 1707, 1387, - /* 1420 */ 750, 807, 438, 1906, 2275, 808, 291, 728, 2191, 1777, - /* 1430 */ 1787, 1803, 1840, 1695, 160, 73, 1804, 1807, 769, 158, - /* 1440 */ 160, 2009, 141, 158, 1788, 1405, 1613, 675, 724, 1403, - /* 1450 */ 2555, 1718, 2565, 1716, 301, 2428, 298, 716, 2466, 316, - /* 1460 */ 753, 1798, 115, 2430, 747, 2432, 2433, 742, 305, 765, - /* 1470 */ 719, 2111, 5, 441, 2493, 2429, 2520, 320, 446, 454, - /* 1480 */ 415, 2516, 386, 1750, 212, 1721, 1722, 1774, 744, 1776, - /* 1490 */ 1779, 1780, 1781, 1782, 1783, 1784, 1785, 1786, 739, 763, - /* 1500 */ 762, 1797, 1799, 1800, 1801, 1802, 2, 2429, 455, 1473, - /* 1510 */ 337, 466, 465, 1502, 1506, 1513, 2447, 1511, 163, 213, - /* 1520 */ 744, 215, 468, 1637, 332, 1740, 1741, 226, 2395, 482, - /* 1530 */ 743, 489, 491, 495, 497, 537, 502, 525, 514, 2267, - /* 1540 */ 527, 533, 1729, 536, 538, 549, 550, 547, 2447, 232, - /* 1550 */ 1728, 552, 231, 553, 234, 555, 557, 1748, 572, 4, - /* 1560 */ 2395, 573, 743, 580, 1743, 581, 242, 93, 583, 245, - /* 1570 */ 2428, 585, 1749, 2466, 586, 1751, 587, 115, 2430, 747, - /* 1580 */ 2432, 2433, 742, 248, 765, 250, 589, 1752, 2283, 733, - /* 1590 */ 94, 2520, 595, 616, 95, 415, 2516, 255, 618, 117, - /* 1600 */ 2139, 1708, 2428, 1698, 259, 2466, 2429, 364, 2135, 116, - /* 1610 */ 2430, 747, 2432, 2433, 742, 261, 765, 98, 165, 744, - /* 1620 */ 166, 647, 2137, 2520, 2133, 167, 168, 2519, 2516, 648, - /* 1630 */ 333, 2346, 662, 1701, 1704, 1709, 278, 660, 154, 2343, - /* 1640 */ 1744, 670, 2342, 669, 283, 674, 281, 2447, 676, 763, - /* 1650 */ 762, 1797, 1799, 1800, 1801, 1802, 2329, 677, 686, 2395, - /* 1660 */ 700, 743, 2570, 288, 751, 290, 8, 709, 671, 687, - /* 1670 */ 2569, 685, 179, 295, 2542, 2429, 292, 297, 684, 717, - /* 1680 */ 411, 2624, 720, 1745, 146, 1871, 300, 294, 744, 1869, - /* 1690 */ 296, 2600, 1866, 191, 2536, 61, 749, 2297, 334, 307, - /* 1700 */ 155, 2428, 2296, 335, 2466, 2429, 754, 207, 116, 2430, - /* 1710 */ 747, 2432, 2433, 742, 2501, 765, 2447, 157, 741, 755, - /* 1720 */ 108, 2295, 2520, 336, 1308, 1, 735, 2516, 2395, 339, - /* 1730 */ 743, 106, 2150, 327, 2429, 767, 852, 421, 855, 351, - /* 1740 */ 2387, 2386, 2195, 52, 384, 164, 2447, 744, 857, 363, - /* 1750 */ 362, 2429, 2367, 352, 343, 2366, 2365, 82, 2395, 2360, - /* 1760 */ 743, 341, 443, 385, 744, 444, 1688, 1689, 210, 448, - /* 1770 */ 745, 2358, 452, 2466, 450, 2447, 451, 116, 2430, 747, - /* 1780 */ 2432, 2433, 742, 1687, 765, 2357, 387, 2395, 2355, 743, - /* 1790 */ 457, 2520, 2447, 2354, 459, 379, 2516, 2353, 461, 2352, - /* 1800 */ 2428, 463, 1676, 2466, 2395, 2333, 743, 360, 2430, 747, - /* 1810 */ 2432, 2433, 742, 740, 765, 731, 2485, 214, 2332, 216, - /* 1820 */ 2429, 83, 1640, 1639, 2310, 2309, 2308, 475, 476, 2428, - /* 1830 */ 2307, 2306, 2466, 744, 2257, 480, 176, 2430, 747, 2432, - /* 1840 */ 2433, 742, 2254, 765, 1583, 483, 2428, 486, 2244, 2466, - /* 1850 */ 2429, 2253, 2247, 177, 2430, 747, 2432, 2433, 742, 2243, - /* 1860 */ 765, 2447, 487, 744, 219, 86, 2242, 2241, 2246, 2245, - /* 1870 */ 221, 2240, 2239, 2395, 2237, 743, 2236, 2235, 683, 2561, - /* 1880 */ 503, 223, 2234, 505, 2232, 2231, 2230, 2429, 2229, 2252, - /* 1890 */ 2228, 2447, 2227, 2226, 2250, 2233, 2225, 2224, 2223, 2221, - /* 1900 */ 744, 2220, 2219, 2395, 2218, 743, 225, 713, 2622, 2217, - /* 1910 */ 2216, 2215, 2214, 2213, 2212, 2428, 2211, 2251, 2466, 2249, - /* 1920 */ 92, 2210, 116, 2430, 747, 2432, 2433, 742, 2447, 765, - /* 1930 */ 2209, 2208, 230, 2207, 2206, 542, 2520, 1589, 540, 2205, - /* 1940 */ 2395, 2517, 743, 2204, 1444, 2428, 1448, 2051, 2466, 2050, - /* 1950 */ 375, 2049, 176, 2430, 747, 2432, 2433, 742, 376, 765, - /* 1960 */ 2429, 2047, 408, 1440, 2044, 560, 558, 2043, 233, 559, - /* 1970 */ 235, 563, 236, 744, 562, 2429, 2036, 564, 566, 2023, - /* 1980 */ 568, 570, 2428, 567, 1998, 2466, 186, 238, 744, 361, - /* 1990 */ 2430, 747, 2432, 2433, 742, 2562, 765, 79, 1997, 2415, - /* 2000 */ 1332, 2447, 240, 196, 80, 578, 2429, 247, 249, 2304, - /* 2010 */ 2281, 2128, 252, 2395, 2331, 743, 2447, 2327, 2317, 744, - /* 2020 */ 2305, 2046, 2042, 597, 1379, 596, 2040, 598, 2395, 600, - /* 2030 */ 743, 601, 602, 2038, 604, 409, 606, 2035, 605, 608, - /* 2040 */ 609, 610, 2018, 2016, 2017, 2015, 1994, 2447, 2130, 1518, - /* 2050 */ 1517, 72, 2129, 258, 1416, 2428, 1430, 824, 2466, 2395, - /* 2060 */ 1429, 743, 361, 2430, 747, 2432, 2433, 742, 1427, 765, - /* 2070 */ 2428, 1425, 1424, 2466, 826, 2429, 1423, 354, 2430, 747, - /* 2080 */ 2432, 2433, 742, 2033, 765, 399, 1422, 1421, 741, 2031, - /* 2090 */ 1418, 1417, 1415, 2429, 400, 2022, 401, 2020, 402, 645, - /* 2100 */ 642, 2428, 1993, 1992, 2466, 1991, 744, 649, 177, 2430, - /* 2110 */ 747, 2432, 2433, 742, 1990, 765, 2447, 651, 1989, 2429, - /* 2120 */ 653, 118, 1670, 708, 1672, 1669, 2330, 280, 2395, 2326, - /* 2130 */ 743, 56, 744, 1674, 2447, 1648, 1646, 28, 2316, 1650, - /* 2140 */ 2303, 672, 57, 67, 2302, 673, 2395, 17, 743, 2606, - /* 2150 */ 678, 65, 688, 170, 284, 1625, 1624, 20, 30, 407, - /* 2160 */ 2447, 680, 6, 2623, 1924, 287, 692, 1898, 418, 694, - /* 2170 */ 2428, 690, 2395, 2466, 743, 7, 289, 360, 2430, 747, - /* 2180 */ 2432, 2433, 742, 21, 765, 1905, 2486, 22, 2428, 178, - /* 2190 */ 190, 2466, 1892, 664, 420, 361, 2430, 747, 2432, 2433, - /* 2200 */ 742, 189, 765, 31, 257, 2429, 32, 201, 2416, 24, - /* 2210 */ 303, 861, 1944, 81, 2428, 1945, 1863, 2466, 744, 1939, - /* 2220 */ 180, 361, 2430, 747, 2432, 2433, 742, 331, 765, 611, - /* 2230 */ 607, 603, 599, 1938, 256, 412, 1943, 1942, 413, 1862, - /* 2240 */ 59, 2301, 181, 194, 2280, 103, 2447, 25, 58, 102, - /* 2250 */ 23, 13, 849, 845, 841, 837, 18, 328, 2395, 1733, - /* 2260 */ 743, 1815, 11, 1790, 2429, 1814, 1825, 182, 192, 38, - /* 2270 */ 1767, 1789, 16, 26, 27, 97, 1759, 744, 254, 311, - /* 2280 */ 746, 752, 1900, 2279, 193, 317, 2429, 69, 104, 322, - /* 2290 */ 105, 109, 2471, 2470, 768, 1792, 319, 764, 114, 744, - /* 2300 */ 659, 321, 1503, 2466, 68, 2447, 766, 356, 2430, 747, - /* 2310 */ 2432, 2433, 742, 427, 765, 770, 772, 2395, 1500, 743, - /* 2320 */ 773, 775, 778, 1499, 776, 781, 784, 2447, 1496, 779, - /* 2330 */ 1479, 1490, 782, 326, 1488, 757, 785, 110, 111, 2395, - /* 2340 */ 1512, 743, 1494, 78, 1508, 791, 1493, 244, 1412, 1377, - /* 2350 */ 1409, 1492, 801, 1408, 1491, 1407, 253, 246, 1406, 2428, - /* 2360 */ 1404, 1402, 2466, 251, 588, 2429, 346, 2430, 747, 2432, - /* 2370 */ 2433, 742, 1401, 765, 1400, 1438, 812, 1437, 744, 309, - /* 2380 */ 208, 2428, 243, 814, 2466, 1398, 308, 2429, 345, 2430, - /* 2390 */ 747, 2432, 2433, 742, 1397, 765, 1396, 1395, 1394, 1393, - /* 2400 */ 744, 1392, 1432, 1434, 1389, 279, 2447, 1388, 1385, 1384, - /* 2410 */ 1383, 1382, 2041, 834, 835, 836, 2039, 839, 2395, 838, - /* 2420 */ 743, 840, 2037, 2429, 842, 844, 2034, 846, 2447, 843, - /* 2430 */ 2014, 848, 847, 1988, 850, 1321, 744, 1309, 854, 330, - /* 2440 */ 2395, 856, 743, 1719, 860, 340, 859, 1958, 1958, 1958, - /* 2450 */ 1958, 1958, 1958, 1958, 1958, 1958, 1958, 1958, 1958, 1958, - /* 2460 */ 2428, 1958, 1958, 2466, 2447, 1958, 1958, 347, 2430, 747, - /* 2470 */ 2432, 2433, 742, 1958, 765, 1958, 2395, 1958, 743, 1958, - /* 2480 */ 1958, 1958, 2428, 1958, 1958, 2466, 1958, 1958, 1958, 353, - /* 2490 */ 2430, 747, 2432, 2433, 742, 1958, 765, 1958, 1958, 1958, - /* 2500 */ 1958, 1958, 1958, 1958, 1958, 1958, 1958, 2429, 1958, 1958, - /* 2510 */ 1958, 1958, 1958, 1958, 1958, 1958, 1958, 1958, 2428, 1958, - /* 2520 */ 744, 2466, 2429, 1958, 1958, 357, 2430, 747, 2432, 2433, - /* 2530 */ 742, 1958, 765, 1958, 1958, 744, 1958, 2429, 1958, 1958, - /* 2540 */ 1958, 1958, 1958, 1958, 1958, 1958, 1958, 1958, 2447, 1958, - /* 2550 */ 744, 1958, 1958, 2429, 1958, 1958, 1958, 1958, 1958, 1958, - /* 2560 */ 2395, 1958, 743, 2447, 1958, 1958, 744, 1958, 1958, 1958, - /* 2570 */ 1958, 1958, 1958, 1958, 1958, 2395, 1958, 743, 2447, 1958, - /* 2580 */ 1958, 1958, 1958, 1958, 1958, 1958, 1958, 1958, 1958, 1958, - /* 2590 */ 2395, 1958, 743, 1958, 2447, 1958, 1958, 1958, 1958, 1958, - /* 2600 */ 1958, 1958, 2428, 1958, 1958, 2466, 2395, 1958, 743, 348, - /* 2610 */ 2430, 747, 2432, 2433, 742, 1958, 765, 2428, 1958, 1958, - /* 2620 */ 2466, 1958, 1958, 2429, 358, 2430, 747, 2432, 2433, 742, - /* 2630 */ 1958, 765, 2428, 1958, 1958, 2466, 744, 1958, 1958, 349, - /* 2640 */ 2430, 747, 2432, 2433, 742, 1958, 765, 1958, 2428, 1958, - /* 2650 */ 1958, 2466, 1958, 1958, 1958, 359, 2430, 747, 2432, 2433, - /* 2660 */ 742, 1958, 765, 1958, 2447, 1958, 1958, 2429, 1958, 1958, - /* 2670 */ 1958, 1958, 1958, 1958, 1958, 1958, 2395, 1958, 743, 1958, - /* 2680 */ 744, 1958, 1958, 1958, 1958, 1958, 1958, 1958, 1958, 1958, - /* 2690 */ 1958, 1958, 1958, 1958, 2429, 1958, 1958, 1958, 1958, 1958, - /* 2700 */ 1958, 1958, 1958, 1958, 1958, 1958, 1958, 744, 2447, 1958, - /* 2710 */ 1958, 1958, 1958, 1958, 1958, 1958, 1958, 1958, 2428, 1958, - /* 2720 */ 2395, 2466, 743, 1958, 1958, 350, 2430, 747, 2432, 2433, - /* 2730 */ 742, 1958, 765, 1958, 1958, 2447, 1958, 1958, 2429, 1958, - /* 2740 */ 1958, 1958, 1958, 1958, 1958, 1958, 1958, 2395, 1958, 743, - /* 2750 */ 1958, 744, 1958, 1958, 2429, 1958, 1958, 1958, 1958, 1958, - /* 2760 */ 1958, 1958, 2428, 1958, 1958, 2466, 1958, 744, 1958, 365, - /* 2770 */ 2430, 747, 2432, 2433, 742, 1958, 765, 2429, 1958, 2447, - /* 2780 */ 1958, 1958, 1958, 1958, 1958, 1958, 1958, 1958, 1958, 2428, - /* 2790 */ 744, 2395, 2466, 743, 1958, 2447, 366, 2430, 747, 2432, - /* 2800 */ 2433, 742, 1958, 765, 1958, 1958, 1958, 2395, 1958, 743, - /* 2810 */ 1958, 1958, 1958, 1958, 1958, 1958, 1958, 1958, 2447, 1958, - /* 2820 */ 1958, 1958, 1958, 1958, 1958, 1958, 1958, 1958, 1958, 1958, - /* 2830 */ 2395, 1958, 743, 2428, 1958, 2429, 2466, 1958, 1958, 1958, - /* 2840 */ 2441, 2430, 747, 2432, 2433, 742, 1958, 765, 744, 2428, - /* 2850 */ 1958, 2429, 2466, 1958, 1958, 1958, 2440, 2430, 747, 2432, - /* 2860 */ 2433, 742, 1958, 765, 744, 1958, 1958, 1958, 1958, 1958, - /* 2870 */ 1958, 1958, 2428, 1958, 1958, 2466, 2447, 1958, 1958, 2439, - /* 2880 */ 2430, 747, 2432, 2433, 742, 1958, 765, 1958, 2395, 1958, - /* 2890 */ 743, 1958, 2447, 1958, 1958, 1958, 1958, 1958, 1958, 1958, - /* 2900 */ 1958, 1958, 1958, 1958, 2395, 1958, 743, 1958, 1958, 2429, - /* 2910 */ 1958, 1958, 1958, 1958, 1958, 1958, 1958, 1958, 1958, 1958, - /* 2920 */ 1958, 1958, 744, 1958, 1958, 1958, 1958, 1958, 1958, 1958, - /* 2930 */ 2428, 1958, 1958, 2466, 2429, 1958, 1958, 381, 2430, 747, - /* 2940 */ 2432, 2433, 742, 1958, 765, 1958, 2428, 744, 1958, 2466, - /* 2950 */ 2447, 1958, 1958, 382, 2430, 747, 2432, 2433, 742, 1958, - /* 2960 */ 765, 1958, 2395, 1958, 743, 1958, 1958, 2429, 1958, 1958, - /* 2970 */ 1958, 1958, 1958, 1958, 1958, 2447, 1958, 1958, 1958, 1958, - /* 2980 */ 744, 1958, 1958, 1958, 1958, 1958, 1958, 2395, 1958, 743, - /* 2990 */ 1958, 1958, 1958, 1958, 1958, 1958, 1958, 1958, 1958, 1958, - /* 3000 */ 1958, 1958, 1958, 1958, 2428, 1958, 1958, 2466, 2447, 1958, - /* 3010 */ 1958, 378, 2430, 747, 2432, 2433, 742, 1958, 765, 1958, - /* 3020 */ 2395, 1958, 743, 1958, 1958, 1958, 1958, 1958, 1958, 2428, - /* 3030 */ 1958, 1958, 2466, 1958, 1958, 1958, 383, 2430, 747, 2432, - /* 3040 */ 2433, 742, 1958, 765, 1958, 1958, 1958, 1958, 1958, 1958, - /* 3050 */ 1958, 1958, 1958, 2429, 1958, 1958, 1958, 1958, 1958, 1958, - /* 3060 */ 1958, 1958, 745, 1958, 1958, 2466, 744, 1958, 1958, 356, - /* 3070 */ 2430, 747, 2432, 2433, 742, 1958, 765, 1958, 1958, 1958, - /* 3080 */ 1958, 1958, 1958, 1958, 1958, 1958, 1958, 1958, 1958, 1958, - /* 3090 */ 1958, 1958, 1958, 1958, 2447, 1958, 1958, 1958, 1958, 1958, - /* 3100 */ 1958, 1958, 1958, 1958, 1958, 1958, 2395, 1958, 743, 1958, - /* 3110 */ 1958, 1958, 1958, 1958, 1958, 1958, 1958, 1958, 1958, 1958, - /* 3120 */ 1958, 1958, 1958, 1958, 1958, 1958, 1958, 1958, 1958, 1958, - /* 3130 */ 1958, 1958, 1958, 1958, 1958, 1958, 1958, 1958, 1958, 1958, - /* 3140 */ 1958, 1958, 1958, 1958, 1958, 1958, 1958, 1958, 2428, 1958, - /* 3150 */ 1958, 2466, 1958, 1958, 1958, 355, 2430, 747, 2432, 2433, - /* 3160 */ 742, 1958, 765, + /* 0 */ 2349, 174, 239, 2485, 791, 2209, 607, 741, 2070, 2148, + /* 10 */ 2681, 2200, 47, 45, 1937, 442, 504, 2615, 2346, 778, + /* 20 */ 439, 503, 1777, 2020, 138, 753, 147, 2489, 740, 204, + /* 30 */ 2469, 647, 1802, 2682, 742, 1863, 2105, 1775, 46, 44, + /* 40 */ 43, 42, 41, 2612, 128, 2509, 1471, 127, 126, 125, + /* 50 */ 124, 123, 122, 121, 120, 119, 40, 39, 756, 1802, + /* 60 */ 46, 44, 43, 42, 41, 1858, 445, 712, 185, 735, + /* 70 */ 2681, 19, 2491, 2493, 436, 791, 2209, 795, 1783, 2686, + /* 80 */ 790, 29, 2681, 795, 2263, 445, 2527, 1473, 2687, 204, + /* 90 */ 410, 408, 2329, 2682, 742, 138, 795, 2527, 2475, 2261, + /* 100 */ 773, 2685, 652, 695, 888, 2682, 2684, 15, 1941, 863, + /* 110 */ 862, 861, 860, 467, 1802, 859, 858, 152, 853, 852, + /* 120 */ 851, 850, 849, 848, 847, 151, 841, 840, 839, 466, + /* 130 */ 465, 836, 835, 834, 184, 183, 833, 302, 2608, 752, + /* 140 */ 2508, 139, 751, 2546, 2681, 1865, 1866, 115, 2510, 777, + /* 150 */ 2512, 2513, 772, 173, 795, 175, 1982, 2031, 364, 187, + /* 160 */ 734, 2600, 740, 204, 609, 435, 2596, 2682, 742, 2468, + /* 170 */ 606, 741, 456, 601, 2681, 362, 75, 66, 846, 74, + /* 180 */ 206, 2170, 599, 1837, 1847, 595, 591, 620, 2630, 391, + /* 190 */ 1864, 1867, 740, 204, 1364, 1636, 1637, 2682, 742, 753, + /* 200 */ 147, 237, 586, 584, 581, 1778, 443, 1776, 197, 753, + /* 210 */ 147, 40, 39, 1371, 172, 46, 44, 43, 42, 41, + /* 220 */ 2250, 790, 2211, 128, 445, 2428, 127, 126, 125, 124, + /* 230 */ 123, 122, 121, 120, 119, 795, 1366, 1369, 1370, 1781, + /* 240 */ 1782, 1834, 62, 1836, 1839, 1840, 1841, 1842, 1843, 1844, + /* 250 */ 1845, 1846, 769, 793, 792, 1857, 1859, 1860, 1861, 1862, + /* 260 */ 2, 47, 45, 2019, 2397, 1802, 388, 2685, 1800, 439, + /* 270 */ 1390, 1777, 1389, 790, 400, 554, 712, 1838, 574, 2681, + /* 280 */ 62, 624, 63, 573, 1863, 2429, 1775, 137, 136, 135, + /* 290 */ 134, 133, 132, 131, 130, 129, 1805, 2687, 204, 534, + /* 300 */ 1803, 575, 2682, 742, 832, 1391, 389, 536, 50, 693, + /* 310 */ 755, 202, 2608, 2609, 1858, 145, 2613, 514, 1892, 276, + /* 320 */ 19, 203, 2608, 2609, 241, 145, 2613, 1783, 607, 2185, + /* 330 */ 2070, 736, 85, 84, 507, 1835, 712, 217, 1934, 2681, + /* 340 */ 604, 40, 39, 605, 2062, 46, 44, 43, 42, 41, + /* 350 */ 499, 497, 62, 888, 411, 2686, 15, 2687, 204, 1529, + /* 360 */ 50, 387, 2682, 742, 486, 522, 2496, 483, 479, 475, + /* 370 */ 472, 500, 1805, 791, 2209, 1520, 820, 819, 818, 1524, + /* 380 */ 817, 1526, 1527, 816, 813, 1893, 1535, 810, 1537, 1538, + /* 390 */ 807, 804, 801, 209, 1865, 1866, 1783, 2336, 2315, 832, + /* 400 */ 562, 561, 560, 559, 558, 553, 552, 551, 550, 394, + /* 410 */ 464, 463, 306, 540, 539, 538, 537, 531, 530, 529, + /* 420 */ 731, 524, 523, 409, 2498, 1564, 1565, 515, 1624, 1625, + /* 430 */ 1970, 96, 1837, 1847, 1643, 1784, 1806, 40, 39, 1864, + /* 440 */ 1867, 46, 44, 43, 42, 41, 314, 315, 412, 1806, + /* 450 */ 306, 313, 416, 415, 1778, 185, 1776, 2204, 40, 39, + /* 460 */ 2005, 304, 46, 44, 43, 42, 41, 36, 437, 1887, + /* 470 */ 1888, 1889, 1890, 1891, 1895, 1896, 1897, 1898, 306, 2330, + /* 480 */ 728, 727, 1968, 1969, 1971, 1972, 1973, 100, 1781, 1782, + /* 490 */ 1834, 12, 1836, 1839, 1840, 1841, 1842, 1843, 1844, 1845, + /* 500 */ 1846, 769, 793, 792, 1857, 1859, 1860, 1861, 1862, 2, + /* 510 */ 12, 47, 45, 2509, 737, 732, 725, 721, 1684, 439, + /* 520 */ 2298, 1777, 306, 2042, 414, 413, 774, 649, 612, 2485, + /* 530 */ 2012, 605, 2062, 33, 1863, 2686, 1775, 304, 2681, 40, + /* 540 */ 39, 673, 843, 46, 44, 43, 42, 41, 1390, 823, + /* 550 */ 1389, 651, 1834, 2489, 2527, 650, 685, 2685, 1981, 2186, + /* 560 */ 2349, 2682, 2683, 744, 1858, 143, 2475, 2108, 773, 2184, + /* 570 */ 19, 2509, 272, 666, 665, 664, 2475, 1783, 2347, 778, + /* 580 */ 656, 144, 660, 1391, 756, 107, 659, 696, 676, 37, + /* 590 */ 310, 658, 663, 418, 417, 670, 668, 657, 2491, 2494, + /* 600 */ 653, 195, 269, 888, 565, 1787, 15, 845, 2508, 795, + /* 610 */ 2202, 2546, 2527, 1933, 200, 115, 2510, 777, 2512, 2513, + /* 620 */ 772, 12, 795, 10, 2475, 149, 773, 156, 2571, 2600, + /* 630 */ 791, 2209, 349, 435, 2596, 2257, 2258, 2011, 2017, 1777, + /* 640 */ 666, 665, 664, 71, 1865, 1866, 70, 656, 144, 660, + /* 650 */ 55, 488, 460, 659, 1775, 2256, 2258, 1807, 658, 663, + /* 660 */ 418, 417, 614, 2388, 657, 767, 2508, 653, 229, 2546, + /* 670 */ 1807, 520, 2325, 115, 2510, 777, 2512, 2513, 772, 2198, + /* 680 */ 795, 224, 1837, 1847, 547, 187, 2194, 2600, 546, 1864, + /* 690 */ 1867, 435, 2596, 564, 228, 1783, 545, 830, 162, 161, + /* 700 */ 827, 826, 825, 159, 1778, 451, 1776, 830, 162, 161, + /* 710 */ 827, 826, 825, 159, 2631, 2263, 791, 2209, 470, 511, + /* 720 */ 220, 888, 91, 469, 688, 90, 687, 40, 39, 1802, + /* 730 */ 760, 46, 44, 43, 42, 41, 508, 274, 1781, 1782, + /* 740 */ 1834, 273, 1836, 1839, 1840, 1841, 1842, 1843, 1844, 1845, + /* 750 */ 1846, 769, 793, 792, 1857, 1859, 1860, 1861, 1862, 2, + /* 760 */ 47, 45, 1868, 2509, 571, 569, 2196, 390, 439, 712, + /* 770 */ 1777, 218, 2681, 753, 147, 160, 774, 2263, 2072, 526, + /* 780 */ 2325, 172, 492, 1863, 424, 1775, 2615, 791, 2209, 2212, + /* 790 */ 2687, 204, 2261, 2509, 89, 2682, 742, 830, 162, 161, + /* 800 */ 827, 826, 825, 159, 2527, 198, 774, 509, 2638, 494, + /* 810 */ 490, 99, 2611, 1858, 397, 62, 2475, 423, 773, 686, + /* 820 */ 62, 762, 1778, 2572, 1776, 35, 1783, 1953, 222, 791, + /* 830 */ 2209, 40, 39, 1884, 2527, 46, 44, 43, 42, 41, + /* 840 */ 791, 2209, 791, 2209, 791, 2209, 2475, 1873, 773, 528, + /* 850 */ 54, 454, 888, 1802, 621, 48, 1781, 1782, 2508, 696, + /* 860 */ 541, 2546, 542, 2509, 543, 115, 2510, 777, 2512, 2513, + /* 870 */ 772, 2041, 795, 2040, 691, 1746, 774, 2701, 2651, 2600, + /* 880 */ 556, 2325, 2615, 435, 2596, 205, 2608, 2609, 2508, 145, + /* 890 */ 2613, 2546, 1838, 1865, 1866, 115, 2510, 777, 2512, 2513, + /* 900 */ 772, 96, 795, 697, 2527, 450, 449, 2701, 2610, 2600, + /* 910 */ 622, 2342, 1371, 435, 2596, 2149, 2475, 502, 773, 501, + /* 920 */ 464, 463, 791, 2209, 2475, 712, 2475, 2205, 2681, 227, + /* 930 */ 1791, 1837, 1847, 1806, 698, 2388, 1369, 1370, 1864, 1867, + /* 940 */ 791, 2209, 623, 1863, 2192, 1784, 2687, 204, 458, 500, + /* 950 */ 1835, 2682, 742, 1778, 712, 1776, 169, 2681, 2508, 1962, + /* 960 */ 2206, 2546, 2282, 425, 2211, 115, 2510, 777, 2512, 2513, + /* 970 */ 772, 2261, 795, 1858, 1963, 2687, 204, 2701, 822, 2600, + /* 980 */ 2682, 742, 757, 435, 2596, 306, 1783, 1781, 1782, 1834, + /* 990 */ 306, 1836, 1839, 1840, 1841, 1842, 1843, 1844, 1845, 1846, + /* 1000 */ 769, 793, 792, 1857, 1859, 1860, 1861, 1862, 2, 47, + /* 1010 */ 45, 684, 766, 51, 282, 1961, 1838, 439, 768, 1777, + /* 1020 */ 2263, 1745, 2263, 458, 1803, 2509, 682, 434, 680, 271, + /* 1030 */ 270, 172, 1863, 712, 1775, 2261, 2681, 786, 774, 2211, + /* 1040 */ 723, 40, 39, 2263, 1806, 46, 44, 43, 42, 41, + /* 1050 */ 444, 453, 452, 2644, 2687, 204, 791, 2209, 2261, 2682, + /* 1060 */ 742, 651, 1858, 40, 39, 650, 2527, 46, 44, 43, + /* 1070 */ 42, 41, 791, 2209, 1835, 1783, 277, 1802, 2475, 711, + /* 1080 */ 773, 461, 791, 2209, 2039, 791, 2209, 791, 2209, 172, + /* 1090 */ 791, 2209, 285, 2263, 791, 2209, 1483, 2211, 199, 2038, + /* 1100 */ 459, 888, 759, 2509, 48, 318, 275, 788, 2261, 148, + /* 1110 */ 789, 1482, 2571, 1792, 345, 1787, 774, 764, 2674, 2572, + /* 1120 */ 2508, 1894, 2037, 2546, 549, 548, 2036, 115, 2510, 777, + /* 1130 */ 2512, 2513, 772, 729, 795, 791, 2209, 2475, 1487, 2701, + /* 1140 */ 9, 2600, 1865, 1866, 2527, 435, 2596, 1795, 1797, 1656, + /* 1150 */ 1657, 113, 2475, 1486, 1807, 462, 2475, 2416, 773, 1393, + /* 1160 */ 1394, 793, 792, 1857, 1859, 1860, 1861, 1862, 150, 43, + /* 1170 */ 42, 41, 14, 13, 2035, 2475, 2201, 2034, 576, 2475, + /* 1180 */ 1837, 1847, 299, 306, 2263, 1705, 1706, 1864, 1867, 745, + /* 1190 */ 643, 642, 645, 644, 1655, 1658, 662, 661, 2508, 2262, + /* 1200 */ 748, 2546, 1778, 34, 1776, 115, 2510, 777, 2512, 2513, + /* 1210 */ 772, 2033, 795, 1899, 60, 2032, 2030, 2701, 171, 2600, + /* 1220 */ 578, 293, 709, 435, 2596, 2029, 142, 2475, 2528, 2028, + /* 1230 */ 2475, 2027, 2026, 2025, 2024, 2023, 1781, 1782, 1834, 2022, + /* 1240 */ 1836, 1839, 1840, 1841, 1842, 1843, 1844, 1845, 1846, 769, + /* 1250 */ 793, 792, 1857, 1859, 1860, 1861, 1862, 2, 47, 45, + /* 1260 */ 2334, 2509, 857, 855, 2475, 1807, 439, 824, 1777, 2475, + /* 1270 */ 2254, 2419, 828, 2308, 774, 2254, 2619, 829, 2475, 1906, + /* 1280 */ 2254, 1863, 2475, 1775, 2475, 2475, 2475, 2475, 2475, 3, + /* 1290 */ 358, 2509, 2475, 2240, 1373, 2047, 883, 140, 1835, 77, + /* 1300 */ 1801, 53, 2527, 2187, 774, 2620, 1926, 262, 2092, 87, + /* 1310 */ 260, 1858, 2090, 654, 2475, 518, 773, 264, 266, 655, + /* 1320 */ 263, 265, 477, 268, 1783, 2081, 267, 2079, 160, 160, + /* 1330 */ 667, 719, 2527, 2146, 669, 286, 153, 1468, 2014, 2015, + /* 1340 */ 14, 13, 49, 1466, 2475, 2145, 773, 671, 49, 674, + /* 1350 */ 888, 188, 160, 15, 88, 2063, 2508, 64, 2073, 2546, + /* 1360 */ 2509, 324, 323, 115, 2510, 777, 2512, 2513, 772, 49, + /* 1370 */ 795, 49, 1786, 774, 1926, 2701, 2634, 2600, 426, 101, + /* 1380 */ 1785, 435, 2596, 726, 312, 76, 2508, 1426, 211, 2546, + /* 1390 */ 112, 1865, 1866, 115, 2510, 777, 2512, 2513, 772, 109, + /* 1400 */ 795, 2527, 158, 1700, 1703, 2575, 1957, 2600, 393, 392, + /* 1410 */ 881, 435, 2596, 2475, 430, 773, 733, 1967, 446, 326, + /* 1420 */ 325, 328, 327, 1966, 330, 329, 291, 758, 1427, 1837, + /* 1430 */ 1847, 1863, 1900, 455, 160, 73, 1864, 1867, 332, 331, + /* 1440 */ 334, 333, 336, 335, 1848, 780, 1653, 338, 337, 340, + /* 1450 */ 339, 1778, 799, 1776, 158, 2508, 160, 746, 2546, 316, + /* 1460 */ 783, 1858, 115, 2510, 777, 2512, 2513, 772, 468, 795, + /* 1470 */ 749, 342, 341, 2335, 2573, 2509, 2600, 320, 344, 343, + /* 1480 */ 435, 2596, 141, 158, 837, 1781, 1782, 1834, 774, 1836, + /* 1490 */ 1839, 1840, 1841, 1842, 1843, 1844, 1845, 1846, 769, 793, + /* 1500 */ 792, 1857, 1859, 1860, 1861, 1862, 2, 2509, 1445, 1513, + /* 1510 */ 357, 838, 2069, 705, 2251, 2635, 2527, 2645, 301, 754, + /* 1520 */ 774, 298, 2171, 305, 5, 471, 476, 1542, 2475, 1546, + /* 1530 */ 773, 1553, 406, 484, 485, 1443, 1810, 496, 212, 213, + /* 1540 */ 495, 215, 1789, 498, 1677, 352, 1800, 512, 2527, 519, + /* 1550 */ 1788, 1801, 226, 567, 521, 525, 527, 1551, 163, 532, + /* 1560 */ 2475, 544, 773, 555, 2327, 557, 579, 563, 566, 568, + /* 1570 */ 2508, 580, 577, 2546, 232, 582, 583, 115, 2510, 777, + /* 1580 */ 2512, 2513, 772, 231, 795, 234, 585, 587, 1808, 763, + /* 1590 */ 602, 2600, 4, 603, 610, 435, 2596, 611, 242, 93, + /* 1600 */ 613, 1768, 2508, 1744, 1803, 2546, 2509, 245, 1809, 116, + /* 1610 */ 2510, 777, 2512, 2513, 772, 615, 795, 616, 1811, 774, + /* 1620 */ 617, 248, 619, 2600, 1812, 2343, 250, 2599, 2596, 625, + /* 1630 */ 94, 95, 255, 448, 447, 1769, 648, 646, 2199, 259, + /* 1640 */ 2195, 384, 261, 677, 2406, 117, 678, 2527, 165, 793, + /* 1650 */ 792, 1857, 1859, 1860, 1861, 1862, 166, 2197, 690, 2475, + /* 1660 */ 2193, 773, 167, 692, 168, 2403, 2402, 98, 278, 353, + /* 1670 */ 154, 1804, 707, 701, 700, 2509, 283, 699, 2389, 281, + /* 1680 */ 704, 8, 730, 716, 2650, 781, 2649, 717, 774, 739, + /* 1690 */ 2622, 288, 715, 179, 714, 290, 706, 431, 292, 294, + /* 1700 */ 295, 2508, 2704, 296, 2546, 2509, 750, 1926, 116, 2510, + /* 1710 */ 777, 2512, 2513, 772, 747, 795, 2527, 297, 771, 146, + /* 1720 */ 1805, 2680, 2600, 1931, 300, 1929, 765, 2596, 2475, 191, + /* 1730 */ 773, 307, 155, 61, 2509, 2616, 354, 779, 784, 2357, + /* 1740 */ 2356, 2355, 355, 441, 157, 2581, 2527, 774, 785, 106, + /* 1750 */ 2210, 2509, 108, 2467, 356, 2466, 2462, 2461, 2475, 797, + /* 1760 */ 773, 1, 1348, 885, 774, 882, 371, 207, 887, 359, + /* 1770 */ 775, 2453, 2452, 2546, 2444, 2527, 2443, 116, 2510, 777, + /* 1780 */ 2512, 2513, 772, 404, 795, 2459, 2458, 2475, 2450, 773, + /* 1790 */ 2427, 2600, 2527, 2449, 2438, 399, 2596, 2437, 2456, 2455, + /* 1800 */ 2508, 2447, 2446, 2546, 2475, 52, 773, 380, 2510, 777, + /* 1810 */ 2512, 2513, 772, 770, 795, 761, 2565, 2435, 347, 2434, + /* 1820 */ 2509, 2432, 2431, 361, 164, 382, 2255, 405, 383, 2508, + /* 1830 */ 363, 372, 2546, 774, 2426, 2425, 176, 2510, 777, 2512, + /* 1840 */ 2513, 772, 82, 795, 2420, 473, 2508, 1728, 474, 2546, + /* 1850 */ 2509, 1729, 210, 177, 2510, 777, 2512, 2513, 772, 478, + /* 1860 */ 795, 2527, 2418, 774, 480, 481, 482, 1727, 2417, 407, + /* 1870 */ 2415, 2414, 2413, 2475, 487, 773, 489, 491, 713, 2641, + /* 1880 */ 2412, 1716, 493, 2393, 214, 2392, 216, 2509, 83, 1680, + /* 1890 */ 1679, 2527, 2370, 2369, 2368, 505, 506, 2367, 2366, 2317, + /* 1900 */ 774, 510, 1623, 2475, 2314, 773, 513, 743, 2702, 2313, + /* 1910 */ 2307, 516, 517, 2304, 219, 2508, 2303, 2302, 2546, 2301, + /* 1920 */ 86, 2306, 116, 2510, 777, 2512, 2513, 772, 2527, 795, + /* 1930 */ 221, 2305, 2300, 2299, 2297, 2296, 2600, 2295, 223, 533, + /* 1940 */ 2475, 2597, 773, 2294, 535, 2508, 2292, 2291, 2546, 2290, + /* 1950 */ 2289, 2312, 176, 2510, 777, 2512, 2513, 772, 2288, 795, + /* 1960 */ 2509, 2287, 428, 2286, 2310, 2293, 2285, 2284, 2283, 2281, + /* 1970 */ 2280, 2279, 2278, 774, 2277, 2509, 2276, 2275, 225, 2274, + /* 1980 */ 2273, 92, 2508, 2272, 2271, 2546, 2311, 2309, 774, 381, + /* 1990 */ 2510, 777, 2512, 2513, 772, 2642, 795, 2270, 2269, 2268, + /* 2000 */ 1629, 2527, 2267, 2266, 230, 570, 2509, 572, 2265, 2264, + /* 2010 */ 1484, 1488, 395, 2475, 2111, 773, 2527, 233, 1480, 774, + /* 2020 */ 2110, 235, 2109, 396, 236, 2107, 2104, 588, 2475, 1372, + /* 2030 */ 773, 2103, 592, 589, 590, 429, 593, 2096, 594, 2083, + /* 2040 */ 2058, 596, 597, 598, 2057, 238, 186, 2527, 600, 240, + /* 2050 */ 2391, 2387, 79, 2377, 2495, 2508, 2365, 2364, 2546, 2475, + /* 2060 */ 80, 773, 381, 2510, 777, 2512, 2513, 772, 196, 795, + /* 2070 */ 2508, 2341, 608, 2546, 247, 2509, 252, 374, 2510, 777, + /* 2080 */ 2512, 2513, 772, 249, 795, 2188, 2106, 2102, 771, 1419, + /* 2090 */ 628, 626, 627, 2509, 2100, 630, 631, 632, 2098, 634, + /* 2100 */ 635, 2508, 636, 2095, 2546, 638, 774, 2078, 177, 2510, + /* 2110 */ 777, 2512, 2513, 772, 639, 795, 2527, 640, 2076, 2509, + /* 2120 */ 2077, 2075, 2054, 738, 2190, 1558, 1557, 72, 2475, 258, + /* 2130 */ 773, 2189, 774, 1470, 2527, 2093, 1469, 1467, 1465, 1464, + /* 2140 */ 2091, 1456, 1463, 1462, 854, 1461, 2475, 856, 773, 1458, + /* 2150 */ 1457, 419, 1455, 2082, 420, 421, 2080, 2053, 422, 2052, + /* 2160 */ 2527, 2051, 672, 2703, 675, 679, 2050, 681, 438, 683, + /* 2170 */ 2508, 2049, 2475, 2546, 773, 118, 1710, 380, 2510, 777, + /* 2180 */ 2512, 2513, 772, 1712, 795, 1709, 2566, 1714, 2508, 28, + /* 2190 */ 2390, 2546, 280, 694, 440, 381, 2510, 777, 2512, 2513, + /* 2200 */ 772, 2386, 795, 1688, 257, 2509, 56, 1686, 2376, 702, + /* 2210 */ 2363, 891, 2362, 57, 2508, 20, 2686, 2546, 774, 703, + /* 2220 */ 180, 381, 2510, 777, 2512, 2513, 772, 351, 795, 641, + /* 2230 */ 637, 633, 629, 67, 256, 284, 1690, 1665, 170, 17, + /* 2240 */ 718, 30, 427, 194, 6, 1984, 2527, 7, 287, 1664, + /* 2250 */ 1958, 708, 879, 875, 871, 867, 722, 348, 2475, 710, + /* 2260 */ 773, 720, 21, 724, 2509, 22, 289, 190, 201, 2496, + /* 2270 */ 1965, 1952, 178, 32, 189, 97, 23, 774, 254, 31, + /* 2280 */ 81, 65, 2004, 2005, 24, 1999, 2509, 1998, 1923, 432, + /* 2290 */ 2003, 2002, 433, 1922, 303, 59, 181, 2361, 114, 774, + /* 2300 */ 689, 321, 2340, 2546, 25, 2527, 102, 376, 2510, 777, + /* 2310 */ 2512, 2513, 772, 58, 795, 18, 103, 2475, 13, 773, + /* 2320 */ 1875, 1874, 1793, 11, 182, 1850, 1849, 2527, 1885, 38, + /* 2330 */ 16, 26, 192, 1819, 1827, 787, 311, 776, 27, 2475, + /* 2340 */ 193, 773, 2339, 1960, 317, 69, 104, 244, 105, 2551, + /* 2350 */ 322, 2550, 109, 346, 1852, 319, 253, 246, 798, 2508, + /* 2360 */ 796, 457, 2546, 251, 618, 2509, 366, 2510, 777, 2512, + /* 2370 */ 2513, 772, 782, 795, 794, 68, 802, 1543, 774, 309, + /* 2380 */ 800, 2508, 243, 803, 2546, 1540, 308, 2509, 365, 2510, + /* 2390 */ 777, 2512, 2513, 772, 1539, 795, 805, 806, 808, 1536, + /* 2400 */ 774, 809, 811, 1530, 1528, 279, 2527, 814, 1519, 1534, + /* 2410 */ 812, 1533, 815, 110, 1532, 1531, 821, 111, 2475, 1552, + /* 2420 */ 773, 78, 1548, 2509, 1417, 831, 1452, 1449, 2527, 1448, + /* 2430 */ 1447, 1446, 1444, 1478, 1442, 1441, 774, 208, 1440, 842, + /* 2440 */ 2475, 1477, 773, 1438, 844, 1437, 1436, 1435, 1434, 1433, + /* 2450 */ 1432, 1474, 1472, 1429, 1428, 1425, 1423, 1424, 1422, 2101, + /* 2460 */ 2508, 864, 2099, 2546, 2527, 865, 868, 367, 2510, 777, + /* 2470 */ 2512, 2513, 772, 866, 795, 870, 2475, 869, 773, 2097, + /* 2480 */ 872, 873, 2508, 874, 2094, 2546, 876, 877, 878, 373, + /* 2490 */ 2510, 777, 2512, 2513, 772, 2074, 795, 880, 1361, 2048, + /* 2500 */ 1349, 884, 350, 886, 2018, 1779, 889, 2509, 360, 890, + /* 2510 */ 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2508, 2018, + /* 2520 */ 774, 2546, 2509, 2018, 2018, 377, 2510, 777, 2512, 2513, + /* 2530 */ 772, 2018, 795, 2018, 2018, 774, 2018, 2509, 2018, 2018, + /* 2540 */ 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2527, 2018, + /* 2550 */ 774, 2018, 2018, 2509, 2018, 2018, 2018, 2018, 2018, 2018, + /* 2560 */ 2475, 2018, 773, 2527, 2018, 2018, 774, 2018, 2018, 2018, + /* 2570 */ 2018, 2018, 2018, 2018, 2018, 2475, 2018, 773, 2527, 2018, + /* 2580 */ 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2018, + /* 2590 */ 2475, 2018, 773, 2018, 2527, 2018, 2018, 2018, 2018, 2018, + /* 2600 */ 2018, 2018, 2508, 2018, 2018, 2546, 2475, 2018, 773, 368, + /* 2610 */ 2510, 777, 2512, 2513, 772, 2018, 795, 2508, 2018, 2018, + /* 2620 */ 2546, 2018, 2018, 2509, 378, 2510, 777, 2512, 2513, 772, + /* 2630 */ 2018, 795, 2508, 2018, 2018, 2546, 774, 2018, 2018, 369, + /* 2640 */ 2510, 777, 2512, 2513, 772, 2018, 795, 2018, 2508, 2018, + /* 2650 */ 2018, 2546, 2018, 2018, 2018, 379, 2510, 777, 2512, 2513, + /* 2660 */ 772, 2018, 795, 2018, 2527, 2018, 2018, 2509, 2018, 2018, + /* 2670 */ 2018, 2018, 2018, 2018, 2018, 2018, 2475, 2018, 773, 2018, + /* 2680 */ 774, 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2018, + /* 2690 */ 2018, 2018, 2018, 2018, 2509, 2018, 2018, 2018, 2018, 2018, + /* 2700 */ 2018, 2018, 2018, 2018, 2018, 2018, 2018, 774, 2527, 2018, + /* 2710 */ 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2508, 2018, + /* 2720 */ 2475, 2546, 773, 2018, 2018, 370, 2510, 777, 2512, 2513, + /* 2730 */ 772, 2018, 795, 2018, 2018, 2527, 2018, 2018, 2509, 2018, + /* 2740 */ 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2475, 2018, 773, + /* 2750 */ 2018, 774, 2018, 2018, 2509, 2018, 2018, 2018, 2018, 2018, + /* 2760 */ 2018, 2018, 2508, 2018, 2018, 2546, 2018, 774, 2018, 385, + /* 2770 */ 2510, 777, 2512, 2513, 772, 2018, 795, 2509, 2018, 2527, + /* 2780 */ 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2508, + /* 2790 */ 774, 2475, 2546, 773, 2018, 2527, 386, 2510, 777, 2512, + /* 2800 */ 2513, 772, 2018, 795, 2018, 2018, 2018, 2475, 2018, 773, + /* 2810 */ 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2527, 2018, + /* 2820 */ 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2018, + /* 2830 */ 2475, 2018, 773, 2508, 2018, 2509, 2546, 2018, 2018, 2018, + /* 2840 */ 2521, 2510, 777, 2512, 2513, 772, 2018, 795, 774, 2508, + /* 2850 */ 2018, 2509, 2546, 2018, 2018, 2018, 2520, 2510, 777, 2512, + /* 2860 */ 2513, 772, 2018, 795, 774, 2018, 2018, 2018, 2018, 2018, + /* 2870 */ 2018, 2018, 2508, 2018, 2018, 2546, 2527, 2018, 2018, 2519, + /* 2880 */ 2510, 777, 2512, 2513, 772, 2018, 795, 2018, 2475, 2018, + /* 2890 */ 773, 2018, 2527, 2018, 2018, 2018, 2018, 2018, 2018, 2018, + /* 2900 */ 2018, 2018, 2018, 2018, 2475, 2018, 773, 2018, 2018, 2509, + /* 2910 */ 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2018, + /* 2920 */ 2018, 2018, 774, 2018, 2018, 2018, 2018, 2018, 2018, 2018, + /* 2930 */ 2508, 2018, 2018, 2546, 2509, 2018, 2018, 401, 2510, 777, + /* 2940 */ 2512, 2513, 772, 2018, 795, 2018, 2508, 774, 2018, 2546, + /* 2950 */ 2527, 2018, 2018, 402, 2510, 777, 2512, 2513, 772, 2018, + /* 2960 */ 795, 2018, 2475, 2018, 773, 2018, 2018, 2509, 2018, 2018, + /* 2970 */ 2018, 2018, 2018, 2018, 2018, 2527, 2018, 2018, 2018, 2018, + /* 2980 */ 774, 2018, 2018, 2018, 2018, 2018, 2018, 2475, 2018, 773, + /* 2990 */ 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2018, + /* 3000 */ 2018, 2018, 2018, 2018, 2508, 2018, 2018, 2546, 2527, 2018, + /* 3010 */ 2018, 398, 2510, 777, 2512, 2513, 772, 2018, 795, 2018, + /* 3020 */ 2475, 2018, 773, 2018, 2018, 2018, 2018, 2018, 2018, 2508, + /* 3030 */ 2018, 2018, 2546, 2018, 2018, 2018, 403, 2510, 777, 2512, + /* 3040 */ 2513, 772, 2018, 795, 2018, 2018, 2018, 2018, 2018, 2018, + /* 3050 */ 2018, 2018, 2018, 2509, 2018, 2018, 2018, 2018, 2018, 2018, + /* 3060 */ 2018, 2018, 775, 2018, 2018, 2546, 774, 2018, 2018, 376, + /* 3070 */ 2510, 777, 2512, 2513, 772, 2018, 795, 2018, 2018, 2018, + /* 3080 */ 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2018, + /* 3090 */ 2018, 2018, 2018, 2018, 2527, 2018, 2018, 2018, 2018, 2018, + /* 3100 */ 2018, 2018, 2018, 2018, 2018, 2018, 2475, 2018, 773, 2018, + /* 3110 */ 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2018, + /* 3120 */ 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2018, + /* 3130 */ 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2018, + /* 3140 */ 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2018, 2508, 2018, + /* 3150 */ 2018, 2546, 2018, 2018, 2018, 375, 2510, 777, 2512, 2513, + /* 3160 */ 772, 2018, 795, }; static const YYCODETYPE yy_lookahead[] = { /* 0 */ 413, 380, 366, 387, 370, 371, 370, 486, 372, 388, @@ -678,120 +678,120 @@ static const YYCODETYPE yy_lookahead[] = { /* 1340 */ 1, 2, 33, 37, 411, 387, 413, 22, 33, 22, /* 1350 */ 104, 33, 33, 107, 172, 369, 453, 33, 0, 456, /* 1360 */ 358, 12, 13, 460, 461, 462, 463, 464, 465, 33, - /* 1370 */ 467, 33, 37, 371, 276, 472, 424, 474, 37, 109, - /* 1380 */ 37, 478, 479, 504, 33, 33, 453, 504, 231, 456, + /* 1370 */ 467, 33, 37, 371, 276, 472, 424, 474, 434, 109, + /* 1380 */ 37, 478, 479, 504, 33, 33, 453, 37, 231, 456, /* 1390 */ 107, 145, 146, 460, 461, 462, 463, 464, 465, 116, /* 1400 */ 467, 399, 33, 108, 108, 472, 108, 474, 12, 13, - /* 1410 */ 52, 478, 479, 411, 504, 413, 434, 108, 22, 78, - /* 1420 */ 504, 13, 374, 108, 424, 13, 108, 108, 410, 183, - /* 1430 */ 184, 35, 108, 37, 33, 33, 190, 191, 33, 33, - /* 1440 */ 33, 371, 33, 33, 108, 37, 108, 442, 488, 37, - /* 1450 */ 424, 205, 424, 207, 509, 453, 480, 301, 456, 108, - /* 1460 */ 108, 65, 460, 461, 462, 463, 464, 465, 491, 467, - /* 1470 */ 303, 389, 280, 436, 472, 358, 474, 108, 51, 42, - /* 1480 */ 478, 479, 455, 20, 452, 239, 240, 241, 371, 243, + /* 1410 */ 52, 478, 479, 411, 504, 413, 504, 108, 22, 12, + /* 1420 */ 13, 12, 13, 108, 12, 13, 108, 108, 78, 183, + /* 1430 */ 184, 35, 108, 37, 33, 33, 190, 191, 12, 13, + /* 1440 */ 12, 13, 12, 13, 108, 504, 108, 12, 13, 12, + /* 1450 */ 13, 205, 33, 207, 33, 453, 33, 301, 456, 108, + /* 1460 */ 108, 65, 460, 461, 462, 463, 464, 465, 374, 467, + /* 1470 */ 303, 12, 13, 424, 472, 358, 474, 108, 12, 13, + /* 1480 */ 478, 479, 33, 33, 13, 239, 240, 241, 371, 243, /* 1490 */ 244, 245, 246, 247, 248, 249, 250, 251, 252, 253, - /* 1500 */ 254, 255, 256, 257, 258, 259, 260, 358, 454, 108, - /* 1510 */ 108, 447, 220, 108, 108, 108, 399, 108, 108, 379, - /* 1520 */ 371, 379, 447, 203, 438, 20, 20, 45, 411, 370, - /* 1530 */ 413, 371, 420, 371, 420, 182, 417, 371, 370, 370, - /* 1540 */ 420, 417, 207, 417, 417, 105, 383, 103, 399, 370, - /* 1550 */ 207, 102, 382, 381, 370, 370, 370, 20, 363, 50, - /* 1560 */ 411, 367, 413, 363, 20, 367, 379, 379, 447, 379, - /* 1570 */ 453, 413, 20, 456, 372, 20, 437, 460, 461, 462, - /* 1580 */ 463, 464, 465, 379, 467, 379, 372, 20, 427, 472, - /* 1590 */ 379, 474, 370, 363, 379, 478, 479, 379, 399, 370, - /* 1600 */ 399, 205, 453, 207, 399, 456, 358, 363, 399, 460, - /* 1610 */ 461, 462, 463, 464, 465, 399, 467, 107, 399, 371, - /* 1620 */ 399, 361, 399, 474, 399, 399, 399, 478, 479, 361, - /* 1630 */ 447, 411, 451, 237, 238, 239, 377, 224, 449, 411, - /* 1640 */ 20, 211, 411, 210, 377, 413, 443, 399, 436, 253, - /* 1650 */ 254, 255, 256, 257, 258, 259, 446, 370, 411, 411, - /* 1660 */ 288, 413, 497, 429, 287, 429, 296, 196, 444, 298, - /* 1670 */ 497, 297, 497, 495, 500, 358, 499, 436, 281, 300, - /* 1680 */ 305, 517, 302, 20, 371, 117, 510, 496, 371, 278, - /* 1690 */ 494, 511, 276, 372, 459, 107, 411, 411, 429, 377, - /* 1700 */ 377, 453, 411, 429, 456, 358, 188, 490, 460, 461, - /* 1710 */ 462, 463, 464, 465, 477, 467, 399, 377, 371, 425, - /* 1720 */ 107, 411, 474, 395, 22, 492, 478, 479, 411, 370, - /* 1730 */ 413, 377, 371, 377, 358, 403, 38, 411, 360, 393, - /* 1740 */ 411, 411, 411, 439, 430, 364, 399, 371, 363, 448, - /* 1750 */ 393, 358, 0, 393, 356, 0, 0, 45, 411, 0, - /* 1760 */ 413, 378, 37, 430, 371, 230, 37, 37, 37, 230, - /* 1770 */ 453, 0, 230, 456, 37, 399, 37, 460, 461, 462, - /* 1780 */ 463, 464, 465, 37, 467, 0, 230, 411, 0, 413, - /* 1790 */ 37, 474, 399, 0, 37, 478, 479, 0, 22, 0, - /* 1800 */ 453, 37, 225, 456, 411, 0, 413, 460, 461, 462, - /* 1810 */ 463, 464, 465, 466, 467, 468, 469, 213, 0, 213, - /* 1820 */ 358, 214, 207, 205, 0, 0, 0, 201, 200, 453, - /* 1830 */ 0, 0, 456, 371, 150, 49, 460, 461, 462, 463, - /* 1840 */ 464, 465, 0, 467, 49, 37, 453, 37, 0, 456, - /* 1850 */ 358, 0, 0, 460, 461, 462, 463, 464, 465, 0, - /* 1860 */ 467, 399, 51, 371, 49, 45, 0, 0, 0, 0, - /* 1870 */ 49, 0, 0, 411, 0, 413, 0, 0, 502, 503, - /* 1880 */ 37, 168, 0, 168, 0, 0, 0, 358, 0, 0, - /* 1890 */ 0, 399, 0, 0, 0, 0, 0, 0, 0, 0, - /* 1900 */ 371, 0, 0, 411, 0, 413, 49, 514, 515, 0, - /* 1910 */ 0, 0, 0, 0, 0, 453, 0, 0, 456, 0, + /* 1500 */ 254, 255, 256, 257, 258, 259, 260, 358, 37, 108, + /* 1510 */ 108, 13, 371, 442, 410, 424, 399, 424, 509, 488, + /* 1520 */ 371, 480, 389, 491, 280, 436, 51, 108, 411, 108, + /* 1530 */ 413, 108, 455, 42, 454, 37, 20, 447, 452, 379, + /* 1540 */ 220, 379, 207, 447, 203, 438, 20, 370, 399, 371, + /* 1550 */ 207, 20, 45, 182, 420, 371, 420, 108, 108, 417, + /* 1560 */ 411, 370, 413, 371, 370, 420, 105, 417, 417, 417, + /* 1570 */ 453, 383, 103, 456, 370, 102, 381, 460, 461, 462, + /* 1580 */ 463, 464, 465, 382, 467, 370, 370, 370, 20, 472, + /* 1590 */ 363, 474, 50, 367, 363, 478, 479, 367, 379, 379, + /* 1600 */ 447, 205, 453, 207, 20, 456, 358, 379, 20, 460, + /* 1610 */ 461, 462, 463, 464, 465, 413, 467, 372, 20, 371, + /* 1620 */ 437, 379, 372, 474, 20, 427, 379, 478, 479, 370, + /* 1630 */ 379, 379, 379, 237, 238, 239, 399, 363, 399, 399, + /* 1640 */ 399, 363, 399, 361, 411, 370, 361, 399, 399, 253, + /* 1650 */ 254, 255, 256, 257, 258, 259, 399, 399, 224, 411, + /* 1660 */ 399, 413, 399, 451, 399, 411, 411, 107, 377, 447, + /* 1670 */ 449, 20, 370, 444, 211, 358, 377, 210, 446, 443, + /* 1680 */ 413, 296, 288, 411, 497, 287, 497, 298, 371, 196, + /* 1690 */ 500, 429, 297, 497, 281, 429, 436, 305, 499, 496, + /* 1700 */ 495, 453, 517, 494, 456, 358, 302, 276, 460, 461, + /* 1710 */ 462, 463, 464, 465, 300, 467, 399, 436, 371, 371, + /* 1720 */ 20, 511, 474, 117, 510, 278, 478, 479, 411, 372, + /* 1730 */ 413, 377, 377, 107, 358, 459, 429, 411, 188, 411, + /* 1740 */ 411, 411, 429, 411, 377, 477, 399, 371, 425, 377, + /* 1750 */ 371, 358, 107, 411, 395, 411, 411, 411, 411, 403, + /* 1760 */ 413, 492, 22, 360, 371, 38, 393, 490, 363, 370, + /* 1770 */ 453, 411, 411, 456, 411, 399, 411, 460, 461, 462, + /* 1780 */ 463, 464, 465, 430, 467, 411, 411, 411, 411, 413, + /* 1790 */ 0, 474, 399, 411, 411, 478, 479, 411, 411, 411, + /* 1800 */ 453, 411, 411, 456, 411, 439, 413, 460, 461, 462, + /* 1810 */ 463, 464, 465, 466, 467, 468, 469, 411, 377, 411, + /* 1820 */ 358, 411, 411, 378, 364, 393, 411, 430, 448, 453, + /* 1830 */ 356, 393, 456, 371, 0, 0, 460, 461, 462, 463, + /* 1840 */ 464, 465, 45, 467, 0, 37, 453, 37, 230, 456, + /* 1850 */ 358, 37, 37, 460, 461, 462, 463, 464, 465, 230, + /* 1860 */ 467, 399, 0, 371, 37, 37, 230, 37, 0, 230, + /* 1870 */ 0, 0, 0, 411, 37, 413, 37, 22, 502, 503, + /* 1880 */ 0, 225, 37, 0, 213, 0, 213, 358, 214, 207, + /* 1890 */ 205, 399, 0, 0, 0, 201, 200, 0, 0, 150, + /* 1900 */ 371, 49, 49, 411, 0, 413, 37, 514, 515, 0, + /* 1910 */ 0, 37, 51, 0, 49, 453, 0, 0, 456, 0, /* 1920 */ 45, 0, 460, 461, 462, 463, 464, 465, 399, 467, - /* 1930 */ 0, 0, 150, 0, 0, 148, 474, 22, 149, 0, - /* 1940 */ 411, 479, 413, 0, 22, 453, 22, 0, 456, 0, - /* 1950 */ 50, 0, 460, 461, 462, 463, 464, 465, 50, 467, - /* 1960 */ 358, 0, 433, 37, 0, 42, 37, 0, 65, 51, - /* 1970 */ 65, 51, 65, 371, 37, 358, 0, 42, 37, 0, - /* 1980 */ 42, 37, 453, 51, 0, 456, 33, 45, 371, 460, - /* 1990 */ 461, 462, 463, 464, 465, 503, 467, 42, 0, 49, - /* 2000 */ 14, 399, 43, 49, 42, 49, 358, 42, 196, 0, - /* 2010 */ 0, 0, 49, 411, 0, 413, 399, 0, 0, 371, - /* 2020 */ 0, 0, 0, 51, 72, 37, 0, 42, 411, 37, - /* 2030 */ 413, 51, 42, 0, 37, 433, 42, 0, 51, 37, - /* 2040 */ 51, 42, 0, 0, 0, 0, 0, 399, 0, 37, - /* 2050 */ 22, 115, 0, 113, 22, 453, 37, 33, 456, 411, - /* 2060 */ 37, 413, 460, 461, 462, 463, 464, 465, 37, 467, - /* 2070 */ 453, 37, 37, 456, 33, 358, 37, 460, 461, 462, - /* 2080 */ 463, 464, 465, 0, 467, 22, 37, 37, 371, 0, - /* 2090 */ 37, 37, 37, 358, 22, 0, 22, 0, 22, 37, - /* 2100 */ 53, 453, 0, 0, 456, 0, 371, 37, 460, 461, - /* 2110 */ 462, 463, 464, 465, 0, 467, 399, 37, 0, 358, - /* 2120 */ 22, 20, 37, 506, 37, 37, 0, 49, 411, 0, - /* 2130 */ 413, 185, 371, 108, 399, 22, 37, 107, 0, 212, - /* 2140 */ 0, 22, 185, 107, 0, 185, 411, 282, 413, 3, - /* 2150 */ 192, 3, 37, 208, 188, 185, 185, 33, 107, 37, - /* 2160 */ 399, 192, 50, 515, 108, 107, 105, 108, 433, 103, - /* 2170 */ 453, 107, 411, 456, 413, 50, 108, 460, 461, 462, - /* 2180 */ 463, 464, 465, 33, 467, 108, 469, 33, 453, 107, - /* 2190 */ 33, 456, 108, 1, 433, 460, 461, 462, 463, 464, - /* 2200 */ 465, 107, 467, 107, 35, 358, 33, 49, 49, 33, - /* 2210 */ 49, 19, 108, 107, 453, 108, 108, 456, 371, 37, + /* 1930 */ 49, 0, 0, 0, 0, 0, 474, 0, 168, 37, + /* 1940 */ 411, 479, 413, 0, 168, 453, 0, 0, 456, 0, + /* 1950 */ 0, 0, 460, 461, 462, 463, 464, 465, 0, 467, + /* 1960 */ 358, 0, 433, 0, 0, 0, 0, 0, 0, 0, + /* 1970 */ 0, 0, 0, 371, 0, 358, 0, 0, 49, 0, + /* 1980 */ 0, 45, 453, 0, 0, 456, 0, 0, 371, 460, + /* 1990 */ 461, 462, 463, 464, 465, 503, 467, 0, 0, 0, + /* 2000 */ 22, 399, 0, 0, 150, 149, 358, 148, 0, 0, + /* 2010 */ 22, 22, 50, 411, 0, 413, 399, 65, 37, 371, + /* 2020 */ 0, 65, 0, 50, 65, 0, 0, 37, 411, 14, + /* 2030 */ 413, 0, 37, 51, 42, 433, 51, 0, 42, 0, + /* 2040 */ 0, 37, 51, 42, 0, 45, 33, 399, 37, 43, + /* 2050 */ 0, 0, 42, 0, 49, 453, 0, 0, 456, 411, + /* 2060 */ 42, 413, 460, 461, 462, 463, 464, 465, 49, 467, + /* 2070 */ 453, 0, 49, 456, 42, 358, 49, 460, 461, 462, + /* 2080 */ 463, 464, 465, 196, 467, 0, 0, 0, 371, 72, + /* 2090 */ 42, 37, 51, 358, 0, 37, 51, 42, 0, 37, + /* 2100 */ 51, 453, 42, 0, 456, 37, 371, 0, 460, 461, + /* 2110 */ 462, 463, 464, 465, 51, 467, 399, 42, 0, 358, + /* 2120 */ 0, 0, 0, 506, 0, 37, 22, 115, 411, 113, + /* 2130 */ 413, 0, 371, 37, 399, 0, 37, 37, 37, 37, + /* 2140 */ 0, 22, 37, 37, 33, 37, 411, 33, 413, 37, + /* 2150 */ 37, 22, 37, 0, 22, 22, 0, 0, 22, 0, + /* 2160 */ 399, 0, 53, 515, 37, 37, 0, 37, 433, 22, + /* 2170 */ 453, 0, 411, 456, 413, 20, 37, 460, 461, 462, + /* 2180 */ 463, 464, 465, 37, 467, 37, 469, 108, 453, 107, + /* 2190 */ 0, 456, 49, 1, 433, 460, 461, 462, 463, 464, + /* 2200 */ 465, 0, 467, 22, 35, 358, 185, 37, 0, 22, + /* 2210 */ 0, 19, 0, 185, 453, 33, 3, 456, 371, 185, /* 2220 */ 51, 460, 461, 462, 463, 464, 465, 35, 467, 60, - /* 2230 */ 61, 62, 63, 37, 65, 37, 37, 37, 37, 108, - /* 2240 */ 33, 0, 49, 51, 0, 42, 399, 33, 275, 107, - /* 2250 */ 282, 2, 60, 61, 62, 63, 282, 65, 411, 22, - /* 2260 */ 413, 105, 262, 108, 358, 105, 239, 49, 49, 107, - /* 2270 */ 22, 108, 107, 107, 107, 106, 108, 371, 109, 108, - /* 2280 */ 242, 189, 108, 0, 107, 107, 358, 107, 42, 49, - /* 2290 */ 107, 116, 107, 107, 37, 108, 187, 107, 106, 371, - /* 2300 */ 453, 109, 108, 456, 107, 399, 117, 460, 461, 462, - /* 2310 */ 463, 464, 465, 37, 467, 107, 37, 411, 108, 413, - /* 2320 */ 107, 37, 37, 108, 107, 37, 37, 399, 108, 107, - /* 2330 */ 119, 108, 107, 33, 108, 143, 107, 107, 107, 411, - /* 2340 */ 37, 413, 130, 107, 22, 118, 130, 178, 37, 72, - /* 2350 */ 37, 130, 71, 37, 130, 37, 187, 188, 37, 453, - /* 2360 */ 37, 37, 456, 194, 195, 358, 460, 461, 462, 463, - /* 2370 */ 464, 465, 37, 467, 37, 78, 101, 78, 371, 187, - /* 2380 */ 33, 453, 213, 101, 456, 37, 194, 358, 460, 461, - /* 2390 */ 462, 463, 464, 465, 37, 467, 37, 22, 37, 37, - /* 2400 */ 371, 37, 37, 78, 37, 213, 399, 37, 37, 37, - /* 2410 */ 22, 37, 0, 37, 51, 42, 0, 51, 411, 37, - /* 2420 */ 413, 42, 0, 358, 37, 42, 0, 37, 399, 51, - /* 2430 */ 0, 42, 51, 0, 37, 37, 371, 22, 33, 22, - /* 2440 */ 411, 21, 413, 22, 20, 22, 21, 518, 518, 518, - /* 2450 */ 518, 518, 518, 518, 518, 518, 518, 518, 518, 518, - /* 2460 */ 453, 518, 518, 456, 399, 518, 518, 460, 461, 462, - /* 2470 */ 463, 464, 465, 518, 467, 518, 411, 518, 413, 518, - /* 2480 */ 518, 518, 453, 518, 518, 456, 518, 518, 518, 460, - /* 2490 */ 461, 462, 463, 464, 465, 518, 467, 518, 518, 518, - /* 2500 */ 518, 518, 518, 518, 518, 518, 518, 358, 518, 518, + /* 2230 */ 61, 62, 63, 107, 65, 188, 212, 185, 208, 282, + /* 2240 */ 37, 107, 37, 51, 50, 108, 399, 50, 107, 185, + /* 2250 */ 108, 192, 60, 61, 62, 63, 105, 65, 411, 192, + /* 2260 */ 413, 107, 33, 103, 358, 33, 108, 33, 49, 49, + /* 2270 */ 108, 108, 107, 33, 107, 106, 282, 371, 109, 107, + /* 2280 */ 107, 3, 108, 108, 33, 37, 358, 37, 108, 37, + /* 2290 */ 37, 37, 37, 108, 49, 33, 49, 0, 106, 371, + /* 2300 */ 453, 109, 0, 456, 33, 399, 107, 460, 461, 462, + /* 2310 */ 463, 464, 465, 275, 467, 282, 42, 411, 2, 413, + /* 2320 */ 105, 105, 22, 262, 49, 108, 108, 399, 239, 107, + /* 2330 */ 107, 107, 49, 108, 22, 143, 108, 242, 107, 411, + /* 2340 */ 107, 413, 0, 108, 107, 107, 42, 178, 107, 107, + /* 2350 */ 49, 107, 116, 33, 108, 187, 187, 188, 37, 453, + /* 2360 */ 117, 37, 456, 194, 195, 358, 460, 461, 462, 463, + /* 2370 */ 464, 465, 189, 467, 107, 107, 37, 108, 371, 187, + /* 2380 */ 107, 453, 213, 107, 456, 108, 194, 358, 460, 461, + /* 2390 */ 462, 463, 464, 465, 108, 467, 37, 107, 37, 108, + /* 2400 */ 371, 107, 37, 108, 108, 213, 399, 37, 119, 130, + /* 2410 */ 107, 130, 107, 107, 130, 130, 118, 107, 411, 37, + /* 2420 */ 413, 107, 22, 358, 72, 71, 37, 37, 399, 37, + /* 2430 */ 37, 37, 37, 78, 37, 37, 371, 33, 37, 101, + /* 2440 */ 411, 78, 413, 37, 101, 37, 37, 22, 37, 37, + /* 2450 */ 37, 78, 37, 37, 37, 37, 22, 37, 37, 0, + /* 2460 */ 453, 37, 0, 456, 399, 51, 37, 460, 461, 462, + /* 2470 */ 463, 464, 465, 42, 467, 42, 411, 51, 413, 0, + /* 2480 */ 37, 51, 453, 42, 0, 456, 37, 51, 42, 460, + /* 2490 */ 461, 462, 463, 464, 465, 0, 467, 37, 37, 0, + /* 2500 */ 22, 33, 22, 21, 518, 22, 21, 358, 22, 20, /* 2510 */ 518, 518, 518, 518, 518, 518, 518, 518, 453, 518, /* 2520 */ 371, 456, 358, 518, 518, 460, 461, 462, 463, 464, /* 2530 */ 465, 518, 467, 518, 518, 371, 518, 358, 518, 518, @@ -894,9 +894,9 @@ static const YYCODETYPE yy_lookahead[] = { /* 3500 */ 355, 355, 355, 355, 355, 355, 355, 355, 355, 355, /* 3510 */ 355, 355, 355, 355, 355, 355, 355, 355, }; -#define YY_SHIFT_COUNT (861) +#define YY_SHIFT_COUNT (891) #define YY_SHIFT_MIN (0) -#define YY_SHIFT_MAX (2433) +#define YY_SHIFT_MAX (2499) static const unsigned short int yy_shift_ofst[] = { /* 0 */ 135, 0, 249, 0, 499, 499, 499, 499, 499, 499, /* 10 */ 499, 499, 499, 499, 499, 499, 748, 997, 997, 1246, @@ -918,75 +918,78 @@ static const unsigned short int yy_shift_ofst[] = { /* 170 */ 255, 255, 255, 2192, 567, 23, 429, 333, 191, 231, /* 180 */ 528, 94, 833, 398, 398, 416, 889, 913, 937, 937, /* 190 */ 937, 1029, 709, 937, 250, 1024, 1280, 923, 309, 1024, - /* 200 */ 1024, 1057, 1030, 1098, 264, 1030, 1256, 334, 529, 1192, - /* 210 */ 1427, 1437, 1463, 1292, 211, 1463, 211, 1320, 1505, 1506, - /* 220 */ 1482, 1506, 1482, 1353, 1505, 1506, 1505, 1482, 1353, 1353, - /* 230 */ 1353, 1440, 1444, 1505, 1449, 1505, 1505, 1505, 1537, 1509, - /* 240 */ 1537, 1509, 1463, 211, 211, 1544, 211, 1552, 1555, 211, - /* 250 */ 1552, 211, 1567, 211, 211, 1505, 211, 1537, 39, 39, - /* 260 */ 39, 39, 39, 39, 39, 39, 39, 39, 39, 1505, - /* 270 */ 598, 598, 1537, 318, 318, 318, 1413, 1510, 1463, 234, - /* 280 */ 1620, 1430, 1433, 1544, 234, 1192, 1505, 318, 1372, 1377, - /* 290 */ 1372, 1377, 1370, 1471, 1372, 1371, 1374, 1397, 1192, 1375, - /* 300 */ 1380, 1379, 1416, 1506, 1663, 1568, 1411, 1552, 234, 234, - /* 310 */ 1588, 1377, 318, 318, 318, 318, 1377, 318, 1518, 234, - /* 320 */ 432, 234, 1506, 318, 318, 1613, 318, 1505, 234, 1702, - /* 330 */ 1698, 1537, 3163, 3163, 3163, 3163, 3163, 3163, 3163, 3163, - /* 340 */ 3163, 36, 2169, 263, 537, 48, 450, 719, 531, 823, - /* 350 */ 1033, 559, 569, 1055, 1055, 1055, 1055, 1055, 1055, 1055, - /* 360 */ 1055, 1055, 659, 597, 990, 26, 26, 582, 616, 520, - /* 370 */ 517, 122, 668, 814, 962, 1074, 1116, 967, 1155, 1171, - /* 380 */ 939, 1155, 1155, 1155, 307, 307, 1271, 1157, 742, 1273, - /* 390 */ 1264, 1182, 1303, 1197, 1207, 1208, 1213, 1300, 1306, 1308, - /* 400 */ 1312, 1325, 1327, 503, 1295, 1296, 1270, 1298, 1309, 1315, - /* 410 */ 1318, 1193, 1156, 1167, 1319, 1339, 1324, 594, 1336, 317, - /* 420 */ 1338, 1351, 1352, 1369, 1401, 1349, 1402, 1405, 1406, 1407, - /* 430 */ 1409, 1410, 1283, 1335, 1343, 1408, 1412, 1341, 1358, 1752, - /* 440 */ 1755, 1756, 1712, 1759, 1725, 1535, 1729, 1730, 1731, 1539, - /* 450 */ 1771, 1737, 1739, 1542, 1746, 1785, 1556, 1788, 1753, 1793, - /* 460 */ 1757, 1797, 1776, 1799, 1764, 1577, 1805, 1604, 1818, 1606, - /* 470 */ 1607, 1615, 1618, 1824, 1825, 1826, 1626, 1628, 1830, 1831, - /* 480 */ 1684, 1786, 1795, 1842, 1808, 1851, 1852, 1810, 1811, 1848, - /* 490 */ 1815, 1859, 1820, 1866, 1867, 1868, 1821, 1869, 1871, 1872, - /* 500 */ 1874, 1876, 1877, 1713, 1843, 1882, 1715, 1884, 1885, 1886, - /* 510 */ 1888, 1889, 1890, 1892, 1893, 1894, 1895, 1896, 1897, 1898, - /* 520 */ 1899, 1901, 1902, 1904, 1909, 1910, 1857, 1911, 1875, 1912, - /* 530 */ 1913, 1914, 1916, 1917, 1919, 1921, 1930, 1915, 1931, 1782, - /* 540 */ 1933, 1789, 1934, 1787, 1939, 1943, 1922, 1900, 1924, 1908, - /* 550 */ 1947, 1903, 1926, 1949, 1905, 1951, 1907, 1961, 1964, 1929, - /* 560 */ 1918, 1923, 1967, 1937, 1920, 1935, 1976, 1941, 1932, 1938, - /* 570 */ 1979, 1944, 1984, 1942, 1955, 1953, 1950, 1954, 1986, 1956, - /* 580 */ 1998, 1959, 1962, 2014, 2017, 2018, 2020, 1965, 1812, 2009, - /* 590 */ 1950, 1963, 2010, 2011, 1952, 2021, 2022, 1988, 1972, 1985, - /* 600 */ 2026, 1992, 1980, 1990, 2033, 1997, 1987, 1994, 2037, 2002, - /* 610 */ 1989, 1999, 2042, 2043, 2044, 2045, 2046, 2048, 1936, 1940, - /* 620 */ 2012, 2028, 2052, 2019, 2023, 2031, 2034, 2035, 2039, 2049, - /* 630 */ 2050, 2024, 2041, 2053, 2054, 2032, 2055, 2083, 2063, 2089, - /* 640 */ 2072, 2095, 2074, 2047, 2097, 2076, 2062, 2102, 2103, 2105, - /* 650 */ 2070, 2114, 2080, 2118, 2098, 2101, 2085, 2087, 2088, 2025, - /* 660 */ 2030, 2126, 1946, 2036, 1927, 1950, 2078, 2129, 1957, 2099, - /* 670 */ 2113, 2138, 1945, 2119, 1960, 1966, 2140, 2144, 1970, 1958, - /* 680 */ 1971, 1969, 2146, 2124, 1865, 2051, 2056, 2058, 2059, 2115, - /* 690 */ 2122, 2064, 2112, 2061, 2125, 2066, 2068, 2150, 2154, 2077, - /* 700 */ 2082, 2094, 2096, 2084, 2157, 2158, 2159, 2106, 2173, 1968, - /* 710 */ 2104, 2107, 2148, 2176, 1974, 2182, 2196, 2198, 2199, 2200, - /* 720 */ 2201, 2108, 2131, 2161, 1973, 2207, 2193, 2241, 2244, 2142, - /* 730 */ 2203, 2214, 2156, 2000, 2160, 2249, 2237, 2027, 2155, 2162, - /* 740 */ 2163, 2218, 2165, 2166, 2219, 2168, 2248, 2038, 2167, 2171, - /* 750 */ 2174, 2177, 2178, 2092, 2180, 2283, 2246, 2109, 2183, 2175, - /* 760 */ 1950, 2240, 2185, 2186, 2187, 2190, 2197, 2189, 2194, 2257, - /* 770 */ 2276, 2208, 2210, 2279, 2213, 2215, 2284, 2217, 2220, 2285, - /* 780 */ 2222, 2223, 2288, 2225, 2226, 2289, 2229, 2212, 2216, 2221, - /* 790 */ 2224, 2211, 2227, 2230, 2300, 2231, 2303, 2236, 2300, 2300, - /* 800 */ 2322, 2277, 2281, 2311, 2313, 2316, 2318, 2321, 2323, 2324, - /* 810 */ 2335, 2337, 2297, 2275, 2299, 2282, 2347, 2348, 2357, 2359, - /* 820 */ 2375, 2361, 2362, 2364, 2325, 2024, 2365, 2041, 2367, 2370, - /* 830 */ 2371, 2372, 2388, 2374, 2412, 2376, 2363, 2373, 2416, 2382, - /* 840 */ 2366, 2379, 2422, 2387, 2378, 2383, 2426, 2390, 2381, 2389, - /* 850 */ 2430, 2397, 2398, 2433, 2415, 2405, 2417, 2420, 2421, 2423, - /* 860 */ 2425, 2424, + /* 200 */ 1024, 1057, 1030, 1098, 264, 1030, 1256, 334, 529, 1244, + /* 210 */ 1475, 1491, 1516, 1320, 211, 1516, 211, 1341, 1526, 1531, + /* 220 */ 1507, 1531, 1507, 1371, 1526, 1531, 1526, 1507, 1371, 1371, + /* 230 */ 1371, 1461, 1469, 1526, 1473, 1526, 1526, 1526, 1568, 1542, + /* 240 */ 1568, 1542, 1516, 211, 211, 1584, 211, 1588, 1598, 211, + /* 250 */ 1588, 211, 1604, 211, 211, 1526, 211, 1568, 39, 39, + /* 260 */ 39, 39, 39, 39, 39, 39, 39, 39, 39, 1526, + /* 270 */ 598, 598, 1568, 318, 318, 318, 1434, 1560, 1516, 234, + /* 280 */ 1651, 1463, 1467, 1584, 234, 1244, 1526, 318, 1394, 1398, + /* 290 */ 1394, 1398, 1385, 1493, 1394, 1389, 1395, 1413, 1244, 1392, + /* 300 */ 1404, 1414, 1431, 1531, 1700, 1606, 1447, 1588, 234, 234, + /* 310 */ 1626, 1398, 318, 318, 318, 318, 1398, 318, 1550, 234, + /* 320 */ 432, 234, 1531, 318, 318, 318, 318, 318, 318, 318, + /* 330 */ 318, 318, 318, 318, 318, 318, 318, 318, 318, 318, + /* 340 */ 318, 318, 318, 318, 318, 1645, 318, 1526, 234, 1740, + /* 350 */ 1727, 1568, 3163, 3163, 3163, 3163, 3163, 3163, 3163, 3163, + /* 360 */ 3163, 36, 2169, 263, 537, 48, 450, 719, 531, 823, + /* 370 */ 1033, 559, 569, 1055, 1055, 1055, 1055, 1055, 1055, 1055, + /* 380 */ 1055, 1055, 659, 597, 990, 26, 26, 582, 616, 520, + /* 390 */ 517, 122, 668, 814, 962, 1074, 1116, 967, 1155, 1171, + /* 400 */ 939, 1155, 1155, 1155, 307, 307, 1271, 1157, 742, 1273, + /* 410 */ 1264, 1182, 1303, 1197, 1207, 1208, 1213, 1300, 1306, 1308, + /* 420 */ 1312, 1325, 1327, 503, 1295, 1296, 1270, 1298, 1309, 1315, + /* 430 */ 1318, 1193, 1156, 1167, 1319, 1339, 1324, 594, 1336, 317, + /* 440 */ 1338, 1351, 1352, 1369, 1401, 1349, 1407, 1409, 1412, 1426, + /* 450 */ 1428, 1430, 1435, 1437, 1459, 1466, 1402, 1419, 1421, 1423, + /* 460 */ 1449, 1450, 1283, 1335, 1343, 1471, 1498, 1350, 1358, 1790, + /* 470 */ 1834, 1835, 1797, 1844, 1808, 1618, 1810, 1814, 1815, 1629, + /* 480 */ 1862, 1827, 1828, 1636, 1830, 1868, 1639, 1870, 1837, 1871, + /* 490 */ 1839, 1872, 1855, 1880, 1845, 1656, 1883, 1671, 1885, 1673, + /* 500 */ 1674, 1682, 1685, 1892, 1893, 1894, 1694, 1696, 1897, 1898, + /* 510 */ 1749, 1852, 1853, 1904, 1869, 1909, 1910, 1874, 1861, 1913, + /* 520 */ 1865, 1916, 1875, 1917, 1919, 1921, 1881, 1931, 1932, 1933, + /* 530 */ 1934, 1935, 1937, 1770, 1902, 1943, 1776, 1946, 1947, 1949, + /* 540 */ 1950, 1951, 1958, 1961, 1963, 1964, 1965, 1966, 1967, 1968, + /* 550 */ 1969, 1970, 1971, 1972, 1974, 1976, 1929, 1977, 1936, 1979, + /* 560 */ 1980, 1983, 1984, 1986, 1987, 1997, 1998, 1978, 1999, 1854, + /* 570 */ 2002, 1856, 2003, 1859, 2008, 2009, 1988, 1962, 1989, 1973, + /* 580 */ 2014, 1952, 1981, 2020, 1956, 2022, 1959, 2025, 2026, 1990, + /* 590 */ 1982, 1992, 2031, 1995, 1985, 1996, 2037, 2004, 1991, 2001, + /* 600 */ 2039, 2011, 2040, 2000, 2010, 2013, 2005, 2019, 2015, 2023, + /* 610 */ 2044, 2006, 2018, 2050, 2051, 2053, 2056, 2032, 1887, 2057, + /* 620 */ 2005, 2027, 2071, 2085, 2017, 2086, 2087, 2054, 2041, 2048, + /* 630 */ 2094, 2058, 2045, 2055, 2098, 2062, 2049, 2060, 2103, 2068, + /* 640 */ 2063, 2075, 2107, 2118, 2120, 2121, 2122, 2124, 2012, 2016, + /* 650 */ 2088, 2104, 2131, 2096, 2099, 2100, 2101, 2102, 2105, 2106, + /* 660 */ 2108, 2111, 2114, 2112, 2113, 2119, 2115, 2135, 2129, 2140, + /* 670 */ 2132, 2153, 2133, 2109, 2156, 2136, 2127, 2157, 2159, 2161, + /* 680 */ 2128, 2166, 2130, 2171, 2147, 2155, 2139, 2146, 2148, 2079, + /* 690 */ 2082, 2190, 2021, 2126, 2024, 2005, 2143, 2201, 2028, 2170, + /* 700 */ 2181, 2208, 2030, 2187, 2034, 2047, 2210, 2212, 2052, 2059, + /* 710 */ 2064, 2067, 2213, 2182, 1957, 2134, 2137, 2141, 2142, 2203, + /* 720 */ 2205, 2154, 2194, 2151, 2197, 2160, 2158, 2229, 2232, 2162, + /* 730 */ 2165, 2167, 2172, 2163, 2234, 2219, 2220, 2173, 2240, 1994, + /* 740 */ 2174, 2175, 2278, 2251, 2033, 2248, 2250, 2252, 2253, 2254, + /* 750 */ 2255, 2180, 2185, 2245, 2038, 2262, 2247, 2297, 2302, 2199, + /* 760 */ 2274, 2271, 2215, 2061, 2216, 2316, 2300, 2089, 2217, 2222, + /* 770 */ 2218, 2275, 2223, 2224, 2283, 2225, 2312, 2095, 2231, 2228, + /* 780 */ 2235, 2233, 2237, 2183, 2238, 2342, 2304, 2168, 2241, 2236, + /* 790 */ 2005, 2301, 2242, 2244, 2246, 2267, 2268, 2243, 2269, 2321, + /* 800 */ 2324, 2273, 2277, 2339, 2276, 2286, 2359, 2290, 2291, 2361, + /* 810 */ 2294, 2295, 2365, 2303, 2296, 2370, 2305, 2279, 2281, 2284, + /* 820 */ 2285, 2289, 2298, 2306, 2320, 2310, 2382, 2314, 2320, 2320, + /* 830 */ 2400, 2352, 2354, 2389, 2390, 2392, 2393, 2394, 2395, 2397, + /* 840 */ 2398, 2401, 2355, 2338, 2363, 2343, 2404, 2406, 2408, 2409, + /* 850 */ 2425, 2411, 2412, 2413, 2373, 2111, 2415, 2114, 2416, 2417, + /* 860 */ 2418, 2420, 2434, 2421, 2459, 2424, 2414, 2431, 2462, 2429, + /* 870 */ 2426, 2433, 2479, 2443, 2430, 2441, 2484, 2449, 2436, 2446, + /* 880 */ 2495, 2460, 2461, 2499, 2478, 2468, 2480, 2482, 2483, 2486, + /* 890 */ 2485, 2489, }; -#define YY_REDUCE_COUNT (340) +#define YY_REDUCE_COUNT (360) #define YY_REDUCE_MIN (-479) #define YY_REDUCE_MAX (2695) static const short yy_reduce_ofst[] = { @@ -1008,112 +1011,117 @@ static const short yy_reduce_ofst[] = { /* 150 */ 208, -208, 878, 522, -131, 316, 639, 623, 382, 859, /* 160 */ 785, 864, 869, 898, 934, 279, 286, 366, 544, 578, /* 170 */ 614, 618, 578, 364, 527, 856, 629, 666, 628, 723, - /* 180 */ 852, 829, 829, 946, 958, 836, 986, 952, 879, 883, - /* 190 */ 910, 982, 829, 916, 1048, 1000, 1070, 1018, 1005, 1026, - /* 200 */ 1028, 829, 960, 960, 945, 960, 976, 977, 1082, 1037, - /* 210 */ 1027, 1054, 1064, 1032, 1140, 1075, 1142, 1086, 1159, 1160, - /* 220 */ 1112, 1162, 1114, 1119, 1168, 1166, 1169, 1120, 1124, 1126, - /* 230 */ 1127, 1163, 1170, 1179, 1172, 1184, 1185, 1186, 1195, 1194, - /* 240 */ 1200, 1198, 1121, 1187, 1188, 1158, 1190, 1202, 1139, 1204, - /* 250 */ 1214, 1206, 1161, 1211, 1215, 1222, 1218, 1230, 1199, 1201, - /* 260 */ 1205, 1209, 1216, 1219, 1221, 1223, 1225, 1226, 1227, 1229, - /* 270 */ 1260, 1268, 1244, 1220, 1228, 1231, 1181, 1189, 1183, 1259, - /* 280 */ 1210, 1224, 1203, 1232, 1267, 1212, 1287, 1247, 1165, 1234, - /* 290 */ 1173, 1236, 1174, 1177, 1175, 1191, 1178, 1196, 1241, 1164, - /* 300 */ 1180, 1176, 960, 1313, 1235, 1233, 1217, 1321, 1322, 1323, - /* 310 */ 1237, 1269, 1285, 1286, 1291, 1310, 1274, 1326, 1294, 1340, - /* 320 */ 1328, 1354, 1361, 1329, 1330, 1332, 1331, 1359, 1356, 1378, - /* 330 */ 1381, 1385, 1304, 1301, 1314, 1333, 1346, 1357, 1360, 1383, - /* 340 */ 1398, + /* 180 */ 852, 829, 829, 946, 958, 836, 986, 952, 879, 910, + /* 190 */ 912, 944, 829, 941, 1094, 1049, 1141, 1104, 1071, 1091, + /* 200 */ 1093, 829, 1031, 1031, 1009, 1031, 1041, 1032, 1133, 1089, + /* 210 */ 1077, 1080, 1090, 1086, 1160, 1096, 1162, 1107, 1177, 1178, + /* 220 */ 1134, 1184, 1136, 1142, 1191, 1192, 1194, 1145, 1150, 1151, + /* 230 */ 1152, 1188, 1201, 1204, 1195, 1215, 1216, 1217, 1227, 1226, + /* 240 */ 1231, 1230, 1153, 1219, 1220, 1202, 1228, 1245, 1183, 1242, + /* 250 */ 1250, 1247, 1198, 1251, 1252, 1259, 1253, 1274, 1237, 1239, + /* 260 */ 1240, 1241, 1243, 1249, 1257, 1258, 1261, 1263, 1265, 1275, + /* 270 */ 1282, 1285, 1278, 1233, 1254, 1255, 1212, 1221, 1222, 1291, + /* 280 */ 1232, 1229, 1236, 1267, 1299, 1260, 1302, 1272, 1187, 1262, + /* 290 */ 1189, 1266, 1190, 1199, 1196, 1203, 1205, 1209, 1281, 1185, + /* 300 */ 1210, 1214, 1031, 1348, 1276, 1269, 1277, 1357, 1354, 1355, + /* 310 */ 1268, 1307, 1326, 1328, 1329, 1330, 1313, 1332, 1323, 1367, + /* 320 */ 1359, 1372, 1379, 1342, 1344, 1345, 1346, 1360, 1361, 1363, + /* 330 */ 1365, 1374, 1375, 1377, 1382, 1383, 1386, 1387, 1388, 1390, + /* 340 */ 1391, 1406, 1408, 1410, 1411, 1356, 1415, 1399, 1441, 1403, + /* 350 */ 1460, 1405, 1366, 1380, 1353, 1397, 1373, 1432, 1438, 1445, + /* 360 */ 1474, }; static const YYACTIONTYPE yy_default[] = { - /* 0 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 10 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 20 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 30 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 40 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 50 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 60 */ 2298, 1956, 1956, 2261, 1956, 1956, 1956, 1956, 1956, 1956, - /* 70 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 2268, 1956, 1956, - /* 80 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 90 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 2055, 1956, 1956, - /* 100 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 110 */ 1956, 1956, 1956, 1956, 2053, 2522, 1956, 1956, 1956, 1956, - /* 120 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 130 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 2534, - /* 140 */ 1956, 1956, 2027, 2027, 1956, 2534, 2534, 2534, 2494, 2494, - /* 150 */ 2053, 1956, 1956, 2055, 2336, 1956, 1956, 1956, 1956, 1956, - /* 160 */ 1956, 1956, 1956, 2179, 1986, 1956, 1956, 1956, 1956, 2203, - /* 170 */ 1956, 1956, 1956, 2324, 1956, 1956, 2563, 2625, 1956, 2566, - /* 180 */ 1956, 1956, 1956, 1956, 1956, 2273, 1956, 2553, 1956, 1956, - /* 190 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 2131, 2318, 1956, - /* 200 */ 1956, 1956, 2526, 2540, 2609, 2527, 2524, 2547, 1956, 2557, - /* 210 */ 1956, 2361, 1956, 2350, 2055, 1956, 2055, 2311, 2256, 1956, - /* 220 */ 2266, 1956, 2266, 2263, 1956, 1956, 1956, 2266, 2263, 2263, - /* 230 */ 2263, 2120, 2116, 1956, 2114, 1956, 1956, 1956, 1956, 2011, - /* 240 */ 1956, 2011, 1956, 2055, 2055, 1956, 2055, 1956, 1956, 2055, - /* 250 */ 1956, 2055, 1956, 2055, 2055, 1956, 2055, 1956, 1956, 1956, - /* 260 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 270 */ 1956, 1956, 1956, 1956, 1956, 1956, 2348, 2334, 1956, 2053, - /* 280 */ 1956, 2322, 2320, 1956, 2053, 2557, 1956, 1956, 2579, 2574, - /* 290 */ 2579, 2574, 2593, 2589, 2579, 2598, 2595, 2559, 2557, 2628, - /* 300 */ 2615, 2611, 2540, 1956, 1956, 2545, 2543, 1956, 2053, 2053, - /* 310 */ 1956, 2574, 1956, 1956, 1956, 1956, 2574, 1956, 1956, 2053, - /* 320 */ 1956, 2053, 1956, 1956, 1956, 2147, 1956, 1956, 2053, 1956, - /* 330 */ 1995, 1956, 2313, 2339, 2294, 2294, 2182, 2182, 2182, 2056, - /* 340 */ 1961, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 350 */ 1956, 1956, 1956, 2592, 2591, 2446, 1956, 2498, 2497, 2496, - /* 360 */ 2487, 2445, 2143, 1956, 1956, 2444, 2443, 1956, 1956, 1956, - /* 370 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 2437, 1956, - /* 380 */ 1956, 2438, 2436, 2435, 2285, 2284, 1956, 1956, 1956, 1956, - /* 390 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 400 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 410 */ 1956, 1956, 2612, 2616, 1956, 2523, 1956, 1956, 1956, 2417, - /* 420 */ 1956, 1956, 1956, 1956, 1956, 2385, 1956, 1956, 1956, 1956, - /* 430 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 440 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 450 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 460 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 470 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 480 */ 2262, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 490 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 500 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 510 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 520 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 530 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 540 */ 1956, 1956, 1956, 2277, 1956, 1956, 1956, 1956, 1956, 1956, - /* 550 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 560 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 570 */ 1956, 1956, 1956, 1956, 1956, 2000, 2424, 1956, 1956, 1956, - /* 580 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 590 */ 2427, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 600 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 610 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 620 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 630 */ 1956, 2095, 2094, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 640 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 650 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 2428, - /* 660 */ 1956, 1956, 1956, 1956, 1956, 2419, 1956, 1956, 1956, 1956, - /* 670 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 680 */ 1956, 1956, 2608, 2560, 1956, 1956, 1956, 1956, 1956, 1956, - /* 690 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 700 */ 1956, 1956, 1956, 1956, 1956, 1956, 2417, 1956, 2590, 1956, - /* 710 */ 1956, 2606, 1956, 2610, 1956, 1956, 1956, 1956, 1956, 1956, - /* 720 */ 1956, 2533, 2529, 1956, 1956, 2525, 1956, 1956, 1956, 1956, - /* 730 */ 1956, 2484, 1956, 1956, 1956, 2518, 1956, 1956, 1956, 1956, - /* 740 */ 1956, 1956, 1956, 1956, 1956, 2428, 1956, 2431, 1956, 1956, - /* 750 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 760 */ 2416, 1956, 2469, 2468, 1956, 1956, 1956, 1956, 1956, 1956, - /* 770 */ 1956, 2176, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 780 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 2160, 2158, 2157, - /* 790 */ 2156, 1956, 2153, 1956, 2189, 1956, 1956, 1956, 2185, 2184, - /* 800 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 810 */ 1956, 1956, 1956, 1956, 1956, 1956, 2074, 1956, 1956, 1956, - /* 820 */ 1956, 1956, 1956, 1956, 1956, 2066, 1956, 2065, 1956, 1956, - /* 830 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 840 */ 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, 1956, - /* 850 */ 1956, 1956, 1956, 1956, 1956, 1985, 1956, 1956, 1956, 1956, - /* 860 */ 1956, 1956, + /* 0 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 10 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 20 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 30 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 40 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 50 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 60 */ 2358, 2016, 2016, 2321, 2016, 2016, 2016, 2016, 2016, 2016, + /* 70 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2328, 2016, 2016, + /* 80 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 90 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2115, 2016, 2016, + /* 100 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 110 */ 2016, 2016, 2016, 2016, 2113, 2602, 2016, 2016, 2016, 2016, + /* 120 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 130 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2614, + /* 140 */ 2016, 2016, 2087, 2087, 2016, 2614, 2614, 2614, 2574, 2574, + /* 150 */ 2113, 2016, 2016, 2115, 2396, 2016, 2016, 2016, 2016, 2016, + /* 160 */ 2016, 2016, 2016, 2239, 2046, 2016, 2016, 2016, 2016, 2263, + /* 170 */ 2016, 2016, 2016, 2384, 2016, 2016, 2643, 2705, 2016, 2646, + /* 180 */ 2016, 2016, 2016, 2016, 2016, 2333, 2016, 2633, 2016, 2016, + /* 190 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2191, 2378, 2016, + /* 200 */ 2016, 2016, 2606, 2620, 2689, 2607, 2604, 2627, 2016, 2637, + /* 210 */ 2016, 2421, 2016, 2410, 2115, 2016, 2115, 2371, 2316, 2016, + /* 220 */ 2326, 2016, 2326, 2323, 2016, 2016, 2016, 2326, 2323, 2323, + /* 230 */ 2323, 2180, 2176, 2016, 2174, 2016, 2016, 2016, 2016, 2071, + /* 240 */ 2016, 2071, 2016, 2115, 2115, 2016, 2115, 2016, 2016, 2115, + /* 250 */ 2016, 2115, 2016, 2115, 2115, 2016, 2115, 2016, 2016, 2016, + /* 260 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 270 */ 2016, 2016, 2016, 2016, 2016, 2016, 2408, 2394, 2016, 2113, + /* 280 */ 2016, 2382, 2380, 2016, 2113, 2637, 2016, 2016, 2659, 2654, + /* 290 */ 2659, 2654, 2673, 2669, 2659, 2678, 2675, 2639, 2637, 2708, + /* 300 */ 2695, 2691, 2620, 2016, 2016, 2625, 2623, 2016, 2113, 2113, + /* 310 */ 2016, 2654, 2016, 2016, 2016, 2016, 2654, 2016, 2016, 2113, + /* 320 */ 2016, 2113, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 330 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 340 */ 2016, 2016, 2016, 2016, 2016, 2207, 2016, 2016, 2113, 2016, + /* 350 */ 2055, 2016, 2373, 2399, 2354, 2354, 2242, 2242, 2242, 2116, + /* 360 */ 2021, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 370 */ 2016, 2016, 2016, 2672, 2671, 2526, 2016, 2578, 2577, 2576, + /* 380 */ 2567, 2525, 2203, 2016, 2016, 2524, 2523, 2016, 2016, 2016, + /* 390 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2517, 2016, + /* 400 */ 2016, 2518, 2516, 2515, 2345, 2344, 2016, 2016, 2016, 2016, + /* 410 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 420 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 430 */ 2016, 2016, 2692, 2696, 2016, 2603, 2016, 2016, 2016, 2497, + /* 440 */ 2016, 2016, 2016, 2016, 2016, 2465, 2460, 2451, 2442, 2457, + /* 450 */ 2448, 2436, 2454, 2445, 2433, 2430, 2016, 2016, 2016, 2016, + /* 460 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 470 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 480 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 490 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 500 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 510 */ 2322, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 520 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 530 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 540 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 550 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 560 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 570 */ 2016, 2016, 2016, 2337, 2016, 2016, 2016, 2016, 2016, 2016, + /* 580 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 590 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 600 */ 2016, 2016, 2016, 2016, 2016, 2060, 2504, 2016, 2016, 2016, + /* 610 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 620 */ 2507, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 630 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 640 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 650 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 660 */ 2016, 2155, 2154, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 670 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 680 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2508, + /* 690 */ 2016, 2016, 2016, 2016, 2016, 2499, 2016, 2016, 2016, 2016, + /* 700 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 710 */ 2016, 2016, 2688, 2640, 2016, 2016, 2016, 2016, 2016, 2016, + /* 720 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 730 */ 2016, 2016, 2016, 2016, 2016, 2016, 2497, 2016, 2670, 2016, + /* 740 */ 2016, 2686, 2016, 2690, 2016, 2016, 2016, 2016, 2016, 2016, + /* 750 */ 2016, 2613, 2609, 2016, 2016, 2605, 2016, 2016, 2016, 2016, + /* 760 */ 2016, 2564, 2016, 2016, 2016, 2598, 2016, 2016, 2016, 2016, + /* 770 */ 2016, 2016, 2016, 2016, 2016, 2508, 2016, 2511, 2016, 2016, + /* 780 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 790 */ 2496, 2016, 2549, 2548, 2016, 2016, 2016, 2016, 2016, 2016, + /* 800 */ 2016, 2236, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 810 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2220, 2218, 2217, + /* 820 */ 2216, 2016, 2213, 2016, 2249, 2016, 2016, 2016, 2245, 2244, + /* 830 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 840 */ 2016, 2016, 2016, 2016, 2016, 2016, 2134, 2016, 2016, 2016, + /* 850 */ 2016, 2016, 2016, 2016, 2016, 2126, 2016, 2125, 2016, 2016, + /* 860 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 870 */ 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, 2016, + /* 880 */ 2016, 2016, 2016, 2016, 2016, 2045, 2016, 2016, 2016, 2016, + /* 890 */ 2016, 2016, }; /********** End of lemon-generated parsing tables *****************************/ @@ -2512,266 +2520,286 @@ static const char *const yyRuleName[] = { /* 409 */ "insert_query ::= INSERT INTO full_table_name NK_LP col_name_list NK_RP query_or_subquery", /* 410 */ "insert_query ::= INSERT INTO full_table_name query_or_subquery", /* 411 */ "tags_literal ::= NK_INTEGER", - /* 412 */ "tags_literal ::= NK_PLUS NK_INTEGER", - /* 413 */ "tags_literal ::= NK_MINUS NK_INTEGER", - /* 414 */ "tags_literal ::= NK_FLOAT", - /* 415 */ "tags_literal ::= NK_PLUS NK_FLOAT", - /* 416 */ "tags_literal ::= NK_MINUS NK_FLOAT", - /* 417 */ "tags_literal ::= NK_BIN", - /* 418 */ "tags_literal ::= NK_PLUS NK_BIN", - /* 419 */ "tags_literal ::= NK_MINUS NK_BIN", - /* 420 */ "tags_literal ::= NK_HEX", - /* 421 */ "tags_literal ::= NK_PLUS NK_HEX", - /* 422 */ "tags_literal ::= NK_MINUS NK_HEX", - /* 423 */ "tags_literal ::= NK_STRING", - /* 424 */ "tags_literal ::= NK_BOOL", - /* 425 */ "tags_literal ::= NULL", - /* 426 */ "tags_literal ::= literal_func", - /* 427 */ "tags_literal ::= literal_func NK_PLUS duration_literal", - /* 428 */ "tags_literal ::= literal_func NK_MINUS duration_literal", - /* 429 */ "tags_literal_list ::= tags_literal", - /* 430 */ "tags_literal_list ::= tags_literal_list NK_COMMA tags_literal", - /* 431 */ "literal ::= NK_INTEGER", - /* 432 */ "literal ::= NK_FLOAT", - /* 433 */ "literal ::= NK_STRING", - /* 434 */ "literal ::= NK_BOOL", - /* 435 */ "literal ::= TIMESTAMP NK_STRING", - /* 436 */ "literal ::= duration_literal", - /* 437 */ "literal ::= NULL", - /* 438 */ "literal ::= NK_QUESTION", - /* 439 */ "duration_literal ::= NK_VARIABLE", - /* 440 */ "signed ::= NK_INTEGER", - /* 441 */ "signed ::= NK_PLUS NK_INTEGER", - /* 442 */ "signed ::= NK_MINUS NK_INTEGER", - /* 443 */ "signed ::= NK_FLOAT", - /* 444 */ "signed ::= NK_PLUS NK_FLOAT", - /* 445 */ "signed ::= NK_MINUS NK_FLOAT", - /* 446 */ "signed_literal ::= signed", - /* 447 */ "signed_literal ::= NK_STRING", - /* 448 */ "signed_literal ::= NK_BOOL", - /* 449 */ "signed_literal ::= TIMESTAMP NK_STRING", - /* 450 */ "signed_literal ::= duration_literal", - /* 451 */ "signed_literal ::= NULL", - /* 452 */ "signed_literal ::= literal_func", - /* 453 */ "signed_literal ::= NK_QUESTION", - /* 454 */ "literal_list ::= signed_literal", - /* 455 */ "literal_list ::= literal_list NK_COMMA signed_literal", - /* 456 */ "db_name ::= NK_ID", - /* 457 */ "table_name ::= NK_ID", - /* 458 */ "column_name ::= NK_ID", - /* 459 */ "function_name ::= NK_ID", - /* 460 */ "view_name ::= NK_ID", - /* 461 */ "table_alias ::= NK_ID", - /* 462 */ "column_alias ::= NK_ID", - /* 463 */ "column_alias ::= NK_ALIAS", - /* 464 */ "user_name ::= NK_ID", - /* 465 */ "topic_name ::= NK_ID", - /* 466 */ "stream_name ::= NK_ID", - /* 467 */ "cgroup_name ::= NK_ID", - /* 468 */ "index_name ::= NK_ID", - /* 469 */ "expr_or_subquery ::= expression", - /* 470 */ "expression ::= literal", - /* 471 */ "expression ::= pseudo_column", - /* 472 */ "expression ::= column_reference", - /* 473 */ "expression ::= function_expression", - /* 474 */ "expression ::= case_when_expression", - /* 475 */ "expression ::= NK_LP expression NK_RP", - /* 476 */ "expression ::= NK_PLUS expr_or_subquery", - /* 477 */ "expression ::= NK_MINUS expr_or_subquery", - /* 478 */ "expression ::= expr_or_subquery NK_PLUS expr_or_subquery", - /* 479 */ "expression ::= expr_or_subquery NK_MINUS expr_or_subquery", - /* 480 */ "expression ::= expr_or_subquery NK_STAR expr_or_subquery", - /* 481 */ "expression ::= expr_or_subquery NK_SLASH expr_or_subquery", - /* 482 */ "expression ::= expr_or_subquery NK_REM expr_or_subquery", - /* 483 */ "expression ::= column_reference NK_ARROW NK_STRING", - /* 484 */ "expression ::= expr_or_subquery NK_BITAND expr_or_subquery", - /* 485 */ "expression ::= expr_or_subquery NK_BITOR expr_or_subquery", - /* 486 */ "expression_list ::= expr_or_subquery", - /* 487 */ "expression_list ::= expression_list NK_COMMA expr_or_subquery", - /* 488 */ "column_reference ::= column_name", - /* 489 */ "column_reference ::= table_name NK_DOT column_name", - /* 490 */ "column_reference ::= NK_ALIAS", - /* 491 */ "column_reference ::= table_name NK_DOT NK_ALIAS", - /* 492 */ "pseudo_column ::= ROWTS", - /* 493 */ "pseudo_column ::= TBNAME", - /* 494 */ "pseudo_column ::= table_name NK_DOT TBNAME", - /* 495 */ "pseudo_column ::= QSTART", - /* 496 */ "pseudo_column ::= QEND", - /* 497 */ "pseudo_column ::= QDURATION", - /* 498 */ "pseudo_column ::= WSTART", - /* 499 */ "pseudo_column ::= WEND", - /* 500 */ "pseudo_column ::= WDURATION", - /* 501 */ "pseudo_column ::= IROWTS", - /* 502 */ "pseudo_column ::= ISFILLED", - /* 503 */ "pseudo_column ::= QTAGS", - /* 504 */ "function_expression ::= function_name NK_LP expression_list NK_RP", - /* 505 */ "function_expression ::= star_func NK_LP star_func_para_list NK_RP", - /* 506 */ "function_expression ::= CAST NK_LP expr_or_subquery AS type_name NK_RP", - /* 507 */ "function_expression ::= literal_func", - /* 508 */ "literal_func ::= noarg_func NK_LP NK_RP", - /* 509 */ "literal_func ::= NOW", - /* 510 */ "literal_func ::= TODAY", - /* 511 */ "noarg_func ::= NOW", - /* 512 */ "noarg_func ::= TODAY", - /* 513 */ "noarg_func ::= TIMEZONE", - /* 514 */ "noarg_func ::= DATABASE", - /* 515 */ "noarg_func ::= CLIENT_VERSION", - /* 516 */ "noarg_func ::= SERVER_VERSION", - /* 517 */ "noarg_func ::= SERVER_STATUS", - /* 518 */ "noarg_func ::= CURRENT_USER", - /* 519 */ "noarg_func ::= USER", - /* 520 */ "star_func ::= COUNT", - /* 521 */ "star_func ::= FIRST", - /* 522 */ "star_func ::= LAST", - /* 523 */ "star_func ::= LAST_ROW", - /* 524 */ "star_func_para_list ::= NK_STAR", - /* 525 */ "star_func_para_list ::= other_para_list", - /* 526 */ "other_para_list ::= star_func_para", - /* 527 */ "other_para_list ::= other_para_list NK_COMMA star_func_para", - /* 528 */ "star_func_para ::= expr_or_subquery", - /* 529 */ "star_func_para ::= table_name NK_DOT NK_STAR", - /* 530 */ "case_when_expression ::= CASE when_then_list case_when_else_opt END", - /* 531 */ "case_when_expression ::= CASE common_expression when_then_list case_when_else_opt END", - /* 532 */ "when_then_list ::= when_then_expr", - /* 533 */ "when_then_list ::= when_then_list when_then_expr", - /* 534 */ "when_then_expr ::= WHEN common_expression THEN common_expression", - /* 535 */ "case_when_else_opt ::=", - /* 536 */ "case_when_else_opt ::= ELSE common_expression", - /* 537 */ "predicate ::= expr_or_subquery compare_op expr_or_subquery", - /* 538 */ "predicate ::= expr_or_subquery BETWEEN expr_or_subquery AND expr_or_subquery", - /* 539 */ "predicate ::= expr_or_subquery NOT BETWEEN expr_or_subquery AND expr_or_subquery", - /* 540 */ "predicate ::= expr_or_subquery IS NULL", - /* 541 */ "predicate ::= expr_or_subquery IS NOT NULL", - /* 542 */ "predicate ::= expr_or_subquery in_op in_predicate_value", - /* 543 */ "compare_op ::= NK_LT", - /* 544 */ "compare_op ::= NK_GT", - /* 545 */ "compare_op ::= NK_LE", - /* 546 */ "compare_op ::= NK_GE", - /* 547 */ "compare_op ::= NK_NE", - /* 548 */ "compare_op ::= NK_EQ", - /* 549 */ "compare_op ::= LIKE", - /* 550 */ "compare_op ::= NOT LIKE", - /* 551 */ "compare_op ::= MATCH", - /* 552 */ "compare_op ::= NMATCH", - /* 553 */ "compare_op ::= CONTAINS", - /* 554 */ "in_op ::= IN", - /* 555 */ "in_op ::= NOT IN", - /* 556 */ "in_predicate_value ::= NK_LP literal_list NK_RP", - /* 557 */ "boolean_value_expression ::= boolean_primary", - /* 558 */ "boolean_value_expression ::= NOT boolean_primary", - /* 559 */ "boolean_value_expression ::= boolean_value_expression OR boolean_value_expression", - /* 560 */ "boolean_value_expression ::= boolean_value_expression AND boolean_value_expression", - /* 561 */ "boolean_primary ::= predicate", - /* 562 */ "boolean_primary ::= NK_LP boolean_value_expression NK_RP", - /* 563 */ "common_expression ::= expr_or_subquery", - /* 564 */ "common_expression ::= boolean_value_expression", - /* 565 */ "from_clause_opt ::=", - /* 566 */ "from_clause_opt ::= FROM table_reference_list", - /* 567 */ "table_reference_list ::= table_reference", - /* 568 */ "table_reference_list ::= table_reference_list NK_COMMA table_reference", - /* 569 */ "table_reference ::= table_primary", - /* 570 */ "table_reference ::= joined_table", - /* 571 */ "table_primary ::= table_name alias_opt", - /* 572 */ "table_primary ::= db_name NK_DOT table_name alias_opt", - /* 573 */ "table_primary ::= subquery alias_opt", - /* 574 */ "table_primary ::= parenthesized_joined_table", - /* 575 */ "alias_opt ::=", - /* 576 */ "alias_opt ::= table_alias", - /* 577 */ "alias_opt ::= AS table_alias", - /* 578 */ "parenthesized_joined_table ::= NK_LP joined_table NK_RP", - /* 579 */ "parenthesized_joined_table ::= NK_LP parenthesized_joined_table NK_RP", - /* 580 */ "joined_table ::= table_reference join_type JOIN table_reference ON search_condition", - /* 581 */ "join_type ::=", - /* 582 */ "join_type ::= INNER", - /* 583 */ "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", - /* 584 */ "hint_list ::=", - /* 585 */ "hint_list ::= NK_HINT", - /* 586 */ "tag_mode_opt ::=", - /* 587 */ "tag_mode_opt ::= TAGS", - /* 588 */ "set_quantifier_opt ::=", - /* 589 */ "set_quantifier_opt ::= DISTINCT", - /* 590 */ "set_quantifier_opt ::= ALL", - /* 591 */ "select_list ::= select_item", - /* 592 */ "select_list ::= select_list NK_COMMA select_item", - /* 593 */ "select_item ::= NK_STAR", - /* 594 */ "select_item ::= common_expression", - /* 595 */ "select_item ::= common_expression column_alias", - /* 596 */ "select_item ::= common_expression AS column_alias", - /* 597 */ "select_item ::= table_name NK_DOT NK_STAR", - /* 598 */ "where_clause_opt ::=", - /* 599 */ "where_clause_opt ::= WHERE search_condition", - /* 600 */ "partition_by_clause_opt ::=", - /* 601 */ "partition_by_clause_opt ::= PARTITION BY partition_list", - /* 602 */ "partition_list ::= partition_item", - /* 603 */ "partition_list ::= partition_list NK_COMMA partition_item", - /* 604 */ "partition_item ::= expr_or_subquery", - /* 605 */ "partition_item ::= expr_or_subquery column_alias", - /* 606 */ "partition_item ::= expr_or_subquery AS column_alias", - /* 607 */ "twindow_clause_opt ::=", - /* 608 */ "twindow_clause_opt ::= SESSION NK_LP column_reference NK_COMMA interval_sliding_duration_literal NK_RP", - /* 609 */ "twindow_clause_opt ::= STATE_WINDOW NK_LP expr_or_subquery NK_RP", - /* 610 */ "twindow_clause_opt ::= INTERVAL NK_LP interval_sliding_duration_literal NK_RP sliding_opt fill_opt", - /* 611 */ "twindow_clause_opt ::= INTERVAL NK_LP interval_sliding_duration_literal NK_COMMA interval_sliding_duration_literal NK_RP sliding_opt fill_opt", - /* 612 */ "twindow_clause_opt ::= EVENT_WINDOW START WITH search_condition END WITH search_condition", - /* 613 */ "twindow_clause_opt ::= COUNT_WINDOW NK_LP NK_INTEGER NK_RP", - /* 614 */ "twindow_clause_opt ::= COUNT_WINDOW NK_LP NK_INTEGER NK_COMMA NK_INTEGER NK_RP", - /* 615 */ "sliding_opt ::=", - /* 616 */ "sliding_opt ::= SLIDING NK_LP interval_sliding_duration_literal NK_RP", - /* 617 */ "interval_sliding_duration_literal ::= NK_VARIABLE", - /* 618 */ "interval_sliding_duration_literal ::= NK_STRING", - /* 619 */ "interval_sliding_duration_literal ::= NK_INTEGER", - /* 620 */ "fill_opt ::=", - /* 621 */ "fill_opt ::= FILL NK_LP fill_mode NK_RP", - /* 622 */ "fill_opt ::= FILL NK_LP VALUE NK_COMMA expression_list NK_RP", - /* 623 */ "fill_opt ::= FILL NK_LP VALUE_F NK_COMMA expression_list NK_RP", - /* 624 */ "fill_mode ::= NONE", - /* 625 */ "fill_mode ::= PREV", - /* 626 */ "fill_mode ::= NULL", - /* 627 */ "fill_mode ::= NULL_F", - /* 628 */ "fill_mode ::= LINEAR", - /* 629 */ "fill_mode ::= NEXT", - /* 630 */ "group_by_clause_opt ::=", - /* 631 */ "group_by_clause_opt ::= GROUP BY group_by_list", - /* 632 */ "group_by_list ::= expr_or_subquery", - /* 633 */ "group_by_list ::= group_by_list NK_COMMA expr_or_subquery", - /* 634 */ "having_clause_opt ::=", - /* 635 */ "having_clause_opt ::= HAVING search_condition", - /* 636 */ "range_opt ::=", - /* 637 */ "range_opt ::= RANGE NK_LP expr_or_subquery NK_COMMA expr_or_subquery NK_RP", - /* 638 */ "range_opt ::= RANGE NK_LP expr_or_subquery NK_RP", - /* 639 */ "every_opt ::=", - /* 640 */ "every_opt ::= EVERY NK_LP duration_literal NK_RP", - /* 641 */ "query_expression ::= query_simple order_by_clause_opt slimit_clause_opt limit_clause_opt", - /* 642 */ "query_simple ::= query_specification", - /* 643 */ "query_simple ::= union_query_expression", - /* 644 */ "union_query_expression ::= query_simple_or_subquery UNION ALL query_simple_or_subquery", - /* 645 */ "union_query_expression ::= query_simple_or_subquery UNION query_simple_or_subquery", - /* 646 */ "query_simple_or_subquery ::= query_simple", - /* 647 */ "query_simple_or_subquery ::= subquery", - /* 648 */ "query_or_subquery ::= query_expression", - /* 649 */ "query_or_subquery ::= subquery", - /* 650 */ "order_by_clause_opt ::=", - /* 651 */ "order_by_clause_opt ::= ORDER BY sort_specification_list", - /* 652 */ "slimit_clause_opt ::=", - /* 653 */ "slimit_clause_opt ::= SLIMIT NK_INTEGER", - /* 654 */ "slimit_clause_opt ::= SLIMIT NK_INTEGER SOFFSET NK_INTEGER", - /* 655 */ "slimit_clause_opt ::= SLIMIT NK_INTEGER NK_COMMA NK_INTEGER", - /* 656 */ "limit_clause_opt ::=", - /* 657 */ "limit_clause_opt ::= LIMIT NK_INTEGER", - /* 658 */ "limit_clause_opt ::= LIMIT NK_INTEGER OFFSET NK_INTEGER", - /* 659 */ "limit_clause_opt ::= LIMIT NK_INTEGER NK_COMMA NK_INTEGER", - /* 660 */ "subquery ::= NK_LP query_expression NK_RP", - /* 661 */ "subquery ::= NK_LP subquery NK_RP", - /* 662 */ "search_condition ::= common_expression", - /* 663 */ "sort_specification_list ::= sort_specification", - /* 664 */ "sort_specification_list ::= sort_specification_list NK_COMMA sort_specification", - /* 665 */ "sort_specification ::= expr_or_subquery ordering_specification_opt null_ordering_opt", - /* 666 */ "ordering_specification_opt ::=", - /* 667 */ "ordering_specification_opt ::= ASC", - /* 668 */ "ordering_specification_opt ::= DESC", - /* 669 */ "null_ordering_opt ::=", - /* 670 */ "null_ordering_opt ::= NULLS FIRST", - /* 671 */ "null_ordering_opt ::= NULLS LAST", + /* 412 */ "tags_literal ::= NK_INTEGER NK_PLUS duration_literal", + /* 413 */ "tags_literal ::= NK_INTEGER NK_MINUS duration_literal", + /* 414 */ "tags_literal ::= NK_PLUS NK_INTEGER", + /* 415 */ "tags_literal ::= NK_PLUS NK_INTEGER NK_PLUS duration_literal", + /* 416 */ "tags_literal ::= NK_PLUS NK_INTEGER NK_MINUS duration_literal", + /* 417 */ "tags_literal ::= NK_MINUS NK_INTEGER", + /* 418 */ "tags_literal ::= NK_MINUS NK_INTEGER NK_PLUS duration_literal", + /* 419 */ "tags_literal ::= NK_MINUS NK_INTEGER NK_MINUS duration_literal", + /* 420 */ "tags_literal ::= NK_FLOAT", + /* 421 */ "tags_literal ::= NK_PLUS NK_FLOAT", + /* 422 */ "tags_literal ::= NK_MINUS NK_FLOAT", + /* 423 */ "tags_literal ::= NK_BIN", + /* 424 */ "tags_literal ::= NK_BIN NK_PLUS duration_literal", + /* 425 */ "tags_literal ::= NK_BIN NK_MINUS duration_literal", + /* 426 */ "tags_literal ::= NK_PLUS NK_BIN", + /* 427 */ "tags_literal ::= NK_PLUS NK_BIN NK_PLUS duration_literal", + /* 428 */ "tags_literal ::= NK_PLUS NK_BIN NK_MINUS duration_literal", + /* 429 */ "tags_literal ::= NK_MINUS NK_BIN", + /* 430 */ "tags_literal ::= NK_MINUS NK_BIN NK_PLUS duration_literal", + /* 431 */ "tags_literal ::= NK_MINUS NK_BIN NK_MINUS duration_literal", + /* 432 */ "tags_literal ::= NK_HEX", + /* 433 */ "tags_literal ::= NK_HEX NK_PLUS duration_literal", + /* 434 */ "tags_literal ::= NK_HEX NK_MINUS duration_literal", + /* 435 */ "tags_literal ::= NK_PLUS NK_HEX", + /* 436 */ "tags_literal ::= NK_PLUS NK_HEX NK_PLUS duration_literal", + /* 437 */ "tags_literal ::= NK_PLUS NK_HEX NK_MINUS duration_literal", + /* 438 */ "tags_literal ::= NK_MINUS NK_HEX", + /* 439 */ "tags_literal ::= NK_MINUS NK_HEX NK_PLUS duration_literal", + /* 440 */ "tags_literal ::= NK_MINUS NK_HEX NK_MINUS duration_literal", + /* 441 */ "tags_literal ::= NK_STRING", + /* 442 */ "tags_literal ::= NK_STRING NK_PLUS duration_literal", + /* 443 */ "tags_literal ::= NK_STRING NK_MINUS duration_literal", + /* 444 */ "tags_literal ::= NK_BOOL", + /* 445 */ "tags_literal ::= NULL", + /* 446 */ "tags_literal ::= literal_func", + /* 447 */ "tags_literal ::= literal_func NK_PLUS duration_literal", + /* 448 */ "tags_literal ::= literal_func NK_MINUS duration_literal", + /* 449 */ "tags_literal_list ::= tags_literal", + /* 450 */ "tags_literal_list ::= tags_literal_list NK_COMMA tags_literal", + /* 451 */ "literal ::= NK_INTEGER", + /* 452 */ "literal ::= NK_FLOAT", + /* 453 */ "literal ::= NK_STRING", + /* 454 */ "literal ::= NK_BOOL", + /* 455 */ "literal ::= TIMESTAMP NK_STRING", + /* 456 */ "literal ::= duration_literal", + /* 457 */ "literal ::= NULL", + /* 458 */ "literal ::= NK_QUESTION", + /* 459 */ "duration_literal ::= NK_VARIABLE", + /* 460 */ "signed ::= NK_INTEGER", + /* 461 */ "signed ::= NK_PLUS NK_INTEGER", + /* 462 */ "signed ::= NK_MINUS NK_INTEGER", + /* 463 */ "signed ::= NK_FLOAT", + /* 464 */ "signed ::= NK_PLUS NK_FLOAT", + /* 465 */ "signed ::= NK_MINUS NK_FLOAT", + /* 466 */ "signed_literal ::= signed", + /* 467 */ "signed_literal ::= NK_STRING", + /* 468 */ "signed_literal ::= NK_BOOL", + /* 469 */ "signed_literal ::= TIMESTAMP NK_STRING", + /* 470 */ "signed_literal ::= duration_literal", + /* 471 */ "signed_literal ::= NULL", + /* 472 */ "signed_literal ::= literal_func", + /* 473 */ "signed_literal ::= NK_QUESTION", + /* 474 */ "literal_list ::= signed_literal", + /* 475 */ "literal_list ::= literal_list NK_COMMA signed_literal", + /* 476 */ "db_name ::= NK_ID", + /* 477 */ "table_name ::= NK_ID", + /* 478 */ "column_name ::= NK_ID", + /* 479 */ "function_name ::= NK_ID", + /* 480 */ "view_name ::= NK_ID", + /* 481 */ "table_alias ::= NK_ID", + /* 482 */ "column_alias ::= NK_ID", + /* 483 */ "column_alias ::= NK_ALIAS", + /* 484 */ "user_name ::= NK_ID", + /* 485 */ "topic_name ::= NK_ID", + /* 486 */ "stream_name ::= NK_ID", + /* 487 */ "cgroup_name ::= NK_ID", + /* 488 */ "index_name ::= NK_ID", + /* 489 */ "expr_or_subquery ::= expression", + /* 490 */ "expression ::= literal", + /* 491 */ "expression ::= pseudo_column", + /* 492 */ "expression ::= column_reference", + /* 493 */ "expression ::= function_expression", + /* 494 */ "expression ::= case_when_expression", + /* 495 */ "expression ::= NK_LP expression NK_RP", + /* 496 */ "expression ::= NK_PLUS expr_or_subquery", + /* 497 */ "expression ::= NK_MINUS expr_or_subquery", + /* 498 */ "expression ::= expr_or_subquery NK_PLUS expr_or_subquery", + /* 499 */ "expression ::= expr_or_subquery NK_MINUS expr_or_subquery", + /* 500 */ "expression ::= expr_or_subquery NK_STAR expr_or_subquery", + /* 501 */ "expression ::= expr_or_subquery NK_SLASH expr_or_subquery", + /* 502 */ "expression ::= expr_or_subquery NK_REM expr_or_subquery", + /* 503 */ "expression ::= column_reference NK_ARROW NK_STRING", + /* 504 */ "expression ::= expr_or_subquery NK_BITAND expr_or_subquery", + /* 505 */ "expression ::= expr_or_subquery NK_BITOR expr_or_subquery", + /* 506 */ "expression_list ::= expr_or_subquery", + /* 507 */ "expression_list ::= expression_list NK_COMMA expr_or_subquery", + /* 508 */ "column_reference ::= column_name", + /* 509 */ "column_reference ::= table_name NK_DOT column_name", + /* 510 */ "column_reference ::= NK_ALIAS", + /* 511 */ "column_reference ::= table_name NK_DOT NK_ALIAS", + /* 512 */ "pseudo_column ::= ROWTS", + /* 513 */ "pseudo_column ::= TBNAME", + /* 514 */ "pseudo_column ::= table_name NK_DOT TBNAME", + /* 515 */ "pseudo_column ::= QSTART", + /* 516 */ "pseudo_column ::= QEND", + /* 517 */ "pseudo_column ::= QDURATION", + /* 518 */ "pseudo_column ::= WSTART", + /* 519 */ "pseudo_column ::= WEND", + /* 520 */ "pseudo_column ::= WDURATION", + /* 521 */ "pseudo_column ::= IROWTS", + /* 522 */ "pseudo_column ::= ISFILLED", + /* 523 */ "pseudo_column ::= QTAGS", + /* 524 */ "function_expression ::= function_name NK_LP expression_list NK_RP", + /* 525 */ "function_expression ::= star_func NK_LP star_func_para_list NK_RP", + /* 526 */ "function_expression ::= CAST NK_LP expr_or_subquery AS type_name NK_RP", + /* 527 */ "function_expression ::= literal_func", + /* 528 */ "literal_func ::= noarg_func NK_LP NK_RP", + /* 529 */ "literal_func ::= NOW", + /* 530 */ "literal_func ::= TODAY", + /* 531 */ "noarg_func ::= NOW", + /* 532 */ "noarg_func ::= TODAY", + /* 533 */ "noarg_func ::= TIMEZONE", + /* 534 */ "noarg_func ::= DATABASE", + /* 535 */ "noarg_func ::= CLIENT_VERSION", + /* 536 */ "noarg_func ::= SERVER_VERSION", + /* 537 */ "noarg_func ::= SERVER_STATUS", + /* 538 */ "noarg_func ::= CURRENT_USER", + /* 539 */ "noarg_func ::= USER", + /* 540 */ "star_func ::= COUNT", + /* 541 */ "star_func ::= FIRST", + /* 542 */ "star_func ::= LAST", + /* 543 */ "star_func ::= LAST_ROW", + /* 544 */ "star_func_para_list ::= NK_STAR", + /* 545 */ "star_func_para_list ::= other_para_list", + /* 546 */ "other_para_list ::= star_func_para", + /* 547 */ "other_para_list ::= other_para_list NK_COMMA star_func_para", + /* 548 */ "star_func_para ::= expr_or_subquery", + /* 549 */ "star_func_para ::= table_name NK_DOT NK_STAR", + /* 550 */ "case_when_expression ::= CASE when_then_list case_when_else_opt END", + /* 551 */ "case_when_expression ::= CASE common_expression when_then_list case_when_else_opt END", + /* 552 */ "when_then_list ::= when_then_expr", + /* 553 */ "when_then_list ::= when_then_list when_then_expr", + /* 554 */ "when_then_expr ::= WHEN common_expression THEN common_expression", + /* 555 */ "case_when_else_opt ::=", + /* 556 */ "case_when_else_opt ::= ELSE common_expression", + /* 557 */ "predicate ::= expr_or_subquery compare_op expr_or_subquery", + /* 558 */ "predicate ::= expr_or_subquery BETWEEN expr_or_subquery AND expr_or_subquery", + /* 559 */ "predicate ::= expr_or_subquery NOT BETWEEN expr_or_subquery AND expr_or_subquery", + /* 560 */ "predicate ::= expr_or_subquery IS NULL", + /* 561 */ "predicate ::= expr_or_subquery IS NOT NULL", + /* 562 */ "predicate ::= expr_or_subquery in_op in_predicate_value", + /* 563 */ "compare_op ::= NK_LT", + /* 564 */ "compare_op ::= NK_GT", + /* 565 */ "compare_op ::= NK_LE", + /* 566 */ "compare_op ::= NK_GE", + /* 567 */ "compare_op ::= NK_NE", + /* 568 */ "compare_op ::= NK_EQ", + /* 569 */ "compare_op ::= LIKE", + /* 570 */ "compare_op ::= NOT LIKE", + /* 571 */ "compare_op ::= MATCH", + /* 572 */ "compare_op ::= NMATCH", + /* 573 */ "compare_op ::= CONTAINS", + /* 574 */ "in_op ::= IN", + /* 575 */ "in_op ::= NOT IN", + /* 576 */ "in_predicate_value ::= NK_LP literal_list NK_RP", + /* 577 */ "boolean_value_expression ::= boolean_primary", + /* 578 */ "boolean_value_expression ::= NOT boolean_primary", + /* 579 */ "boolean_value_expression ::= boolean_value_expression OR boolean_value_expression", + /* 580 */ "boolean_value_expression ::= boolean_value_expression AND boolean_value_expression", + /* 581 */ "boolean_primary ::= predicate", + /* 582 */ "boolean_primary ::= NK_LP boolean_value_expression NK_RP", + /* 583 */ "common_expression ::= expr_or_subquery", + /* 584 */ "common_expression ::= boolean_value_expression", + /* 585 */ "from_clause_opt ::=", + /* 586 */ "from_clause_opt ::= FROM table_reference_list", + /* 587 */ "table_reference_list ::= table_reference", + /* 588 */ "table_reference_list ::= table_reference_list NK_COMMA table_reference", + /* 589 */ "table_reference ::= table_primary", + /* 590 */ "table_reference ::= joined_table", + /* 591 */ "table_primary ::= table_name alias_opt", + /* 592 */ "table_primary ::= db_name NK_DOT table_name alias_opt", + /* 593 */ "table_primary ::= subquery alias_opt", + /* 594 */ "table_primary ::= parenthesized_joined_table", + /* 595 */ "alias_opt ::=", + /* 596 */ "alias_opt ::= table_alias", + /* 597 */ "alias_opt ::= AS table_alias", + /* 598 */ "parenthesized_joined_table ::= NK_LP joined_table NK_RP", + /* 599 */ "parenthesized_joined_table ::= NK_LP parenthesized_joined_table NK_RP", + /* 600 */ "joined_table ::= table_reference join_type JOIN table_reference ON search_condition", + /* 601 */ "join_type ::=", + /* 602 */ "join_type ::= INNER", + /* 603 */ "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", + /* 604 */ "hint_list ::=", + /* 605 */ "hint_list ::= NK_HINT", + /* 606 */ "tag_mode_opt ::=", + /* 607 */ "tag_mode_opt ::= TAGS", + /* 608 */ "set_quantifier_opt ::=", + /* 609 */ "set_quantifier_opt ::= DISTINCT", + /* 610 */ "set_quantifier_opt ::= ALL", + /* 611 */ "select_list ::= select_item", + /* 612 */ "select_list ::= select_list NK_COMMA select_item", + /* 613 */ "select_item ::= NK_STAR", + /* 614 */ "select_item ::= common_expression", + /* 615 */ "select_item ::= common_expression column_alias", + /* 616 */ "select_item ::= common_expression AS column_alias", + /* 617 */ "select_item ::= table_name NK_DOT NK_STAR", + /* 618 */ "where_clause_opt ::=", + /* 619 */ "where_clause_opt ::= WHERE search_condition", + /* 620 */ "partition_by_clause_opt ::=", + /* 621 */ "partition_by_clause_opt ::= PARTITION BY partition_list", + /* 622 */ "partition_list ::= partition_item", + /* 623 */ "partition_list ::= partition_list NK_COMMA partition_item", + /* 624 */ "partition_item ::= expr_or_subquery", + /* 625 */ "partition_item ::= expr_or_subquery column_alias", + /* 626 */ "partition_item ::= expr_or_subquery AS column_alias", + /* 627 */ "twindow_clause_opt ::=", + /* 628 */ "twindow_clause_opt ::= SESSION NK_LP column_reference NK_COMMA interval_sliding_duration_literal NK_RP", + /* 629 */ "twindow_clause_opt ::= STATE_WINDOW NK_LP expr_or_subquery NK_RP", + /* 630 */ "twindow_clause_opt ::= INTERVAL NK_LP interval_sliding_duration_literal NK_RP sliding_opt fill_opt", + /* 631 */ "twindow_clause_opt ::= INTERVAL NK_LP interval_sliding_duration_literal NK_COMMA interval_sliding_duration_literal NK_RP sliding_opt fill_opt", + /* 632 */ "twindow_clause_opt ::= EVENT_WINDOW START WITH search_condition END WITH search_condition", + /* 633 */ "twindow_clause_opt ::= COUNT_WINDOW NK_LP NK_INTEGER NK_RP", + /* 634 */ "twindow_clause_opt ::= COUNT_WINDOW NK_LP NK_INTEGER NK_COMMA NK_INTEGER NK_RP", + /* 635 */ "sliding_opt ::=", + /* 636 */ "sliding_opt ::= SLIDING NK_LP interval_sliding_duration_literal NK_RP", + /* 637 */ "interval_sliding_duration_literal ::= NK_VARIABLE", + /* 638 */ "interval_sliding_duration_literal ::= NK_STRING", + /* 639 */ "interval_sliding_duration_literal ::= NK_INTEGER", + /* 640 */ "fill_opt ::=", + /* 641 */ "fill_opt ::= FILL NK_LP fill_mode NK_RP", + /* 642 */ "fill_opt ::= FILL NK_LP VALUE NK_COMMA expression_list NK_RP", + /* 643 */ "fill_opt ::= FILL NK_LP VALUE_F NK_COMMA expression_list NK_RP", + /* 644 */ "fill_mode ::= NONE", + /* 645 */ "fill_mode ::= PREV", + /* 646 */ "fill_mode ::= NULL", + /* 647 */ "fill_mode ::= NULL_F", + /* 648 */ "fill_mode ::= LINEAR", + /* 649 */ "fill_mode ::= NEXT", + /* 650 */ "group_by_clause_opt ::=", + /* 651 */ "group_by_clause_opt ::= GROUP BY group_by_list", + /* 652 */ "group_by_list ::= expr_or_subquery", + /* 653 */ "group_by_list ::= group_by_list NK_COMMA expr_or_subquery", + /* 654 */ "having_clause_opt ::=", + /* 655 */ "having_clause_opt ::= HAVING search_condition", + /* 656 */ "range_opt ::=", + /* 657 */ "range_opt ::= RANGE NK_LP expr_or_subquery NK_COMMA expr_or_subquery NK_RP", + /* 658 */ "range_opt ::= RANGE NK_LP expr_or_subquery NK_RP", + /* 659 */ "every_opt ::=", + /* 660 */ "every_opt ::= EVERY NK_LP duration_literal NK_RP", + /* 661 */ "query_expression ::= query_simple order_by_clause_opt slimit_clause_opt limit_clause_opt", + /* 662 */ "query_simple ::= query_specification", + /* 663 */ "query_simple ::= union_query_expression", + /* 664 */ "union_query_expression ::= query_simple_or_subquery UNION ALL query_simple_or_subquery", + /* 665 */ "union_query_expression ::= query_simple_or_subquery UNION query_simple_or_subquery", + /* 666 */ "query_simple_or_subquery ::= query_simple", + /* 667 */ "query_simple_or_subquery ::= subquery", + /* 668 */ "query_or_subquery ::= query_expression", + /* 669 */ "query_or_subquery ::= subquery", + /* 670 */ "order_by_clause_opt ::=", + /* 671 */ "order_by_clause_opt ::= ORDER BY sort_specification_list", + /* 672 */ "slimit_clause_opt ::=", + /* 673 */ "slimit_clause_opt ::= SLIMIT NK_INTEGER", + /* 674 */ "slimit_clause_opt ::= SLIMIT NK_INTEGER SOFFSET NK_INTEGER", + /* 675 */ "slimit_clause_opt ::= SLIMIT NK_INTEGER NK_COMMA NK_INTEGER", + /* 676 */ "limit_clause_opt ::=", + /* 677 */ "limit_clause_opt ::= LIMIT NK_INTEGER", + /* 678 */ "limit_clause_opt ::= LIMIT NK_INTEGER OFFSET NK_INTEGER", + /* 679 */ "limit_clause_opt ::= LIMIT NK_INTEGER NK_COMMA NK_INTEGER", + /* 680 */ "subquery ::= NK_LP query_expression NK_RP", + /* 681 */ "subquery ::= NK_LP subquery NK_RP", + /* 682 */ "search_condition ::= common_expression", + /* 683 */ "sort_specification_list ::= sort_specification", + /* 684 */ "sort_specification_list ::= sort_specification_list NK_COMMA sort_specification", + /* 685 */ "sort_specification ::= expr_or_subquery ordering_specification_opt null_ordering_opt", + /* 686 */ "ordering_specification_opt ::=", + /* 687 */ "ordering_specification_opt ::= ASC", + /* 688 */ "ordering_specification_opt ::= DESC", + /* 689 */ "null_ordering_opt ::=", + /* 690 */ "null_ordering_opt ::= NULLS FIRST", + /* 691 */ "null_ordering_opt ::= NULLS LAST", }; #endif /* NDEBUG */ @@ -3827,266 +3855,286 @@ static const YYCODETYPE yyRuleInfoLhs[] = { 440, /* (409) insert_query ::= INSERT INTO full_table_name NK_LP col_name_list NK_RP query_or_subquery */ 440, /* (410) insert_query ::= INSERT INTO full_table_name query_or_subquery */ 401, /* (411) tags_literal ::= NK_INTEGER */ - 401, /* (412) tags_literal ::= NK_PLUS NK_INTEGER */ - 401, /* (413) tags_literal ::= NK_MINUS NK_INTEGER */ - 401, /* (414) tags_literal ::= NK_FLOAT */ - 401, /* (415) tags_literal ::= NK_PLUS NK_FLOAT */ - 401, /* (416) tags_literal ::= NK_MINUS NK_FLOAT */ - 401, /* (417) tags_literal ::= NK_BIN */ - 401, /* (418) tags_literal ::= NK_PLUS NK_BIN */ - 401, /* (419) tags_literal ::= NK_MINUS NK_BIN */ - 401, /* (420) tags_literal ::= NK_HEX */ - 401, /* (421) tags_literal ::= NK_PLUS NK_HEX */ - 401, /* (422) tags_literal ::= NK_MINUS NK_HEX */ - 401, /* (423) tags_literal ::= NK_STRING */ - 401, /* (424) tags_literal ::= NK_BOOL */ - 401, /* (425) tags_literal ::= NULL */ - 401, /* (426) tags_literal ::= literal_func */ - 401, /* (427) tags_literal ::= literal_func NK_PLUS duration_literal */ - 401, /* (428) tags_literal ::= literal_func NK_MINUS duration_literal */ - 404, /* (429) tags_literal_list ::= tags_literal */ - 404, /* (430) tags_literal_list ::= tags_literal_list NK_COMMA tags_literal */ - 358, /* (431) literal ::= NK_INTEGER */ - 358, /* (432) literal ::= NK_FLOAT */ - 358, /* (433) literal ::= NK_STRING */ - 358, /* (434) literal ::= NK_BOOL */ - 358, /* (435) literal ::= TIMESTAMP NK_STRING */ - 358, /* (436) literal ::= duration_literal */ - 358, /* (437) literal ::= NULL */ - 358, /* (438) literal ::= NK_QUESTION */ - 411, /* (439) duration_literal ::= NK_VARIABLE */ - 387, /* (440) signed ::= NK_INTEGER */ - 387, /* (441) signed ::= NK_PLUS NK_INTEGER */ - 387, /* (442) signed ::= NK_MINUS NK_INTEGER */ - 387, /* (443) signed ::= NK_FLOAT */ - 387, /* (444) signed ::= NK_PLUS NK_FLOAT */ - 387, /* (445) signed ::= NK_MINUS NK_FLOAT */ - 457, /* (446) signed_literal ::= signed */ - 457, /* (447) signed_literal ::= NK_STRING */ - 457, /* (448) signed_literal ::= NK_BOOL */ - 457, /* (449) signed_literal ::= TIMESTAMP NK_STRING */ - 457, /* (450) signed_literal ::= duration_literal */ - 457, /* (451) signed_literal ::= NULL */ - 457, /* (452) signed_literal ::= literal_func */ - 457, /* (453) signed_literal ::= NK_QUESTION */ - 458, /* (454) literal_list ::= signed_literal */ - 458, /* (455) literal_list ::= literal_list NK_COMMA signed_literal */ - 370, /* (456) db_name ::= NK_ID */ - 371, /* (457) table_name ::= NK_ID */ - 399, /* (458) column_name ::= NK_ID */ - 413, /* (459) function_name ::= NK_ID */ - 446, /* (460) view_name ::= NK_ID */ - 459, /* (461) table_alias ::= NK_ID */ - 424, /* (462) column_alias ::= NK_ID */ - 424, /* (463) column_alias ::= NK_ALIAS */ - 363, /* (464) user_name ::= NK_ID */ - 372, /* (465) topic_name ::= NK_ID */ - 447, /* (466) stream_name ::= NK_ID */ - 437, /* (467) cgroup_name ::= NK_ID */ - 427, /* (468) index_name ::= NK_ID */ - 460, /* (469) expr_or_subquery ::= expression */ - 453, /* (470) expression ::= literal */ - 453, /* (471) expression ::= pseudo_column */ - 453, /* (472) expression ::= column_reference */ - 453, /* (473) expression ::= function_expression */ - 453, /* (474) expression ::= case_when_expression */ - 453, /* (475) expression ::= NK_LP expression NK_RP */ - 453, /* (476) expression ::= NK_PLUS expr_or_subquery */ - 453, /* (477) expression ::= NK_MINUS expr_or_subquery */ - 453, /* (478) expression ::= expr_or_subquery NK_PLUS expr_or_subquery */ - 453, /* (479) expression ::= expr_or_subquery NK_MINUS expr_or_subquery */ - 453, /* (480) expression ::= expr_or_subquery NK_STAR expr_or_subquery */ - 453, /* (481) expression ::= expr_or_subquery NK_SLASH expr_or_subquery */ - 453, /* (482) expression ::= expr_or_subquery NK_REM expr_or_subquery */ - 453, /* (483) expression ::= column_reference NK_ARROW NK_STRING */ - 453, /* (484) expression ::= expr_or_subquery NK_BITAND expr_or_subquery */ - 453, /* (485) expression ::= expr_or_subquery NK_BITOR expr_or_subquery */ - 433, /* (486) expression_list ::= expr_or_subquery */ - 433, /* (487) expression_list ::= expression_list NK_COMMA expr_or_subquery */ - 462, /* (488) column_reference ::= column_name */ - 462, /* (489) column_reference ::= table_name NK_DOT column_name */ - 462, /* (490) column_reference ::= NK_ALIAS */ - 462, /* (491) column_reference ::= table_name NK_DOT NK_ALIAS */ - 461, /* (492) pseudo_column ::= ROWTS */ - 461, /* (493) pseudo_column ::= TBNAME */ - 461, /* (494) pseudo_column ::= table_name NK_DOT TBNAME */ - 461, /* (495) pseudo_column ::= QSTART */ - 461, /* (496) pseudo_column ::= QEND */ - 461, /* (497) pseudo_column ::= QDURATION */ - 461, /* (498) pseudo_column ::= WSTART */ - 461, /* (499) pseudo_column ::= WEND */ - 461, /* (500) pseudo_column ::= WDURATION */ - 461, /* (501) pseudo_column ::= IROWTS */ - 461, /* (502) pseudo_column ::= ISFILLED */ - 461, /* (503) pseudo_column ::= QTAGS */ - 463, /* (504) function_expression ::= function_name NK_LP expression_list NK_RP */ - 463, /* (505) function_expression ::= star_func NK_LP star_func_para_list NK_RP */ - 463, /* (506) function_expression ::= CAST NK_LP expr_or_subquery AS type_name NK_RP */ - 463, /* (507) function_expression ::= literal_func */ - 456, /* (508) literal_func ::= noarg_func NK_LP NK_RP */ - 456, /* (509) literal_func ::= NOW */ - 456, /* (510) literal_func ::= TODAY */ - 467, /* (511) noarg_func ::= NOW */ - 467, /* (512) noarg_func ::= TODAY */ - 467, /* (513) noarg_func ::= TIMEZONE */ - 467, /* (514) noarg_func ::= DATABASE */ - 467, /* (515) noarg_func ::= CLIENT_VERSION */ - 467, /* (516) noarg_func ::= SERVER_VERSION */ - 467, /* (517) noarg_func ::= SERVER_STATUS */ - 467, /* (518) noarg_func ::= CURRENT_USER */ - 467, /* (519) noarg_func ::= USER */ - 465, /* (520) star_func ::= COUNT */ - 465, /* (521) star_func ::= FIRST */ - 465, /* (522) star_func ::= LAST */ - 465, /* (523) star_func ::= LAST_ROW */ - 466, /* (524) star_func_para_list ::= NK_STAR */ - 466, /* (525) star_func_para_list ::= other_para_list */ - 468, /* (526) other_para_list ::= star_func_para */ - 468, /* (527) other_para_list ::= other_para_list NK_COMMA star_func_para */ - 469, /* (528) star_func_para ::= expr_or_subquery */ - 469, /* (529) star_func_para ::= table_name NK_DOT NK_STAR */ - 464, /* (530) case_when_expression ::= CASE when_then_list case_when_else_opt END */ - 464, /* (531) case_when_expression ::= CASE common_expression when_then_list case_when_else_opt END */ - 470, /* (532) when_then_list ::= when_then_expr */ - 470, /* (533) when_then_list ::= when_then_list when_then_expr */ - 473, /* (534) when_then_expr ::= WHEN common_expression THEN common_expression */ - 471, /* (535) case_when_else_opt ::= */ - 471, /* (536) case_when_else_opt ::= ELSE common_expression */ - 474, /* (537) predicate ::= expr_or_subquery compare_op expr_or_subquery */ - 474, /* (538) predicate ::= expr_or_subquery BETWEEN expr_or_subquery AND expr_or_subquery */ - 474, /* (539) predicate ::= expr_or_subquery NOT BETWEEN expr_or_subquery AND expr_or_subquery */ - 474, /* (540) predicate ::= expr_or_subquery IS NULL */ - 474, /* (541) predicate ::= expr_or_subquery IS NOT NULL */ - 474, /* (542) predicate ::= expr_or_subquery in_op in_predicate_value */ - 475, /* (543) compare_op ::= NK_LT */ - 475, /* (544) compare_op ::= NK_GT */ - 475, /* (545) compare_op ::= NK_LE */ - 475, /* (546) compare_op ::= NK_GE */ - 475, /* (547) compare_op ::= NK_NE */ - 475, /* (548) compare_op ::= NK_EQ */ - 475, /* (549) compare_op ::= LIKE */ - 475, /* (550) compare_op ::= NOT LIKE */ - 475, /* (551) compare_op ::= MATCH */ - 475, /* (552) compare_op ::= NMATCH */ - 475, /* (553) compare_op ::= CONTAINS */ - 476, /* (554) in_op ::= IN */ - 476, /* (555) in_op ::= NOT IN */ - 477, /* (556) in_predicate_value ::= NK_LP literal_list NK_RP */ - 478, /* (557) boolean_value_expression ::= boolean_primary */ - 478, /* (558) boolean_value_expression ::= NOT boolean_primary */ - 478, /* (559) boolean_value_expression ::= boolean_value_expression OR boolean_value_expression */ - 478, /* (560) boolean_value_expression ::= boolean_value_expression AND boolean_value_expression */ - 479, /* (561) boolean_primary ::= predicate */ - 479, /* (562) boolean_primary ::= NK_LP boolean_value_expression NK_RP */ - 472, /* (563) common_expression ::= expr_or_subquery */ - 472, /* (564) common_expression ::= boolean_value_expression */ - 480, /* (565) from_clause_opt ::= */ - 480, /* (566) from_clause_opt ::= FROM table_reference_list */ - 481, /* (567) table_reference_list ::= table_reference */ - 481, /* (568) table_reference_list ::= table_reference_list NK_COMMA table_reference */ - 482, /* (569) table_reference ::= table_primary */ - 482, /* (570) table_reference ::= joined_table */ - 483, /* (571) table_primary ::= table_name alias_opt */ - 483, /* (572) table_primary ::= db_name NK_DOT table_name alias_opt */ - 483, /* (573) table_primary ::= subquery alias_opt */ - 483, /* (574) table_primary ::= parenthesized_joined_table */ - 485, /* (575) alias_opt ::= */ - 485, /* (576) alias_opt ::= table_alias */ - 485, /* (577) alias_opt ::= AS table_alias */ - 487, /* (578) parenthesized_joined_table ::= NK_LP joined_table NK_RP */ - 487, /* (579) parenthesized_joined_table ::= NK_LP parenthesized_joined_table NK_RP */ - 484, /* (580) joined_table ::= table_reference join_type JOIN table_reference ON search_condition */ - 488, /* (581) join_type ::= */ - 488, /* (582) join_type ::= INNER */ - 489, /* (583) 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 */ - 490, /* (584) hint_list ::= */ - 490, /* (585) hint_list ::= NK_HINT */ - 492, /* (586) tag_mode_opt ::= */ - 492, /* (587) tag_mode_opt ::= TAGS */ - 491, /* (588) set_quantifier_opt ::= */ - 491, /* (589) set_quantifier_opt ::= DISTINCT */ - 491, /* (590) set_quantifier_opt ::= ALL */ - 493, /* (591) select_list ::= select_item */ - 493, /* (592) select_list ::= select_list NK_COMMA select_item */ - 501, /* (593) select_item ::= NK_STAR */ - 501, /* (594) select_item ::= common_expression */ - 501, /* (595) select_item ::= common_expression column_alias */ - 501, /* (596) select_item ::= common_expression AS column_alias */ - 501, /* (597) select_item ::= table_name NK_DOT NK_STAR */ - 436, /* (598) where_clause_opt ::= */ - 436, /* (599) where_clause_opt ::= WHERE search_condition */ - 494, /* (600) partition_by_clause_opt ::= */ - 494, /* (601) partition_by_clause_opt ::= PARTITION BY partition_list */ - 502, /* (602) partition_list ::= partition_item */ - 502, /* (603) partition_list ::= partition_list NK_COMMA partition_item */ - 503, /* (604) partition_item ::= expr_or_subquery */ - 503, /* (605) partition_item ::= expr_or_subquery column_alias */ - 503, /* (606) partition_item ::= expr_or_subquery AS column_alias */ - 498, /* (607) twindow_clause_opt ::= */ - 498, /* (608) twindow_clause_opt ::= SESSION NK_LP column_reference NK_COMMA interval_sliding_duration_literal NK_RP */ - 498, /* (609) twindow_clause_opt ::= STATE_WINDOW NK_LP expr_or_subquery NK_RP */ - 498, /* (610) twindow_clause_opt ::= INTERVAL NK_LP interval_sliding_duration_literal NK_RP sliding_opt fill_opt */ - 498, /* (611) twindow_clause_opt ::= INTERVAL NK_LP interval_sliding_duration_literal NK_COMMA interval_sliding_duration_literal NK_RP sliding_opt fill_opt */ - 498, /* (612) twindow_clause_opt ::= EVENT_WINDOW START WITH search_condition END WITH search_condition */ - 498, /* (613) twindow_clause_opt ::= COUNT_WINDOW NK_LP NK_INTEGER NK_RP */ - 498, /* (614) twindow_clause_opt ::= COUNT_WINDOW NK_LP NK_INTEGER NK_COMMA NK_INTEGER NK_RP */ - 429, /* (615) sliding_opt ::= */ - 429, /* (616) sliding_opt ::= SLIDING NK_LP interval_sliding_duration_literal NK_RP */ - 504, /* (617) interval_sliding_duration_literal ::= NK_VARIABLE */ - 504, /* (618) interval_sliding_duration_literal ::= NK_STRING */ - 504, /* (619) interval_sliding_duration_literal ::= NK_INTEGER */ - 497, /* (620) fill_opt ::= */ - 497, /* (621) fill_opt ::= FILL NK_LP fill_mode NK_RP */ - 497, /* (622) fill_opt ::= FILL NK_LP VALUE NK_COMMA expression_list NK_RP */ - 497, /* (623) fill_opt ::= FILL NK_LP VALUE_F NK_COMMA expression_list NK_RP */ - 505, /* (624) fill_mode ::= NONE */ - 505, /* (625) fill_mode ::= PREV */ - 505, /* (626) fill_mode ::= NULL */ - 505, /* (627) fill_mode ::= NULL_F */ - 505, /* (628) fill_mode ::= LINEAR */ - 505, /* (629) fill_mode ::= NEXT */ - 499, /* (630) group_by_clause_opt ::= */ - 499, /* (631) group_by_clause_opt ::= GROUP BY group_by_list */ - 506, /* (632) group_by_list ::= expr_or_subquery */ - 506, /* (633) group_by_list ::= group_by_list NK_COMMA expr_or_subquery */ - 500, /* (634) having_clause_opt ::= */ - 500, /* (635) having_clause_opt ::= HAVING search_condition */ - 495, /* (636) range_opt ::= */ - 495, /* (637) range_opt ::= RANGE NK_LP expr_or_subquery NK_COMMA expr_or_subquery NK_RP */ - 495, /* (638) range_opt ::= RANGE NK_LP expr_or_subquery NK_RP */ - 496, /* (639) every_opt ::= */ - 496, /* (640) every_opt ::= EVERY NK_LP duration_literal NK_RP */ - 507, /* (641) query_expression ::= query_simple order_by_clause_opt slimit_clause_opt limit_clause_opt */ - 508, /* (642) query_simple ::= query_specification */ - 508, /* (643) query_simple ::= union_query_expression */ - 512, /* (644) union_query_expression ::= query_simple_or_subquery UNION ALL query_simple_or_subquery */ - 512, /* (645) union_query_expression ::= query_simple_or_subquery UNION query_simple_or_subquery */ - 513, /* (646) query_simple_or_subquery ::= query_simple */ - 513, /* (647) query_simple_or_subquery ::= subquery */ - 435, /* (648) query_or_subquery ::= query_expression */ - 435, /* (649) query_or_subquery ::= subquery */ - 509, /* (650) order_by_clause_opt ::= */ - 509, /* (651) order_by_clause_opt ::= ORDER BY sort_specification_list */ - 510, /* (652) slimit_clause_opt ::= */ - 510, /* (653) slimit_clause_opt ::= SLIMIT NK_INTEGER */ - 510, /* (654) slimit_clause_opt ::= SLIMIT NK_INTEGER SOFFSET NK_INTEGER */ - 510, /* (655) slimit_clause_opt ::= SLIMIT NK_INTEGER NK_COMMA NK_INTEGER */ - 511, /* (656) limit_clause_opt ::= */ - 511, /* (657) limit_clause_opt ::= LIMIT NK_INTEGER */ - 511, /* (658) limit_clause_opt ::= LIMIT NK_INTEGER OFFSET NK_INTEGER */ - 511, /* (659) limit_clause_opt ::= LIMIT NK_INTEGER NK_COMMA NK_INTEGER */ - 486, /* (660) subquery ::= NK_LP query_expression NK_RP */ - 486, /* (661) subquery ::= NK_LP subquery NK_RP */ - 373, /* (662) search_condition ::= common_expression */ - 514, /* (663) sort_specification_list ::= sort_specification */ - 514, /* (664) sort_specification_list ::= sort_specification_list NK_COMMA sort_specification */ - 515, /* (665) sort_specification ::= expr_or_subquery ordering_specification_opt null_ordering_opt */ - 516, /* (666) ordering_specification_opt ::= */ - 516, /* (667) ordering_specification_opt ::= ASC */ - 516, /* (668) ordering_specification_opt ::= DESC */ - 517, /* (669) null_ordering_opt ::= */ - 517, /* (670) null_ordering_opt ::= NULLS FIRST */ - 517, /* (671) null_ordering_opt ::= NULLS LAST */ + 401, /* (412) tags_literal ::= NK_INTEGER NK_PLUS duration_literal */ + 401, /* (413) tags_literal ::= NK_INTEGER NK_MINUS duration_literal */ + 401, /* (414) tags_literal ::= NK_PLUS NK_INTEGER */ + 401, /* (415) tags_literal ::= NK_PLUS NK_INTEGER NK_PLUS duration_literal */ + 401, /* (416) tags_literal ::= NK_PLUS NK_INTEGER NK_MINUS duration_literal */ + 401, /* (417) tags_literal ::= NK_MINUS NK_INTEGER */ + 401, /* (418) tags_literal ::= NK_MINUS NK_INTEGER NK_PLUS duration_literal */ + 401, /* (419) tags_literal ::= NK_MINUS NK_INTEGER NK_MINUS duration_literal */ + 401, /* (420) tags_literal ::= NK_FLOAT */ + 401, /* (421) tags_literal ::= NK_PLUS NK_FLOAT */ + 401, /* (422) tags_literal ::= NK_MINUS NK_FLOAT */ + 401, /* (423) tags_literal ::= NK_BIN */ + 401, /* (424) tags_literal ::= NK_BIN NK_PLUS duration_literal */ + 401, /* (425) tags_literal ::= NK_BIN NK_MINUS duration_literal */ + 401, /* (426) tags_literal ::= NK_PLUS NK_BIN */ + 401, /* (427) tags_literal ::= NK_PLUS NK_BIN NK_PLUS duration_literal */ + 401, /* (428) tags_literal ::= NK_PLUS NK_BIN NK_MINUS duration_literal */ + 401, /* (429) tags_literal ::= NK_MINUS NK_BIN */ + 401, /* (430) tags_literal ::= NK_MINUS NK_BIN NK_PLUS duration_literal */ + 401, /* (431) tags_literal ::= NK_MINUS NK_BIN NK_MINUS duration_literal */ + 401, /* (432) tags_literal ::= NK_HEX */ + 401, /* (433) tags_literal ::= NK_HEX NK_PLUS duration_literal */ + 401, /* (434) tags_literal ::= NK_HEX NK_MINUS duration_literal */ + 401, /* (435) tags_literal ::= NK_PLUS NK_HEX */ + 401, /* (436) tags_literal ::= NK_PLUS NK_HEX NK_PLUS duration_literal */ + 401, /* (437) tags_literal ::= NK_PLUS NK_HEX NK_MINUS duration_literal */ + 401, /* (438) tags_literal ::= NK_MINUS NK_HEX */ + 401, /* (439) tags_literal ::= NK_MINUS NK_HEX NK_PLUS duration_literal */ + 401, /* (440) tags_literal ::= NK_MINUS NK_HEX NK_MINUS duration_literal */ + 401, /* (441) tags_literal ::= NK_STRING */ + 401, /* (442) tags_literal ::= NK_STRING NK_PLUS duration_literal */ + 401, /* (443) tags_literal ::= NK_STRING NK_MINUS duration_literal */ + 401, /* (444) tags_literal ::= NK_BOOL */ + 401, /* (445) tags_literal ::= NULL */ + 401, /* (446) tags_literal ::= literal_func */ + 401, /* (447) tags_literal ::= literal_func NK_PLUS duration_literal */ + 401, /* (448) tags_literal ::= literal_func NK_MINUS duration_literal */ + 404, /* (449) tags_literal_list ::= tags_literal */ + 404, /* (450) tags_literal_list ::= tags_literal_list NK_COMMA tags_literal */ + 358, /* (451) literal ::= NK_INTEGER */ + 358, /* (452) literal ::= NK_FLOAT */ + 358, /* (453) literal ::= NK_STRING */ + 358, /* (454) literal ::= NK_BOOL */ + 358, /* (455) literal ::= TIMESTAMP NK_STRING */ + 358, /* (456) literal ::= duration_literal */ + 358, /* (457) literal ::= NULL */ + 358, /* (458) literal ::= NK_QUESTION */ + 411, /* (459) duration_literal ::= NK_VARIABLE */ + 387, /* (460) signed ::= NK_INTEGER */ + 387, /* (461) signed ::= NK_PLUS NK_INTEGER */ + 387, /* (462) signed ::= NK_MINUS NK_INTEGER */ + 387, /* (463) signed ::= NK_FLOAT */ + 387, /* (464) signed ::= NK_PLUS NK_FLOAT */ + 387, /* (465) signed ::= NK_MINUS NK_FLOAT */ + 457, /* (466) signed_literal ::= signed */ + 457, /* (467) signed_literal ::= NK_STRING */ + 457, /* (468) signed_literal ::= NK_BOOL */ + 457, /* (469) signed_literal ::= TIMESTAMP NK_STRING */ + 457, /* (470) signed_literal ::= duration_literal */ + 457, /* (471) signed_literal ::= NULL */ + 457, /* (472) signed_literal ::= literal_func */ + 457, /* (473) signed_literal ::= NK_QUESTION */ + 458, /* (474) literal_list ::= signed_literal */ + 458, /* (475) literal_list ::= literal_list NK_COMMA signed_literal */ + 370, /* (476) db_name ::= NK_ID */ + 371, /* (477) table_name ::= NK_ID */ + 399, /* (478) column_name ::= NK_ID */ + 413, /* (479) function_name ::= NK_ID */ + 446, /* (480) view_name ::= NK_ID */ + 459, /* (481) table_alias ::= NK_ID */ + 424, /* (482) column_alias ::= NK_ID */ + 424, /* (483) column_alias ::= NK_ALIAS */ + 363, /* (484) user_name ::= NK_ID */ + 372, /* (485) topic_name ::= NK_ID */ + 447, /* (486) stream_name ::= NK_ID */ + 437, /* (487) cgroup_name ::= NK_ID */ + 427, /* (488) index_name ::= NK_ID */ + 460, /* (489) expr_or_subquery ::= expression */ + 453, /* (490) expression ::= literal */ + 453, /* (491) expression ::= pseudo_column */ + 453, /* (492) expression ::= column_reference */ + 453, /* (493) expression ::= function_expression */ + 453, /* (494) expression ::= case_when_expression */ + 453, /* (495) expression ::= NK_LP expression NK_RP */ + 453, /* (496) expression ::= NK_PLUS expr_or_subquery */ + 453, /* (497) expression ::= NK_MINUS expr_or_subquery */ + 453, /* (498) expression ::= expr_or_subquery NK_PLUS expr_or_subquery */ + 453, /* (499) expression ::= expr_or_subquery NK_MINUS expr_or_subquery */ + 453, /* (500) expression ::= expr_or_subquery NK_STAR expr_or_subquery */ + 453, /* (501) expression ::= expr_or_subquery NK_SLASH expr_or_subquery */ + 453, /* (502) expression ::= expr_or_subquery NK_REM expr_or_subquery */ + 453, /* (503) expression ::= column_reference NK_ARROW NK_STRING */ + 453, /* (504) expression ::= expr_or_subquery NK_BITAND expr_or_subquery */ + 453, /* (505) expression ::= expr_or_subquery NK_BITOR expr_or_subquery */ + 433, /* (506) expression_list ::= expr_or_subquery */ + 433, /* (507) expression_list ::= expression_list NK_COMMA expr_or_subquery */ + 462, /* (508) column_reference ::= column_name */ + 462, /* (509) column_reference ::= table_name NK_DOT column_name */ + 462, /* (510) column_reference ::= NK_ALIAS */ + 462, /* (511) column_reference ::= table_name NK_DOT NK_ALIAS */ + 461, /* (512) pseudo_column ::= ROWTS */ + 461, /* (513) pseudo_column ::= TBNAME */ + 461, /* (514) pseudo_column ::= table_name NK_DOT TBNAME */ + 461, /* (515) pseudo_column ::= QSTART */ + 461, /* (516) pseudo_column ::= QEND */ + 461, /* (517) pseudo_column ::= QDURATION */ + 461, /* (518) pseudo_column ::= WSTART */ + 461, /* (519) pseudo_column ::= WEND */ + 461, /* (520) pseudo_column ::= WDURATION */ + 461, /* (521) pseudo_column ::= IROWTS */ + 461, /* (522) pseudo_column ::= ISFILLED */ + 461, /* (523) pseudo_column ::= QTAGS */ + 463, /* (524) function_expression ::= function_name NK_LP expression_list NK_RP */ + 463, /* (525) function_expression ::= star_func NK_LP star_func_para_list NK_RP */ + 463, /* (526) function_expression ::= CAST NK_LP expr_or_subquery AS type_name NK_RP */ + 463, /* (527) function_expression ::= literal_func */ + 456, /* (528) literal_func ::= noarg_func NK_LP NK_RP */ + 456, /* (529) literal_func ::= NOW */ + 456, /* (530) literal_func ::= TODAY */ + 467, /* (531) noarg_func ::= NOW */ + 467, /* (532) noarg_func ::= TODAY */ + 467, /* (533) noarg_func ::= TIMEZONE */ + 467, /* (534) noarg_func ::= DATABASE */ + 467, /* (535) noarg_func ::= CLIENT_VERSION */ + 467, /* (536) noarg_func ::= SERVER_VERSION */ + 467, /* (537) noarg_func ::= SERVER_STATUS */ + 467, /* (538) noarg_func ::= CURRENT_USER */ + 467, /* (539) noarg_func ::= USER */ + 465, /* (540) star_func ::= COUNT */ + 465, /* (541) star_func ::= FIRST */ + 465, /* (542) star_func ::= LAST */ + 465, /* (543) star_func ::= LAST_ROW */ + 466, /* (544) star_func_para_list ::= NK_STAR */ + 466, /* (545) star_func_para_list ::= other_para_list */ + 468, /* (546) other_para_list ::= star_func_para */ + 468, /* (547) other_para_list ::= other_para_list NK_COMMA star_func_para */ + 469, /* (548) star_func_para ::= expr_or_subquery */ + 469, /* (549) star_func_para ::= table_name NK_DOT NK_STAR */ + 464, /* (550) case_when_expression ::= CASE when_then_list case_when_else_opt END */ + 464, /* (551) case_when_expression ::= CASE common_expression when_then_list case_when_else_opt END */ + 470, /* (552) when_then_list ::= when_then_expr */ + 470, /* (553) when_then_list ::= when_then_list when_then_expr */ + 473, /* (554) when_then_expr ::= WHEN common_expression THEN common_expression */ + 471, /* (555) case_when_else_opt ::= */ + 471, /* (556) case_when_else_opt ::= ELSE common_expression */ + 474, /* (557) predicate ::= expr_or_subquery compare_op expr_or_subquery */ + 474, /* (558) predicate ::= expr_or_subquery BETWEEN expr_or_subquery AND expr_or_subquery */ + 474, /* (559) predicate ::= expr_or_subquery NOT BETWEEN expr_or_subquery AND expr_or_subquery */ + 474, /* (560) predicate ::= expr_or_subquery IS NULL */ + 474, /* (561) predicate ::= expr_or_subquery IS NOT NULL */ + 474, /* (562) predicate ::= expr_or_subquery in_op in_predicate_value */ + 475, /* (563) compare_op ::= NK_LT */ + 475, /* (564) compare_op ::= NK_GT */ + 475, /* (565) compare_op ::= NK_LE */ + 475, /* (566) compare_op ::= NK_GE */ + 475, /* (567) compare_op ::= NK_NE */ + 475, /* (568) compare_op ::= NK_EQ */ + 475, /* (569) compare_op ::= LIKE */ + 475, /* (570) compare_op ::= NOT LIKE */ + 475, /* (571) compare_op ::= MATCH */ + 475, /* (572) compare_op ::= NMATCH */ + 475, /* (573) compare_op ::= CONTAINS */ + 476, /* (574) in_op ::= IN */ + 476, /* (575) in_op ::= NOT IN */ + 477, /* (576) in_predicate_value ::= NK_LP literal_list NK_RP */ + 478, /* (577) boolean_value_expression ::= boolean_primary */ + 478, /* (578) boolean_value_expression ::= NOT boolean_primary */ + 478, /* (579) boolean_value_expression ::= boolean_value_expression OR boolean_value_expression */ + 478, /* (580) boolean_value_expression ::= boolean_value_expression AND boolean_value_expression */ + 479, /* (581) boolean_primary ::= predicate */ + 479, /* (582) boolean_primary ::= NK_LP boolean_value_expression NK_RP */ + 472, /* (583) common_expression ::= expr_or_subquery */ + 472, /* (584) common_expression ::= boolean_value_expression */ + 480, /* (585) from_clause_opt ::= */ + 480, /* (586) from_clause_opt ::= FROM table_reference_list */ + 481, /* (587) table_reference_list ::= table_reference */ + 481, /* (588) table_reference_list ::= table_reference_list NK_COMMA table_reference */ + 482, /* (589) table_reference ::= table_primary */ + 482, /* (590) table_reference ::= joined_table */ + 483, /* (591) table_primary ::= table_name alias_opt */ + 483, /* (592) table_primary ::= db_name NK_DOT table_name alias_opt */ + 483, /* (593) table_primary ::= subquery alias_opt */ + 483, /* (594) table_primary ::= parenthesized_joined_table */ + 485, /* (595) alias_opt ::= */ + 485, /* (596) alias_opt ::= table_alias */ + 485, /* (597) alias_opt ::= AS table_alias */ + 487, /* (598) parenthesized_joined_table ::= NK_LP joined_table NK_RP */ + 487, /* (599) parenthesized_joined_table ::= NK_LP parenthesized_joined_table NK_RP */ + 484, /* (600) joined_table ::= table_reference join_type JOIN table_reference ON search_condition */ + 488, /* (601) join_type ::= */ + 488, /* (602) join_type ::= INNER */ + 489, /* (603) 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 */ + 490, /* (604) hint_list ::= */ + 490, /* (605) hint_list ::= NK_HINT */ + 492, /* (606) tag_mode_opt ::= */ + 492, /* (607) tag_mode_opt ::= TAGS */ + 491, /* (608) set_quantifier_opt ::= */ + 491, /* (609) set_quantifier_opt ::= DISTINCT */ + 491, /* (610) set_quantifier_opt ::= ALL */ + 493, /* (611) select_list ::= select_item */ + 493, /* (612) select_list ::= select_list NK_COMMA select_item */ + 501, /* (613) select_item ::= NK_STAR */ + 501, /* (614) select_item ::= common_expression */ + 501, /* (615) select_item ::= common_expression column_alias */ + 501, /* (616) select_item ::= common_expression AS column_alias */ + 501, /* (617) select_item ::= table_name NK_DOT NK_STAR */ + 436, /* (618) where_clause_opt ::= */ + 436, /* (619) where_clause_opt ::= WHERE search_condition */ + 494, /* (620) partition_by_clause_opt ::= */ + 494, /* (621) partition_by_clause_opt ::= PARTITION BY partition_list */ + 502, /* (622) partition_list ::= partition_item */ + 502, /* (623) partition_list ::= partition_list NK_COMMA partition_item */ + 503, /* (624) partition_item ::= expr_or_subquery */ + 503, /* (625) partition_item ::= expr_or_subquery column_alias */ + 503, /* (626) partition_item ::= expr_or_subquery AS column_alias */ + 498, /* (627) twindow_clause_opt ::= */ + 498, /* (628) twindow_clause_opt ::= SESSION NK_LP column_reference NK_COMMA interval_sliding_duration_literal NK_RP */ + 498, /* (629) twindow_clause_opt ::= STATE_WINDOW NK_LP expr_or_subquery NK_RP */ + 498, /* (630) twindow_clause_opt ::= INTERVAL NK_LP interval_sliding_duration_literal NK_RP sliding_opt fill_opt */ + 498, /* (631) twindow_clause_opt ::= INTERVAL NK_LP interval_sliding_duration_literal NK_COMMA interval_sliding_duration_literal NK_RP sliding_opt fill_opt */ + 498, /* (632) twindow_clause_opt ::= EVENT_WINDOW START WITH search_condition END WITH search_condition */ + 498, /* (633) twindow_clause_opt ::= COUNT_WINDOW NK_LP NK_INTEGER NK_RP */ + 498, /* (634) twindow_clause_opt ::= COUNT_WINDOW NK_LP NK_INTEGER NK_COMMA NK_INTEGER NK_RP */ + 429, /* (635) sliding_opt ::= */ + 429, /* (636) sliding_opt ::= SLIDING NK_LP interval_sliding_duration_literal NK_RP */ + 504, /* (637) interval_sliding_duration_literal ::= NK_VARIABLE */ + 504, /* (638) interval_sliding_duration_literal ::= NK_STRING */ + 504, /* (639) interval_sliding_duration_literal ::= NK_INTEGER */ + 497, /* (640) fill_opt ::= */ + 497, /* (641) fill_opt ::= FILL NK_LP fill_mode NK_RP */ + 497, /* (642) fill_opt ::= FILL NK_LP VALUE NK_COMMA expression_list NK_RP */ + 497, /* (643) fill_opt ::= FILL NK_LP VALUE_F NK_COMMA expression_list NK_RP */ + 505, /* (644) fill_mode ::= NONE */ + 505, /* (645) fill_mode ::= PREV */ + 505, /* (646) fill_mode ::= NULL */ + 505, /* (647) fill_mode ::= NULL_F */ + 505, /* (648) fill_mode ::= LINEAR */ + 505, /* (649) fill_mode ::= NEXT */ + 499, /* (650) group_by_clause_opt ::= */ + 499, /* (651) group_by_clause_opt ::= GROUP BY group_by_list */ + 506, /* (652) group_by_list ::= expr_or_subquery */ + 506, /* (653) group_by_list ::= group_by_list NK_COMMA expr_or_subquery */ + 500, /* (654) having_clause_opt ::= */ + 500, /* (655) having_clause_opt ::= HAVING search_condition */ + 495, /* (656) range_opt ::= */ + 495, /* (657) range_opt ::= RANGE NK_LP expr_or_subquery NK_COMMA expr_or_subquery NK_RP */ + 495, /* (658) range_opt ::= RANGE NK_LP expr_or_subquery NK_RP */ + 496, /* (659) every_opt ::= */ + 496, /* (660) every_opt ::= EVERY NK_LP duration_literal NK_RP */ + 507, /* (661) query_expression ::= query_simple order_by_clause_opt slimit_clause_opt limit_clause_opt */ + 508, /* (662) query_simple ::= query_specification */ + 508, /* (663) query_simple ::= union_query_expression */ + 512, /* (664) union_query_expression ::= query_simple_or_subquery UNION ALL query_simple_or_subquery */ + 512, /* (665) union_query_expression ::= query_simple_or_subquery UNION query_simple_or_subquery */ + 513, /* (666) query_simple_or_subquery ::= query_simple */ + 513, /* (667) query_simple_or_subquery ::= subquery */ + 435, /* (668) query_or_subquery ::= query_expression */ + 435, /* (669) query_or_subquery ::= subquery */ + 509, /* (670) order_by_clause_opt ::= */ + 509, /* (671) order_by_clause_opt ::= ORDER BY sort_specification_list */ + 510, /* (672) slimit_clause_opt ::= */ + 510, /* (673) slimit_clause_opt ::= SLIMIT NK_INTEGER */ + 510, /* (674) slimit_clause_opt ::= SLIMIT NK_INTEGER SOFFSET NK_INTEGER */ + 510, /* (675) slimit_clause_opt ::= SLIMIT NK_INTEGER NK_COMMA NK_INTEGER */ + 511, /* (676) limit_clause_opt ::= */ + 511, /* (677) limit_clause_opt ::= LIMIT NK_INTEGER */ + 511, /* (678) limit_clause_opt ::= LIMIT NK_INTEGER OFFSET NK_INTEGER */ + 511, /* (679) limit_clause_opt ::= LIMIT NK_INTEGER NK_COMMA NK_INTEGER */ + 486, /* (680) subquery ::= NK_LP query_expression NK_RP */ + 486, /* (681) subquery ::= NK_LP subquery NK_RP */ + 373, /* (682) search_condition ::= common_expression */ + 514, /* (683) sort_specification_list ::= sort_specification */ + 514, /* (684) sort_specification_list ::= sort_specification_list NK_COMMA sort_specification */ + 515, /* (685) sort_specification ::= expr_or_subquery ordering_specification_opt null_ordering_opt */ + 516, /* (686) ordering_specification_opt ::= */ + 516, /* (687) ordering_specification_opt ::= ASC */ + 516, /* (688) ordering_specification_opt ::= DESC */ + 517, /* (689) null_ordering_opt ::= */ + 517, /* (690) null_ordering_opt ::= NULLS FIRST */ + 517, /* (691) null_ordering_opt ::= NULLS LAST */ }; /* For rule J, yyRuleInfoNRhs[J] contains the negative of the number @@ -4504,266 +4552,286 @@ static const signed char yyRuleInfoNRhs[] = { -7, /* (409) insert_query ::= INSERT INTO full_table_name NK_LP col_name_list NK_RP query_or_subquery */ -4, /* (410) insert_query ::= INSERT INTO full_table_name query_or_subquery */ -1, /* (411) tags_literal ::= NK_INTEGER */ - -2, /* (412) tags_literal ::= NK_PLUS NK_INTEGER */ - -2, /* (413) tags_literal ::= NK_MINUS NK_INTEGER */ - -1, /* (414) tags_literal ::= NK_FLOAT */ - -2, /* (415) tags_literal ::= NK_PLUS NK_FLOAT */ - -2, /* (416) tags_literal ::= NK_MINUS NK_FLOAT */ - -1, /* (417) tags_literal ::= NK_BIN */ - -2, /* (418) tags_literal ::= NK_PLUS NK_BIN */ - -2, /* (419) tags_literal ::= NK_MINUS NK_BIN */ - -1, /* (420) tags_literal ::= NK_HEX */ - -2, /* (421) tags_literal ::= NK_PLUS NK_HEX */ - -2, /* (422) tags_literal ::= NK_MINUS NK_HEX */ - -1, /* (423) tags_literal ::= NK_STRING */ - -1, /* (424) tags_literal ::= NK_BOOL */ - -1, /* (425) tags_literal ::= NULL */ - -1, /* (426) tags_literal ::= literal_func */ - -3, /* (427) tags_literal ::= literal_func NK_PLUS duration_literal */ - -3, /* (428) tags_literal ::= literal_func NK_MINUS duration_literal */ - -1, /* (429) tags_literal_list ::= tags_literal */ - -3, /* (430) tags_literal_list ::= tags_literal_list NK_COMMA tags_literal */ - -1, /* (431) literal ::= NK_INTEGER */ - -1, /* (432) literal ::= NK_FLOAT */ - -1, /* (433) literal ::= NK_STRING */ - -1, /* (434) literal ::= NK_BOOL */ - -2, /* (435) literal ::= TIMESTAMP NK_STRING */ - -1, /* (436) literal ::= duration_literal */ - -1, /* (437) literal ::= NULL */ - -1, /* (438) literal ::= NK_QUESTION */ - -1, /* (439) duration_literal ::= NK_VARIABLE */ - -1, /* (440) signed ::= NK_INTEGER */ - -2, /* (441) signed ::= NK_PLUS NK_INTEGER */ - -2, /* (442) signed ::= NK_MINUS NK_INTEGER */ - -1, /* (443) signed ::= NK_FLOAT */ - -2, /* (444) signed ::= NK_PLUS NK_FLOAT */ - -2, /* (445) signed ::= NK_MINUS NK_FLOAT */ - -1, /* (446) signed_literal ::= signed */ - -1, /* (447) signed_literal ::= NK_STRING */ - -1, /* (448) signed_literal ::= NK_BOOL */ - -2, /* (449) signed_literal ::= TIMESTAMP NK_STRING */ - -1, /* (450) signed_literal ::= duration_literal */ - -1, /* (451) signed_literal ::= NULL */ - -1, /* (452) signed_literal ::= literal_func */ - -1, /* (453) signed_literal ::= NK_QUESTION */ - -1, /* (454) literal_list ::= signed_literal */ - -3, /* (455) literal_list ::= literal_list NK_COMMA signed_literal */ - -1, /* (456) db_name ::= NK_ID */ - -1, /* (457) table_name ::= NK_ID */ - -1, /* (458) column_name ::= NK_ID */ - -1, /* (459) function_name ::= NK_ID */ - -1, /* (460) view_name ::= NK_ID */ - -1, /* (461) table_alias ::= NK_ID */ - -1, /* (462) column_alias ::= NK_ID */ - -1, /* (463) column_alias ::= NK_ALIAS */ - -1, /* (464) user_name ::= NK_ID */ - -1, /* (465) topic_name ::= NK_ID */ - -1, /* (466) stream_name ::= NK_ID */ - -1, /* (467) cgroup_name ::= NK_ID */ - -1, /* (468) index_name ::= NK_ID */ - -1, /* (469) expr_or_subquery ::= expression */ - -1, /* (470) expression ::= literal */ - -1, /* (471) expression ::= pseudo_column */ - -1, /* (472) expression ::= column_reference */ - -1, /* (473) expression ::= function_expression */ - -1, /* (474) expression ::= case_when_expression */ - -3, /* (475) expression ::= NK_LP expression NK_RP */ - -2, /* (476) expression ::= NK_PLUS expr_or_subquery */ - -2, /* (477) expression ::= NK_MINUS expr_or_subquery */ - -3, /* (478) expression ::= expr_or_subquery NK_PLUS expr_or_subquery */ - -3, /* (479) expression ::= expr_or_subquery NK_MINUS expr_or_subquery */ - -3, /* (480) expression ::= expr_or_subquery NK_STAR expr_or_subquery */ - -3, /* (481) expression ::= expr_or_subquery NK_SLASH expr_or_subquery */ - -3, /* (482) expression ::= expr_or_subquery NK_REM expr_or_subquery */ - -3, /* (483) expression ::= column_reference NK_ARROW NK_STRING */ - -3, /* (484) expression ::= expr_or_subquery NK_BITAND expr_or_subquery */ - -3, /* (485) expression ::= expr_or_subquery NK_BITOR expr_or_subquery */ - -1, /* (486) expression_list ::= expr_or_subquery */ - -3, /* (487) expression_list ::= expression_list NK_COMMA expr_or_subquery */ - -1, /* (488) column_reference ::= column_name */ - -3, /* (489) column_reference ::= table_name NK_DOT column_name */ - -1, /* (490) column_reference ::= NK_ALIAS */ - -3, /* (491) column_reference ::= table_name NK_DOT NK_ALIAS */ - -1, /* (492) pseudo_column ::= ROWTS */ - -1, /* (493) pseudo_column ::= TBNAME */ - -3, /* (494) pseudo_column ::= table_name NK_DOT TBNAME */ - -1, /* (495) pseudo_column ::= QSTART */ - -1, /* (496) pseudo_column ::= QEND */ - -1, /* (497) pseudo_column ::= QDURATION */ - -1, /* (498) pseudo_column ::= WSTART */ - -1, /* (499) pseudo_column ::= WEND */ - -1, /* (500) pseudo_column ::= WDURATION */ - -1, /* (501) pseudo_column ::= IROWTS */ - -1, /* (502) pseudo_column ::= ISFILLED */ - -1, /* (503) pseudo_column ::= QTAGS */ - -4, /* (504) function_expression ::= function_name NK_LP expression_list NK_RP */ - -4, /* (505) function_expression ::= star_func NK_LP star_func_para_list NK_RP */ - -6, /* (506) function_expression ::= CAST NK_LP expr_or_subquery AS type_name NK_RP */ - -1, /* (507) function_expression ::= literal_func */ - -3, /* (508) literal_func ::= noarg_func NK_LP NK_RP */ - -1, /* (509) literal_func ::= NOW */ - -1, /* (510) literal_func ::= TODAY */ - -1, /* (511) noarg_func ::= NOW */ - -1, /* (512) noarg_func ::= TODAY */ - -1, /* (513) noarg_func ::= TIMEZONE */ - -1, /* (514) noarg_func ::= DATABASE */ - -1, /* (515) noarg_func ::= CLIENT_VERSION */ - -1, /* (516) noarg_func ::= SERVER_VERSION */ - -1, /* (517) noarg_func ::= SERVER_STATUS */ - -1, /* (518) noarg_func ::= CURRENT_USER */ - -1, /* (519) noarg_func ::= USER */ - -1, /* (520) star_func ::= COUNT */ - -1, /* (521) star_func ::= FIRST */ - -1, /* (522) star_func ::= LAST */ - -1, /* (523) star_func ::= LAST_ROW */ - -1, /* (524) star_func_para_list ::= NK_STAR */ - -1, /* (525) star_func_para_list ::= other_para_list */ - -1, /* (526) other_para_list ::= star_func_para */ - -3, /* (527) other_para_list ::= other_para_list NK_COMMA star_func_para */ - -1, /* (528) star_func_para ::= expr_or_subquery */ - -3, /* (529) star_func_para ::= table_name NK_DOT NK_STAR */ - -4, /* (530) case_when_expression ::= CASE when_then_list case_when_else_opt END */ - -5, /* (531) case_when_expression ::= CASE common_expression when_then_list case_when_else_opt END */ - -1, /* (532) when_then_list ::= when_then_expr */ - -2, /* (533) when_then_list ::= when_then_list when_then_expr */ - -4, /* (534) when_then_expr ::= WHEN common_expression THEN common_expression */ - 0, /* (535) case_when_else_opt ::= */ - -2, /* (536) case_when_else_opt ::= ELSE common_expression */ - -3, /* (537) predicate ::= expr_or_subquery compare_op expr_or_subquery */ - -5, /* (538) predicate ::= expr_or_subquery BETWEEN expr_or_subquery AND expr_or_subquery */ - -6, /* (539) predicate ::= expr_or_subquery NOT BETWEEN expr_or_subquery AND expr_or_subquery */ - -3, /* (540) predicate ::= expr_or_subquery IS NULL */ - -4, /* (541) predicate ::= expr_or_subquery IS NOT NULL */ - -3, /* (542) predicate ::= expr_or_subquery in_op in_predicate_value */ - -1, /* (543) compare_op ::= NK_LT */ - -1, /* (544) compare_op ::= NK_GT */ - -1, /* (545) compare_op ::= NK_LE */ - -1, /* (546) compare_op ::= NK_GE */ - -1, /* (547) compare_op ::= NK_NE */ - -1, /* (548) compare_op ::= NK_EQ */ - -1, /* (549) compare_op ::= LIKE */ - -2, /* (550) compare_op ::= NOT LIKE */ - -1, /* (551) compare_op ::= MATCH */ - -1, /* (552) compare_op ::= NMATCH */ - -1, /* (553) compare_op ::= CONTAINS */ - -1, /* (554) in_op ::= IN */ - -2, /* (555) in_op ::= NOT IN */ - -3, /* (556) in_predicate_value ::= NK_LP literal_list NK_RP */ - -1, /* (557) boolean_value_expression ::= boolean_primary */ - -2, /* (558) boolean_value_expression ::= NOT boolean_primary */ - -3, /* (559) boolean_value_expression ::= boolean_value_expression OR boolean_value_expression */ - -3, /* (560) boolean_value_expression ::= boolean_value_expression AND boolean_value_expression */ - -1, /* (561) boolean_primary ::= predicate */ - -3, /* (562) boolean_primary ::= NK_LP boolean_value_expression NK_RP */ - -1, /* (563) common_expression ::= expr_or_subquery */ - -1, /* (564) common_expression ::= boolean_value_expression */ - 0, /* (565) from_clause_opt ::= */ - -2, /* (566) from_clause_opt ::= FROM table_reference_list */ - -1, /* (567) table_reference_list ::= table_reference */ - -3, /* (568) table_reference_list ::= table_reference_list NK_COMMA table_reference */ - -1, /* (569) table_reference ::= table_primary */ - -1, /* (570) table_reference ::= joined_table */ - -2, /* (571) table_primary ::= table_name alias_opt */ - -4, /* (572) table_primary ::= db_name NK_DOT table_name alias_opt */ - -2, /* (573) table_primary ::= subquery alias_opt */ - -1, /* (574) table_primary ::= parenthesized_joined_table */ - 0, /* (575) alias_opt ::= */ - -1, /* (576) alias_opt ::= table_alias */ - -2, /* (577) alias_opt ::= AS table_alias */ - -3, /* (578) parenthesized_joined_table ::= NK_LP joined_table NK_RP */ - -3, /* (579) parenthesized_joined_table ::= NK_LP parenthesized_joined_table NK_RP */ - -6, /* (580) joined_table ::= table_reference join_type JOIN table_reference ON search_condition */ - 0, /* (581) join_type ::= */ - -1, /* (582) join_type ::= INNER */ - -14, /* (583) 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, /* (584) hint_list ::= */ - -1, /* (585) hint_list ::= NK_HINT */ - 0, /* (586) tag_mode_opt ::= */ - -1, /* (587) tag_mode_opt ::= TAGS */ - 0, /* (588) set_quantifier_opt ::= */ - -1, /* (589) set_quantifier_opt ::= DISTINCT */ - -1, /* (590) set_quantifier_opt ::= ALL */ - -1, /* (591) select_list ::= select_item */ - -3, /* (592) select_list ::= select_list NK_COMMA select_item */ - -1, /* (593) select_item ::= NK_STAR */ - -1, /* (594) select_item ::= common_expression */ - -2, /* (595) select_item ::= common_expression column_alias */ - -3, /* (596) select_item ::= common_expression AS column_alias */ - -3, /* (597) select_item ::= table_name NK_DOT NK_STAR */ - 0, /* (598) where_clause_opt ::= */ - -2, /* (599) where_clause_opt ::= WHERE search_condition */ - 0, /* (600) partition_by_clause_opt ::= */ - -3, /* (601) partition_by_clause_opt ::= PARTITION BY partition_list */ - -1, /* (602) partition_list ::= partition_item */ - -3, /* (603) partition_list ::= partition_list NK_COMMA partition_item */ - -1, /* (604) partition_item ::= expr_or_subquery */ - -2, /* (605) partition_item ::= expr_or_subquery column_alias */ - -3, /* (606) partition_item ::= expr_or_subquery AS column_alias */ - 0, /* (607) twindow_clause_opt ::= */ - -6, /* (608) twindow_clause_opt ::= SESSION NK_LP column_reference NK_COMMA interval_sliding_duration_literal NK_RP */ - -4, /* (609) twindow_clause_opt ::= STATE_WINDOW NK_LP expr_or_subquery NK_RP */ - -6, /* (610) twindow_clause_opt ::= INTERVAL NK_LP interval_sliding_duration_literal NK_RP sliding_opt fill_opt */ - -8, /* (611) twindow_clause_opt ::= INTERVAL NK_LP interval_sliding_duration_literal NK_COMMA interval_sliding_duration_literal NK_RP sliding_opt fill_opt */ - -7, /* (612) twindow_clause_opt ::= EVENT_WINDOW START WITH search_condition END WITH search_condition */ - -4, /* (613) twindow_clause_opt ::= COUNT_WINDOW NK_LP NK_INTEGER NK_RP */ - -6, /* (614) twindow_clause_opt ::= COUNT_WINDOW NK_LP NK_INTEGER NK_COMMA NK_INTEGER NK_RP */ - 0, /* (615) sliding_opt ::= */ - -4, /* (616) sliding_opt ::= SLIDING NK_LP interval_sliding_duration_literal NK_RP */ - -1, /* (617) interval_sliding_duration_literal ::= NK_VARIABLE */ - -1, /* (618) interval_sliding_duration_literal ::= NK_STRING */ - -1, /* (619) interval_sliding_duration_literal ::= NK_INTEGER */ - 0, /* (620) fill_opt ::= */ - -4, /* (621) fill_opt ::= FILL NK_LP fill_mode NK_RP */ - -6, /* (622) fill_opt ::= FILL NK_LP VALUE NK_COMMA expression_list NK_RP */ - -6, /* (623) fill_opt ::= FILL NK_LP VALUE_F NK_COMMA expression_list NK_RP */ - -1, /* (624) fill_mode ::= NONE */ - -1, /* (625) fill_mode ::= PREV */ - -1, /* (626) fill_mode ::= NULL */ - -1, /* (627) fill_mode ::= NULL_F */ - -1, /* (628) fill_mode ::= LINEAR */ - -1, /* (629) fill_mode ::= NEXT */ - 0, /* (630) group_by_clause_opt ::= */ - -3, /* (631) group_by_clause_opt ::= GROUP BY group_by_list */ - -1, /* (632) group_by_list ::= expr_or_subquery */ - -3, /* (633) group_by_list ::= group_by_list NK_COMMA expr_or_subquery */ - 0, /* (634) having_clause_opt ::= */ - -2, /* (635) having_clause_opt ::= HAVING search_condition */ - 0, /* (636) range_opt ::= */ - -6, /* (637) range_opt ::= RANGE NK_LP expr_or_subquery NK_COMMA expr_or_subquery NK_RP */ - -4, /* (638) range_opt ::= RANGE NK_LP expr_or_subquery NK_RP */ - 0, /* (639) every_opt ::= */ - -4, /* (640) every_opt ::= EVERY NK_LP duration_literal NK_RP */ - -4, /* (641) query_expression ::= query_simple order_by_clause_opt slimit_clause_opt limit_clause_opt */ - -1, /* (642) query_simple ::= query_specification */ - -1, /* (643) query_simple ::= union_query_expression */ - -4, /* (644) union_query_expression ::= query_simple_or_subquery UNION ALL query_simple_or_subquery */ - -3, /* (645) union_query_expression ::= query_simple_or_subquery UNION query_simple_or_subquery */ - -1, /* (646) query_simple_or_subquery ::= query_simple */ - -1, /* (647) query_simple_or_subquery ::= subquery */ - -1, /* (648) query_or_subquery ::= query_expression */ - -1, /* (649) query_or_subquery ::= subquery */ - 0, /* (650) order_by_clause_opt ::= */ - -3, /* (651) order_by_clause_opt ::= ORDER BY sort_specification_list */ - 0, /* (652) slimit_clause_opt ::= */ - -2, /* (653) slimit_clause_opt ::= SLIMIT NK_INTEGER */ - -4, /* (654) slimit_clause_opt ::= SLIMIT NK_INTEGER SOFFSET NK_INTEGER */ - -4, /* (655) slimit_clause_opt ::= SLIMIT NK_INTEGER NK_COMMA NK_INTEGER */ - 0, /* (656) limit_clause_opt ::= */ - -2, /* (657) limit_clause_opt ::= LIMIT NK_INTEGER */ - -4, /* (658) limit_clause_opt ::= LIMIT NK_INTEGER OFFSET NK_INTEGER */ - -4, /* (659) limit_clause_opt ::= LIMIT NK_INTEGER NK_COMMA NK_INTEGER */ - -3, /* (660) subquery ::= NK_LP query_expression NK_RP */ - -3, /* (661) subquery ::= NK_LP subquery NK_RP */ - -1, /* (662) search_condition ::= common_expression */ - -1, /* (663) sort_specification_list ::= sort_specification */ - -3, /* (664) sort_specification_list ::= sort_specification_list NK_COMMA sort_specification */ - -3, /* (665) sort_specification ::= expr_or_subquery ordering_specification_opt null_ordering_opt */ - 0, /* (666) ordering_specification_opt ::= */ - -1, /* (667) ordering_specification_opt ::= ASC */ - -1, /* (668) ordering_specification_opt ::= DESC */ - 0, /* (669) null_ordering_opt ::= */ - -2, /* (670) null_ordering_opt ::= NULLS FIRST */ - -2, /* (671) null_ordering_opt ::= NULLS LAST */ + -3, /* (412) tags_literal ::= NK_INTEGER NK_PLUS duration_literal */ + -3, /* (413) tags_literal ::= NK_INTEGER NK_MINUS duration_literal */ + -2, /* (414) tags_literal ::= NK_PLUS NK_INTEGER */ + -4, /* (415) tags_literal ::= NK_PLUS NK_INTEGER NK_PLUS duration_literal */ + -4, /* (416) tags_literal ::= NK_PLUS NK_INTEGER NK_MINUS duration_literal */ + -2, /* (417) tags_literal ::= NK_MINUS NK_INTEGER */ + -4, /* (418) tags_literal ::= NK_MINUS NK_INTEGER NK_PLUS duration_literal */ + -4, /* (419) tags_literal ::= NK_MINUS NK_INTEGER NK_MINUS duration_literal */ + -1, /* (420) tags_literal ::= NK_FLOAT */ + -2, /* (421) tags_literal ::= NK_PLUS NK_FLOAT */ + -2, /* (422) tags_literal ::= NK_MINUS NK_FLOAT */ + -1, /* (423) tags_literal ::= NK_BIN */ + -3, /* (424) tags_literal ::= NK_BIN NK_PLUS duration_literal */ + -3, /* (425) tags_literal ::= NK_BIN NK_MINUS duration_literal */ + -2, /* (426) tags_literal ::= NK_PLUS NK_BIN */ + -4, /* (427) tags_literal ::= NK_PLUS NK_BIN NK_PLUS duration_literal */ + -4, /* (428) tags_literal ::= NK_PLUS NK_BIN NK_MINUS duration_literal */ + -2, /* (429) tags_literal ::= NK_MINUS NK_BIN */ + -4, /* (430) tags_literal ::= NK_MINUS NK_BIN NK_PLUS duration_literal */ + -4, /* (431) tags_literal ::= NK_MINUS NK_BIN NK_MINUS duration_literal */ + -1, /* (432) tags_literal ::= NK_HEX */ + -3, /* (433) tags_literal ::= NK_HEX NK_PLUS duration_literal */ + -3, /* (434) tags_literal ::= NK_HEX NK_MINUS duration_literal */ + -2, /* (435) tags_literal ::= NK_PLUS NK_HEX */ + -4, /* (436) tags_literal ::= NK_PLUS NK_HEX NK_PLUS duration_literal */ + -4, /* (437) tags_literal ::= NK_PLUS NK_HEX NK_MINUS duration_literal */ + -2, /* (438) tags_literal ::= NK_MINUS NK_HEX */ + -4, /* (439) tags_literal ::= NK_MINUS NK_HEX NK_PLUS duration_literal */ + -4, /* (440) tags_literal ::= NK_MINUS NK_HEX NK_MINUS duration_literal */ + -1, /* (441) tags_literal ::= NK_STRING */ + -3, /* (442) tags_literal ::= NK_STRING NK_PLUS duration_literal */ + -3, /* (443) tags_literal ::= NK_STRING NK_MINUS duration_literal */ + -1, /* (444) tags_literal ::= NK_BOOL */ + -1, /* (445) tags_literal ::= NULL */ + -1, /* (446) tags_literal ::= literal_func */ + -3, /* (447) tags_literal ::= literal_func NK_PLUS duration_literal */ + -3, /* (448) tags_literal ::= literal_func NK_MINUS duration_literal */ + -1, /* (449) tags_literal_list ::= tags_literal */ + -3, /* (450) tags_literal_list ::= tags_literal_list NK_COMMA tags_literal */ + -1, /* (451) literal ::= NK_INTEGER */ + -1, /* (452) literal ::= NK_FLOAT */ + -1, /* (453) literal ::= NK_STRING */ + -1, /* (454) literal ::= NK_BOOL */ + -2, /* (455) literal ::= TIMESTAMP NK_STRING */ + -1, /* (456) literal ::= duration_literal */ + -1, /* (457) literal ::= NULL */ + -1, /* (458) literal ::= NK_QUESTION */ + -1, /* (459) duration_literal ::= NK_VARIABLE */ + -1, /* (460) signed ::= NK_INTEGER */ + -2, /* (461) signed ::= NK_PLUS NK_INTEGER */ + -2, /* (462) signed ::= NK_MINUS NK_INTEGER */ + -1, /* (463) signed ::= NK_FLOAT */ + -2, /* (464) signed ::= NK_PLUS NK_FLOAT */ + -2, /* (465) signed ::= NK_MINUS NK_FLOAT */ + -1, /* (466) signed_literal ::= signed */ + -1, /* (467) signed_literal ::= NK_STRING */ + -1, /* (468) signed_literal ::= NK_BOOL */ + -2, /* (469) signed_literal ::= TIMESTAMP NK_STRING */ + -1, /* (470) signed_literal ::= duration_literal */ + -1, /* (471) signed_literal ::= NULL */ + -1, /* (472) signed_literal ::= literal_func */ + -1, /* (473) signed_literal ::= NK_QUESTION */ + -1, /* (474) literal_list ::= signed_literal */ + -3, /* (475) literal_list ::= literal_list NK_COMMA signed_literal */ + -1, /* (476) db_name ::= NK_ID */ + -1, /* (477) table_name ::= NK_ID */ + -1, /* (478) column_name ::= NK_ID */ + -1, /* (479) function_name ::= NK_ID */ + -1, /* (480) view_name ::= NK_ID */ + -1, /* (481) table_alias ::= NK_ID */ + -1, /* (482) column_alias ::= NK_ID */ + -1, /* (483) column_alias ::= NK_ALIAS */ + -1, /* (484) user_name ::= NK_ID */ + -1, /* (485) topic_name ::= NK_ID */ + -1, /* (486) stream_name ::= NK_ID */ + -1, /* (487) cgroup_name ::= NK_ID */ + -1, /* (488) index_name ::= NK_ID */ + -1, /* (489) expr_or_subquery ::= expression */ + -1, /* (490) expression ::= literal */ + -1, /* (491) expression ::= pseudo_column */ + -1, /* (492) expression ::= column_reference */ + -1, /* (493) expression ::= function_expression */ + -1, /* (494) expression ::= case_when_expression */ + -3, /* (495) expression ::= NK_LP expression NK_RP */ + -2, /* (496) expression ::= NK_PLUS expr_or_subquery */ + -2, /* (497) expression ::= NK_MINUS expr_or_subquery */ + -3, /* (498) expression ::= expr_or_subquery NK_PLUS expr_or_subquery */ + -3, /* (499) expression ::= expr_or_subquery NK_MINUS expr_or_subquery */ + -3, /* (500) expression ::= expr_or_subquery NK_STAR expr_or_subquery */ + -3, /* (501) expression ::= expr_or_subquery NK_SLASH expr_or_subquery */ + -3, /* (502) expression ::= expr_or_subquery NK_REM expr_or_subquery */ + -3, /* (503) expression ::= column_reference NK_ARROW NK_STRING */ + -3, /* (504) expression ::= expr_or_subquery NK_BITAND expr_or_subquery */ + -3, /* (505) expression ::= expr_or_subquery NK_BITOR expr_or_subquery */ + -1, /* (506) expression_list ::= expr_or_subquery */ + -3, /* (507) expression_list ::= expression_list NK_COMMA expr_or_subquery */ + -1, /* (508) column_reference ::= column_name */ + -3, /* (509) column_reference ::= table_name NK_DOT column_name */ + -1, /* (510) column_reference ::= NK_ALIAS */ + -3, /* (511) column_reference ::= table_name NK_DOT NK_ALIAS */ + -1, /* (512) pseudo_column ::= ROWTS */ + -1, /* (513) pseudo_column ::= TBNAME */ + -3, /* (514) pseudo_column ::= table_name NK_DOT TBNAME */ + -1, /* (515) pseudo_column ::= QSTART */ + -1, /* (516) pseudo_column ::= QEND */ + -1, /* (517) pseudo_column ::= QDURATION */ + -1, /* (518) pseudo_column ::= WSTART */ + -1, /* (519) pseudo_column ::= WEND */ + -1, /* (520) pseudo_column ::= WDURATION */ + -1, /* (521) pseudo_column ::= IROWTS */ + -1, /* (522) pseudo_column ::= ISFILLED */ + -1, /* (523) pseudo_column ::= QTAGS */ + -4, /* (524) function_expression ::= function_name NK_LP expression_list NK_RP */ + -4, /* (525) function_expression ::= star_func NK_LP star_func_para_list NK_RP */ + -6, /* (526) function_expression ::= CAST NK_LP expr_or_subquery AS type_name NK_RP */ + -1, /* (527) function_expression ::= literal_func */ + -3, /* (528) literal_func ::= noarg_func NK_LP NK_RP */ + -1, /* (529) literal_func ::= NOW */ + -1, /* (530) literal_func ::= TODAY */ + -1, /* (531) noarg_func ::= NOW */ + -1, /* (532) noarg_func ::= TODAY */ + -1, /* (533) noarg_func ::= TIMEZONE */ + -1, /* (534) noarg_func ::= DATABASE */ + -1, /* (535) noarg_func ::= CLIENT_VERSION */ + -1, /* (536) noarg_func ::= SERVER_VERSION */ + -1, /* (537) noarg_func ::= SERVER_STATUS */ + -1, /* (538) noarg_func ::= CURRENT_USER */ + -1, /* (539) noarg_func ::= USER */ + -1, /* (540) star_func ::= COUNT */ + -1, /* (541) star_func ::= FIRST */ + -1, /* (542) star_func ::= LAST */ + -1, /* (543) star_func ::= LAST_ROW */ + -1, /* (544) star_func_para_list ::= NK_STAR */ + -1, /* (545) star_func_para_list ::= other_para_list */ + -1, /* (546) other_para_list ::= star_func_para */ + -3, /* (547) other_para_list ::= other_para_list NK_COMMA star_func_para */ + -1, /* (548) star_func_para ::= expr_or_subquery */ + -3, /* (549) star_func_para ::= table_name NK_DOT NK_STAR */ + -4, /* (550) case_when_expression ::= CASE when_then_list case_when_else_opt END */ + -5, /* (551) case_when_expression ::= CASE common_expression when_then_list case_when_else_opt END */ + -1, /* (552) when_then_list ::= when_then_expr */ + -2, /* (553) when_then_list ::= when_then_list when_then_expr */ + -4, /* (554) when_then_expr ::= WHEN common_expression THEN common_expression */ + 0, /* (555) case_when_else_opt ::= */ + -2, /* (556) case_when_else_opt ::= ELSE common_expression */ + -3, /* (557) predicate ::= expr_or_subquery compare_op expr_or_subquery */ + -5, /* (558) predicate ::= expr_or_subquery BETWEEN expr_or_subquery AND expr_or_subquery */ + -6, /* (559) predicate ::= expr_or_subquery NOT BETWEEN expr_or_subquery AND expr_or_subquery */ + -3, /* (560) predicate ::= expr_or_subquery IS NULL */ + -4, /* (561) predicate ::= expr_or_subquery IS NOT NULL */ + -3, /* (562) predicate ::= expr_or_subquery in_op in_predicate_value */ + -1, /* (563) compare_op ::= NK_LT */ + -1, /* (564) compare_op ::= NK_GT */ + -1, /* (565) compare_op ::= NK_LE */ + -1, /* (566) compare_op ::= NK_GE */ + -1, /* (567) compare_op ::= NK_NE */ + -1, /* (568) compare_op ::= NK_EQ */ + -1, /* (569) compare_op ::= LIKE */ + -2, /* (570) compare_op ::= NOT LIKE */ + -1, /* (571) compare_op ::= MATCH */ + -1, /* (572) compare_op ::= NMATCH */ + -1, /* (573) compare_op ::= CONTAINS */ + -1, /* (574) in_op ::= IN */ + -2, /* (575) in_op ::= NOT IN */ + -3, /* (576) in_predicate_value ::= NK_LP literal_list NK_RP */ + -1, /* (577) boolean_value_expression ::= boolean_primary */ + -2, /* (578) boolean_value_expression ::= NOT boolean_primary */ + -3, /* (579) boolean_value_expression ::= boolean_value_expression OR boolean_value_expression */ + -3, /* (580) boolean_value_expression ::= boolean_value_expression AND boolean_value_expression */ + -1, /* (581) boolean_primary ::= predicate */ + -3, /* (582) boolean_primary ::= NK_LP boolean_value_expression NK_RP */ + -1, /* (583) common_expression ::= expr_or_subquery */ + -1, /* (584) common_expression ::= boolean_value_expression */ + 0, /* (585) from_clause_opt ::= */ + -2, /* (586) from_clause_opt ::= FROM table_reference_list */ + -1, /* (587) table_reference_list ::= table_reference */ + -3, /* (588) table_reference_list ::= table_reference_list NK_COMMA table_reference */ + -1, /* (589) table_reference ::= table_primary */ + -1, /* (590) table_reference ::= joined_table */ + -2, /* (591) table_primary ::= table_name alias_opt */ + -4, /* (592) table_primary ::= db_name NK_DOT table_name alias_opt */ + -2, /* (593) table_primary ::= subquery alias_opt */ + -1, /* (594) table_primary ::= parenthesized_joined_table */ + 0, /* (595) alias_opt ::= */ + -1, /* (596) alias_opt ::= table_alias */ + -2, /* (597) alias_opt ::= AS table_alias */ + -3, /* (598) parenthesized_joined_table ::= NK_LP joined_table NK_RP */ + -3, /* (599) parenthesized_joined_table ::= NK_LP parenthesized_joined_table NK_RP */ + -6, /* (600) joined_table ::= table_reference join_type JOIN table_reference ON search_condition */ + 0, /* (601) join_type ::= */ + -1, /* (602) join_type ::= INNER */ + -14, /* (603) 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, /* (604) hint_list ::= */ + -1, /* (605) hint_list ::= NK_HINT */ + 0, /* (606) tag_mode_opt ::= */ + -1, /* (607) tag_mode_opt ::= TAGS */ + 0, /* (608) set_quantifier_opt ::= */ + -1, /* (609) set_quantifier_opt ::= DISTINCT */ + -1, /* (610) set_quantifier_opt ::= ALL */ + -1, /* (611) select_list ::= select_item */ + -3, /* (612) select_list ::= select_list NK_COMMA select_item */ + -1, /* (613) select_item ::= NK_STAR */ + -1, /* (614) select_item ::= common_expression */ + -2, /* (615) select_item ::= common_expression column_alias */ + -3, /* (616) select_item ::= common_expression AS column_alias */ + -3, /* (617) select_item ::= table_name NK_DOT NK_STAR */ + 0, /* (618) where_clause_opt ::= */ + -2, /* (619) where_clause_opt ::= WHERE search_condition */ + 0, /* (620) partition_by_clause_opt ::= */ + -3, /* (621) partition_by_clause_opt ::= PARTITION BY partition_list */ + -1, /* (622) partition_list ::= partition_item */ + -3, /* (623) partition_list ::= partition_list NK_COMMA partition_item */ + -1, /* (624) partition_item ::= expr_or_subquery */ + -2, /* (625) partition_item ::= expr_or_subquery column_alias */ + -3, /* (626) partition_item ::= expr_or_subquery AS column_alias */ + 0, /* (627) twindow_clause_opt ::= */ + -6, /* (628) twindow_clause_opt ::= SESSION NK_LP column_reference NK_COMMA interval_sliding_duration_literal NK_RP */ + -4, /* (629) twindow_clause_opt ::= STATE_WINDOW NK_LP expr_or_subquery NK_RP */ + -6, /* (630) twindow_clause_opt ::= INTERVAL NK_LP interval_sliding_duration_literal NK_RP sliding_opt fill_opt */ + -8, /* (631) twindow_clause_opt ::= INTERVAL NK_LP interval_sliding_duration_literal NK_COMMA interval_sliding_duration_literal NK_RP sliding_opt fill_opt */ + -7, /* (632) twindow_clause_opt ::= EVENT_WINDOW START WITH search_condition END WITH search_condition */ + -4, /* (633) twindow_clause_opt ::= COUNT_WINDOW NK_LP NK_INTEGER NK_RP */ + -6, /* (634) twindow_clause_opt ::= COUNT_WINDOW NK_LP NK_INTEGER NK_COMMA NK_INTEGER NK_RP */ + 0, /* (635) sliding_opt ::= */ + -4, /* (636) sliding_opt ::= SLIDING NK_LP interval_sliding_duration_literal NK_RP */ + -1, /* (637) interval_sliding_duration_literal ::= NK_VARIABLE */ + -1, /* (638) interval_sliding_duration_literal ::= NK_STRING */ + -1, /* (639) interval_sliding_duration_literal ::= NK_INTEGER */ + 0, /* (640) fill_opt ::= */ + -4, /* (641) fill_opt ::= FILL NK_LP fill_mode NK_RP */ + -6, /* (642) fill_opt ::= FILL NK_LP VALUE NK_COMMA expression_list NK_RP */ + -6, /* (643) fill_opt ::= FILL NK_LP VALUE_F NK_COMMA expression_list NK_RP */ + -1, /* (644) fill_mode ::= NONE */ + -1, /* (645) fill_mode ::= PREV */ + -1, /* (646) fill_mode ::= NULL */ + -1, /* (647) fill_mode ::= NULL_F */ + -1, /* (648) fill_mode ::= LINEAR */ + -1, /* (649) fill_mode ::= NEXT */ + 0, /* (650) group_by_clause_opt ::= */ + -3, /* (651) group_by_clause_opt ::= GROUP BY group_by_list */ + -1, /* (652) group_by_list ::= expr_or_subquery */ + -3, /* (653) group_by_list ::= group_by_list NK_COMMA expr_or_subquery */ + 0, /* (654) having_clause_opt ::= */ + -2, /* (655) having_clause_opt ::= HAVING search_condition */ + 0, /* (656) range_opt ::= */ + -6, /* (657) range_opt ::= RANGE NK_LP expr_or_subquery NK_COMMA expr_or_subquery NK_RP */ + -4, /* (658) range_opt ::= RANGE NK_LP expr_or_subquery NK_RP */ + 0, /* (659) every_opt ::= */ + -4, /* (660) every_opt ::= EVERY NK_LP duration_literal NK_RP */ + -4, /* (661) query_expression ::= query_simple order_by_clause_opt slimit_clause_opt limit_clause_opt */ + -1, /* (662) query_simple ::= query_specification */ + -1, /* (663) query_simple ::= union_query_expression */ + -4, /* (664) union_query_expression ::= query_simple_or_subquery UNION ALL query_simple_or_subquery */ + -3, /* (665) union_query_expression ::= query_simple_or_subquery UNION query_simple_or_subquery */ + -1, /* (666) query_simple_or_subquery ::= query_simple */ + -1, /* (667) query_simple_or_subquery ::= subquery */ + -1, /* (668) query_or_subquery ::= query_expression */ + -1, /* (669) query_or_subquery ::= subquery */ + 0, /* (670) order_by_clause_opt ::= */ + -3, /* (671) order_by_clause_opt ::= ORDER BY sort_specification_list */ + 0, /* (672) slimit_clause_opt ::= */ + -2, /* (673) slimit_clause_opt ::= SLIMIT NK_INTEGER */ + -4, /* (674) slimit_clause_opt ::= SLIMIT NK_INTEGER SOFFSET NK_INTEGER */ + -4, /* (675) slimit_clause_opt ::= SLIMIT NK_INTEGER NK_COMMA NK_INTEGER */ + 0, /* (676) limit_clause_opt ::= */ + -2, /* (677) limit_clause_opt ::= LIMIT NK_INTEGER */ + -4, /* (678) limit_clause_opt ::= LIMIT NK_INTEGER OFFSET NK_INTEGER */ + -4, /* (679) limit_clause_opt ::= LIMIT NK_INTEGER NK_COMMA NK_INTEGER */ + -3, /* (680) subquery ::= NK_LP query_expression NK_RP */ + -3, /* (681) subquery ::= NK_LP subquery NK_RP */ + -1, /* (682) search_condition ::= common_expression */ + -1, /* (683) sort_specification_list ::= sort_specification */ + -3, /* (684) sort_specification_list ::= sort_specification_list NK_COMMA sort_specification */ + -3, /* (685) sort_specification ::= expr_or_subquery ordering_specification_opt null_ordering_opt */ + 0, /* (686) ordering_specification_opt ::= */ + -1, /* (687) ordering_specification_opt ::= ASC */ + -1, /* (688) ordering_specification_opt ::= DESC */ + 0, /* (689) null_ordering_opt ::= */ + -2, /* (690) null_ordering_opt ::= NULLS FIRST */ + -2, /* (691) null_ordering_opt ::= NULLS LAST */ }; static void yy_accept(yyParser*); /* Forward Declaration */ @@ -4919,15 +4987,15 @@ static YYACTIONTYPE yy_reduce( case 309: /* tag_list_opt ::= */ yytestcase(yyruleno==309); case 375: /* col_list_opt ::= */ yytestcase(yyruleno==375); case 377: /* tag_def_or_ref_opt ::= */ yytestcase(yyruleno==377); - case 600: /* partition_by_clause_opt ::= */ yytestcase(yyruleno==600); - case 630: /* group_by_clause_opt ::= */ yytestcase(yyruleno==630); - case 650: /* order_by_clause_opt ::= */ yytestcase(yyruleno==650); + case 620: /* partition_by_clause_opt ::= */ yytestcase(yyruleno==620); + case 650: /* group_by_clause_opt ::= */ yytestcase(yyruleno==650); + case 670: /* order_by_clause_opt ::= */ yytestcase(yyruleno==670); { yymsp[1].minor.yy404 = NULL; } break; case 28: /* white_list_opt ::= white_list */ case 221: /* tags_def_opt ::= tags_def */ yytestcase(yyruleno==221); case 378: /* tag_def_or_ref_opt ::= tags_def */ yytestcase(yyruleno==378); - case 525: /* star_func_para_list ::= other_para_list */ yytestcase(yyruleno==525); + case 545: /* star_func_para_list ::= other_para_list */ yytestcase(yyruleno==545); { yylhsminor.yy404 = yymsp[0].minor.yy404; } yymsp[0].minor.yy404 = yylhsminor.yy404; break; @@ -5012,23 +5080,23 @@ static YYACTIONTYPE yy_reduce( case 161: /* end_opt ::= */ yytestcase(yyruleno==161); case 304: /* like_pattern_opt ::= */ yytestcase(yyruleno==304); case 389: /* subtable_opt ::= */ yytestcase(yyruleno==389); - case 535: /* case_when_else_opt ::= */ yytestcase(yyruleno==535); - case 565: /* from_clause_opt ::= */ yytestcase(yyruleno==565); - case 598: /* where_clause_opt ::= */ yytestcase(yyruleno==598); - case 607: /* twindow_clause_opt ::= */ yytestcase(yyruleno==607); - case 615: /* sliding_opt ::= */ yytestcase(yyruleno==615); - case 620: /* fill_opt ::= */ yytestcase(yyruleno==620); - case 634: /* having_clause_opt ::= */ yytestcase(yyruleno==634); - case 636: /* range_opt ::= */ yytestcase(yyruleno==636); - case 639: /* every_opt ::= */ yytestcase(yyruleno==639); - case 652: /* slimit_clause_opt ::= */ yytestcase(yyruleno==652); - case 656: /* limit_clause_opt ::= */ yytestcase(yyruleno==656); + case 555: /* case_when_else_opt ::= */ yytestcase(yyruleno==555); + case 585: /* from_clause_opt ::= */ yytestcase(yyruleno==585); + case 618: /* where_clause_opt ::= */ yytestcase(yyruleno==618); + case 627: /* twindow_clause_opt ::= */ yytestcase(yyruleno==627); + case 635: /* sliding_opt ::= */ yytestcase(yyruleno==635); + case 640: /* fill_opt ::= */ yytestcase(yyruleno==640); + case 654: /* having_clause_opt ::= */ yytestcase(yyruleno==654); + case 656: /* range_opt ::= */ yytestcase(yyruleno==656); + case 659: /* every_opt ::= */ yytestcase(yyruleno==659); + case 672: /* slimit_clause_opt ::= */ yytestcase(yyruleno==672); + case 676: /* limit_clause_opt ::= */ yytestcase(yyruleno==676); { yymsp[1].minor.yy896 = NULL; } break; case 53: /* with_opt ::= WITH search_condition */ - case 566: /* from_clause_opt ::= FROM table_reference_list */ yytestcase(yyruleno==566); - case 599: /* where_clause_opt ::= WHERE search_condition */ yytestcase(yyruleno==599); - case 635: /* having_clause_opt ::= HAVING search_condition */ yytestcase(yyruleno==635); + case 586: /* from_clause_opt ::= FROM table_reference_list */ yytestcase(yyruleno==586); + case 619: /* where_clause_opt ::= WHERE search_condition */ yytestcase(yyruleno==619); + case 655: /* having_clause_opt ::= HAVING search_condition */ yytestcase(yyruleno==655); { yymsp[-1].minor.yy896 = yymsp[0].minor.yy896; } break; case 54: /* cmd ::= CREATE DNODE dnode_endpoint */ @@ -5071,32 +5139,32 @@ static YYACTIONTYPE yy_reduce( case 332: /* sma_func_name ::= FIRST */ yytestcase(yyruleno==332); case 333: /* sma_func_name ::= LAST */ yytestcase(yyruleno==333); case 334: /* sma_func_name ::= LAST_ROW */ yytestcase(yyruleno==334); - case 456: /* db_name ::= NK_ID */ yytestcase(yyruleno==456); - case 457: /* table_name ::= NK_ID */ yytestcase(yyruleno==457); - case 458: /* column_name ::= NK_ID */ yytestcase(yyruleno==458); - case 459: /* function_name ::= NK_ID */ yytestcase(yyruleno==459); - case 460: /* view_name ::= NK_ID */ yytestcase(yyruleno==460); - case 461: /* table_alias ::= NK_ID */ yytestcase(yyruleno==461); - case 462: /* column_alias ::= NK_ID */ yytestcase(yyruleno==462); - case 463: /* column_alias ::= NK_ALIAS */ yytestcase(yyruleno==463); - case 464: /* user_name ::= NK_ID */ yytestcase(yyruleno==464); - case 465: /* topic_name ::= NK_ID */ yytestcase(yyruleno==465); - case 466: /* stream_name ::= NK_ID */ yytestcase(yyruleno==466); - case 467: /* cgroup_name ::= NK_ID */ yytestcase(yyruleno==467); - case 468: /* index_name ::= NK_ID */ yytestcase(yyruleno==468); - case 511: /* noarg_func ::= NOW */ yytestcase(yyruleno==511); - case 512: /* noarg_func ::= TODAY */ yytestcase(yyruleno==512); - case 513: /* noarg_func ::= TIMEZONE */ yytestcase(yyruleno==513); - case 514: /* noarg_func ::= DATABASE */ yytestcase(yyruleno==514); - case 515: /* noarg_func ::= CLIENT_VERSION */ yytestcase(yyruleno==515); - case 516: /* noarg_func ::= SERVER_VERSION */ yytestcase(yyruleno==516); - case 517: /* noarg_func ::= SERVER_STATUS */ yytestcase(yyruleno==517); - case 518: /* noarg_func ::= CURRENT_USER */ yytestcase(yyruleno==518); - case 519: /* noarg_func ::= USER */ yytestcase(yyruleno==519); - case 520: /* star_func ::= COUNT */ yytestcase(yyruleno==520); - case 521: /* star_func ::= FIRST */ yytestcase(yyruleno==521); - case 522: /* star_func ::= LAST */ yytestcase(yyruleno==522); - case 523: /* star_func ::= LAST_ROW */ yytestcase(yyruleno==523); + case 476: /* db_name ::= NK_ID */ yytestcase(yyruleno==476); + case 477: /* table_name ::= NK_ID */ yytestcase(yyruleno==477); + case 478: /* column_name ::= NK_ID */ yytestcase(yyruleno==478); + case 479: /* function_name ::= NK_ID */ yytestcase(yyruleno==479); + case 480: /* view_name ::= NK_ID */ yytestcase(yyruleno==480); + case 481: /* table_alias ::= NK_ID */ yytestcase(yyruleno==481); + case 482: /* column_alias ::= NK_ID */ yytestcase(yyruleno==482); + case 483: /* column_alias ::= NK_ALIAS */ yytestcase(yyruleno==483); + case 484: /* user_name ::= NK_ID */ yytestcase(yyruleno==484); + case 485: /* topic_name ::= NK_ID */ yytestcase(yyruleno==485); + case 486: /* stream_name ::= NK_ID */ yytestcase(yyruleno==486); + case 487: /* cgroup_name ::= NK_ID */ yytestcase(yyruleno==487); + case 488: /* index_name ::= NK_ID */ yytestcase(yyruleno==488); + case 531: /* noarg_func ::= NOW */ yytestcase(yyruleno==531); + case 532: /* noarg_func ::= TODAY */ yytestcase(yyruleno==532); + case 533: /* noarg_func ::= TIMEZONE */ yytestcase(yyruleno==533); + case 534: /* noarg_func ::= DATABASE */ yytestcase(yyruleno==534); + case 535: /* noarg_func ::= CLIENT_VERSION */ yytestcase(yyruleno==535); + case 536: /* noarg_func ::= SERVER_VERSION */ yytestcase(yyruleno==536); + case 537: /* noarg_func ::= SERVER_STATUS */ yytestcase(yyruleno==537); + case 538: /* noarg_func ::= CURRENT_USER */ yytestcase(yyruleno==538); + case 539: /* noarg_func ::= USER */ yytestcase(yyruleno==539); + case 540: /* star_func ::= COUNT */ yytestcase(yyruleno==540); + case 541: /* star_func ::= FIRST */ yytestcase(yyruleno==541); + case 542: /* star_func ::= LAST */ yytestcase(yyruleno==542); + case 543: /* star_func ::= LAST_ROW */ yytestcase(yyruleno==543); { yylhsminor.yy701 = yymsp[0].minor.yy0; } yymsp[0].minor.yy701 = yylhsminor.yy701; break; @@ -5107,16 +5175,16 @@ static YYACTIONTYPE yy_reduce( case 359: /* agg_func_opt ::= */ yytestcase(yyruleno==359); case 365: /* or_replace_opt ::= */ yytestcase(yyruleno==365); case 391: /* ignore_opt ::= */ yytestcase(yyruleno==391); - case 586: /* tag_mode_opt ::= */ yytestcase(yyruleno==586); - case 588: /* set_quantifier_opt ::= */ yytestcase(yyruleno==588); + case 606: /* tag_mode_opt ::= */ yytestcase(yyruleno==606); + case 608: /* set_quantifier_opt ::= */ yytestcase(yyruleno==608); { yymsp[1].minor.yy733 = false; } break; case 69: /* force_opt ::= FORCE */ case 70: /* unsafe_opt ::= UNSAFE */ yytestcase(yyruleno==70); case 353: /* analyze_opt ::= ANALYZE */ yytestcase(yyruleno==353); case 360: /* agg_func_opt ::= AGGREGATE */ yytestcase(yyruleno==360); - case 587: /* tag_mode_opt ::= TAGS */ yytestcase(yyruleno==587); - case 589: /* set_quantifier_opt ::= DISTINCT */ yytestcase(yyruleno==589); + case 607: /* tag_mode_opt ::= TAGS */ yytestcase(yyruleno==607); + case 609: /* set_quantifier_opt ::= DISTINCT */ yytestcase(yyruleno==609); { yymsp[0].minor.yy733 = true; } break; case 71: /* cmd ::= ALTER CLUSTER NK_STRING */ @@ -5409,13 +5477,13 @@ static YYACTIONTYPE yy_reduce( case 242: /* col_name_list ::= col_name */ yytestcase(yyruleno==242); case 310: /* tag_list_opt ::= tag_item */ yytestcase(yyruleno==310); case 327: /* func_list ::= func */ yytestcase(yyruleno==327); - case 429: /* tags_literal_list ::= tags_literal */ yytestcase(yyruleno==429); - case 454: /* literal_list ::= signed_literal */ yytestcase(yyruleno==454); - case 526: /* other_para_list ::= star_func_para */ yytestcase(yyruleno==526); - case 532: /* when_then_list ::= when_then_expr */ yytestcase(yyruleno==532); - case 591: /* select_list ::= select_item */ yytestcase(yyruleno==591); - case 602: /* partition_list ::= partition_item */ yytestcase(yyruleno==602); - case 663: /* sort_specification_list ::= sort_specification */ yytestcase(yyruleno==663); + case 449: /* tags_literal_list ::= tags_literal */ yytestcase(yyruleno==449); + case 474: /* literal_list ::= signed_literal */ yytestcase(yyruleno==474); + case 546: /* other_para_list ::= star_func_para */ yytestcase(yyruleno==546); + case 552: /* when_then_list ::= when_then_expr */ yytestcase(yyruleno==552); + case 611: /* select_list ::= select_item */ yytestcase(yyruleno==611); + case 622: /* partition_list ::= partition_item */ yytestcase(yyruleno==622); + case 683: /* sort_specification_list ::= sort_specification */ yytestcase(yyruleno==683); { yylhsminor.yy404 = createNodeList(pCxt, yymsp[0].minor.yy896); } yymsp[0].minor.yy404 = yylhsminor.yy404; break; @@ -5426,12 +5494,12 @@ static YYACTIONTYPE yy_reduce( case 243: /* col_name_list ::= col_name_list NK_COMMA col_name */ yytestcase(yyruleno==243); case 311: /* tag_list_opt ::= tag_list_opt NK_COMMA tag_item */ yytestcase(yyruleno==311); case 328: /* func_list ::= func_list NK_COMMA func */ yytestcase(yyruleno==328); - case 430: /* tags_literal_list ::= tags_literal_list NK_COMMA tags_literal */ yytestcase(yyruleno==430); - case 455: /* literal_list ::= literal_list NK_COMMA signed_literal */ yytestcase(yyruleno==455); - case 527: /* other_para_list ::= other_para_list NK_COMMA star_func_para */ yytestcase(yyruleno==527); - case 592: /* select_list ::= select_list NK_COMMA select_item */ yytestcase(yyruleno==592); - case 603: /* partition_list ::= partition_list NK_COMMA partition_item */ yytestcase(yyruleno==603); - case 664: /* sort_specification_list ::= sort_specification_list NK_COMMA sort_specification */ yytestcase(yyruleno==664); + case 450: /* tags_literal_list ::= tags_literal_list NK_COMMA tags_literal */ yytestcase(yyruleno==450); + case 475: /* literal_list ::= literal_list NK_COMMA signed_literal */ yytestcase(yyruleno==475); + case 547: /* other_para_list ::= other_para_list NK_COMMA star_func_para */ yytestcase(yyruleno==547); + case 612: /* select_list ::= select_list NK_COMMA select_item */ yytestcase(yyruleno==612); + case 623: /* partition_list ::= partition_list NK_COMMA partition_item */ yytestcase(yyruleno==623); + case 684: /* sort_specification_list ::= sort_specification_list NK_COMMA sort_specification */ yytestcase(yyruleno==684); { yylhsminor.yy404 = addNodeToList(pCxt, yymsp[-2].minor.yy404, yymsp[0].minor.yy896); } yymsp[-2].minor.yy404 = yylhsminor.yy404; break; @@ -5522,7 +5590,7 @@ static YYACTIONTYPE yy_reduce( yymsp[-5].minor.yy896 = yylhsminor.yy896; break; case 183: /* multi_create_clause ::= multi_create_clause create_subtable_clause */ - case 533: /* when_then_list ::= when_then_list when_then_expr */ yytestcase(yyruleno==533); + case 553: /* when_then_list ::= when_then_list when_then_expr */ yytestcase(yyruleno==553); { yylhsminor.yy404 = addNodeToList(pCxt, yymsp[-1].minor.yy404, yymsp[0].minor.yy896); } yymsp[-1].minor.yy404 = yylhsminor.yy404; break; @@ -5674,12 +5742,12 @@ static YYACTIONTYPE yy_reduce( { yymsp[-1].minor.yy529.type = TABLE_OPTION_TTL; yymsp[-1].minor.yy529.val = yymsp[0].minor.yy0; } break; case 235: /* duration_list ::= duration_literal */ - case 486: /* expression_list ::= expr_or_subquery */ yytestcase(yyruleno==486); + case 506: /* expression_list ::= expr_or_subquery */ yytestcase(yyruleno==506); { yylhsminor.yy404 = createNodeList(pCxt, releaseRawExprNode(pCxt, yymsp[0].minor.yy896)); } yymsp[0].minor.yy404 = yylhsminor.yy404; break; case 236: /* duration_list ::= duration_list NK_COMMA duration_literal */ - case 487: /* expression_list ::= expression_list NK_COMMA expr_or_subquery */ yytestcase(yyruleno==487); + case 507: /* expression_list ::= expression_list NK_COMMA expr_or_subquery */ yytestcase(yyruleno==507); { yylhsminor.yy404 = addNodeToList(pCxt, yymsp[-2].minor.yy404, releaseRawExprNode(pCxt, yymsp[0].minor.yy896)); } yymsp[-2].minor.yy404 = yylhsminor.yy404; break; @@ -5940,7 +6008,7 @@ static YYACTIONTYPE yy_reduce( yymsp[-3].minor.yy896 = yylhsminor.yy896; break; case 330: /* sma_func_name ::= function_name */ - case 576: /* alias_opt ::= table_alias */ yytestcase(yyruleno==576); + case 596: /* alias_opt ::= table_alias */ yytestcase(yyruleno==596); { yylhsminor.yy701 = yymsp[0].minor.yy701; } yymsp[0].minor.yy701 = yylhsminor.yy701; break; @@ -6076,8 +6144,8 @@ static YYACTIONTYPE yy_reduce( yymsp[-3].minor.yy896 = yylhsminor.yy896; break; case 390: /* subtable_opt ::= SUBTABLE NK_LP expression NK_RP */ - case 616: /* sliding_opt ::= SLIDING NK_LP interval_sliding_duration_literal NK_RP */ yytestcase(yyruleno==616); - case 640: /* every_opt ::= EVERY NK_LP duration_literal NK_RP */ yytestcase(yyruleno==640); + case 636: /* sliding_opt ::= SLIDING NK_LP interval_sliding_duration_literal NK_RP */ yytestcase(yyruleno==636); + case 660: /* every_opt ::= EVERY NK_LP duration_literal NK_RP */ yytestcase(yyruleno==660); { yymsp[-3].minor.yy896 = releaseRawExprNode(pCxt, yymsp[-1].minor.yy896); } break; case 393: /* cmd ::= KILL CONNECTION NK_INTEGER */ @@ -6120,17 +6188,33 @@ static YYACTIONTYPE yy_reduce( { yymsp[-3].minor.yy896 = createInsertStmt(pCxt, yymsp[-1].minor.yy896, NULL, yymsp[0].minor.yy896); } break; case 411: /* tags_literal ::= NK_INTEGER */ - case 417: /* tags_literal ::= NK_BIN */ yytestcase(yyruleno==417); - case 420: /* tags_literal ::= NK_HEX */ yytestcase(yyruleno==420); + case 423: /* tags_literal ::= NK_BIN */ yytestcase(yyruleno==423); + case 432: /* tags_literal ::= NK_HEX */ yytestcase(yyruleno==432); { yylhsminor.yy896 = createRawValueNode(pCxt, TSDB_DATA_TYPE_UBIGINT, &yymsp[0].minor.yy0, NULL); } yymsp[0].minor.yy896 = yylhsminor.yy896; break; - case 412: /* tags_literal ::= NK_PLUS NK_INTEGER */ - case 413: /* tags_literal ::= NK_MINUS NK_INTEGER */ yytestcase(yyruleno==413); - case 418: /* tags_literal ::= NK_PLUS NK_BIN */ yytestcase(yyruleno==418); - case 419: /* tags_literal ::= NK_MINUS NK_BIN */ yytestcase(yyruleno==419); - case 421: /* tags_literal ::= NK_PLUS NK_HEX */ yytestcase(yyruleno==421); - case 422: /* tags_literal ::= NK_MINUS NK_HEX */ yytestcase(yyruleno==422); + case 412: /* tags_literal ::= NK_INTEGER NK_PLUS duration_literal */ + case 413: /* tags_literal ::= NK_INTEGER NK_MINUS duration_literal */ yytestcase(yyruleno==413); + case 424: /* tags_literal ::= NK_BIN NK_PLUS duration_literal */ yytestcase(yyruleno==424); + case 425: /* tags_literal ::= NK_BIN NK_MINUS duration_literal */ yytestcase(yyruleno==425); + case 433: /* tags_literal ::= NK_HEX NK_PLUS duration_literal */ yytestcase(yyruleno==433); + case 434: /* tags_literal ::= NK_HEX NK_MINUS duration_literal */ yytestcase(yyruleno==434); + case 442: /* tags_literal ::= NK_STRING NK_PLUS duration_literal */ yytestcase(yyruleno==442); + case 443: /* tags_literal ::= NK_STRING NK_MINUS duration_literal */ yytestcase(yyruleno==443); +{ + SToken l = yymsp[-2].minor.yy0; + SToken r = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy896); + l.n = (r.z + r.n) - l.z; + yylhsminor.yy896 = createRawValueNodeExt(pCxt, TSDB_DATA_TYPE_BINARY, &l, NULL, yymsp[0].minor.yy896); + } + yymsp[-2].minor.yy896 = yylhsminor.yy896; + break; + case 414: /* tags_literal ::= NK_PLUS NK_INTEGER */ + case 417: /* tags_literal ::= NK_MINUS NK_INTEGER */ yytestcase(yyruleno==417); + case 426: /* tags_literal ::= NK_PLUS NK_BIN */ yytestcase(yyruleno==426); + case 429: /* tags_literal ::= NK_MINUS NK_BIN */ yytestcase(yyruleno==429); + case 435: /* tags_literal ::= NK_PLUS NK_HEX */ yytestcase(yyruleno==435); + case 438: /* tags_literal ::= NK_MINUS NK_HEX */ yytestcase(yyruleno==438); { SToken t = yymsp[-1].minor.yy0; t.n = (yymsp[0].minor.yy0.z + yymsp[0].minor.yy0.n) - yymsp[-1].minor.yy0.z; @@ -6138,12 +6222,32 @@ static YYACTIONTYPE yy_reduce( } yymsp[-1].minor.yy896 = yylhsminor.yy896; break; - case 414: /* tags_literal ::= NK_FLOAT */ + case 415: /* tags_literal ::= NK_PLUS NK_INTEGER NK_PLUS duration_literal */ + case 416: /* tags_literal ::= NK_PLUS NK_INTEGER NK_MINUS duration_literal */ yytestcase(yyruleno==416); + case 418: /* tags_literal ::= NK_MINUS NK_INTEGER NK_PLUS duration_literal */ yytestcase(yyruleno==418); + case 419: /* tags_literal ::= NK_MINUS NK_INTEGER NK_MINUS duration_literal */ yytestcase(yyruleno==419); + case 427: /* tags_literal ::= NK_PLUS NK_BIN NK_PLUS duration_literal */ yytestcase(yyruleno==427); + case 428: /* tags_literal ::= NK_PLUS NK_BIN NK_MINUS duration_literal */ yytestcase(yyruleno==428); + case 430: /* tags_literal ::= NK_MINUS NK_BIN NK_PLUS duration_literal */ yytestcase(yyruleno==430); + case 431: /* tags_literal ::= NK_MINUS NK_BIN NK_MINUS duration_literal */ yytestcase(yyruleno==431); + case 436: /* tags_literal ::= NK_PLUS NK_HEX NK_PLUS duration_literal */ yytestcase(yyruleno==436); + case 437: /* tags_literal ::= NK_PLUS NK_HEX NK_MINUS duration_literal */ yytestcase(yyruleno==437); + case 439: /* tags_literal ::= NK_MINUS NK_HEX NK_PLUS duration_literal */ yytestcase(yyruleno==439); + case 440: /* tags_literal ::= NK_MINUS NK_HEX NK_MINUS duration_literal */ yytestcase(yyruleno==440); +{ + SToken l = yymsp[-3].minor.yy0; + SToken r = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy896); + l.n = (r.z + r.n) - l.z; + yylhsminor.yy896 = createRawValueNodeExt(pCxt, TSDB_DATA_TYPE_BINARY, &l, NULL, yymsp[0].minor.yy896); + } + yymsp[-3].minor.yy896 = yylhsminor.yy896; + break; + case 420: /* tags_literal ::= NK_FLOAT */ { yylhsminor.yy896 = createRawValueNode(pCxt, TSDB_DATA_TYPE_DOUBLE, &yymsp[0].minor.yy0, NULL); } yymsp[0].minor.yy896 = yylhsminor.yy896; break; - case 415: /* tags_literal ::= NK_PLUS NK_FLOAT */ - case 416: /* tags_literal ::= NK_MINUS NK_FLOAT */ yytestcase(yyruleno==416); + case 421: /* tags_literal ::= NK_PLUS NK_FLOAT */ + case 422: /* tags_literal ::= NK_MINUS NK_FLOAT */ yytestcase(yyruleno==422); { SToken t = yymsp[-1].minor.yy0; t.n = (yymsp[0].minor.yy0.z + yymsp[0].minor.yy0.n) - yymsp[-1].minor.yy0.z; @@ -6151,24 +6255,24 @@ static YYACTIONTYPE yy_reduce( } yymsp[-1].minor.yy896 = yylhsminor.yy896; break; - case 423: /* tags_literal ::= NK_STRING */ + case 441: /* tags_literal ::= NK_STRING */ { yylhsminor.yy896 = createRawValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy0, NULL); } yymsp[0].minor.yy896 = yylhsminor.yy896; break; - case 424: /* tags_literal ::= NK_BOOL */ + case 444: /* tags_literal ::= NK_BOOL */ { yylhsminor.yy896 = createRawValueNode(pCxt, TSDB_DATA_TYPE_BOOL, &yymsp[0].minor.yy0, NULL); } yymsp[0].minor.yy896 = yylhsminor.yy896; break; - case 425: /* tags_literal ::= NULL */ + case 445: /* tags_literal ::= NULL */ { yylhsminor.yy896 = createRawValueNode(pCxt, TSDB_DATA_TYPE_NULL, &yymsp[0].minor.yy0, NULL); } yymsp[0].minor.yy896 = yylhsminor.yy896; break; - case 426: /* tags_literal ::= literal_func */ + case 446: /* tags_literal ::= literal_func */ { yylhsminor.yy896 = createRawValueNode(pCxt, TSDB_DATA_TYPE_BINARY, NULL, yymsp[0].minor.yy896); } yymsp[0].minor.yy896 = yylhsminor.yy896; break; - case 427: /* tags_literal ::= literal_func NK_PLUS duration_literal */ - case 428: /* tags_literal ::= literal_func NK_MINUS duration_literal */ yytestcase(yyruleno==428); + case 447: /* tags_literal ::= literal_func NK_PLUS duration_literal */ + case 448: /* tags_literal ::= literal_func NK_MINUS duration_literal */ yytestcase(yyruleno==448); { SToken l = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy896); SToken r = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy896); @@ -6177,72 +6281,72 @@ static YYACTIONTYPE yy_reduce( } yymsp[-2].minor.yy896 = yylhsminor.yy896; break; - case 431: /* literal ::= NK_INTEGER */ + case 451: /* literal ::= NK_INTEGER */ { yylhsminor.yy896 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_UBIGINT, &yymsp[0].minor.yy0)); } yymsp[0].minor.yy896 = yylhsminor.yy896; break; - case 432: /* literal ::= NK_FLOAT */ + case 452: /* literal ::= NK_FLOAT */ { yylhsminor.yy896 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_DOUBLE, &yymsp[0].minor.yy0)); } yymsp[0].minor.yy896 = yylhsminor.yy896; break; - case 433: /* literal ::= NK_STRING */ + case 453: /* literal ::= NK_STRING */ { yylhsminor.yy896 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy0)); } yymsp[0].minor.yy896 = yylhsminor.yy896; break; - case 434: /* literal ::= NK_BOOL */ + case 454: /* literal ::= NK_BOOL */ { yylhsminor.yy896 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_BOOL, &yymsp[0].minor.yy0)); } yymsp[0].minor.yy896 = yylhsminor.yy896; break; - case 435: /* literal ::= TIMESTAMP NK_STRING */ + case 455: /* literal ::= TIMESTAMP NK_STRING */ { yylhsminor.yy896 = createRawExprNodeExt(pCxt, &yymsp[-1].minor.yy0, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_TIMESTAMP, &yymsp[0].minor.yy0)); } yymsp[-1].minor.yy896 = yylhsminor.yy896; break; - case 436: /* literal ::= duration_literal */ - case 446: /* signed_literal ::= signed */ yytestcase(yyruleno==446); - case 469: /* expr_or_subquery ::= expression */ yytestcase(yyruleno==469); - case 470: /* expression ::= literal */ yytestcase(yyruleno==470); - case 472: /* expression ::= column_reference */ yytestcase(yyruleno==472); - case 473: /* expression ::= function_expression */ yytestcase(yyruleno==473); - case 474: /* expression ::= case_when_expression */ yytestcase(yyruleno==474); - case 507: /* function_expression ::= literal_func */ yytestcase(yyruleno==507); - case 557: /* boolean_value_expression ::= boolean_primary */ yytestcase(yyruleno==557); - case 561: /* boolean_primary ::= predicate */ yytestcase(yyruleno==561); - case 563: /* common_expression ::= expr_or_subquery */ yytestcase(yyruleno==563); - case 564: /* common_expression ::= boolean_value_expression */ yytestcase(yyruleno==564); - case 567: /* table_reference_list ::= table_reference */ yytestcase(yyruleno==567); - case 569: /* table_reference ::= table_primary */ yytestcase(yyruleno==569); - case 570: /* table_reference ::= joined_table */ yytestcase(yyruleno==570); - case 574: /* table_primary ::= parenthesized_joined_table */ yytestcase(yyruleno==574); - case 642: /* query_simple ::= query_specification */ yytestcase(yyruleno==642); - case 643: /* query_simple ::= union_query_expression */ yytestcase(yyruleno==643); - case 646: /* query_simple_or_subquery ::= query_simple */ yytestcase(yyruleno==646); - case 648: /* query_or_subquery ::= query_expression */ yytestcase(yyruleno==648); + case 456: /* literal ::= duration_literal */ + case 466: /* signed_literal ::= signed */ yytestcase(yyruleno==466); + case 489: /* expr_or_subquery ::= expression */ yytestcase(yyruleno==489); + case 490: /* expression ::= literal */ yytestcase(yyruleno==490); + case 492: /* expression ::= column_reference */ yytestcase(yyruleno==492); + case 493: /* expression ::= function_expression */ yytestcase(yyruleno==493); + case 494: /* expression ::= case_when_expression */ yytestcase(yyruleno==494); + case 527: /* function_expression ::= literal_func */ yytestcase(yyruleno==527); + case 577: /* boolean_value_expression ::= boolean_primary */ yytestcase(yyruleno==577); + case 581: /* boolean_primary ::= predicate */ yytestcase(yyruleno==581); + case 583: /* common_expression ::= expr_or_subquery */ yytestcase(yyruleno==583); + case 584: /* common_expression ::= boolean_value_expression */ yytestcase(yyruleno==584); + case 587: /* table_reference_list ::= table_reference */ yytestcase(yyruleno==587); + case 589: /* table_reference ::= table_primary */ yytestcase(yyruleno==589); + case 590: /* table_reference ::= joined_table */ yytestcase(yyruleno==590); + case 594: /* table_primary ::= parenthesized_joined_table */ yytestcase(yyruleno==594); + case 662: /* query_simple ::= query_specification */ yytestcase(yyruleno==662); + case 663: /* query_simple ::= union_query_expression */ yytestcase(yyruleno==663); + case 666: /* query_simple_or_subquery ::= query_simple */ yytestcase(yyruleno==666); + case 668: /* query_or_subquery ::= query_expression */ yytestcase(yyruleno==668); { yylhsminor.yy896 = yymsp[0].minor.yy896; } yymsp[0].minor.yy896 = yylhsminor.yy896; break; - case 437: /* literal ::= NULL */ + case 457: /* literal ::= NULL */ { yylhsminor.yy896 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_NULL, &yymsp[0].minor.yy0)); } yymsp[0].minor.yy896 = yylhsminor.yy896; break; - case 438: /* literal ::= NK_QUESTION */ + case 458: /* literal ::= NK_QUESTION */ { yylhsminor.yy896 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createPlaceholderValueNode(pCxt, &yymsp[0].minor.yy0)); } yymsp[0].minor.yy896 = yylhsminor.yy896; break; - case 439: /* duration_literal ::= NK_VARIABLE */ - case 617: /* interval_sliding_duration_literal ::= NK_VARIABLE */ yytestcase(yyruleno==617); - case 618: /* interval_sliding_duration_literal ::= NK_STRING */ yytestcase(yyruleno==618); - case 619: /* interval_sliding_duration_literal ::= NK_INTEGER */ yytestcase(yyruleno==619); + case 459: /* duration_literal ::= NK_VARIABLE */ + case 637: /* interval_sliding_duration_literal ::= NK_VARIABLE */ yytestcase(yyruleno==637); + case 638: /* interval_sliding_duration_literal ::= NK_STRING */ yytestcase(yyruleno==638); + case 639: /* interval_sliding_duration_literal ::= NK_INTEGER */ yytestcase(yyruleno==639); { yylhsminor.yy896 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createDurationValueNode(pCxt, &yymsp[0].minor.yy0)); } yymsp[0].minor.yy896 = yylhsminor.yy896; break; - case 440: /* signed ::= NK_INTEGER */ + case 460: /* signed ::= NK_INTEGER */ { yylhsminor.yy896 = createValueNode(pCxt, TSDB_DATA_TYPE_UBIGINT, &yymsp[0].minor.yy0); } yymsp[0].minor.yy896 = yylhsminor.yy896; break; - case 441: /* signed ::= NK_PLUS NK_INTEGER */ + case 461: /* signed ::= NK_PLUS NK_INTEGER */ { yymsp[-1].minor.yy896 = createValueNode(pCxt, TSDB_DATA_TYPE_UBIGINT, &yymsp[0].minor.yy0); } break; - case 442: /* signed ::= NK_MINUS NK_INTEGER */ + case 462: /* 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; @@ -6250,14 +6354,14 @@ static YYACTIONTYPE yy_reduce( } yymsp[-1].minor.yy896 = yylhsminor.yy896; break; - case 443: /* signed ::= NK_FLOAT */ + case 463: /* signed ::= NK_FLOAT */ { yylhsminor.yy896 = createValueNode(pCxt, TSDB_DATA_TYPE_DOUBLE, &yymsp[0].minor.yy0); } yymsp[0].minor.yy896 = yylhsminor.yy896; break; - case 444: /* signed ::= NK_PLUS NK_FLOAT */ + case 464: /* signed ::= NK_PLUS NK_FLOAT */ { yymsp[-1].minor.yy896 = createValueNode(pCxt, TSDB_DATA_TYPE_DOUBLE, &yymsp[0].minor.yy0); } break; - case 445: /* signed ::= NK_MINUS NK_FLOAT */ + case 465: /* 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; @@ -6265,61 +6369,61 @@ static YYACTIONTYPE yy_reduce( } yymsp[-1].minor.yy896 = yylhsminor.yy896; break; - case 447: /* signed_literal ::= NK_STRING */ + case 467: /* signed_literal ::= NK_STRING */ { yylhsminor.yy896 = createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy0); } yymsp[0].minor.yy896 = yylhsminor.yy896; break; - case 448: /* signed_literal ::= NK_BOOL */ + case 468: /* signed_literal ::= NK_BOOL */ { yylhsminor.yy896 = createValueNode(pCxt, TSDB_DATA_TYPE_BOOL, &yymsp[0].minor.yy0); } yymsp[0].minor.yy896 = yylhsminor.yy896; break; - case 449: /* signed_literal ::= TIMESTAMP NK_STRING */ + case 469: /* signed_literal ::= TIMESTAMP NK_STRING */ { yymsp[-1].minor.yy896 = createValueNode(pCxt, TSDB_DATA_TYPE_TIMESTAMP, &yymsp[0].minor.yy0); } break; - case 450: /* signed_literal ::= duration_literal */ - case 452: /* signed_literal ::= literal_func */ yytestcase(yyruleno==452); - case 528: /* star_func_para ::= expr_or_subquery */ yytestcase(yyruleno==528); - case 594: /* select_item ::= common_expression */ yytestcase(yyruleno==594); - case 604: /* partition_item ::= expr_or_subquery */ yytestcase(yyruleno==604); - case 647: /* query_simple_or_subquery ::= subquery */ yytestcase(yyruleno==647); - case 649: /* query_or_subquery ::= subquery */ yytestcase(yyruleno==649); - case 662: /* search_condition ::= common_expression */ yytestcase(yyruleno==662); + case 470: /* signed_literal ::= duration_literal */ + case 472: /* signed_literal ::= literal_func */ yytestcase(yyruleno==472); + case 548: /* star_func_para ::= expr_or_subquery */ yytestcase(yyruleno==548); + case 614: /* select_item ::= common_expression */ yytestcase(yyruleno==614); + case 624: /* partition_item ::= expr_or_subquery */ yytestcase(yyruleno==624); + case 667: /* query_simple_or_subquery ::= subquery */ yytestcase(yyruleno==667); + case 669: /* query_or_subquery ::= subquery */ yytestcase(yyruleno==669); + case 682: /* search_condition ::= common_expression */ yytestcase(yyruleno==682); { yylhsminor.yy896 = releaseRawExprNode(pCxt, yymsp[0].minor.yy896); } yymsp[0].minor.yy896 = yylhsminor.yy896; break; - case 451: /* signed_literal ::= NULL */ + case 471: /* signed_literal ::= NULL */ { yylhsminor.yy896 = createValueNode(pCxt, TSDB_DATA_TYPE_NULL, &yymsp[0].minor.yy0); } yymsp[0].minor.yy896 = yylhsminor.yy896; break; - case 453: /* signed_literal ::= NK_QUESTION */ + case 473: /* signed_literal ::= NK_QUESTION */ { yylhsminor.yy896 = createPlaceholderValueNode(pCxt, &yymsp[0].minor.yy0); } yymsp[0].minor.yy896 = yylhsminor.yy896; break; - case 471: /* expression ::= pseudo_column */ + case 491: /* expression ::= pseudo_column */ { yylhsminor.yy896 = yymsp[0].minor.yy896; setRawExprNodeIsPseudoColumn(pCxt, yylhsminor.yy896, true); } yymsp[0].minor.yy896 = yylhsminor.yy896; break; - case 475: /* expression ::= NK_LP expression NK_RP */ - case 562: /* boolean_primary ::= NK_LP boolean_value_expression NK_RP */ yytestcase(yyruleno==562); - case 661: /* subquery ::= NK_LP subquery NK_RP */ yytestcase(yyruleno==661); + case 495: /* expression ::= NK_LP expression NK_RP */ + case 582: /* boolean_primary ::= NK_LP boolean_value_expression NK_RP */ yytestcase(yyruleno==582); + case 681: /* subquery ::= NK_LP subquery NK_RP */ yytestcase(yyruleno==681); { yylhsminor.yy896 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy0, &yymsp[0].minor.yy0, releaseRawExprNode(pCxt, yymsp[-1].minor.yy896)); } yymsp[-2].minor.yy896 = yylhsminor.yy896; break; - case 476: /* expression ::= NK_PLUS expr_or_subquery */ + case 496: /* expression ::= NK_PLUS expr_or_subquery */ { SToken t = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy896); yylhsminor.yy896 = createRawExprNodeExt(pCxt, &yymsp[-1].minor.yy0, &t, releaseRawExprNode(pCxt, yymsp[0].minor.yy896)); } yymsp[-1].minor.yy896 = yylhsminor.yy896; break; - case 477: /* expression ::= NK_MINUS expr_or_subquery */ + case 497: /* expression ::= NK_MINUS expr_or_subquery */ { SToken t = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy896); yylhsminor.yy896 = createRawExprNodeExt(pCxt, &yymsp[-1].minor.yy0, &t, createOperatorNode(pCxt, OP_TYPE_MINUS, releaseRawExprNode(pCxt, yymsp[0].minor.yy896), NULL)); } yymsp[-1].minor.yy896 = yylhsminor.yy896; break; - case 478: /* expression ::= expr_or_subquery NK_PLUS expr_or_subquery */ + case 498: /* expression ::= expr_or_subquery NK_PLUS expr_or_subquery */ { SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy896); SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy896); @@ -6327,7 +6431,7 @@ static YYACTIONTYPE yy_reduce( } yymsp[-2].minor.yy896 = yylhsminor.yy896; break; - case 479: /* expression ::= expr_or_subquery NK_MINUS expr_or_subquery */ + case 499: /* expression ::= expr_or_subquery NK_MINUS expr_or_subquery */ { SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy896); SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy896); @@ -6335,7 +6439,7 @@ static YYACTIONTYPE yy_reduce( } yymsp[-2].minor.yy896 = yylhsminor.yy896; break; - case 480: /* expression ::= expr_or_subquery NK_STAR expr_or_subquery */ + case 500: /* expression ::= expr_or_subquery NK_STAR expr_or_subquery */ { SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy896); SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy896); @@ -6343,7 +6447,7 @@ static YYACTIONTYPE yy_reduce( } yymsp[-2].minor.yy896 = yylhsminor.yy896; break; - case 481: /* expression ::= expr_or_subquery NK_SLASH expr_or_subquery */ + case 501: /* expression ::= expr_or_subquery NK_SLASH expr_or_subquery */ { SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy896); SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy896); @@ -6351,7 +6455,7 @@ static YYACTIONTYPE yy_reduce( } yymsp[-2].minor.yy896 = yylhsminor.yy896; break; - case 482: /* expression ::= expr_or_subquery NK_REM expr_or_subquery */ + case 502: /* expression ::= expr_or_subquery NK_REM expr_or_subquery */ { SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy896); SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy896); @@ -6359,14 +6463,14 @@ static YYACTIONTYPE yy_reduce( } yymsp[-2].minor.yy896 = yylhsminor.yy896; break; - case 483: /* expression ::= column_reference NK_ARROW NK_STRING */ + case 503: /* expression ::= column_reference NK_ARROW NK_STRING */ { SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy896); yylhsminor.yy896 = createRawExprNodeExt(pCxt, &s, &yymsp[0].minor.yy0, createOperatorNode(pCxt, OP_TYPE_JSON_GET_VALUE, releaseRawExprNode(pCxt, yymsp[-2].minor.yy896), createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy0))); } yymsp[-2].minor.yy896 = yylhsminor.yy896; break; - case 484: /* expression ::= expr_or_subquery NK_BITAND expr_or_subquery */ + case 504: /* expression ::= expr_or_subquery NK_BITAND expr_or_subquery */ { SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy896); SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy896); @@ -6374,7 +6478,7 @@ static YYACTIONTYPE yy_reduce( } yymsp[-2].minor.yy896 = yylhsminor.yy896; break; - case 485: /* expression ::= expr_or_subquery NK_BITOR expr_or_subquery */ + case 505: /* expression ::= expr_or_subquery NK_BITOR expr_or_subquery */ { SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy896); SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy896); @@ -6382,80 +6486,80 @@ static YYACTIONTYPE yy_reduce( } yymsp[-2].minor.yy896 = yylhsminor.yy896; break; - case 488: /* column_reference ::= column_name */ + case 508: /* column_reference ::= column_name */ { yylhsminor.yy896 = createRawExprNode(pCxt, &yymsp[0].minor.yy701, createColumnNode(pCxt, NULL, &yymsp[0].minor.yy701)); } yymsp[0].minor.yy896 = yylhsminor.yy896; break; - case 489: /* column_reference ::= table_name NK_DOT column_name */ + case 509: /* column_reference ::= table_name NK_DOT column_name */ { yylhsminor.yy896 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy701, &yymsp[0].minor.yy701, createColumnNode(pCxt, &yymsp[-2].minor.yy701, &yymsp[0].minor.yy701)); } yymsp[-2].minor.yy896 = yylhsminor.yy896; break; - case 490: /* column_reference ::= NK_ALIAS */ + case 510: /* column_reference ::= NK_ALIAS */ { yylhsminor.yy896 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createColumnNode(pCxt, NULL, &yymsp[0].minor.yy0)); } yymsp[0].minor.yy896 = yylhsminor.yy896; break; - case 491: /* column_reference ::= table_name NK_DOT NK_ALIAS */ + case 511: /* column_reference ::= table_name NK_DOT NK_ALIAS */ { yylhsminor.yy896 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy701, &yymsp[0].minor.yy0, createColumnNode(pCxt, &yymsp[-2].minor.yy701, &yymsp[0].minor.yy0)); } yymsp[-2].minor.yy896 = yylhsminor.yy896; break; - case 492: /* pseudo_column ::= ROWTS */ - case 493: /* pseudo_column ::= TBNAME */ yytestcase(yyruleno==493); - case 495: /* pseudo_column ::= QSTART */ yytestcase(yyruleno==495); - case 496: /* pseudo_column ::= QEND */ yytestcase(yyruleno==496); - case 497: /* pseudo_column ::= QDURATION */ yytestcase(yyruleno==497); - case 498: /* pseudo_column ::= WSTART */ yytestcase(yyruleno==498); - case 499: /* pseudo_column ::= WEND */ yytestcase(yyruleno==499); - case 500: /* pseudo_column ::= WDURATION */ yytestcase(yyruleno==500); - case 501: /* pseudo_column ::= IROWTS */ yytestcase(yyruleno==501); - case 502: /* pseudo_column ::= ISFILLED */ yytestcase(yyruleno==502); - case 503: /* pseudo_column ::= QTAGS */ yytestcase(yyruleno==503); - case 509: /* literal_func ::= NOW */ yytestcase(yyruleno==509); - case 510: /* literal_func ::= TODAY */ yytestcase(yyruleno==510); + case 512: /* pseudo_column ::= ROWTS */ + case 513: /* pseudo_column ::= TBNAME */ yytestcase(yyruleno==513); + case 515: /* pseudo_column ::= QSTART */ yytestcase(yyruleno==515); + case 516: /* pseudo_column ::= QEND */ yytestcase(yyruleno==516); + case 517: /* pseudo_column ::= QDURATION */ yytestcase(yyruleno==517); + case 518: /* pseudo_column ::= WSTART */ yytestcase(yyruleno==518); + case 519: /* pseudo_column ::= WEND */ yytestcase(yyruleno==519); + case 520: /* pseudo_column ::= WDURATION */ yytestcase(yyruleno==520); + case 521: /* pseudo_column ::= IROWTS */ yytestcase(yyruleno==521); + case 522: /* pseudo_column ::= ISFILLED */ yytestcase(yyruleno==522); + case 523: /* pseudo_column ::= QTAGS */ yytestcase(yyruleno==523); + case 529: /* literal_func ::= NOW */ yytestcase(yyruleno==529); + case 530: /* literal_func ::= TODAY */ yytestcase(yyruleno==530); { yylhsminor.yy896 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createFunctionNode(pCxt, &yymsp[0].minor.yy0, NULL)); } yymsp[0].minor.yy896 = yylhsminor.yy896; break; - case 494: /* pseudo_column ::= table_name NK_DOT TBNAME */ + case 514: /* pseudo_column ::= table_name NK_DOT TBNAME */ { yylhsminor.yy896 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy701, &yymsp[0].minor.yy0, createFunctionNode(pCxt, &yymsp[0].minor.yy0, createNodeList(pCxt, createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[-2].minor.yy701)))); } yymsp[-2].minor.yy896 = yylhsminor.yy896; break; - case 504: /* function_expression ::= function_name NK_LP expression_list NK_RP */ - case 505: /* function_expression ::= star_func NK_LP star_func_para_list NK_RP */ yytestcase(yyruleno==505); + case 524: /* function_expression ::= function_name NK_LP expression_list NK_RP */ + case 525: /* function_expression ::= star_func NK_LP star_func_para_list NK_RP */ yytestcase(yyruleno==525); { yylhsminor.yy896 = createRawExprNodeExt(pCxt, &yymsp[-3].minor.yy701, &yymsp[0].minor.yy0, createFunctionNode(pCxt, &yymsp[-3].minor.yy701, yymsp[-1].minor.yy404)); } yymsp[-3].minor.yy896 = yylhsminor.yy896; break; - case 506: /* function_expression ::= CAST NK_LP expr_or_subquery AS type_name NK_RP */ + case 526: /* function_expression ::= CAST NK_LP expr_or_subquery AS type_name NK_RP */ { yylhsminor.yy896 = createRawExprNodeExt(pCxt, &yymsp[-5].minor.yy0, &yymsp[0].minor.yy0, createCastFunctionNode(pCxt, releaseRawExprNode(pCxt, yymsp[-3].minor.yy896), yymsp[-1].minor.yy504)); } yymsp[-5].minor.yy896 = yylhsminor.yy896; break; - case 508: /* literal_func ::= noarg_func NK_LP NK_RP */ + case 528: /* literal_func ::= noarg_func NK_LP NK_RP */ { yylhsminor.yy896 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy701, &yymsp[0].minor.yy0, createFunctionNode(pCxt, &yymsp[-2].minor.yy701, NULL)); } yymsp[-2].minor.yy896 = yylhsminor.yy896; break; - case 524: /* star_func_para_list ::= NK_STAR */ + case 544: /* star_func_para_list ::= NK_STAR */ { yylhsminor.yy404 = createNodeList(pCxt, createColumnNode(pCxt, NULL, &yymsp[0].minor.yy0)); } yymsp[0].minor.yy404 = yylhsminor.yy404; break; - case 529: /* star_func_para ::= table_name NK_DOT NK_STAR */ - case 597: /* select_item ::= table_name NK_DOT NK_STAR */ yytestcase(yyruleno==597); + case 549: /* star_func_para ::= table_name NK_DOT NK_STAR */ + case 617: /* select_item ::= table_name NK_DOT NK_STAR */ yytestcase(yyruleno==617); { yylhsminor.yy896 = createColumnNode(pCxt, &yymsp[-2].minor.yy701, &yymsp[0].minor.yy0); } yymsp[-2].minor.yy896 = yylhsminor.yy896; break; - case 530: /* case_when_expression ::= CASE when_then_list case_when_else_opt END */ + case 550: /* case_when_expression ::= CASE when_then_list case_when_else_opt END */ { yylhsminor.yy896 = createRawExprNodeExt(pCxt, &yymsp[-3].minor.yy0, &yymsp[0].minor.yy0, createCaseWhenNode(pCxt, NULL, yymsp[-2].minor.yy404, yymsp[-1].minor.yy896)); } yymsp[-3].minor.yy896 = yylhsminor.yy896; break; - case 531: /* case_when_expression ::= CASE common_expression when_then_list case_when_else_opt END */ + case 551: /* case_when_expression ::= CASE common_expression when_then_list case_when_else_opt END */ { yylhsminor.yy896 = createRawExprNodeExt(pCxt, &yymsp[-4].minor.yy0, &yymsp[0].minor.yy0, createCaseWhenNode(pCxt, releaseRawExprNode(pCxt, yymsp[-3].minor.yy896), yymsp[-2].minor.yy404, yymsp[-1].minor.yy896)); } yymsp[-4].minor.yy896 = yylhsminor.yy896; break; - case 534: /* when_then_expr ::= WHEN common_expression THEN common_expression */ + case 554: /* when_then_expr ::= WHEN common_expression THEN common_expression */ { yymsp[-3].minor.yy896 = createWhenThenNode(pCxt, releaseRawExprNode(pCxt, yymsp[-2].minor.yy896), releaseRawExprNode(pCxt, yymsp[0].minor.yy896)); } break; - case 536: /* case_when_else_opt ::= ELSE common_expression */ + case 556: /* case_when_else_opt ::= ELSE common_expression */ { yymsp[-1].minor.yy896 = releaseRawExprNode(pCxt, yymsp[0].minor.yy896); } break; - case 537: /* predicate ::= expr_or_subquery compare_op expr_or_subquery */ - case 542: /* predicate ::= expr_or_subquery in_op in_predicate_value */ yytestcase(yyruleno==542); + case 557: /* predicate ::= expr_or_subquery compare_op expr_or_subquery */ + case 562: /* predicate ::= expr_or_subquery in_op in_predicate_value */ yytestcase(yyruleno==562); { SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy896); SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy896); @@ -6463,7 +6567,7 @@ static YYACTIONTYPE yy_reduce( } yymsp[-2].minor.yy896 = yylhsminor.yy896; break; - case 538: /* predicate ::= expr_or_subquery BETWEEN expr_or_subquery AND expr_or_subquery */ + case 558: /* predicate ::= expr_or_subquery BETWEEN expr_or_subquery AND expr_or_subquery */ { SToken s = getTokenFromRawExprNode(pCxt, yymsp[-4].minor.yy896); SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy896); @@ -6471,7 +6575,7 @@ static YYACTIONTYPE yy_reduce( } yymsp[-4].minor.yy896 = yylhsminor.yy896; break; - case 539: /* predicate ::= expr_or_subquery NOT BETWEEN expr_or_subquery AND expr_or_subquery */ + case 559: /* predicate ::= expr_or_subquery NOT BETWEEN expr_or_subquery AND expr_or_subquery */ { SToken s = getTokenFromRawExprNode(pCxt, yymsp[-5].minor.yy896); SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy896); @@ -6479,71 +6583,71 @@ static YYACTIONTYPE yy_reduce( } yymsp[-5].minor.yy896 = yylhsminor.yy896; break; - case 540: /* predicate ::= expr_or_subquery IS NULL */ + case 560: /* predicate ::= expr_or_subquery IS NULL */ { SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy896); yylhsminor.yy896 = createRawExprNodeExt(pCxt, &s, &yymsp[0].minor.yy0, createOperatorNode(pCxt, OP_TYPE_IS_NULL, releaseRawExprNode(pCxt, yymsp[-2].minor.yy896), NULL)); } yymsp[-2].minor.yy896 = yylhsminor.yy896; break; - case 541: /* predicate ::= expr_or_subquery IS NOT NULL */ + case 561: /* predicate ::= expr_or_subquery IS NOT NULL */ { SToken s = getTokenFromRawExprNode(pCxt, yymsp[-3].minor.yy896); yylhsminor.yy896 = createRawExprNodeExt(pCxt, &s, &yymsp[0].minor.yy0, createOperatorNode(pCxt, OP_TYPE_IS_NOT_NULL, releaseRawExprNode(pCxt, yymsp[-3].minor.yy896), NULL)); } yymsp[-3].minor.yy896 = yylhsminor.yy896; break; - case 543: /* compare_op ::= NK_LT */ + case 563: /* compare_op ::= NK_LT */ { yymsp[0].minor.yy884 = OP_TYPE_LOWER_THAN; } break; - case 544: /* compare_op ::= NK_GT */ + case 564: /* compare_op ::= NK_GT */ { yymsp[0].minor.yy884 = OP_TYPE_GREATER_THAN; } break; - case 545: /* compare_op ::= NK_LE */ + case 565: /* compare_op ::= NK_LE */ { yymsp[0].minor.yy884 = OP_TYPE_LOWER_EQUAL; } break; - case 546: /* compare_op ::= NK_GE */ + case 566: /* compare_op ::= NK_GE */ { yymsp[0].minor.yy884 = OP_TYPE_GREATER_EQUAL; } break; - case 547: /* compare_op ::= NK_NE */ + case 567: /* compare_op ::= NK_NE */ { yymsp[0].minor.yy884 = OP_TYPE_NOT_EQUAL; } break; - case 548: /* compare_op ::= NK_EQ */ + case 568: /* compare_op ::= NK_EQ */ { yymsp[0].minor.yy884 = OP_TYPE_EQUAL; } break; - case 549: /* compare_op ::= LIKE */ + case 569: /* compare_op ::= LIKE */ { yymsp[0].minor.yy884 = OP_TYPE_LIKE; } break; - case 550: /* compare_op ::= NOT LIKE */ + case 570: /* compare_op ::= NOT LIKE */ { yymsp[-1].minor.yy884 = OP_TYPE_NOT_LIKE; } break; - case 551: /* compare_op ::= MATCH */ + case 571: /* compare_op ::= MATCH */ { yymsp[0].minor.yy884 = OP_TYPE_MATCH; } break; - case 552: /* compare_op ::= NMATCH */ + case 572: /* compare_op ::= NMATCH */ { yymsp[0].minor.yy884 = OP_TYPE_NMATCH; } break; - case 553: /* compare_op ::= CONTAINS */ + case 573: /* compare_op ::= CONTAINS */ { yymsp[0].minor.yy884 = OP_TYPE_JSON_CONTAINS; } break; - case 554: /* in_op ::= IN */ + case 574: /* in_op ::= IN */ { yymsp[0].minor.yy884 = OP_TYPE_IN; } break; - case 555: /* in_op ::= NOT IN */ + case 575: /* in_op ::= NOT IN */ { yymsp[-1].minor.yy884 = OP_TYPE_NOT_IN; } break; - case 556: /* in_predicate_value ::= NK_LP literal_list NK_RP */ + case 576: /* in_predicate_value ::= NK_LP literal_list NK_RP */ { yylhsminor.yy896 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy0, &yymsp[0].minor.yy0, createNodeListNode(pCxt, yymsp[-1].minor.yy404)); } yymsp[-2].minor.yy896 = yylhsminor.yy896; break; - case 558: /* boolean_value_expression ::= NOT boolean_primary */ + case 578: /* boolean_value_expression ::= NOT boolean_primary */ { SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy896); yylhsminor.yy896 = createRawExprNodeExt(pCxt, &yymsp[-1].minor.yy0, &e, createLogicConditionNode(pCxt, LOGIC_COND_TYPE_NOT, releaseRawExprNode(pCxt, yymsp[0].minor.yy896), NULL)); } yymsp[-1].minor.yy896 = yylhsminor.yy896; break; - case 559: /* boolean_value_expression ::= boolean_value_expression OR boolean_value_expression */ + case 579: /* boolean_value_expression ::= boolean_value_expression OR boolean_value_expression */ { SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy896); SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy896); @@ -6551,7 +6655,7 @@ static YYACTIONTYPE yy_reduce( } yymsp[-2].minor.yy896 = yylhsminor.yy896; break; - case 560: /* boolean_value_expression ::= boolean_value_expression AND boolean_value_expression */ + case 580: /* boolean_value_expression ::= boolean_value_expression AND boolean_value_expression */ { SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy896); SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy896); @@ -6559,43 +6663,43 @@ static YYACTIONTYPE yy_reduce( } yymsp[-2].minor.yy896 = yylhsminor.yy896; break; - case 568: /* table_reference_list ::= table_reference_list NK_COMMA table_reference */ + case 588: /* table_reference_list ::= table_reference_list NK_COMMA table_reference */ { yylhsminor.yy896 = createJoinTableNode(pCxt, JOIN_TYPE_INNER, yymsp[-2].minor.yy896, yymsp[0].minor.yy896, NULL); } yymsp[-2].minor.yy896 = yylhsminor.yy896; break; - case 571: /* table_primary ::= table_name alias_opt */ + case 591: /* table_primary ::= table_name alias_opt */ { yylhsminor.yy896 = createRealTableNode(pCxt, NULL, &yymsp[-1].minor.yy701, &yymsp[0].minor.yy701); } yymsp[-1].minor.yy896 = yylhsminor.yy896; break; - case 572: /* table_primary ::= db_name NK_DOT table_name alias_opt */ + case 592: /* table_primary ::= db_name NK_DOT table_name alias_opt */ { yylhsminor.yy896 = createRealTableNode(pCxt, &yymsp[-3].minor.yy701, &yymsp[-1].minor.yy701, &yymsp[0].minor.yy701); } yymsp[-3].minor.yy896 = yylhsminor.yy896; break; - case 573: /* table_primary ::= subquery alias_opt */ + case 593: /* table_primary ::= subquery alias_opt */ { yylhsminor.yy896 = createTempTableNode(pCxt, releaseRawExprNode(pCxt, yymsp[-1].minor.yy896), &yymsp[0].minor.yy701); } yymsp[-1].minor.yy896 = yylhsminor.yy896; break; - case 575: /* alias_opt ::= */ + case 595: /* alias_opt ::= */ { yymsp[1].minor.yy701 = nil_token; } break; - case 577: /* alias_opt ::= AS table_alias */ + case 597: /* alias_opt ::= AS table_alias */ { yymsp[-1].minor.yy701 = yymsp[0].minor.yy701; } break; - case 578: /* parenthesized_joined_table ::= NK_LP joined_table NK_RP */ - case 579: /* parenthesized_joined_table ::= NK_LP parenthesized_joined_table NK_RP */ yytestcase(yyruleno==579); + case 598: /* parenthesized_joined_table ::= NK_LP joined_table NK_RP */ + case 599: /* parenthesized_joined_table ::= NK_LP parenthesized_joined_table NK_RP */ yytestcase(yyruleno==599); { yymsp[-2].minor.yy896 = yymsp[-1].minor.yy896; } break; - case 580: /* joined_table ::= table_reference join_type JOIN table_reference ON search_condition */ + case 600: /* joined_table ::= table_reference join_type JOIN table_reference ON search_condition */ { yylhsminor.yy896 = createJoinTableNode(pCxt, yymsp[-4].minor.yy680, yymsp[-5].minor.yy896, yymsp[-2].minor.yy896, yymsp[0].minor.yy896); } yymsp[-5].minor.yy896 = yylhsminor.yy896; break; - case 581: /* join_type ::= */ + case 601: /* join_type ::= */ { yymsp[1].minor.yy680 = JOIN_TYPE_INNER; } break; - case 582: /* join_type ::= INNER */ + case 602: /* join_type ::= INNER */ { yymsp[0].minor.yy680 = JOIN_TYPE_INNER; } break; - case 583: /* 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 */ + case 603: /* 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.yy896 = createSelectStmt(pCxt, yymsp[-11].minor.yy733, yymsp[-9].minor.yy404, yymsp[-8].minor.yy896, yymsp[-12].minor.yy404); yymsp[-13].minor.yy896 = setSelectStmtTagMode(pCxt, yymsp[-13].minor.yy896, yymsp[-10].minor.yy733); @@ -6609,98 +6713,98 @@ static YYACTIONTYPE yy_reduce( yymsp[-13].minor.yy896 = addFillClause(pCxt, yymsp[-13].minor.yy896, yymsp[-3].minor.yy896); } break; - case 584: /* hint_list ::= */ + case 604: /* hint_list ::= */ { yymsp[1].minor.yy404 = createHintNodeList(pCxt, NULL); } break; - case 585: /* hint_list ::= NK_HINT */ + case 605: /* hint_list ::= NK_HINT */ { yylhsminor.yy404 = createHintNodeList(pCxt, &yymsp[0].minor.yy0); } yymsp[0].minor.yy404 = yylhsminor.yy404; break; - case 590: /* set_quantifier_opt ::= ALL */ + case 610: /* set_quantifier_opt ::= ALL */ { yymsp[0].minor.yy733 = false; } break; - case 593: /* select_item ::= NK_STAR */ + case 613: /* select_item ::= NK_STAR */ { yylhsminor.yy896 = createColumnNode(pCxt, NULL, &yymsp[0].minor.yy0); } yymsp[0].minor.yy896 = yylhsminor.yy896; break; - case 595: /* select_item ::= common_expression column_alias */ - case 605: /* partition_item ::= expr_or_subquery column_alias */ yytestcase(yyruleno==605); + case 615: /* select_item ::= common_expression column_alias */ + case 625: /* partition_item ::= expr_or_subquery column_alias */ yytestcase(yyruleno==625); { yylhsminor.yy896 = setProjectionAlias(pCxt, releaseRawExprNode(pCxt, yymsp[-1].minor.yy896), &yymsp[0].minor.yy701); } yymsp[-1].minor.yy896 = yylhsminor.yy896; break; - case 596: /* select_item ::= common_expression AS column_alias */ - case 606: /* partition_item ::= expr_or_subquery AS column_alias */ yytestcase(yyruleno==606); + case 616: /* select_item ::= common_expression AS column_alias */ + case 626: /* partition_item ::= expr_or_subquery AS column_alias */ yytestcase(yyruleno==626); { yylhsminor.yy896 = setProjectionAlias(pCxt, releaseRawExprNode(pCxt, yymsp[-2].minor.yy896), &yymsp[0].minor.yy701); } yymsp[-2].minor.yy896 = yylhsminor.yy896; break; - case 601: /* partition_by_clause_opt ::= PARTITION BY partition_list */ - case 631: /* group_by_clause_opt ::= GROUP BY group_by_list */ yytestcase(yyruleno==631); - case 651: /* order_by_clause_opt ::= ORDER BY sort_specification_list */ yytestcase(yyruleno==651); + case 621: /* partition_by_clause_opt ::= PARTITION BY partition_list */ + case 651: /* group_by_clause_opt ::= GROUP BY group_by_list */ yytestcase(yyruleno==651); + case 671: /* order_by_clause_opt ::= ORDER BY sort_specification_list */ yytestcase(yyruleno==671); { yymsp[-2].minor.yy404 = yymsp[0].minor.yy404; } break; - case 608: /* twindow_clause_opt ::= SESSION NK_LP column_reference NK_COMMA interval_sliding_duration_literal NK_RP */ + case 628: /* twindow_clause_opt ::= SESSION NK_LP column_reference NK_COMMA interval_sliding_duration_literal NK_RP */ { yymsp[-5].minor.yy896 = createSessionWindowNode(pCxt, releaseRawExprNode(pCxt, yymsp[-3].minor.yy896), releaseRawExprNode(pCxt, yymsp[-1].minor.yy896)); } break; - case 609: /* twindow_clause_opt ::= STATE_WINDOW NK_LP expr_or_subquery NK_RP */ + case 629: /* twindow_clause_opt ::= STATE_WINDOW NK_LP expr_or_subquery NK_RP */ { yymsp[-3].minor.yy896 = createStateWindowNode(pCxt, releaseRawExprNode(pCxt, yymsp[-1].minor.yy896)); } break; - case 610: /* twindow_clause_opt ::= INTERVAL NK_LP interval_sliding_duration_literal NK_RP sliding_opt fill_opt */ + case 630: /* twindow_clause_opt ::= INTERVAL NK_LP interval_sliding_duration_literal NK_RP sliding_opt fill_opt */ { yymsp[-5].minor.yy896 = createIntervalWindowNode(pCxt, releaseRawExprNode(pCxt, yymsp[-3].minor.yy896), NULL, yymsp[-1].minor.yy896, yymsp[0].minor.yy896); } break; - case 611: /* twindow_clause_opt ::= INTERVAL NK_LP interval_sliding_duration_literal NK_COMMA interval_sliding_duration_literal NK_RP sliding_opt fill_opt */ + case 631: /* 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.yy896 = createIntervalWindowNode(pCxt, releaseRawExprNode(pCxt, yymsp[-5].minor.yy896), releaseRawExprNode(pCxt, yymsp[-3].minor.yy896), yymsp[-1].minor.yy896, yymsp[0].minor.yy896); } break; - case 612: /* twindow_clause_opt ::= EVENT_WINDOW START WITH search_condition END WITH search_condition */ + case 632: /* twindow_clause_opt ::= EVENT_WINDOW START WITH search_condition END WITH search_condition */ { yymsp[-6].minor.yy896 = createEventWindowNode(pCxt, yymsp[-3].minor.yy896, yymsp[0].minor.yy896); } break; - case 613: /* twindow_clause_opt ::= COUNT_WINDOW NK_LP NK_INTEGER NK_RP */ + case 633: /* twindow_clause_opt ::= COUNT_WINDOW NK_LP NK_INTEGER NK_RP */ { yymsp[-3].minor.yy896 = createCountWindowNode(pCxt, &yymsp[-1].minor.yy0, &yymsp[-1].minor.yy0); } break; - case 614: /* twindow_clause_opt ::= COUNT_WINDOW NK_LP NK_INTEGER NK_COMMA NK_INTEGER NK_RP */ + case 634: /* twindow_clause_opt ::= COUNT_WINDOW NK_LP NK_INTEGER NK_COMMA NK_INTEGER NK_RP */ { yymsp[-5].minor.yy896 = createCountWindowNode(pCxt, &yymsp[-3].minor.yy0, &yymsp[-1].minor.yy0); } break; - case 621: /* fill_opt ::= FILL NK_LP fill_mode NK_RP */ + case 641: /* fill_opt ::= FILL NK_LP fill_mode NK_RP */ { yymsp[-3].minor.yy896 = createFillNode(pCxt, yymsp[-1].minor.yy466, NULL); } break; - case 622: /* fill_opt ::= FILL NK_LP VALUE NK_COMMA expression_list NK_RP */ + case 642: /* fill_opt ::= FILL NK_LP VALUE NK_COMMA expression_list NK_RP */ { yymsp[-5].minor.yy896 = createFillNode(pCxt, FILL_MODE_VALUE, createNodeListNode(pCxt, yymsp[-1].minor.yy404)); } break; - case 623: /* fill_opt ::= FILL NK_LP VALUE_F NK_COMMA expression_list NK_RP */ + case 643: /* fill_opt ::= FILL NK_LP VALUE_F NK_COMMA expression_list NK_RP */ { yymsp[-5].minor.yy896 = createFillNode(pCxt, FILL_MODE_VALUE_F, createNodeListNode(pCxt, yymsp[-1].minor.yy404)); } break; - case 624: /* fill_mode ::= NONE */ + case 644: /* fill_mode ::= NONE */ { yymsp[0].minor.yy466 = FILL_MODE_NONE; } break; - case 625: /* fill_mode ::= PREV */ + case 645: /* fill_mode ::= PREV */ { yymsp[0].minor.yy466 = FILL_MODE_PREV; } break; - case 626: /* fill_mode ::= NULL */ + case 646: /* fill_mode ::= NULL */ { yymsp[0].minor.yy466 = FILL_MODE_NULL; } break; - case 627: /* fill_mode ::= NULL_F */ + case 647: /* fill_mode ::= NULL_F */ { yymsp[0].minor.yy466 = FILL_MODE_NULL_F; } break; - case 628: /* fill_mode ::= LINEAR */ + case 648: /* fill_mode ::= LINEAR */ { yymsp[0].minor.yy466 = FILL_MODE_LINEAR; } break; - case 629: /* fill_mode ::= NEXT */ + case 649: /* fill_mode ::= NEXT */ { yymsp[0].minor.yy466 = FILL_MODE_NEXT; } break; - case 632: /* group_by_list ::= expr_or_subquery */ + case 652: /* group_by_list ::= expr_or_subquery */ { yylhsminor.yy404 = createNodeList(pCxt, createGroupingSetNode(pCxt, releaseRawExprNode(pCxt, yymsp[0].minor.yy896))); } yymsp[0].minor.yy404 = yylhsminor.yy404; break; - case 633: /* group_by_list ::= group_by_list NK_COMMA expr_or_subquery */ + case 653: /* group_by_list ::= group_by_list NK_COMMA expr_or_subquery */ { yylhsminor.yy404 = addNodeToList(pCxt, yymsp[-2].minor.yy404, createGroupingSetNode(pCxt, releaseRawExprNode(pCxt, yymsp[0].minor.yy896))); } yymsp[-2].minor.yy404 = yylhsminor.yy404; break; - case 637: /* range_opt ::= RANGE NK_LP expr_or_subquery NK_COMMA expr_or_subquery NK_RP */ + case 657: /* range_opt ::= RANGE NK_LP expr_or_subquery NK_COMMA expr_or_subquery NK_RP */ { yymsp[-5].minor.yy896 = createInterpTimeRange(pCxt, releaseRawExprNode(pCxt, yymsp[-3].minor.yy896), releaseRawExprNode(pCxt, yymsp[-1].minor.yy896)); } break; - case 638: /* range_opt ::= RANGE NK_LP expr_or_subquery NK_RP */ + case 658: /* range_opt ::= RANGE NK_LP expr_or_subquery NK_RP */ { yymsp[-3].minor.yy896 = createInterpTimePoint(pCxt, releaseRawExprNode(pCxt, yymsp[-1].minor.yy896)); } break; - case 641: /* query_expression ::= query_simple order_by_clause_opt slimit_clause_opt limit_clause_opt */ + case 661: /* query_expression ::= query_simple order_by_clause_opt slimit_clause_opt limit_clause_opt */ { yylhsminor.yy896 = addOrderByClause(pCxt, yymsp[-3].minor.yy896, yymsp[-2].minor.yy404); yylhsminor.yy896 = addSlimitClause(pCxt, yylhsminor.yy896, yymsp[-1].minor.yy896); @@ -6708,50 +6812,50 @@ static YYACTIONTYPE yy_reduce( } yymsp[-3].minor.yy896 = yylhsminor.yy896; break; - case 644: /* union_query_expression ::= query_simple_or_subquery UNION ALL query_simple_or_subquery */ + case 664: /* union_query_expression ::= query_simple_or_subquery UNION ALL query_simple_or_subquery */ { yylhsminor.yy896 = createSetOperator(pCxt, SET_OP_TYPE_UNION_ALL, yymsp[-3].minor.yy896, yymsp[0].minor.yy896); } yymsp[-3].minor.yy896 = yylhsminor.yy896; break; - case 645: /* union_query_expression ::= query_simple_or_subquery UNION query_simple_or_subquery */ + case 665: /* union_query_expression ::= query_simple_or_subquery UNION query_simple_or_subquery */ { yylhsminor.yy896 = createSetOperator(pCxt, SET_OP_TYPE_UNION, yymsp[-2].minor.yy896, yymsp[0].minor.yy896); } yymsp[-2].minor.yy896 = yylhsminor.yy896; break; - case 653: /* slimit_clause_opt ::= SLIMIT NK_INTEGER */ - case 657: /* limit_clause_opt ::= LIMIT NK_INTEGER */ yytestcase(yyruleno==657); + case 673: /* slimit_clause_opt ::= SLIMIT NK_INTEGER */ + case 677: /* limit_clause_opt ::= LIMIT NK_INTEGER */ yytestcase(yyruleno==677); { yymsp[-1].minor.yy896 = createLimitNode(pCxt, &yymsp[0].minor.yy0, NULL); } break; - case 654: /* slimit_clause_opt ::= SLIMIT NK_INTEGER SOFFSET NK_INTEGER */ - case 658: /* limit_clause_opt ::= LIMIT NK_INTEGER OFFSET NK_INTEGER */ yytestcase(yyruleno==658); + case 674: /* slimit_clause_opt ::= SLIMIT NK_INTEGER SOFFSET NK_INTEGER */ + case 678: /* limit_clause_opt ::= LIMIT NK_INTEGER OFFSET NK_INTEGER */ yytestcase(yyruleno==678); { yymsp[-3].minor.yy896 = createLimitNode(pCxt, &yymsp[-2].minor.yy0, &yymsp[0].minor.yy0); } break; - case 655: /* slimit_clause_opt ::= SLIMIT NK_INTEGER NK_COMMA NK_INTEGER */ - case 659: /* limit_clause_opt ::= LIMIT NK_INTEGER NK_COMMA NK_INTEGER */ yytestcase(yyruleno==659); + case 675: /* slimit_clause_opt ::= SLIMIT NK_INTEGER NK_COMMA NK_INTEGER */ + case 679: /* limit_clause_opt ::= LIMIT NK_INTEGER NK_COMMA NK_INTEGER */ yytestcase(yyruleno==679); { yymsp[-3].minor.yy896 = createLimitNode(pCxt, &yymsp[0].minor.yy0, &yymsp[-2].minor.yy0); } break; - case 660: /* subquery ::= NK_LP query_expression NK_RP */ + case 680: /* subquery ::= NK_LP query_expression NK_RP */ { yylhsminor.yy896 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy0, &yymsp[0].minor.yy0, yymsp[-1].minor.yy896); } yymsp[-2].minor.yy896 = yylhsminor.yy896; break; - case 665: /* sort_specification ::= expr_or_subquery ordering_specification_opt null_ordering_opt */ + case 685: /* sort_specification ::= expr_or_subquery ordering_specification_opt null_ordering_opt */ { yylhsminor.yy896 = createOrderByExprNode(pCxt, releaseRawExprNode(pCxt, yymsp[-2].minor.yy896), yymsp[-1].minor.yy918, yymsp[0].minor.yy669); } yymsp[-2].minor.yy896 = yylhsminor.yy896; break; - case 666: /* ordering_specification_opt ::= */ + case 686: /* ordering_specification_opt ::= */ { yymsp[1].minor.yy918 = ORDER_ASC; } break; - case 667: /* ordering_specification_opt ::= ASC */ + case 687: /* ordering_specification_opt ::= ASC */ { yymsp[0].minor.yy918 = ORDER_ASC; } break; - case 668: /* ordering_specification_opt ::= DESC */ + case 688: /* ordering_specification_opt ::= DESC */ { yymsp[0].minor.yy918 = ORDER_DESC; } break; - case 669: /* null_ordering_opt ::= */ + case 689: /* null_ordering_opt ::= */ { yymsp[1].minor.yy669 = NULL_ORDER_DEFAULT; } break; - case 670: /* null_ordering_opt ::= NULLS FIRST */ + case 690: /* null_ordering_opt ::= NULLS FIRST */ { yymsp[-1].minor.yy669 = NULL_ORDER_FIRST; } break; - case 671: /* null_ordering_opt ::= NULLS LAST */ + case 691: /* null_ordering_opt ::= NULLS LAST */ { yymsp[-1].minor.yy669 = NULL_ORDER_LAST; } break; default: diff --git a/source/libs/stream/src/streamCheckpoint.c b/source/libs/stream/src/streamCheckpoint.c index f58c72eded..7f52c5d2f0 100644 --- a/source/libs/stream/src/streamCheckpoint.c +++ b/source/libs/stream/src/streamCheckpoint.c @@ -278,6 +278,7 @@ void streamTaskClearCheckInfo(SStreamTask* pTask, bool clearChkpReadyMsg) { pTask->chkInfo.numOfNotReady = 0; pTask->chkInfo.transId = 0; pTask->chkInfo.dispatchCheckpointTrigger = false; + pTask->chkInfo.downstreamAlignNum = 0; streamTaskOpenAllUpstreamInput(pTask); // open inputQ for all upstream tasks if (clearChkpReadyMsg) { diff --git a/source/libs/stream/src/streamDispatch.c b/source/libs/stream/src/streamDispatch.c index 0af664f1e1..9542009d72 100644 --- a/source/libs/stream/src/streamDispatch.c +++ b/source/libs/stream/src/streamDispatch.c @@ -580,12 +580,15 @@ int32_t streamSearchAndAddBlock(SStreamTask* pTask, SStreamDispatchReq* pReqs, S } else { char ctbName[TSDB_TABLE_FNAME_LEN] = {0}; if (pDataBlock->info.parTbName[0]) { - if(pTask->ver >= SSTREAM_TASK_SUBTABLE_CHANGED_VER && - pTask->subtableWithoutMd5 != 1 && + if(pTask->subtableWithoutMd5 != 1 && !isAutoTableName(pDataBlock->info.parTbName) && !alreadyAddGroupId(pDataBlock->info.parTbName) && groupId != 0){ - buildCtbNameAddGroupId(pDataBlock->info.parTbName, groupId); + if(pTask->ver == SSTREAM_TASK_SUBTABLE_CHANGED_VER){ + buildCtbNameAddGroupId(NULL, pDataBlock->info.parTbName, groupId); + }else if(pTask->ver > SSTREAM_TASK_SUBTABLE_CHANGED_VER) { + buildCtbNameAddGroupId(pTask->outputInfo.shuffleDispatcher.stbFullName, pDataBlock->info.parTbName, groupId); + } } } else { buildCtbNameByGroupIdImpl(pTask->outputInfo.shuffleDispatcher.stbFullName, groupId, pDataBlock->info.parTbName); diff --git a/source/libs/stream/src/streamMeta.c b/source/libs/stream/src/streamMeta.c index 5f6440c06d..aae3594905 100644 --- a/source/libs/stream/src/streamMeta.c +++ b/source/libs/stream/src/streamMeta.c @@ -542,7 +542,6 @@ int32_t streamMetaSaveTask(SStreamMeta* pMeta, SStreamTask* pTask) { void* buf = NULL; int32_t len; int32_t code; - pTask->ver = SSTREAM_TASK_VER; tEncodeSize(tEncodeStreamTask, pTask, len, code); if (code < 0) { return -1; @@ -552,6 +551,9 @@ int32_t streamMetaSaveTask(SStreamMeta* pMeta, SStreamTask* pTask) { return -1; } + if (pTask->ver < SSTREAM_TASK_SUBTABLE_CHANGED_VER){ + pTask->ver = SSTREAM_TASK_VER; + } SEncoder encoder = {0}; tEncoderInit(&encoder, buf, len); tEncodeStreamTask(&encoder, pTask); @@ -648,14 +650,17 @@ SStreamTask* streamMetaAcquireOneTask(SStreamTask* pTask) { } void streamMetaReleaseTask(SStreamMeta* UNUSED_PARAM(pMeta), SStreamTask* pTask) { + int32_t taskId = pTask->id.taskId; int32_t ref = atomic_sub_fetch_32(&pTask->refCnt, 1); + + // not safe to use the pTask->id.idStr, since pTask may be released by other threads when print logs. if (ref > 0) { - stTrace("s-task:%s release task, ref:%d", pTask->id.idStr, ref); + stTrace("s-task:0x%x release task, ref:%d", taskId, ref); } else if (ref == 0) { - stTrace("s-task:%s all refs are gone, free it", pTask->id.idStr); + stTrace("s-task:0x%x all refs are gone, free it", taskId); tFreeStreamTask(pTask); } else if (ref < 0) { - stError("task ref is invalid, ref:%d, %s", ref, pTask->id.idStr); + stError("task ref is invalid, ref:%d, 0x%x", ref, taskId); } } @@ -824,13 +829,6 @@ int64_t streamMetaGetLatestCheckpointId(SStreamMeta* pMeta) { return chkpId; } -static void doClear(void* pKey, void* pVal, TBC* pCur, SArray* pRecycleList) { - tdbFree(pKey); - tdbFree(pVal); - tdbTbcClose(pCur); - taosArrayDestroy(pRecycleList); -} - int32_t streamMetaLoadAllTasks(SStreamMeta* pMeta) { TBC* pCur = NULL; void* pKey = NULL; @@ -847,10 +845,11 @@ int32_t streamMetaLoadAllTasks(SStreamMeta* pMeta) { int32_t vgId = pMeta->vgId; stInfo("vgId:%d load stream tasks from meta files", vgId); - if (tdbTbcOpen(pMeta->pTaskDb, &pCur, NULL) < 0) { - stError("vgId:%d failed to open stream meta, code:%s", vgId, tstrerror(terrno)); + int32_t code = tdbTbcOpen(pMeta->pTaskDb, &pCur, NULL); + if (code != TSDB_CODE_SUCCESS) { + stError("vgId:%d failed to open stream meta, code:%s, not load any stream tasks", vgId, tstrerror(terrno)); taosArrayDestroy(pRecycleList); - return -1; + return TSDB_CODE_SUCCESS; } tdbTbcMoveToFirst(pCur); @@ -859,20 +858,18 @@ int32_t streamMetaLoadAllTasks(SStreamMeta* pMeta) { if (pTask == NULL) { terrno = TSDB_CODE_OUT_OF_MEMORY; stError("vgId:%d failed to load stream task from meta-files, code:%s", vgId, tstrerror(terrno)); - doClear(pKey, pVal, pCur, pRecycleList); - return -1; + break; } tDecoderInit(&decoder, (uint8_t*)pVal, vLen); if (tDecodeStreamTask(&decoder, pTask) < 0) { tDecoderClear(&decoder); - doClear(pKey, pVal, pCur, pRecycleList); tFreeStreamTask(pTask); stError( "vgId:%d stream read incompatible data, rm %s/vnode/vnode*/tq/stream if taosd cannot start, and rebuild " "stream manually", vgId, tsDataDir); - return -1; + break; } tDecoderClear(&decoder); @@ -892,10 +889,11 @@ int32_t streamMetaLoadAllTasks(SStreamMeta* pMeta) { STaskId id = {.streamId = pTask->id.streamId, .taskId = pTask->id.taskId}; void* p = taosHashGet(pMeta->pTasksMap, &id, sizeof(id)); if (p == NULL) { - if (pMeta->expandFunc(pMeta->ahandle, pTask, pTask->chkInfo.checkpointVer + 1) < 0) { - doClear(pKey, pVal, pCur, pRecycleList); + code = pMeta->expandFunc(pMeta->ahandle, pTask, pTask->chkInfo.checkpointVer + 1); + if (code < 0) { + stError("failed to expand s-task:0x%"PRIx64", code:%s, continue", id.taskId, tstrerror(terrno)); tFreeStreamTask(pTask); - return -1; + continue; } taosArrayPush(pMeta->pTaskList, &pTask->id); @@ -907,9 +905,10 @@ int32_t streamMetaLoadAllTasks(SStreamMeta* pMeta) { } if (taosHashPut(pMeta->pTasksMap, &id, sizeof(id), &pTask, POINTER_BYTES) < 0) { - doClear(pKey, pVal, pCur, pRecycleList); + stError("s-task:0x%x failed to put into hashTable, code:%s, continue", pTask->id.taskId, tstrerror(terrno)); + taosArrayPop(pMeta->pTaskList); tFreeStreamTask(pTask); - return -1; + continue; } if (pTask->info.fillHistory == 0) { @@ -925,10 +924,9 @@ int32_t streamMetaLoadAllTasks(SStreamMeta* pMeta) { tdbFree(pKey); tdbFree(pVal); + if (tdbTbcClose(pCur) < 0) { - stError("vgId:%d failed to close meta-file cursor", vgId); - taosArrayDestroy(pRecycleList); - return -1; + stError("vgId:%d failed to close meta-file cursor, code:%s, continue", vgId, tstrerror(terrno)); } if (taosArrayGetSize(pRecycleList) > 0) { @@ -942,8 +940,9 @@ int32_t streamMetaLoadAllTasks(SStreamMeta* pMeta) { ASSERT(pMeta->numOfStreamTasks <= numOfTasks && pMeta->numOfPausedTasks <= numOfTasks); stDebug("vgId:%d load %d tasks into meta from disk completed, streamTask:%d, paused:%d", pMeta->vgId, numOfTasks, pMeta->numOfStreamTasks, pMeta->numOfPausedTasks); + taosArrayDestroy(pRecycleList); - return 0; + return TSDB_CODE_SUCCESS; } int32_t tEncodeStreamHbMsg(SEncoder* pEncoder, const SStreamHbMsg* pReq) { diff --git a/source/libs/stream/src/streamTask.c b/source/libs/stream/src/streamTask.c index 4ca784a32f..c7a1a00a46 100644 --- a/source/libs/stream/src/streamTask.c +++ b/source/libs/stream/src/streamTask.c @@ -216,7 +216,7 @@ int32_t tDecodeStreamTask(SDecoder* pDecoder, SStreamTask* pTask) { if (tStartDecode(pDecoder) < 0) return -1; if (tDecodeI64(pDecoder, &pTask->ver) < 0) return -1; - if (pTask->ver <= SSTREAM_TASK_INCOMPATIBLE_VER) return -1; + if (pTask->ver <= SSTREAM_TASK_INCOMPATIBLE_VER || pTask->ver > SSTREAM_TASK_VER) return -1; if (tDecodeI64(pDecoder, &pTask->id.streamId) < 0) return -1; if (tDecodeI32(pDecoder, &pTask->id.taskId) < 0) return -1; @@ -287,7 +287,9 @@ int32_t tDecodeStreamTask(SDecoder* pDecoder, SStreamTask* pTask) { if (tDecodeCStrTo(pDecoder, pTask->outputInfo.shuffleDispatcher.stbFullName) < 0) return -1; } if (tDecodeI64(pDecoder, &pTask->info.triggerParam) < 0) return -1; - if (tDecodeI8(pDecoder, &pTask->subtableWithoutMd5) < 0) return -1; + if (pTask->ver >= SSTREAM_TASK_SUBTABLE_CHANGED_VER){ + if (tDecodeI8(pDecoder, &pTask->subtableWithoutMd5) < 0) return -1; + } if (tDecodeCStrTo(pDecoder, pTask->reserve) < 0) return -1; tEndDecode(pDecoder); diff --git a/source/libs/sync/src/syncPipeline.c b/source/libs/sync/src/syncPipeline.c index d40fff447f..3543ed574c 100644 --- a/source/libs/sync/src/syncPipeline.c +++ b/source/libs/sync/src/syncPipeline.c @@ -866,9 +866,14 @@ int32_t syncLogReplRecover(SSyncLogReplMgr* pMgr, SSyncNode* pNode, SyncAppendEn SyncTerm term = -1; SyncIndex firstVer = pNode->pLogStore->syncLogBeginIndex(pNode->pLogStore); SyncIndex index = TMIN(pMsg->matchIndex, pNode->pLogBuf->matchIndex); + errno = 0; if (pMsg->matchIndex < pNode->pLogBuf->matchIndex) { term = syncLogReplGetPrevLogTerm(pMgr, pNode, index + 1); + if (term < 0 && (errno == ENFILE || errno == EMFILE)) { + sError("vgId:%d, failed to get prev log term since %s. index:%" PRId64, pNode->vgId, terrstr(), index + 1); + return -1; + } if ((index + 1 < firstVer) || (term < 0) || (term != pMsg->lastMatchTerm && (index + 1 == firstVer || index == firstVer))) { ASSERT(term >= 0 || terrno == TSDB_CODE_WAL_LOG_NOT_EXIST); diff --git a/source/libs/transport/src/transCli.c b/source/libs/transport/src/transCli.c index ac45f1eef6..2d8f4ed3c2 100644 --- a/source/libs/transport/src/transCli.c +++ b/source/libs/transport/src/transCli.c @@ -585,11 +585,12 @@ void* destroyConnPool(SCliThrd* pThrd) { static SCliConn* getConnFromPool(SCliThrd* pThrd, char* key, bool* exceed) { void* pool = pThrd->pool; STrans* pTranInst = pThrd->pTransInst; - SConnList* plist = taosHashGet((SHashObj*)pool, key, strlen(key) + 1); + size_t klen = strlen(key); + SConnList* plist = taosHashGet((SHashObj*)pool, key, klen); if (plist == NULL) { SConnList list = {0}; - taosHashPut((SHashObj*)pool, key, strlen(key) + 1, (void*)&list, sizeof(list)); - plist = taosHashGet(pool, key, strlen(key) + 1); + taosHashPut((SHashObj*)pool, key, klen, (void*)&list, sizeof(list)); + plist = taosHashGet(pool, key, klen); SMsgList* nList = taosMemoryCalloc(1, sizeof(SMsgList)); QUEUE_INIT(&nList->msgQ); @@ -624,11 +625,12 @@ static SCliConn* getConnFromPool(SCliThrd* pThrd, char* key, bool* exceed) { static SCliConn* getConnFromPool2(SCliThrd* pThrd, char* key, SCliMsg** pMsg) { void* pool = pThrd->pool; STrans* pTransInst = pThrd->pTransInst; - SConnList* plist = taosHashGet((SHashObj*)pool, key, strlen(key) + 1); + size_t klen = strlen(key); + SConnList* plist = taosHashGet((SHashObj*)pool, key, klen); if (plist == NULL) { SConnList list = {0}; - taosHashPut((SHashObj*)pool, key, strlen(key) + 1, (void*)&list, sizeof(list)); - plist = taosHashGet(pool, key, strlen(key) + 1); + taosHashPut((SHashObj*)pool, key, klen, (void*)&list, sizeof(list)); + plist = taosHashGet(pool, key, klen); SMsgList* nList = taosMemoryCalloc(1, sizeof(SMsgList)); QUEUE_INIT(&nList->msgQ); @@ -714,7 +716,7 @@ static void addConnToPool(void* pool, SCliConn* conn) { cliDestroyConnMsgs(conn, false); if (conn->list == NULL) { - conn->list = taosHashGet((SHashObj*)pool, conn->dstAddr, strlen(conn->dstAddr) + 1); + conn->list = taosHashGet((SHashObj*)pool, conn->dstAddr, strlen(conn->dstAddr)); } SConnList* pList = conn->list; @@ -1279,7 +1281,7 @@ static void cliHandleFastFail(SCliConn* pConn, int status) { if (pMsg != NULL && REQUEST_NO_RESP(&pMsg->msg) && (pTransInst->failFastFp != NULL && pTransInst->failFastFp(pMsg->msg.msgType))) { - SFailFastItem* item = taosHashGet(pThrd->failFastCache, pConn->dstAddr, strlen(pConn->dstAddr) + 1); + SFailFastItem* item = taosHashGet(pThrd->failFastCache, pConn->dstAddr, strlen(pConn->dstAddr)); int64_t cTimestamp = taosGetTimestampMs(); if (item != NULL) { int32_t elapse = cTimestamp - item->timestamp; @@ -1291,7 +1293,7 @@ static void cliHandleFastFail(SCliConn* pConn, int status) { } } else { SFailFastItem item = {.count = 1, .timestamp = cTimestamp}; - taosHashPut(pThrd->failFastCache, pConn->dstAddr, strlen(pConn->dstAddr) + 1, &item, sizeof(SFailFastItem)); + taosHashPut(pThrd->failFastCache, pConn->dstAddr, strlen(pConn->dstAddr), &item, sizeof(SFailFastItem)); } } } else { @@ -1471,7 +1473,8 @@ FORCE_INLINE int32_t cliBuildExceptResp(SCliMsg* pMsg, STransMsg* pResp) { } static FORCE_INLINE uint32_t cliGetIpFromFqdnCache(SHashObj* cache, char* fqdn) { uint32_t addr = 0; - uint32_t* v = taosHashGet(cache, fqdn, strlen(fqdn) + 1); + size_t len = strlen(fqdn); + uint32_t* v = taosHashGet(cache, fqdn, len); if (v == NULL) { addr = taosGetIpv4FromFqdn(fqdn); if (addr == 0xffffffff) { @@ -1480,7 +1483,7 @@ static FORCE_INLINE uint32_t cliGetIpFromFqdnCache(SHashObj* cache, char* fqdn) return addr; } - taosHashPut(cache, fqdn, strlen(fqdn) + 1, &addr, sizeof(addr)); + taosHashPut(cache, fqdn, len, &addr, sizeof(addr)); } else { addr = *v; } @@ -1490,13 +1493,14 @@ static FORCE_INLINE void cliUpdateFqdnCache(SHashObj* cache, char* fqdn) { // impl later uint32_t addr = taosGetIpv4FromFqdn(fqdn); if (addr != 0xffffffff) { - uint32_t* v = taosHashGet(cache, fqdn, strlen(fqdn) + 1); + size_t len = strlen(fqdn); + uint32_t* v = taosHashGet(cache, fqdn, len); if (addr != *v) { char old[64] = {0}, new[64] = {0}; tinet_ntoa(old, *v); tinet_ntoa(new, addr); tWarn("update ip of fqdn:%s, old: %s, new: %s", fqdn, old, new); - taosHashPut(cache, fqdn, strlen(fqdn) + 1, &addr, sizeof(addr)); + taosHashPut(cache, fqdn, len, &addr, sizeof(addr)); } } return; @@ -1537,21 +1541,6 @@ void cliHandleReq(SCliMsg* pMsg, SCliThrd* pThrd) { return; } - if (rpcDebugFlag & DEBUG_TRACE) { - if (tmsgIsValid(pMsg->msg.msgType)) { - char buf[128] = {0}; - sprintf(buf, "%s", TMSG_INFO(pMsg->msg.msgType)); - int* count = taosHashGet(pThrd->msgCount, buf, sizeof(buf)); - if (NULL == 0) { - int localCount = 1; - taosHashPut(pThrd->msgCount, buf, sizeof(buf), &localCount, sizeof(localCount)); - } else { - int localCount = *count + 1; - taosHashPut(pThrd->msgCount, buf, sizeof(buf), &localCount, sizeof(localCount)); - } - } - } - char* fqdn = EPSET_GET_INUSE_IP(&pMsg->ctx->epSet); uint16_t port = EPSET_GET_INUSE_PORT(&pMsg->ctx->epSet); char addr[TSDB_FQDN_LEN + 64] = {0}; @@ -1704,9 +1693,8 @@ static void cliBatchDealReq(queue* wq, SCliThrd* pThrd) { uint32_t port = EPSET_GET_INUSE_PORT(&pCtx->epSet); char key[TSDB_FQDN_LEN + 64] = {0}; CONN_CONSTRUCT_HASH_KEY(key, ip, port); - - // SCliBatch** ppBatch = taosHashGet(pThrd->batchCache, key, sizeof(key)); - SCliBatchList** ppBatchList = taosHashGet(pThrd->batchCache, key, sizeof(key)); + size_t klen = strlen(key); + SCliBatchList** ppBatchList = taosHashGet(pThrd->batchCache, key, klen); if (ppBatchList == NULL || *ppBatchList == NULL) { SCliBatchList* pBatchList = taosMemoryCalloc(1, sizeof(SCliBatchList)); QUEUE_INIT(&pBatchList->wq); @@ -1730,7 +1718,7 @@ static void cliBatchDealReq(queue* wq, SCliThrd* pThrd) { QUEUE_PUSH(&pBatchList->wq, &pBatch->listq); - taosHashPut(pThrd->batchCache, key, sizeof(key), &pBatchList, sizeof(void*)); + taosHashPut(pThrd->batchCache, key, klen, &pBatchList, sizeof(void*)); } else { if (QUEUE_IS_EMPTY(&(*ppBatchList)->wq)) { SCliBatch* pBatch = taosMemoryCalloc(1, sizeof(SCliBatch)); @@ -1800,21 +1788,6 @@ static void cliAsyncCb(uv_async_t* handle) { QUEUE_MOVE(&item->qmsg, &wq); taosThreadMutexUnlock(&item->mtx); - if (rpcDebugFlag & DEBUG_TRACE) { - void* pIter = taosHashIterate(pThrd->msgCount, NULL); - while (pIter != NULL) { - int* count = pIter; - size_t len = 0; - char* key = taosHashGetKey(pIter, &len); - if (*count != 0) { - tDebug("key: %s count: %d", key, *count); - } - - pIter = taosHashIterate(pThrd->msgCount, pIter); - } - tDebug("all conn count: %d", pThrd->newConnCount); - } - int8_t supportBatch = pTransInst->supportBatch; if (supportBatch == 0) { cliNoBatchDealReq(&wq, pThrd); @@ -1971,8 +1944,9 @@ static FORCE_INLINE void destroyCmsgWrapper(void* arg, void* param) { if (pMsg == NULL) { return; } - if (param != NULL) { - SCliThrd* pThrd = param; + + SCliThrd* pThrd = param; + if (pMsg->msg.info.notFreeAhandle == 0 && pThrd != NULL) { if (pThrd->destroyAhandleFp) (*pThrd->destroyAhandleFp)(pMsg->msg.info.ahandle); } destroyCmsg(pMsg); @@ -1984,12 +1958,9 @@ static FORCE_INLINE void destroyCmsgAndAhandle(void* param) { SCliMsg* pMsg = arg->param1; SCliThrd* pThrd = arg->param2; - tDebug("destroy Ahandle A"); - if (pThrd != NULL && pThrd->destroyAhandleFp != NULL) { - tDebug("destroy Ahandle B"); + if (pMsg->msg.info.notFreeAhandle == 0 && pThrd != NULL && pThrd->destroyAhandleFp != NULL) { pThrd->destroyAhandleFp(pMsg->ctx->ahandle); } - tDebug("destroy Ahandle C"); transDestroyConnCtx(pMsg->ctx); transFreeMsg(pMsg->msg.pCont); @@ -2411,20 +2382,6 @@ int cliAppCb(SCliConn* pConn, STransMsg* pResp, SCliMsg* pMsg) { tGTrace("%s conn %p extract epset from msg", CONN_GET_INST_LABEL(pConn), pConn); } } - if (rpcDebugFlag & DEBUG_TRACE) { - if (tmsgIsValid(pResp->msgType - 1)) { - char buf[128] = {0}; - sprintf(buf, "%s", TMSG_INFO(pResp->msgType - 1)); - int* count = taosHashGet(pThrd->msgCount, buf, sizeof(buf)); - if (NULL == 0) { - int localCount = 0; - taosHashPut(pThrd->msgCount, buf, sizeof(buf), &localCount, sizeof(localCount)); - } else { - int localCount = *count - 1; - taosHashPut(pThrd->msgCount, buf, sizeof(buf), &localCount, sizeof(localCount)); - } - } - } if (pCtx->pSem || pCtx->syncMsgRef != 0) { tGTrace("%s conn %p(sync) handle resp", CONN_GET_INST_LABEL(pConn), pConn); if (pCtx->pSem) { diff --git a/source/util/src/tworker.c b/source/util/src/tworker.c index 138d4bc1f4..0712010458 100644 --- a/source/util/src/tworker.c +++ b/source/util/src/tworker.c @@ -19,7 +19,7 @@ #include "tgeosctx.h" #include "tlog.h" -#define QUEUE_THRESHOLD 1000 * 1000 +#define QUEUE_THRESHOLD (1000 * 1000) typedef void *(*ThreadFp)(void *param); diff --git a/tests/script/tsim/parser/columnValue_bool.sim b/tests/script/tsim/parser/columnValue_bool.sim index db89db4256..97d074a6f9 100644 --- a/tests/script/tsim/parser/columnValue_bool.sim +++ b/tests/script/tsim/parser/columnValue_bool.sim @@ -936,6 +936,9 @@ sql_error alter table st_bool_i1 set tag tagname="123abc" sql alter table st_bool_i2 set tag tagname="123" sql_error alter table st_bool_i3 set tag tagname=abc sql_error alter table st_bool_i4 set tag tagname="abc" +sql_error alter table st_bool_i4 set tag tagname=now +sql_error alter table st_bool_i4 set tag tagname=now()+1d +sql_error alter table st_bool_i4 set tag tagname=1+1d sql_error alter table st_bool_i5 set tag tagname=" " sql_error alter table st_bool_i6 set tag tagname='' diff --git a/tests/script/tsim/parser/columnValue_int.sim b/tests/script/tsim/parser/columnValue_int.sim index f03a576ae3..f022c33363 100644 --- a/tests/script/tsim/parser/columnValue_int.sim +++ b/tests/script/tsim/parser/columnValue_int.sim @@ -913,6 +913,8 @@ sql_error alter table st_int_e19 set tag tagname=123abc sql_error alter table st_int_e20 set tag tagname="123abc" sql_error alter table st_int_e22 set tag tagname=abc sql_error alter table st_int_e23 set tag tagname="abc" +sql_error alter table st_int_e25 set tag tagname=1+1d +sql_error alter table st_int_e25 set tag tagname="1"+1d sql_error alter table st_int_e24 set tag tagname=" " sql_error alter table st_int_e25 set tag tagname='' sql alter table st_int_e26_1 set tag tagname='123' diff --git a/tests/script/tsim/parser/columnValue_timestamp.sim b/tests/script/tsim/parser/columnValue_timestamp.sim index 1f457dbd7c..4334230a05 100644 --- a/tests/script/tsim/parser/columnValue_timestamp.sim +++ b/tests/script/tsim/parser/columnValue_timestamp.sim @@ -132,6 +132,77 @@ sql show tags from st_timestamp_22 if $data05 != -1 then return -1 endi +sql create table st_timestamp_23 using mt_timestamp tags (1+ 1d ) +sql show tags from st_timestamp_23 +if $data05 != 86400001 then + return -1 +endi +sql create table st_timestamp_24 using mt_timestamp tags (-0 + 1d) +sql show tags from st_timestamp_24 +if $data05 != 86400000 then + return -1 +endi +sql create table st_timestamp_25 using mt_timestamp tags ("-0" -1s) +sql show tags from st_timestamp_25 +if $data05 != -1000 then + return -1 +endi +sql create table st_timestamp_26 using mt_timestamp tags (0b01 -1a) +sql show tags from st_timestamp_26 +if $data05 != 0 then + return -1 +endi +sql create table st_timestamp_27 using mt_timestamp tags (0b01 -1s) +sql show tags from st_timestamp_27 +if $data05 != -999 then + return -1 +endi +sql create table st_timestamp_28 using mt_timestamp tags ("0x01" +1u) +sql show tags from st_timestamp_28 +if $data05 != 1 then + return -1 +endi +sql create table st_timestamp_29 using mt_timestamp tags (0x01 +1b) +sql show tags from st_timestamp_29 +if $data05 != 1 then + return -1 +endi +sql create table st_timestamp_30 using mt_timestamp tags (-0b00 -0a) +sql show tags from st_timestamp_30 +if $data05 != 0 then + return -1 +endi +sql create table st_timestamp_31 using mt_timestamp tags ("-0x00" +1u) +sql show tags from st_timestamp_31 +if $data05 != 0 then + return -1 +endi +sql create table st_timestamp_32 using mt_timestamp tags (-0x00 +1b) +sql show tags from st_timestamp_32 +if $data05 != 0 then + return -1 +endi +sql create table st_timestamp_33 using mt_timestamp tags (now +1b) +sql show tags from st_timestamp_33 +if $data05 < 1711883186000 then + return -1 +endi +sql create table st_timestamp_34 using mt_timestamp tags ("now()" +1b) +sql show tags from st_timestamp_34 +if $data05 < 1711883186000 then + return -1 +endi +sql create table st_timestamp_35 using mt_timestamp tags (today() +1d) +sql show tags from st_timestamp_35 +if $data05 < 1711883186000 then + return -1 +endi +sql create table st_timestamp_36 using mt_timestamp tags ("today()" +1d) +sql show tags from st_timestamp_36 +if $data05 < 1711883186000 then + return -1 +endi + ## case 01: insert values for test column values sql insert into st_timestamp_0 values(now,NULL) @@ -249,6 +320,76 @@ sql select ts, cast(c as bigint) from st_timestamp_22 if $data01 != -1 then return -1 endi +sql insert into st_timestamp_23 values(now,1+ 1d ) +sql select ts, cast(c as bigint) from st_timestamp_23 +if $data01 != 86400001 then + return -1 +endi +sql insert into st_timestamp_24 values(now,-0 + 1d) +sql select ts, cast(c as bigint) from st_timestamp_24 +if $data01 != 86400000 then + return -1 +endi +sql insert into st_timestamp_25 values(now,"-0" -1s) +sql select ts, cast(c as bigint) from st_timestamp_25 +if $data01 != -1000 then + return -1 +endi +sql insert into st_timestamp_26 values(now,0b01 -1a) +sql select ts, cast(c as bigint) from st_timestamp_26 +if $data01 != 0 then + return -1 +endi +sql insert into st_timestamp_27 values(now,+0b01 -1s) +sql select ts, cast(c as bigint) from st_timestamp_27 +if $data01 != -999 then + return -1 +endi +sql insert into st_timestamp_28 values(now,"+0x01" +1u) +sql select ts, cast(c as bigint) from st_timestamp_28 +if $data01 != 1 then + return -1 +endi +sql insert into st_timestamp_29 values(now,0x01 +1b) +sql select ts, cast(c as bigint) from st_timestamp_29 +if $data01 != 1 then + return -1 +endi +sql insert into st_timestamp_30 values(now,-0b00 -0a) +sql show tags from st_timestamp_30 +if $data05 != 0 then + return -1 +endi +sql insert into st_timestamp_31 values(now,"-0x00" +1u) +sql show tags from st_timestamp_31 +if $data05 != 0 then + return -1 +endi +sql insert into st_timestamp_32 values (now,-0x00 +1b) +sql show tags from st_timestamp_32 +if $data05 != 0 then + return -1 +endi +sql insert into st_timestamp_33 values(now,now +1b) +sql select ts, cast(c as bigint) from st_timestamp_33 +if $data01 < 1711883186000 then + return -1 +endi +sql insert into st_timestamp_34 values(now,"now()" +1b) +sql select ts, cast(c as bigint) from st_timestamp_34 +if $data01 < 1711883186000 then + return -1 +endi +sql insert into st_timestamp_35 values(now,today() +1d) +sql select ts, cast(c as bigint) from st_timestamp_35 +if $data01 < 1711883186000 then + return -1 +endi +sql insert into st_timestamp_36 values(now,"today()" +1d) +sql select ts, cast(c as bigint) from st_timestamp_36 +if $data01 < 1711883186000 then + return -1 +endi ## case 02: dynamic create table for test tag values sql insert into st_timestamp_100 using mt_timestamp tags(NULL) values(now, NULL) @@ -450,6 +591,136 @@ sql select ts, cast(c as bigint) from st_timestamp_1022 if $data01 != -1 then return -1 endi +sql insert into st_timestamp_1023 using mt_timestamp tags(+1+1d) values(now,+1+ 1d ) +sql show tags from st_timestamp_1023 +if $data05 != 86400001 then + return -1 +endi +sql select ts, cast(c as bigint) from st_timestamp_1023 +if $data01 != 86400001 then + return -1 +endi +sql insert into st_timestamp_1024 using mt_timestamp tags(-0+1d) values(now,-0 + 1d) +sql show tags from st_timestamp_1024 +if $data05 != 86400000 then + return -1 +endi +sql select ts, cast(c as bigint) from st_timestamp_1024 +if $data01 != 86400000 then + return -1 +endi +sql insert into st_timestamp_1025 using mt_timestamp tags("-0" -1s) values(now,"-0" -1s) +sql show tags from st_timestamp_1025 +if $data05 != -1000 then + return -1 +endi +sql select ts, cast(c as bigint) from st_timestamp_1025 +if $data01 != -1000 then + return -1 +endi +sql insert into st_timestamp_1026 using mt_timestamp tags(+0b01-1a) values(now,+0b01 -1a) +sql show tags from st_timestamp_1026 +if $data05 != 0 then + return -1 +endi +sql select ts, cast(c as bigint) from st_timestamp_1026 +if $data01 != 0 then + return -1 +endi +sql insert into st_timestamp_1027 using mt_timestamp tags(0b01-1s) values(now,0b01 -1s) +sql show tags from st_timestamp_1027 +if $data05 != -999 then + return -1 +endi +sql select ts, cast(c as bigint) from st_timestamp_1027 +if $data01 != -999 then + return -1 +endi +sql insert into st_timestamp_1028 using mt_timestamp tags("0x01" + 1u) values(now,"0x01" +1u) +sql show tags from st_timestamp_1028 +if $data05 != 1 then + return -1 +endi +sql select ts, cast(c as bigint) from st_timestamp_1028 +if $data01 != 1 then + return -1 +endi +sql insert into st_timestamp_1029 using mt_timestamp tags(+0x01 +1b) values(now,+0x01 +1b) +sql show tags from st_timestamp_1029 +if $data05 != 1 then + return -1 +endi +sql select ts, cast(c as bigint) from st_timestamp_1029 +if $data01 != 1 then + return -1 +endi +sql insert into st_timestamp_1030 using mt_timestamp tags (-0b00 -0a) values(now,-0b00 -0a) +sql show tags from st_timestamp_1030 +if $data05 != 0 then + return -1 +endi +sql select ts, cast(c as bigint) from st_timestamp_1030 +if $data01 != 0 then + return -1 +endi +sql insert into st_timestamp_1031 using mt_timestamp tags ("-0x00" +1u) values(now,"-0x00" +1u) +sql show tags from st_timestamp_1031 +if $data05 != 0 then + return -1 +endi +sql select ts, cast(c as bigint) from st_timestamp_1031 +if $data01 != 0 then + return -1 +endi +sql insert into st_timestamp_1032 using mt_timestamp tags (-0x00 +1b) values(now,-0x00 +1b) +sql show tags from st_timestamp_1032 +if $data05 != 0 then + return -1 +endi +sql select ts, cast(c as bigint) from st_timestamp_1032 +if $data01 != 0 then + return -1 +endi +sql insert into st_timestamp_1033 using mt_timestamp tags(now+1b) values(now,now +1b) +sql show tags from st_timestamp_1033 +if $data05 < 1711883186000 then + return -1 +endi +sql select ts, cast(c as bigint) from st_timestamp_1033 +if $data01 < 1711883186000 then + return -1 +endi +sql insert into st_timestamp_1034 using mt_timestamp tags("now" +1b) values(now,"now()" +1b) +sql show tags from st_timestamp_1034 +if $data05 < 1711883186000 then + return -1 +endi +sql select ts, cast(c as bigint) from st_timestamp_1034 +if $data01 < 1711883186000 then + return -1 +endi +sql insert into st_timestamp_1035 using mt_timestamp tags(today() + 1d) values(now,today() +1d) +sql show tags from st_timestamp_1035 +if $data05 < 1711883186000 then + return -1 +endi +sql select ts, cast(c as bigint) from st_timestamp_1035 +if $data01 < 1711883186000 then + return -1 +endi +sql insert into st_timestamp_1036 using mt_timestamp tags("today" +1d) values(now,"today()" +1d) +sql show tags from st_timestamp_1036 +if $data05 < 1711883186000 then + return -1 +endi +sql select ts, cast(c as bigint) from st_timestamp_1036 +if $data01 < 1711883186000 then + return -1 +endi + + + + ### case 03: alter tag values sql alter table st_timestamp_0 set tag tagname=NULL @@ -567,12 +838,85 @@ sql show tags from st_timestamp_22 if $data05 != -1 then return -1 endi +sql alter table st_timestamp_23 set tag tagname=1+ 1d +sql show tags from st_timestamp_23 +if $data05 != 86400001 then + return -1 +endi +sql alter table st_timestamp_24 set tag tagname=-0 + 1d +sql show tags from st_timestamp_24 +if $data05 != 86400000 then + return -1 +endi +sql alter table st_timestamp_25 set tag tagname="-0" -1s +sql show tags from st_timestamp_25 +if $data05 != -1000 then + return -1 +endi +sql alter table st_timestamp_26 set tag tagname=+0b01 -1a +sql show tags from st_timestamp_26 +if $data05 != 0 then + return -1 +endi +sql alter table st_timestamp_27 set tag tagname=0b01 -1s +sql show tags from st_timestamp_27 +if $data05 != -999 then + return -1 +endi +sql alter table st_timestamp_28 set tag tagname="0x01" +1u +sql show tags from st_timestamp_28 +if $data05 != 1 then + return -1 +endi +sql alter table st_timestamp_29 set tag tagname=0x01 +1b +sql show tags from st_timestamp_29 +if $data05 != 1 then + return -1 +endi +sql alter table st_timestamp_30 set tag tagname==-0b00 -0a +sql show tags from st_timestamp_30 +if $data05 != 0 then + return -1 +endi +sql alter table st_timestamp_31 set tag tagname="-0x00" +1u +sql show tags from st_timestamp_31 +if $data05 != 0 then + return -1 +endi +sql alter table st_timestamp_32 set tag tagname=-0x00 +1b +sql show tags from st_timestamp_32 +if $data05 != 0 then + return -1 +endi +sql alter table st_timestamp_33 set tag tagname=now +1b +sql show tags from st_timestamp_33 +if $data05 < 1711883186000 then + return -1 +endi +sql alter table st_timestamp_34 set tag tagname="now()" +1b +sql show tags from st_timestamp_34 +if $data05 < 1711883186000 then + return -1 +endi +sql alter table st_timestamp_35 set tag tagname=today( ) +1d +sql show tags from st_timestamp_35 +if $data05 < 1711883186000 then + return -1 +endi +sql alter table st_timestamp_36 set tag tagname="today()" +1d +sql show tags from st_timestamp_36 +if $data05 < 1711883186000 then + return -1 +endi ## case 04: illegal input sql_error create table st_timestamp_e0 using mt_timestamp tags (123abc) sql_error create table st_timestamp_e0 using mt_timestamp tags ("123abc") sql_error create table st_timestamp_e0 using mt_timestamp tags (abc) sql_error create table st_timestamp_e0 using mt_timestamp tags ("abc") +sql_error create table st_timestamp_e0 using mt_timestamp tags (now()+1d+1s) +sql_error create table st_timestamp_e0 using mt_timestamp tags (1+1y) +sql_error create table st_timestamp_e0 using mt_timestamp tags (0x01+1b+1a) sql_error create table st_timestamp_e0 using mt_timestamp tags (" ") sql_error create table st_timestamp_e0 using mt_timestamp tags ('') sql_error create table st_timestamp_104 using mt_timestamp tags ("-123.1") @@ -590,5 +934,7 @@ sql_error create table st_timestamp_115 using mt_timestamp tags (922337203685477 sql create table st_timestamp_116 using mt_timestamp tags (-9223372036854775808) sql_error create table st_timestamp_117 using mt_timestamp tags (-9223372036854775809) sql_error insert into st_timestamp_118 using mt_timestamp tags(9223372036854775807) values(9223372036854775807, 9223372036854775807) +sql_error insert into st_timestamp_119 using mt_timestamp tags(1+1s-1s) values(now, now) +sql_error insert into st_timestamp_120 using mt_timestamp tags(1-1s) values(now, now-1s+1d) system sh/exec.sh -n dnode1 -s stop -x SIGINT diff --git a/tests/script/tsim/parser/columnValue_varbinary.sim b/tests/script/tsim/parser/columnValue_varbinary.sim index 1db1054646..eb437f7597 100644 --- a/tests/script/tsim/parser/columnValue_varbinary.sim +++ b/tests/script/tsim/parser/columnValue_varbinary.sim @@ -299,6 +299,8 @@ sql_error create table st_varbinary_1012 using mt_varbinary tags(tRue) sql_error create table st_varbinary_1013 using mt_varbinary tags(FalsE) sql_error create table st_varbinary_1014 using mt_varbinary tags(noW) sql_error create table st_varbinary_1015 using mt_varbinary tags(toDay) +sql_error create table st_varbinary_1016 using mt_varbinary tags(now()+1s) +sql_error create table st_varbinary_1017 using mt_varbinary tags(1+1s) sql_error insert into st_varbinary_106 using mt_varbinary tags(+0123) values(now, NULL); sql_error insert into st_varbinary_107 using mt_varbinary tags(-01.23) values(now, NULL); sql_error insert into st_varbinary_108 using mt_varbinary tags(+0x01) values(now, NULL); @@ -309,6 +311,8 @@ sql_error insert into st_varbinary_1012 using mt_varbinary tags(tRue) values(no sql_error insert into st_varbinary_1013 using mt_varbinary tags(FalsE) values(now, NULL); sql_error insert into st_varbinary_1014 using mt_varbinary tags(noW) values(now, NULL); sql_error insert into st_varbinary_1015 using mt_varbinary tags(toDay) values(now, NULL); +sql_error insert into st_varbinary_1016 using mt_varbinary tags(now()+1s) values(now, NULL); +sql_error insert into st_varbinary_1017 using mt_varbinary tags(1+1s) values(now, NULL); sql_error insert into st_varbinary_106 using mt_varbinary tags(NULL) values(now(), +0123) sql_error insert into st_varbinary_107 using mt_varbinary tags(NULL) values(now(), -01.23) sql_error insert into st_varbinary_108 using mt_varbinary tags(NULL) values(now(), +0x01) @@ -319,5 +323,7 @@ sql_error insert into st_varbinary_1012 using mt_varbinary tags(NULL) values(no sql_error insert into st_varbinary_1013 using mt_varbinary tags(NULL) values(now(), FalsE) sql_error insert into st_varbinary_1014 using mt_varbinary tags(NULL) values(now(), noW) sql_error insert into st_varbinary_1015 using mt_varbinary tags(NULL) values(now(), toDay) +sql_error insert into st_varbinary_1016 using mt_varbinary tags(NULL) values(now(), now()+1s) +sql_error insert into st_varbinary_1017 using mt_varbinary tags(NULL) values(now(), 1+1s) system sh/exec.sh -n dnode1 -s stop -x SIGINT diff --git a/tests/script/tsim/parser/columnValue_varchar.sim b/tests/script/tsim/parser/columnValue_varchar.sim index 5edfe5ed24..b705f3069a 100644 --- a/tests/script/tsim/parser/columnValue_varchar.sim +++ b/tests/script/tsim/parser/columnValue_varchar.sim @@ -410,6 +410,17 @@ endi # case 04: illegal input +sql_error create table st_varchar_100 using mt_varchar tags(now+1d) +sql_error create table st_varchar_101 using mt_varchar tags(toDay+1d) +sql_error create table st_varchar_102 using mt_varchar tags(1+1b) +sql_error create table st_varchar_103 using mt_varchar tags(0x01+1d) +sql_error create table st_varchar_104 using mt_varchar tags(0b01+1s) +sql_error insert into st_varchar_1100 using mt_varchar tags('now') values(now(),now+1d) +sql_error insert into st_varchar_1101 using mt_varchar tags('now') values(now(),toDay+1d) +sql_error insert into st_varchar_1102 using mt_varchar tags('now') values(now(),1+1b) +sql_error insert into st_varchar_1103 using mt_varchar tags('now') values(now(),0x01+1d) +sql_error insert into st_varchar_1104 using mt_varchar tags('now') values(now(),0b01+1s) +sql_error alter table st_varchar_15 set tag tagname=now()+1d system sh/exec.sh -n dnode1 -s stop -x SIGINT diff --git a/tests/system-test/8-stream/stream_basic.py b/tests/system-test/8-stream/stream_basic.py index 3ebc255114..ff16bee787 100644 --- a/tests/system-test/8-stream/stream_basic.py +++ b/tests/system-test/8-stream/stream_basic.py @@ -78,14 +78,55 @@ class TDTestCase: tdLog.info(cmd) os.system(cmd) + def case1(self): + + tdSql.execute(f'create database if not exists d1 vgroups 1') + tdSql.execute(f'use d1') + tdSql.execute(f'create table st(ts timestamp, i int) tags(t int)') + tdSql.execute(f'insert into t1 using st tags(1) values(now, 1) (now+1s, 2)') + tdSql.execute(f'insert into t2 using st tags(2) values(now, 1) (now+1s, 2)') + tdSql.execute(f'insert into t3 using st tags(3) values(now, 1) (now+1s, 2)') + + tdSql.execute("create stream stream1 fill_history 1 into sta subtable(concat('new-', tname)) AS SELECT " + "_wstart, count(*), avg(i) FROM st PARTITION BY tbname tname INTERVAL(1m)", show=True) + + tdSql.execute("create stream stream2 fill_history 1 into stb subtable(concat('new-', tname)) AS SELECT " + "_wstart, count(*), avg(i) FROM st PARTITION BY tbname tname INTERVAL(1m)", show=True) + + time.sleep(2) + tdSql.query("select * from sta") + tdSql.checkRows(3) + tdSql.query("select tbname from sta order by tbname") + if not tdSql.getData(0, 0).startswith('new-t1_1.d1.sta_'): + tdLog.exit("error1") + + if not tdSql.getData(1, 0).startswith('new-t2_1.d1.sta_'): + tdLog.exit("error2") + + if not tdSql.getData(2, 0).startswith('new-t3_1.d1.sta_'): + tdLog.exit("error3") + + tdSql.query("select * from stb") + tdSql.checkRows(3) + tdSql.query("select tbname from stb order by tbname") + if not tdSql.getData(0, 0).startswith('new-t1_1.d1.stb_'): + tdLog.exit("error4") + + if not tdSql.getData(1, 0).startswith('new-t2_1.d1.stb_'): + tdLog.exit("error5") + + if not tdSql.getData(2, 0).startswith('new-t3_1.d1.stb_'): + tdLog.exit("error6") + # run def run(self): + self.case1() # gen data random.seed(int(time.time())) self.taosBenchmark(" -d db -t 2 -v 2 -n 1000000 -y") # create stream tdSql.execute("use db") - tdSql.execute("create stream stream1 fill_history 1 into sta as select count(*) as cnt from meters interval(10a);",show=True) + tdSql.execute("create stream stream3 fill_history 1 into sta as select count(*) as cnt from meters interval(10a);",show=True) sql = "select count(*) from sta" # loop wait max 60s to check count is ok tdLog.info("loop wait result ...") diff --git a/tools/CMakeLists.txt b/tools/CMakeLists.txt index a1c5405253..188abb4b58 100644 --- a/tools/CMakeLists.txt +++ b/tools/CMakeLists.txt @@ -18,7 +18,7 @@ IF (TD_WEBSOCKET) COMMAND git clean -f -d BUILD_COMMAND COMMAND cargo update - COMMAND RUSTFLAGS=-Ctarget-feature=-crt-static cargo build --release -p taos-ws-sys --features native-tls + COMMAND RUSTFLAGS=-Ctarget-feature=-crt-static cargo build --release -p taos-ws-sys --features rustls INSTALL_COMMAND COMMAND cp target/release/${websocket_lib_file} ${CMAKE_BINARY_DIR}/build/lib COMMAND cmake -E make_directory ${CMAKE_BINARY_DIR}/build/include @@ -37,7 +37,7 @@ IF (TD_WEBSOCKET) COMMAND git clean -f -d BUILD_COMMAND COMMAND cargo update - COMMAND cargo build --release -p taos-ws-sys --features native-tls-vendored + COMMAND cargo build --release -p taos-ws-sys --features rustls INSTALL_COMMAND COMMAND cp target/release/taosws.dll ${CMAKE_BINARY_DIR}/build/lib COMMAND cp target/release/taosws.dll.lib ${CMAKE_BINARY_DIR}/build/lib/taosws.lib @@ -57,7 +57,7 @@ IF (TD_WEBSOCKET) COMMAND git clean -f -d BUILD_COMMAND COMMAND cargo update - COMMAND cargo build --release -p taos-ws-sys --features native-tls-vendored + COMMAND cargo build --release -p taos-ws-sys --features rustls INSTALL_COMMAND COMMAND cp target/release/${websocket_lib_file} ${CMAKE_BINARY_DIR}/build/lib COMMAND cmake -E make_directory ${CMAKE_BINARY_DIR}/build/include