Merge branch '3.0' into feature/3_liaohj
This commit is contained in:
commit
918df89b4f
|
@ -83,12 +83,6 @@ option(
|
|||
OFF
|
||||
)
|
||||
|
||||
option(
|
||||
TDENGINE_3
|
||||
"TDengine 3.x"
|
||||
ON
|
||||
)
|
||||
|
||||
option(
|
||||
BUILD_ADDR2LINE
|
||||
"If build addr2line"
|
||||
|
|
|
@ -275,7 +275,12 @@ typedef struct SScanPhysiNode {
|
|||
|
||||
typedef SScanPhysiNode STagScanPhysiNode;
|
||||
typedef SScanPhysiNode SBlockDistScanPhysiNode;
|
||||
typedef SScanPhysiNode SLastRowScanPhysiNode;
|
||||
|
||||
typedef struct SLastRowScanPhysiNode {
|
||||
SScanPhysiNode scan;
|
||||
SNodeList* pGroupTags;
|
||||
bool groupSort;
|
||||
} SLastRowScanPhysiNode;
|
||||
|
||||
typedef struct SSystemTableScanPhysiNode {
|
||||
SScanPhysiNode scan;
|
||||
|
|
|
@ -163,7 +163,6 @@ typedef struct SSdbRow {
|
|||
ESdbType type;
|
||||
ESdbStatus status;
|
||||
int32_t refCount;
|
||||
int64_t forAlign;
|
||||
char pObj[];
|
||||
} SSdbRow;
|
||||
|
||||
|
|
|
@ -206,7 +206,7 @@ int32_t qExplainGenerateResChildren(SPhysiNode *pNode, SExplainGroup *group, SNo
|
|||
}
|
||||
case QUERY_NODE_PHYSICAL_PLAN_LAST_ROW_SCAN: {
|
||||
SLastRowScanPhysiNode *lastRowPhysiNode = (SLastRowScanPhysiNode *)pNode;
|
||||
pPhysiChildren = lastRowPhysiNode->node.pChildren;
|
||||
pPhysiChildren = lastRowPhysiNode->scan.node.pChildren;
|
||||
break;
|
||||
}
|
||||
case QUERY_NODE_PHYSICAL_PLAN_GROUP_SORT: {
|
||||
|
@ -1209,19 +1209,19 @@ int32_t qExplainResNodeToRowsImpl(SExplainResNode *pResNode, SExplainCtx *ctx, i
|
|||
}
|
||||
case QUERY_NODE_PHYSICAL_PLAN_LAST_ROW_SCAN: {
|
||||
SLastRowScanPhysiNode *pLastRowNode = (SLastRowScanPhysiNode *)pNode;
|
||||
EXPLAIN_ROW_NEW(level, EXPLAIN_LASTROW_SCAN_FORMAT, pLastRowNode->tableName.tname);
|
||||
EXPLAIN_ROW_NEW(level, EXPLAIN_LASTROW_SCAN_FORMAT, pLastRowNode->scan.tableName.tname);
|
||||
EXPLAIN_ROW_APPEND(EXPLAIN_LEFT_PARENTHESIS_FORMAT);
|
||||
if (pResNode->pExecInfo) {
|
||||
QRY_ERR_RET(qExplainBufAppendExecInfo(pResNode->pExecInfo, tbuf, &tlen));
|
||||
EXPLAIN_ROW_APPEND(EXPLAIN_BLANK_FORMAT);
|
||||
}
|
||||
EXPLAIN_ROW_APPEND(EXPLAIN_COLUMNS_FORMAT, pLastRowNode->pScanCols->length);
|
||||
EXPLAIN_ROW_APPEND(EXPLAIN_COLUMNS_FORMAT, pLastRowNode->scan.pScanCols->length);
|
||||
EXPLAIN_ROW_APPEND(EXPLAIN_BLANK_FORMAT);
|
||||
if (pLastRowNode->pScanPseudoCols) {
|
||||
EXPLAIN_ROW_APPEND(EXPLAIN_PSEUDO_COLUMNS_FORMAT, pLastRowNode->pScanPseudoCols->length);
|
||||
if (pLastRowNode->scan.pScanPseudoCols) {
|
||||
EXPLAIN_ROW_APPEND(EXPLAIN_PSEUDO_COLUMNS_FORMAT, pLastRowNode->scan.pScanPseudoCols->length);
|
||||
EXPLAIN_ROW_APPEND(EXPLAIN_BLANK_FORMAT);
|
||||
}
|
||||
EXPLAIN_ROW_APPEND(EXPLAIN_WIDTH_FORMAT, pLastRowNode->node.pOutputDataBlockDesc->totalRowSize);
|
||||
EXPLAIN_ROW_APPEND(EXPLAIN_WIDTH_FORMAT, pLastRowNode->scan.node.pOutputDataBlockDesc->totalRowSize);
|
||||
EXPLAIN_ROW_APPEND(EXPLAIN_BLANK_FORMAT);
|
||||
EXPLAIN_ROW_APPEND(EXPLAIN_RIGHT_PARENTHESIS_FORMAT);
|
||||
EXPLAIN_ROW_END();
|
||||
|
@ -1230,15 +1230,15 @@ int32_t qExplainResNodeToRowsImpl(SExplainResNode *pResNode, SExplainCtx *ctx, i
|
|||
if (verbose) {
|
||||
EXPLAIN_ROW_NEW(level + 1, EXPLAIN_OUTPUT_FORMAT);
|
||||
EXPLAIN_ROW_APPEND(EXPLAIN_COLUMNS_FORMAT,
|
||||
nodesGetOutputNumFromSlotList(pLastRowNode->node.pOutputDataBlockDesc->pSlots));
|
||||
nodesGetOutputNumFromSlotList(pLastRowNode->scan.node.pOutputDataBlockDesc->pSlots));
|
||||
EXPLAIN_ROW_APPEND(EXPLAIN_BLANK_FORMAT);
|
||||
EXPLAIN_ROW_APPEND(EXPLAIN_WIDTH_FORMAT, pLastRowNode->node.pOutputDataBlockDesc->outputRowSize);
|
||||
EXPLAIN_ROW_APPEND(EXPLAIN_WIDTH_FORMAT, pLastRowNode->scan.node.pOutputDataBlockDesc->outputRowSize);
|
||||
EXPLAIN_ROW_END();
|
||||
QRY_ERR_RET(qExplainResAppendRow(ctx, tbuf, tlen, level + 1));
|
||||
|
||||
if (pLastRowNode->node.pConditions) {
|
||||
if (pLastRowNode->scan.node.pConditions) {
|
||||
EXPLAIN_ROW_NEW(level + 1, EXPLAIN_FILTER_FORMAT);
|
||||
QRY_ERR_RET(nodesNodeToSQL(pLastRowNode->node.pConditions, tbuf + VARSTR_HEADER_SIZE,
|
||||
QRY_ERR_RET(nodesNodeToSQL(pLastRowNode->scan.node.pConditions, tbuf + VARSTR_HEADER_SIZE,
|
||||
TSDB_EXPLAIN_RESULT_ROW_SIZE, &tlen));
|
||||
EXPLAIN_ROW_END();
|
||||
QRY_ERR_RET(qExplainResAppendRow(ctx, tbuf, tlen, level + 1));
|
||||
|
|
|
@ -40,10 +40,10 @@ SOperatorInfo* createLastrowScanOperator(SLastRowScanPhysiNode* pScanNode, SRead
|
|||
|
||||
pInfo->pTableList = pTableList;
|
||||
pInfo->readHandle = *readHandle;
|
||||
pInfo->pRes = createResDataBlock(pScanNode->node.pOutputDataBlockDesc);
|
||||
pInfo->pRes = createResDataBlock(pScanNode->scan.node.pOutputDataBlockDesc);
|
||||
|
||||
int32_t numOfCols = 0;
|
||||
pInfo->pColMatchInfo = extractColMatchInfo(pScanNode->pScanCols, pScanNode->node.pOutputDataBlockDesc, &numOfCols,
|
||||
pInfo->pColMatchInfo = extractColMatchInfo(pScanNode->scan.pScanCols, pScanNode->scan.node.pOutputDataBlockDesc, &numOfCols,
|
||||
COL_MATCH_FROM_COL_ID);
|
||||
int32_t code = extractTargetSlotId(pInfo->pColMatchInfo, pTaskInfo, &pInfo->pSlotIds);
|
||||
if (code != TSDB_CODE_SUCCESS) {
|
||||
|
@ -53,10 +53,10 @@ SOperatorInfo* createLastrowScanOperator(SLastRowScanPhysiNode* pScanNode, SRead
|
|||
tsdbLastRowReaderOpen(readHandle->vnode, LASTROW_RETRIEVE_TYPE_SINGLE, pTableList, taosArrayGetSize(pInfo->pColMatchInfo),
|
||||
&pInfo->pLastrowReader);
|
||||
|
||||
if (pScanNode->pScanPseudoCols != NULL) {
|
||||
if (pScanNode->scan.pScanPseudoCols != NULL) {
|
||||
SExprSupp* pPseudoExpr = &pInfo->pseudoExprSup;
|
||||
|
||||
pPseudoExpr->pExprInfo = createExprInfo(pScanNode->pScanPseudoCols, NULL, &pPseudoExpr->numOfExprs);
|
||||
pPseudoExpr->pExprInfo = createExprInfo(pScanNode->scan.pScanPseudoCols, NULL, &pPseudoExpr->numOfExprs);
|
||||
pPseudoExpr->pCtx = createSqlFunctionCtx(pPseudoExpr->pExprInfo, pPseudoExpr->numOfExprs, &pPseudoExpr->rowEntryInfoOffset);
|
||||
}
|
||||
|
||||
|
|
|
@ -4438,21 +4438,21 @@ SOperatorInfo* createOperatorTree(SPhysiNode* pPhyNode, SExecTaskInfo* pTaskInfo
|
|||
// return NULL;
|
||||
// }
|
||||
|
||||
int32_t code = extractTableSchemaInfo(pHandle, pScanNode->uid, pTaskInfo);
|
||||
int32_t code = extractTableSchemaInfo(pHandle, pScanNode->scan.uid, pTaskInfo);
|
||||
if (code != TSDB_CODE_SUCCESS) {
|
||||
pTaskInfo->code = code;
|
||||
return NULL;
|
||||
}
|
||||
|
||||
pTableListInfo->pTableList = taosArrayInit(4, sizeof(STableKeyInfo));
|
||||
if (pScanNode->tableType == TSDB_SUPER_TABLE) {
|
||||
code = vnodeGetAllTableList(pHandle->vnode, pScanNode->uid, pTableListInfo->pTableList);
|
||||
if (pScanNode->scan.tableType == TSDB_SUPER_TABLE) {
|
||||
code = vnodeGetAllTableList(pHandle->vnode, pScanNode->scan.uid, pTableListInfo->pTableList);
|
||||
if (code != TSDB_CODE_SUCCESS) {
|
||||
pTaskInfo->code = terrno;
|
||||
return NULL;
|
||||
}
|
||||
} else { // Create one table group.
|
||||
STableKeyInfo info = {.lastKey = 0, .uid = pScanNode->uid, .groupId = 0};
|
||||
STableKeyInfo info = {.lastKey = 0, .uid = pScanNode->scan.uid, .groupId = 0};
|
||||
taosArrayPush(pTableListInfo->pTableList, &info);
|
||||
}
|
||||
|
||||
|
|
|
@ -402,7 +402,6 @@ typedef struct SGroupKeyInfo {
|
|||
(x) += step; \
|
||||
} while (0)
|
||||
|
||||
|
||||
#define STATE_COMP(_op, _lval, _param) STATE_COMP_IMPL(_op, _lval, GET_STATE_VAL(_param))
|
||||
|
||||
#define GET_STATE_VAL(param) ((param.nType == TSDB_DATA_TYPE_BIGINT) ? (param.i) : (param.d))
|
||||
|
@ -4200,13 +4199,9 @@ static int32_t histogramFunctionImpl(SqlFunctionCtx* pCtx, bool isPartial) {
|
|||
return TSDB_CODE_SUCCESS;
|
||||
}
|
||||
|
||||
int32_t histogramFunction(SqlFunctionCtx* pCtx) {
|
||||
return histogramFunctionImpl(pCtx, false);
|
||||
}
|
||||
int32_t histogramFunction(SqlFunctionCtx* pCtx) { return histogramFunctionImpl(pCtx, false); }
|
||||
|
||||
int32_t histogramFunctionPartial(SqlFunctionCtx* pCtx) {
|
||||
return histogramFunctionImpl(pCtx, true);
|
||||
}
|
||||
int32_t histogramFunctionPartial(SqlFunctionCtx* pCtx) { return histogramFunctionImpl(pCtx, true); }
|
||||
|
||||
static void histogramTransferInfo(SHistoFuncInfo* pInput, SHistoFuncInfo* pOutput) {
|
||||
pOutput->normalized = pInput->normalized;
|
||||
|
@ -6019,7 +6014,6 @@ int32_t lastrowFunction(SqlFunctionCtx* pCtx) {
|
|||
char* data = colDataGetData(pInputCol, i);
|
||||
TSKEY cts = getRowPTs(pInput->pPTS, i);
|
||||
if (pResInfo->numOfRes == 0 || pInfo->ts < cts) {
|
||||
|
||||
if (colDataIsNull_s(pInputCol, i)) {
|
||||
pInfo->isNull = true;
|
||||
} else {
|
||||
|
|
|
@ -1470,9 +1470,36 @@ static int32_t jsonToPhysiScanNode(const SJson* pJson, void* pObj) {
|
|||
return code;
|
||||
}
|
||||
|
||||
static int32_t physiTagScanNodeToJson(const void* pObj, SJson* pJson) { return physiScanNodeToJson(pObj, pJson); }
|
||||
static const char* jkLastRowScanPhysiPlanGroupTags = "GroupTags";
|
||||
static const char* jkLastRowScanPhysiPlanGroupSort = "GroupSort";
|
||||
|
||||
static int32_t jsonToPhysiTagScanNode(const SJson* pJson, void* pObj) { return jsonToPhysiScanNode(pJson, pObj); }
|
||||
static int32_t physiLastRowScanNodeToJson(const void* pObj, SJson* pJson) {
|
||||
const SLastRowScanPhysiNode* pNode = (const SLastRowScanPhysiNode*)pObj;
|
||||
|
||||
int32_t code = physiScanNodeToJson(pObj, pJson);
|
||||
if (TSDB_CODE_SUCCESS == code) {
|
||||
code = nodeListToJson(pJson, jkLastRowScanPhysiPlanGroupTags, pNode->pGroupTags);
|
||||
}
|
||||
if (TSDB_CODE_SUCCESS == code) {
|
||||
code = tjsonAddBoolToObject(pJson, jkLastRowScanPhysiPlanGroupSort, pNode->groupSort);
|
||||
}
|
||||
|
||||
return code;
|
||||
}
|
||||
|
||||
static int32_t jsonToPhysiLastRowScanNode(const SJson* pJson, void* pObj) {
|
||||
SLastRowScanPhysiNode* pNode = (SLastRowScanPhysiNode*)pObj;
|
||||
|
||||
int32_t code = jsonToPhysiScanNode(pJson, pObj);
|
||||
if (TSDB_CODE_SUCCESS == code) {
|
||||
code = jsonToNodeList(pJson, jkLastRowScanPhysiPlanGroupTags, &pNode->pGroupTags);
|
||||
}
|
||||
if (TSDB_CODE_SUCCESS == code) {
|
||||
code = tjsonGetBoolValue(pJson, jkLastRowScanPhysiPlanGroupSort, &pNode->groupSort);
|
||||
}
|
||||
|
||||
return code;
|
||||
}
|
||||
|
||||
static const char* jkTableScanPhysiPlanScanCount = "ScanCount";
|
||||
static const char* jkTableScanPhysiPlanReverseScanCount = "ReverseScanCount";
|
||||
|
@ -4317,8 +4344,9 @@ static int32_t specificNodeToJson(const void* pObj, SJson* pJson) {
|
|||
return logicPlanToJson(pObj, pJson);
|
||||
case QUERY_NODE_PHYSICAL_PLAN_TAG_SCAN:
|
||||
case QUERY_NODE_PHYSICAL_PLAN_BLOCK_DIST_SCAN:
|
||||
return physiScanNodeToJson(pObj, pJson);
|
||||
case QUERY_NODE_PHYSICAL_PLAN_LAST_ROW_SCAN:
|
||||
return physiTagScanNodeToJson(pObj, pJson);
|
||||
return physiLastRowScanNodeToJson(pObj, pJson);
|
||||
case QUERY_NODE_PHYSICAL_PLAN_TABLE_SCAN:
|
||||
case QUERY_NODE_PHYSICAL_PLAN_TABLE_MERGE_SCAN:
|
||||
case QUERY_NODE_PHYSICAL_PLAN_STREAM_SCAN:
|
||||
|
@ -4463,8 +4491,10 @@ static int32_t jsonToSpecificNode(const SJson* pJson, void* pObj) {
|
|||
return jsonToLogicPlan(pJson, pObj);
|
||||
case QUERY_NODE_PHYSICAL_PLAN_TAG_SCAN:
|
||||
case QUERY_NODE_PHYSICAL_PLAN_BLOCK_DIST_SCAN:
|
||||
return jsonToPhysiScanNode(pJson, pObj);
|
||||
case QUERY_NODE_PHYSICAL_PLAN_LAST_ROW_SCAN:
|
||||
return jsonToPhysiTagScanNode(pJson, pObj);
|
||||
|
||||
return jsonToPhysiLastRowScanNode(pJson, pObj);
|
||||
case QUERY_NODE_PHYSICAL_PLAN_TABLE_SCAN:
|
||||
case QUERY_NODE_PHYSICAL_PLAN_TABLE_MERGE_SCAN:
|
||||
case QUERY_NODE_PHYSICAL_PLAN_STREAM_SCAN:
|
||||
|
|
|
@ -1178,6 +1178,13 @@ static int parseOneRow(SInsertParseContext* pCxt, STableDataBlocks* pDataBlocks,
|
|||
TSKEY tsKey = TD_ROW_KEY(row);
|
||||
checkTimestamp(pDataBlocks, (const char*)&tsKey);
|
||||
}
|
||||
|
||||
if (i < spd->numOfBound - 1) {
|
||||
NEXT_VALID_TOKEN(pCxt->pSql, sToken);
|
||||
if (TK_NK_COMMA != sToken.type) {
|
||||
return buildSyntaxErrMsg(&pCxt->msg, ", expected", sToken.z);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (!isParseBindParam) {
|
||||
|
|
|
@ -481,8 +481,6 @@ static ENodeType getScanOperatorType(EScanType scanType) {
|
|||
return QUERY_NODE_PHYSICAL_PLAN_TABLE_MERGE_SCAN;
|
||||
case SCAN_TYPE_BLOCK_INFO:
|
||||
return QUERY_NODE_PHYSICAL_PLAN_BLOCK_DIST_SCAN;
|
||||
case SCAN_TYPE_LAST_ROW:
|
||||
return QUERY_NODE_PHYSICAL_PLAN_LAST_ROW_SCAN;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
@ -502,6 +500,24 @@ static int32_t createSimpleScanPhysiNode(SPhysiPlanContext* pCxt, SSubplan* pSub
|
|||
return createScanPhysiNodeFinalize(pCxt, pSubplan, pScanLogicNode, pScan, pPhyNode);
|
||||
}
|
||||
|
||||
static int32_t createLastRowScanPhysiNode(SPhysiPlanContext* pCxt, SSubplan* pSubplan, SScanLogicNode* pScanLogicNode,
|
||||
SPhysiNode** pPhyNode) {
|
||||
SLastRowScanPhysiNode* pScan =
|
||||
(SLastRowScanPhysiNode*)makePhysiNode(pCxt, (SLogicNode*)pScanLogicNode, QUERY_NODE_PHYSICAL_PLAN_LAST_ROW_SCAN);
|
||||
if (NULL == pScan) {
|
||||
return TSDB_CODE_OUT_OF_MEMORY;
|
||||
}
|
||||
|
||||
pScan->pGroupTags = nodesCloneList(pScanLogicNode->pGroupTags);
|
||||
if (NULL != pScanLogicNode->pGroupTags && NULL == pScan->pGroupTags) {
|
||||
nodesDestroyNode((SNode*)pScan);
|
||||
return TSDB_CODE_OUT_OF_MEMORY;
|
||||
}
|
||||
pScan->groupSort = pScanLogicNode->groupSort;
|
||||
|
||||
return createScanPhysiNodeFinalize(pCxt, pSubplan, pScanLogicNode, (SScanPhysiNode*)pScan, pPhyNode);
|
||||
}
|
||||
|
||||
static int32_t createTableScanPhysiNode(SPhysiPlanContext* pCxt, SSubplan* pSubplan, SScanLogicNode* pScanLogicNode,
|
||||
SPhysiNode** pPhyNode) {
|
||||
STableScanPhysiNode* pTableScan = (STableScanPhysiNode*)makePhysiNode(pCxt, (SLogicNode*)pScanLogicNode,
|
||||
|
@ -583,8 +599,9 @@ static int32_t createScanPhysiNode(SPhysiPlanContext* pCxt, SSubplan* pSubplan,
|
|||
switch (pScanLogicNode->scanType) {
|
||||
case SCAN_TYPE_TAG:
|
||||
case SCAN_TYPE_BLOCK_INFO:
|
||||
case SCAN_TYPE_LAST_ROW:
|
||||
return createSimpleScanPhysiNode(pCxt, pSubplan, pScanLogicNode, pPhyNode);
|
||||
case SCAN_TYPE_LAST_ROW:
|
||||
return createLastRowScanPhysiNode(pCxt, pSubplan, pScanLogicNode, pPhyNode);
|
||||
case SCAN_TYPE_TABLE:
|
||||
return createTableScanPhysiNode(pCxt, pSubplan, pScanLogicNode, pPhyNode);
|
||||
case SCAN_TYPE_SYSTEM_TABLE:
|
||||
|
|
|
@ -364,6 +364,8 @@ static int32_t stbSplCreatePartWindowNode(SWindowLogicNode* pMergeWindow, SLogic
|
|||
pMergeWindow->node.pTargets = NULL;
|
||||
SNodeList* pChildren = pMergeWindow->node.pChildren;
|
||||
pMergeWindow->node.pChildren = NULL;
|
||||
SNode* pConditions = pMergeWindow->node.pConditions;
|
||||
pMergeWindow->node.pConditions = NULL;
|
||||
|
||||
int32_t code = TSDB_CODE_SUCCESS;
|
||||
SWindowLogicNode* pPartWin = (SWindowLogicNode*)nodesCloneNode((SNode*)pMergeWindow);
|
||||
|
@ -373,6 +375,7 @@ static int32_t stbSplCreatePartWindowNode(SWindowLogicNode* pMergeWindow, SLogic
|
|||
|
||||
if (TSDB_CODE_SUCCESS == code) {
|
||||
pMergeWindow->node.pTargets = pTargets;
|
||||
pMergeWindow->node.pConditions = pConditions;
|
||||
pPartWin->node.pChildren = pChildren;
|
||||
splSetParent((SLogicNode*)pPartWin);
|
||||
code = stbSplRewriteFuns(pFunc, &pPartWin->pFuncs, &pMergeWindow->pFuncs);
|
||||
|
|
|
@ -108,6 +108,8 @@ TEST_F(PlanBasicTest, lastRowFunc) {
|
|||
|
||||
run("SELECT LAST_ROW(c1) FROM st1");
|
||||
|
||||
run("SELECT LAST_ROW(c1) FROM st1 PARTITION BY TBNAME");
|
||||
|
||||
run("SELECT LAST_ROW(c1), SUM(c3) FROM t1");
|
||||
}
|
||||
|
||||
|
|
|
@ -36,6 +36,8 @@ TEST_F(PlanSubqeuryTest, basic) {
|
|||
run("SELECT * FROM (SELECT NOW() FROM t1)");
|
||||
|
||||
run("SELECT NOW() FROM (SELECT * FROM t1) ORDER BY ts");
|
||||
|
||||
run("SELECT * FROM (SELECT AVG(c1) a FROM st1 INTERVAL(10s)) WHERE a > 1");
|
||||
}
|
||||
|
||||
TEST_F(PlanSubqeuryTest, doubleGroupBy) {
|
||||
|
|
|
@ -1477,7 +1477,8 @@ void vectorAssign(SScalarParam* pLeft, SScalarParam* pRight, SScalarParam *pOut,
|
|||
|
||||
pOut->numOfRows = pLeft->numOfRows;
|
||||
|
||||
if (IS_HELPER_NULL(pRight->columnData, 0)) {
|
||||
// if (IS_HELPER_NULL(pRight->columnData, 0)) {
|
||||
if(colDataIsNull_s(pRight->columnData, 0)){
|
||||
for (int32_t i = 0; i < pOut->numOfRows; ++i) {
|
||||
colDataAppend(pOutputCol, i, NULL, true);
|
||||
}
|
||||
|
|
|
@ -1,9 +0,0 @@
|
|||
run general/insert/basic.sim
|
||||
run general/insert/insert_drop.sim
|
||||
run general/insert/query_block1_memory.sim
|
||||
run general/insert/query_block2_memory.sim
|
||||
run general/insert/query_block1_file.sim
|
||||
run general/insert/query_block2_file.sim
|
||||
run general/insert/query_file_memory.sim
|
||||
run general/insert/query_multi_file.sim
|
||||
run general/insert/tcp.sim
|
|
@ -1,27 +0,0 @@
|
|||
run general/table/autocreate.sim
|
||||
run general/table/basic1.sim
|
||||
run general/table/basic2.sim
|
||||
run general/table/basic3.sim
|
||||
run general/table/bigint.sim
|
||||
run general/table/binary.sim
|
||||
run general/table/bool.sim
|
||||
run general/table/column_name.sim
|
||||
run general/table/column_num.sim
|
||||
run general/table/column_value.sim
|
||||
run general/table/column2.sim
|
||||
run general/table/date.sim
|
||||
run general/table/db.table.sim
|
||||
run general/table/delete_reuse1.sim
|
||||
run general/table/delete_reuse2.sim
|
||||
run general/table/delete_writing.sim
|
||||
run general/table/describe.sim
|
||||
run general/table/double.sim
|
||||
run general/table/fill.sim
|
||||
run general/table/float.sim
|
||||
run general/table/int.sim
|
||||
run general/table/limit.sim
|
||||
run general/table/smallint.sim
|
||||
run general/table/table_len.sim
|
||||
run general/table/table.sim
|
||||
run general/table/tinyint.sim
|
||||
run general/table/vgroup.sim
|
|
@ -52,13 +52,22 @@
|
|||
./test.sh -f tsim/import/replica1.sim
|
||||
|
||||
# ---- insert
|
||||
./test.sh -f tsim/insert/backquote.sim
|
||||
./test.sh -f tsim/insert/basic.sim
|
||||
./test.sh -f tsim/insert/basic0.sim
|
||||
./test.sh -f tsim/insert/basic1.sim
|
||||
./test.sh -f tsim/insert/backquote.sim
|
||||
./test.sh -f tsim/insert/null.sim
|
||||
./test.sh -f tsim/insert/update0.sim
|
||||
./test.sh -f tsim/insert/commit-merge0.sim
|
||||
./test.sh -f tsim/insert/insert_drop.sim
|
||||
./test.sh -f tsim/insert/insert_select.sim
|
||||
./test.sh -f tsim/insert/null.sim
|
||||
./test.sh -f tsim/insert/query_block1_file.sim
|
||||
./test.sh -f tsim/insert/query_block1_memory.sim
|
||||
./test.sh -f tsim/insert/query_block2_file.sim
|
||||
./test.sh -f tsim/insert/query_block2_memory.sim
|
||||
./test.sh -f tsim/insert/query_file_memory.sim
|
||||
./test.sh -f tsim/insert/query_multi_file.sim
|
||||
#./test.sh -f tsim/insert/tcp.sim
|
||||
./test.sh -f tsim/insert/update0.sim
|
||||
|
||||
# ---- parser
|
||||
./test.sh -f tsim/parser/groupby-basic.sim
|
||||
|
@ -94,7 +103,33 @@
|
|||
./test.sh -f tsim/show/basic.sim
|
||||
|
||||
# ---- table
|
||||
./test.sh -f tsim/table/autocreate.sim
|
||||
./test.sh -f tsim/table/basic1.sim
|
||||
./test.sh -f tsim/table/basic2.sim
|
||||
./test.sh -f tsim/table/basic3.sim
|
||||
./test.sh -f tsim/table/bigint.sim
|
||||
./test.sh -f tsim/table/binary.sim
|
||||
./test.sh -f tsim/table/bool.sim
|
||||
./test.sh -f tsim/table/column_name.sim
|
||||
./test.sh -f tsim/table/column_num.sim
|
||||
./test.sh -f tsim/table/column_value.sim
|
||||
./test.sh -f tsim/table/column2.sim
|
||||
./test.sh -f tsim/table/createmulti.sim
|
||||
./test.sh -f tsim/table/date.sim
|
||||
./test.sh -f tsim/table/db.table.sim
|
||||
# ./test.sh -f tsim/table/delete_reuse1.sim
|
||||
# ./test.sh -f tsim/table/delete_reuse2.sim
|
||||
# ./test.sh -f tsim/table/delete_writing.sim
|
||||
./test.sh -f tsim/table/describe.sim
|
||||
./test.sh -f tsim/table/double.sim
|
||||
./test.sh -f tsim/table/float.sim
|
||||
./test.sh -f tsim/table/int.sim
|
||||
./test.sh -f tsim/table/limit.sim
|
||||
./test.sh -f tsim/table/smallint.sim
|
||||
./test.sh -f tsim/table/table_len.sim
|
||||
./test.sh -f tsim/table/table.sim
|
||||
./test.sh -f tsim/table/tinyint.sim
|
||||
./test.sh -f tsim/table/vgroup.sim
|
||||
|
||||
# ---- stream
|
||||
./test.sh -f tsim/stream/basic0.sim
|
||||
|
@ -228,23 +263,23 @@
|
|||
./test.sh -f tsim/compress/uncompress.sim
|
||||
|
||||
# ---- compute
|
||||
#./test.sh -f tsim/compute/avg.sim
|
||||
./test.sh -f tsim/compute/avg.sim
|
||||
#./test.sh -f tsim/compute/block_dist.sim
|
||||
#./test.sh -f tsim/compute/bottom.sim
|
||||
#./test.sh -f tsim/compute/count.sim
|
||||
#./test.sh -f tsim/compute/diff.sim
|
||||
#./test.sh -f tsim/compute/diff2.sim
|
||||
#./test.sh -f tsim/compute/first.sim
|
||||
#./test.sh -f tsim/compute/interval.sim
|
||||
./test.sh -f tsim/compute/bottom.sim
|
||||
./test.sh -f tsim/compute/count.sim
|
||||
./test.sh -f tsim/compute/diff.sim
|
||||
./test.sh -f tsim/compute/diff2.sim
|
||||
./test.sh -f tsim/compute/first.sim
|
||||
./test.sh -f tsim/compute/interval.sim
|
||||
#./test.sh -f tsim/compute/last_row.sim
|
||||
#./test.sh -f tsim/compute/last.sim
|
||||
#./test.sh -f tsim/compute/leastsquare.sim
|
||||
#./test.sh -f tsim/compute/max.sim
|
||||
#./test.sh -f tsim/compute/min.sim
|
||||
./test.sh -f tsim/compute/last.sim
|
||||
./test.sh -f tsim/compute/leastsquare.sim
|
||||
./test.sh -f tsim/compute/max.sim
|
||||
./test.sh -f tsim/compute/min.sim
|
||||
#./test.sh -f tsim/compute/null.sim
|
||||
./test.sh -f tsim/compute/percentile.sim
|
||||
./test.sh -f tsim/compute/stddev.sim
|
||||
#./test.sh -f tsim/compute/sum.sim
|
||||
./test.sh -f tsim/compute/sum.sim
|
||||
./test.sh -f tsim/compute/top.sim
|
||||
|
||||
# ---- field
|
||||
|
|
|
@ -83,10 +83,6 @@ while $i < 10
|
|||
$i = $i + 1
|
||||
endw
|
||||
|
||||
print ==> sleep 1 seconds to renew cache
|
||||
sql reset query cache
|
||||
sleep 1000
|
||||
|
||||
print =============== step5
|
||||
sql select * from $tb order by ts desc
|
||||
print ===>rows $rows, data $data01
|
||||
|
|
|
@ -48,9 +48,7 @@ system sh/deploy.sh -n dnode1 -i 1
|
|||
system sh/exec.sh -n dnode1 -s start
|
||||
|
||||
print =============== step3
|
||||
print ==> sleep 1 seconds to renew cache
|
||||
sql reset query cache
|
||||
sleep 1000
|
||||
|
||||
print =============== step4
|
||||
sql create database $db
|
||||
|
|
|
@ -32,9 +32,7 @@ system sh/deploy.sh -n dnode1 -i 1
|
|||
system sh/exec.sh -n dnode1 -s start
|
||||
|
||||
print =============== step3
|
||||
print ==> sleep 1 seconds to renew cache
|
||||
sql reset query cache
|
||||
sleep 1000
|
||||
|
||||
print =============== step4
|
||||
sql create database $db
|
||||
|
|
|
@ -57,15 +57,7 @@ $tb = $tbPrefix . $i
|
|||
|
||||
sql create database $db
|
||||
sql use $db
|
||||
|
||||
$x = 0
|
||||
step3:
|
||||
$x = $x + 1
|
||||
sleep 1000
|
||||
if $x == 20 then
|
||||
return -1
|
||||
endi
|
||||
sql create table $tb (ts timestamp, b bool, t tinyint, s smallint, i int, big bigint, f float, d double, str binary(256)) -x step3
|
||||
sql create table $tb (ts timestamp, b bool, t tinyint, s smallint, i int, big bigint, f float, d double, str binary(256))
|
||||
|
||||
$count = 0
|
||||
while $count < $N
|
||||
|
|
|
@ -38,8 +38,6 @@ while $i < $tbNum
|
|||
$i = $i + 1
|
||||
endw
|
||||
|
||||
sleep 100
|
||||
|
||||
print =============== step2
|
||||
$i = 1
|
||||
$tb = $tbPrefix . $i
|
||||
|
@ -69,13 +67,13 @@ endi
|
|||
print =============== step5
|
||||
sql select avg(tbcol) as b from $tb interval(1m)
|
||||
print ===> $data01
|
||||
if $data11 != 1.000000000 then
|
||||
if $data10 != 1.000000000 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
sql select avg(tbcol) as b from $tb interval(1d)
|
||||
print ===> $data01
|
||||
if $data01 != 9.500000000 then
|
||||
if $data00 != 9.500000000 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
@ -84,7 +82,7 @@ $cc = 4 * 60000
|
|||
$ms = 1601481600000 + $cc
|
||||
sql select avg(tbcol) as b from $tb where ts <= $ms interval(1m)
|
||||
print ===> $data01
|
||||
if $data41 != 4.000000000 then
|
||||
if $data40 != 4.000000000 then
|
||||
return -1
|
||||
endi
|
||||
if $rows != 5 then
|
||||
|
@ -123,14 +121,14 @@ endi
|
|||
|
||||
print =============== step9
|
||||
sql select avg(tbcol) as b from $mt interval(1m)
|
||||
print ===> $data11
|
||||
if $data11 != 1.000000000 then
|
||||
print ===> $data10
|
||||
if $data10 != 1.000000000 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
sql select avg(tbcol) as b from $mt interval(1d)
|
||||
print ===> $data01
|
||||
if $data01 != 9.500000000 then
|
||||
if $data00 != 9.500000000 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
@ -148,9 +146,9 @@ endi
|
|||
print =============== step11
|
||||
$cc = 4 * 60000
|
||||
$ms = 1601481600000 + $cc
|
||||
sql select avg(tbcol) as b from $mt where ts <= $ms interval(1m) group by tgcol
|
||||
print ===> $data11
|
||||
if $data11 != 1.000000000 then
|
||||
sql select avg(tbcol) as b from $mt where ts <= $ms partition by tgcol interval(1m)
|
||||
print ===> $data10
|
||||
if $data10 != 1.000000000 then
|
||||
return -1
|
||||
endi
|
||||
if $rows != 50 then
|
||||
|
|
|
@ -47,8 +47,6 @@ while $x < $rowNum
|
|||
$x = $x + 1
|
||||
endw
|
||||
|
||||
sleep 100
|
||||
|
||||
print =============== step2
|
||||
$i = 0
|
||||
$tb = $tbPrefix . $i
|
||||
|
|
|
@ -38,15 +38,13 @@ while $i < $tbNum
|
|||
$i = $i + 1
|
||||
endw
|
||||
|
||||
sleep 100
|
||||
|
||||
print =============== step2
|
||||
$i = 1
|
||||
$tb = $tbPrefix . $i
|
||||
|
||||
sql select bottom(tbcol, 1) from $tb
|
||||
print ===> $data01
|
||||
if $data01 != 0 then
|
||||
print ===> $data00
|
||||
if $data00 != 0 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
@ -54,25 +52,25 @@ print =============== step3
|
|||
$cc = 4 * 60000
|
||||
$ms = 1601481600000 + $cc
|
||||
sql select bottom(tbcol, 1) from $tb where ts > $ms
|
||||
print ===> $data01
|
||||
if $data01 != 5 then
|
||||
print ===> $data00
|
||||
if $data00 != 5 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
print =============== step4
|
||||
sql select bottom(tbcol, 1) as b from $tb
|
||||
print ===> $data01
|
||||
if $data01 != 0 then
|
||||
print ===> $data00
|
||||
if $data00 != 0 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
print =============== step5
|
||||
sql select bottom(tbcol, 2) as b from $tb
|
||||
print ===> $data01 $data11
|
||||
if $data01 != 0 then
|
||||
print ===> $data00 $data10
|
||||
if $data00 != 1 then
|
||||
return -1
|
||||
endi
|
||||
if $data11 != 1 then
|
||||
if $data10 != 0 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
@ -80,11 +78,11 @@ print =============== step6
|
|||
$cc = 4 * 60000
|
||||
$ms = 1601481600000 + $cc
|
||||
sql select bottom(tbcol, 2) as b from $tb where ts > $ms
|
||||
print ===> $data01 $data11
|
||||
if $data01 != 5 then
|
||||
print ===> $data00 $data10
|
||||
if $data00 != 6 then
|
||||
return -1
|
||||
endi
|
||||
if $data11 != 6 then
|
||||
if $data10 != 5 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
|
|
@ -38,13 +38,10 @@ while $i < $tbNum
|
|||
$i = $i + 1
|
||||
endw
|
||||
|
||||
sleep 100
|
||||
|
||||
print =============== step2
|
||||
$i = 1
|
||||
$tb = $tbPrefix . $i
|
||||
|
||||
|
||||
sql select count(*) from $tb
|
||||
print ===> select count(*) from $tb => $data00
|
||||
if $data00 != $rowNum then
|
||||
|
@ -81,14 +78,14 @@ endi
|
|||
|
||||
print =============== step5
|
||||
sql select count(tbcol) as b from $tb interval(1m)
|
||||
print ===> $data01
|
||||
if $data01 != 1 then
|
||||
print ===> $data00
|
||||
if $data00 != 1 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
sql select count(tbcol) as b from $tb interval(1d)
|
||||
print ===> $data01
|
||||
if $data01 != $rowNum then
|
||||
print ===> $data00
|
||||
if $data00 != $rowNum then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
@ -96,8 +93,8 @@ print =============== step6
|
|||
$cc = 4 * 60000
|
||||
$ms = 1601481600000 + $cc
|
||||
sql select count(tbcol) as b from $tb where ts <= $ms interval(1m)
|
||||
print ===> $data01
|
||||
if $data01 != 1 then
|
||||
print ===> $data00
|
||||
if $data00 != 1 then
|
||||
return -1
|
||||
endi
|
||||
if $rows != 5 then
|
||||
|
@ -149,17 +146,17 @@ endi
|
|||
|
||||
print =============== step9
|
||||
sql select count(tbcol) as b from $mt interval(1m)
|
||||
print ===> $data01
|
||||
if $data01 != 10 then
|
||||
print ===> $data00
|
||||
if $data00 != 10 then
|
||||
return -1
|
||||
endi
|
||||
if $data11 != 10 then
|
||||
if $data10 != 10 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
sql select count(tbcol) as b from $mt interval(1d)
|
||||
print ===> $data01
|
||||
if $data01 != 200 then
|
||||
print ===> $data00
|
||||
if $data00 != 200 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
@ -177,9 +174,9 @@ endi
|
|||
print =============== step11
|
||||
$cc = 4 * 60000
|
||||
$ms = 1601481600000 + $cc
|
||||
sql select count(tbcol) as b from $mt where ts <= $ms interval(1m) group by tgcol
|
||||
sql select count(tbcol) as b from $mt where ts <= $ms partition by tgcol interval(1m)
|
||||
print ===> $data01
|
||||
if $data01 != 1 then
|
||||
if $data00 != 1 then
|
||||
return -1
|
||||
endi
|
||||
if $rows != 50 then
|
||||
|
|
|
@ -37,15 +37,13 @@ while $i < $tbNum
|
|||
$i = $i + 1
|
||||
endw
|
||||
|
||||
sleep 100
|
||||
|
||||
print =============== step2
|
||||
$i = 1
|
||||
$tb = $tbPrefix . $i
|
||||
|
||||
sql select diff(tbcol) from $tb
|
||||
print ===> $data11
|
||||
if $data11 != 1 then
|
||||
print ===> $data10
|
||||
if $data10 != 1 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
@ -53,23 +51,23 @@ print =============== step3
|
|||
$cc = 4 * 60000
|
||||
$ms = 1601481600000 + $cc
|
||||
sql select diff(tbcol) from $tb where ts > $ms
|
||||
print ===> $data11
|
||||
if $data11 != 1 then
|
||||
print ===> $data10
|
||||
if $data10 != 1 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
$cc = 4 * 60000
|
||||
$ms = 1601481600000 + $cc
|
||||
sql select diff(tbcol) from $tb where ts <= $ms
|
||||
print ===> $data11
|
||||
if $data11 != 1 then
|
||||
print ===> $data10
|
||||
if $data10 != 1 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
print =============== step4
|
||||
sql select diff(tbcol) as b from $tb
|
||||
print ===> $data11
|
||||
if $data11 != 1 then
|
||||
print ===> $data10
|
||||
if $data10 != 1 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
system sh/stop_dnodes.sh
|
||||
system sh/deploy.sh -n dnode1 -i 1
|
||||
system sh/cfg.sh -n dnode1 -c debugflag -v 131
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
sql connect
|
||||
|
||||
|
@ -39,91 +40,90 @@ while $i < $tbNum
|
|||
$i = $i + 1
|
||||
endw
|
||||
|
||||
sleep 100
|
||||
|
||||
print =============== step2
|
||||
$i = 1
|
||||
$tb = $tbPrefix . $i
|
||||
|
||||
sql select diff(c1) from $tb
|
||||
print ===> $data11
|
||||
if $data11 != 1 then
|
||||
print ===> $data10
|
||||
if $data10 != 1 then
|
||||
return -1
|
||||
endi
|
||||
sql select diff(c2) from $tb
|
||||
print ===> $data11
|
||||
if $data11 != 1.00000 then
|
||||
print ===> $data10
|
||||
if $data10 != 1.000000000 then
|
||||
return -1
|
||||
endi
|
||||
sql select diff(c3) from $tb
|
||||
print ===> $data11
|
||||
if $data11 != 1 then
|
||||
print ===> $data10
|
||||
if $data10 != 1 then
|
||||
return -1
|
||||
endi
|
||||
sql select diff(c4) from $tb
|
||||
print ===> $data11
|
||||
if $data11 != 1 then
|
||||
print ===> $data10
|
||||
if $data10 != 1 then
|
||||
return -1
|
||||
endi
|
||||
sql select diff(c5) from $tb
|
||||
print ===> $data11
|
||||
if $data11 != 0 then
|
||||
print ===> $data10
|
||||
if $data10 != 0 then
|
||||
return -1
|
||||
endi
|
||||
sql select diff(c6) from $tb
|
||||
print ===> $data11
|
||||
if $data11 != 1.000000000 then
|
||||
print ===> $data10
|
||||
if $data10 != 1.000000000 then
|
||||
return -1
|
||||
endi
|
||||
sql_error select diff(c7) from $tb
|
||||
|
||||
sql select diff(c7) from $tb
|
||||
sql_error select diff(c8) from $tb
|
||||
sql_error select diff(c9) from $tb
|
||||
sql_error select diff(ts) from $tb
|
||||
sql_error select diff(c1), diff(c2) from $tb
|
||||
#sql_error select 2+diff(c1) from $tb
|
||||
sql_error select diff(c1+2) from $tb
|
||||
|
||||
sql select 2+diff(c1) from $tb
|
||||
sql select diff(c1+2) from $tb
|
||||
sql_error select diff(c1) from $tb where ts > 0 and ts < now + 100m interval(10m)
|
||||
sql_error select diff(c1) from $mt
|
||||
sql select diff(c1) from $mt
|
||||
sql_error select diff(diff(c1)) from $tb
|
||||
sql_error select diff(c1) from m_di_tb1 where c2 like '2%'
|
||||
|
||||
|
||||
print =============== step3
|
||||
sql select diff(c1) from $tb where c1 > 5
|
||||
print ===> $data11
|
||||
if $data11 != 1 then
|
||||
print ===> $data10
|
||||
if $data10 != 1 then
|
||||
return -1
|
||||
endi
|
||||
sql select diff(c2) from $tb where c2 > 5
|
||||
print ===> $data11
|
||||
if $data11 != 1.00000 then
|
||||
print ===> $data10
|
||||
if $data10 != 1.000000000 then
|
||||
return -1
|
||||
endi
|
||||
sql select diff(c3) from $tb where c3 > 5
|
||||
print ===> $data11
|
||||
if $data11 != 1 then
|
||||
print ===> $data10
|
||||
if $data10 != 1 then
|
||||
return -1
|
||||
endi
|
||||
sql select diff(c4) from $tb where c4 > 5
|
||||
print ===> $data11
|
||||
if $data11 != 1 then
|
||||
print ===> $data10
|
||||
if $data10 != 1 then
|
||||
return -1
|
||||
endi
|
||||
sql select diff(c5) from $tb where c5 > 5
|
||||
print ===> $data11
|
||||
if $data11 != 0 then
|
||||
print ===> $data10
|
||||
if $data10 != 0 then
|
||||
return -1
|
||||
endi
|
||||
sql select diff(c6) from $tb where c6 > 5
|
||||
print ===> $data11
|
||||
if $data11 != 1.000000000 then
|
||||
print ===> $data10
|
||||
if $data10 != 1.000000000 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
print =============== step4
|
||||
sql select diff(c1) from $tb where c1 > 5 and c2 < $rowNum
|
||||
print ===> $data11
|
||||
if $data11 != 1 then
|
||||
print ===> $data10
|
||||
if $data10 != 1 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
@ -131,8 +131,8 @@ sql select diff(c1) from $tb where c9 like '%9' and c1 <= 20
|
|||
if $rows != 1 then
|
||||
return -1
|
||||
endi
|
||||
print ===> $data11
|
||||
if $data01 != 10 then
|
||||
print ===> $data10
|
||||
if $data00 != 10 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
|
|
@ -38,8 +38,6 @@ while $i < $tbNum
|
|||
$i = $i + 1
|
||||
endw
|
||||
|
||||
sleep 100
|
||||
|
||||
print =============== step2
|
||||
$i = 1
|
||||
$tb = $tbPrefix . $i
|
||||
|
@ -68,14 +66,14 @@ endi
|
|||
|
||||
print =============== step5
|
||||
sql select first(tbcol) as b from $tb interval(1m)
|
||||
print ===> $data01
|
||||
if $data01 != 0 then
|
||||
print ===> $data00
|
||||
if $data00 != 0 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
sql select first(tbcol) as b from $tb interval(1d)
|
||||
print ===> $data01
|
||||
if $data01 != 0 then
|
||||
print ===> $data00
|
||||
if $data00 != 0 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
@ -83,8 +81,8 @@ print =============== step6
|
|||
$cc = 4 * 60000
|
||||
$ms = 1601481600000 + $cc
|
||||
sql select first(tbcol) as b from $tb where ts <= $ms interval(1m)
|
||||
print ===> $data01
|
||||
if $data41 != 4 then
|
||||
print ===> $data00
|
||||
if $data40 != 4 then
|
||||
return -1
|
||||
endi
|
||||
if $rows != 5 then
|
||||
|
@ -124,14 +122,14 @@ endi
|
|||
print =============== step9
|
||||
sql select first(tbcol) as b from $mt interval(1m)
|
||||
print select first(tbcol) as b from $mt interval(1m)
|
||||
print ===> $data11
|
||||
if $data11 != 1 then
|
||||
print ===> $data10
|
||||
if $data10 != 1 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
sql select first(tbcol) as b from $mt interval(1d)
|
||||
print ===> $data01
|
||||
if $data01 != 0 then
|
||||
print ===> $data00
|
||||
if $data00 != 0 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
@ -149,9 +147,9 @@ endi
|
|||
print =============== step11
|
||||
$cc = 4 * 60000
|
||||
$ms = 1601481600000 + $cc
|
||||
sql select first(tbcol) as b from $mt where ts <= $ms interval(1m) group by tgcol
|
||||
print ===> $data11
|
||||
if $data11 != 1 then
|
||||
sql select first(tbcol) as b from $mt where ts <= $ms partition by tgcol interval(1m)
|
||||
print ===> $data10
|
||||
if $data10 != 1 then
|
||||
return -1
|
||||
endi
|
||||
print ===> $rows
|
||||
|
|
|
@ -47,10 +47,10 @@ print ===> $rows
|
|||
if $rows < $rowNum then
|
||||
return -1
|
||||
endi
|
||||
if $data01 != 1 then
|
||||
if $data00 != 1 then
|
||||
return -1
|
||||
endi
|
||||
if $data05 != 1 then
|
||||
if $data04 != 1 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
@ -65,10 +65,10 @@ endi
|
|||
if $rows < 3 then
|
||||
return -1
|
||||
endi
|
||||
if $data01 != 1 then
|
||||
if $data00 != 1 then
|
||||
return -1
|
||||
endi
|
||||
if $data05 != 1 then
|
||||
if $data04 != 1 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
@ -87,10 +87,10 @@ endi
|
|||
if $rows > 22 then
|
||||
return -1
|
||||
endi
|
||||
if $data01 != 1 then
|
||||
if $data00 != 1 then
|
||||
return -1
|
||||
endi
|
||||
if $data05 != 1 then
|
||||
if $data04 != 1 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
@ -109,10 +109,10 @@ endi
|
|||
if $rows > 50 then
|
||||
return -1
|
||||
endi
|
||||
if $data21 != 1 then
|
||||
if $data20 != 1 then
|
||||
return -1
|
||||
endi
|
||||
if $data25 != 1 then
|
||||
if $data24 != 1 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
@ -125,10 +125,10 @@ endi
|
|||
if $rows > 22 then
|
||||
return -1
|
||||
endi
|
||||
if $data11 > 15 then
|
||||
if $data10 > 15 then
|
||||
return -1
|
||||
endi
|
||||
if $data11 < 5 then
|
||||
if $data10 < 5 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
@ -143,10 +143,10 @@ endi
|
|||
if $rows > 7 then
|
||||
return -1
|
||||
endi
|
||||
if $data11 > 15 then
|
||||
if $data10 > 15 then
|
||||
return -1
|
||||
endi
|
||||
if $data11 < 5 then
|
||||
if $data10 < 5 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
@ -165,10 +165,10 @@ endi
|
|||
if $rows > 22 then
|
||||
return -1
|
||||
endi
|
||||
if $data11 > 15 then
|
||||
if $data10 > 15 then
|
||||
return -1
|
||||
endi
|
||||
if $data11 < 5 then
|
||||
if $data10 < 5 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
@ -186,10 +186,10 @@ endi
|
|||
if $rows > 50 then
|
||||
return -1
|
||||
endi
|
||||
if $data11 > 15 then
|
||||
if $data10 > 15 then
|
||||
return -1
|
||||
endi
|
||||
if $data11 < 5 then
|
||||
if $data10 < 5 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
|
|
@ -38,8 +38,6 @@ while $i < $tbNum
|
|||
$i = $i + 1
|
||||
endw
|
||||
|
||||
sleep 100
|
||||
|
||||
print =============== step2
|
||||
$i = 1
|
||||
$tb = $tbPrefix . $i
|
||||
|
@ -69,14 +67,14 @@ endi
|
|||
|
||||
print =============== step5
|
||||
sql select last(tbcol) as b from $tb interval(1m)
|
||||
print ===> $data11
|
||||
if $data11 != 1 then
|
||||
print ===> $data10
|
||||
if $data10 != 1 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
sql select last(tbcol) as b from $tb interval(1d)
|
||||
print ===> $data01
|
||||
if $data01 != 19 then
|
||||
print ===> $data00
|
||||
if $data00 != 19 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
@ -85,8 +83,8 @@ $cc = 4 * 60000
|
|||
$ms = 1601481600000 + $cc
|
||||
|
||||
sql select last(tbcol) as b from $tb where ts <= $ms interval(1m)
|
||||
print ===> $data11
|
||||
if $data11 != 1 then
|
||||
print ===> $data10
|
||||
if $data10 != 1 then
|
||||
return -1
|
||||
endi
|
||||
if $rows != 5 then
|
||||
|
@ -127,14 +125,14 @@ endi
|
|||
|
||||
print =============== step9
|
||||
sql select last(tbcol) as b from $mt interval(1m)
|
||||
print ===> $data11
|
||||
if $data11 != 1 then
|
||||
print ===> $data10
|
||||
if $data10 != 1 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
sql select last(tbcol) as b from $mt interval(1d)
|
||||
print ===> $data01
|
||||
if $data01 != 19 then
|
||||
print ===> $data00
|
||||
if $data00 != 19 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
@ -153,9 +151,9 @@ print =============== step11
|
|||
$cc = 4 * 60000
|
||||
$ms = 1601481600000 + $cc
|
||||
|
||||
sql select last(tbcol) as b from $mt where ts <= $ms interval(1m) group by tgcol
|
||||
print ===> $data11
|
||||
if $data11 != 1 then
|
||||
sql select last(tbcol) as b from $mt where ts <= $ms partition by tgcol interval(1m)
|
||||
print ===> $data10
|
||||
if $data10 != 1 then
|
||||
return -1
|
||||
endi
|
||||
print ===> $rows
|
||||
|
|
|
@ -38,8 +38,6 @@ while $i < $tbNum
|
|||
$i = $i + 1
|
||||
endw
|
||||
|
||||
sleep 100
|
||||
|
||||
print =============== step2
|
||||
$i = 1
|
||||
$tb = $tbPrefix . $i
|
||||
|
@ -53,6 +51,7 @@ endi
|
|||
print =============== step3
|
||||
$cc = 4 * 60000
|
||||
$ms = 1601481600000 + $cc
|
||||
print select last_row(tbcol) from $tb where ts <= $ms
|
||||
sql select last_row(tbcol) from $tb where ts <= $ms
|
||||
print ===> $data00
|
||||
if $data00 != 4 then
|
||||
|
@ -98,8 +97,6 @@ if $data00 != 4 then
|
|||
return -1
|
||||
endi
|
||||
|
||||
|
||||
|
||||
print =============== step10
|
||||
sql select last_row(tbcol) as b from $mt group by tgcol
|
||||
print ===> $data00
|
||||
|
|
|
@ -37,8 +37,6 @@ while $i < $tbNum
|
|||
$i = $i + 1
|
||||
endw
|
||||
|
||||
sleep 100
|
||||
|
||||
print =============== step2
|
||||
$i = 1
|
||||
$tb = $tbPrefix . $i
|
||||
|
@ -65,21 +63,21 @@ endi
|
|||
|
||||
print =============== step5
|
||||
sql select leastsquares(tbcol, 1, 1) as b from $tb interval(1m)
|
||||
print ===> $data01
|
||||
if $data01 != @{slop:1.000000, intercept:1.000000}@ then
|
||||
print ===> $data00
|
||||
if $data00 != @{slop:1.000000, intercept:1.000000}@ then
|
||||
return -1
|
||||
endi
|
||||
|
||||
sql select leastsquares(tbcol, 1, 1) as b from $tb interval(1d)
|
||||
print ===> $data01
|
||||
if $data01 != @{slop:1.000000, intercept:1.000000}@ then
|
||||
print ===> $data00
|
||||
if $data00 != @{slop:1.000000, intercept:1.000000}@ then
|
||||
return -1
|
||||
endi
|
||||
|
||||
print =============== step6
|
||||
sql select leastsquares(tbcol, 1, 1) as b from $tb where ts < now + 4m interval(1m)
|
||||
print ===> $data01
|
||||
if $data01 != @{slop:1.000000, intercept:1.000000}@ then
|
||||
print ===> $data00
|
||||
if $data00 != @{slop:1.000000, intercept:1.000000}@ then
|
||||
return -1
|
||||
endi
|
||||
print ===> $rows
|
||||
|
|
|
@ -38,8 +38,6 @@ while $i < $tbNum
|
|||
$i = $i + 1
|
||||
endw
|
||||
|
||||
sleep 100
|
||||
|
||||
print =============== step2
|
||||
$i = 1
|
||||
$tb = $tbPrefix . $i
|
||||
|
@ -69,14 +67,14 @@ endi
|
|||
|
||||
print =============== step5
|
||||
sql select max(tbcol) as b from $tb interval(1m)
|
||||
print ===> $data11
|
||||
if $data11 != 1 then
|
||||
print ===> $data10
|
||||
if $data10 != 1 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
sql select max(tbcol) as b from $tb interval(1d)
|
||||
print ===> $data01
|
||||
if $data01 != 19 then
|
||||
print ===> $data00
|
||||
if $data00 != 19 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
@ -85,8 +83,8 @@ $cc = 4 * 60000
|
|||
$ms = 1601481600000 + $cc
|
||||
|
||||
sql select max(tbcol) as b from $tb where ts <= $ms interval(1m)
|
||||
print ===> $data11
|
||||
if $data11 != 1 then
|
||||
print ===> $data10
|
||||
if $data10 != 1 then
|
||||
return -1
|
||||
endi
|
||||
if $rows != 5 then
|
||||
|
@ -127,14 +125,14 @@ endi
|
|||
|
||||
print =============== step9
|
||||
sql select max(tbcol) as b from $mt interval(1m)
|
||||
print ===> $data11
|
||||
if $data11 != 1 then
|
||||
print ===> $data10
|
||||
if $data10 != 1 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
sql select max(tbcol) as b from $mt interval(1d)
|
||||
print ===> $data01
|
||||
if $data01 != 19 then
|
||||
print ===> $data00
|
||||
if $data00 != 19 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
@ -153,9 +151,9 @@ print =============== step11
|
|||
$cc = 4 * 60000
|
||||
$ms = 1601481600000 + $cc
|
||||
|
||||
sql select max(tbcol) as b from $mt where ts <= $ms interval(1m) group by tgcol
|
||||
print ===> $data11
|
||||
if $data11 != 1 then
|
||||
sql select max(tbcol) as b from $mt where ts <= $ms partition by tgcol interval(1m)
|
||||
print ===> $data10
|
||||
if $data10 != 1 then
|
||||
return -1
|
||||
endi
|
||||
print ===> $rows
|
||||
|
|
|
@ -38,8 +38,6 @@ while $i < $tbNum
|
|||
$i = $i + 1
|
||||
endw
|
||||
|
||||
sleep 100
|
||||
|
||||
print =============== step2
|
||||
$i = 1
|
||||
$tb = $tbPrefix . $i
|
||||
|
|
|
@ -100,9 +100,10 @@ if $rows != 1 then
|
|||
return -1
|
||||
endi
|
||||
|
||||
sql_error select * from $tb where tbcol = NULL
|
||||
|
||||
return
|
||||
sql select * from $tb where tbcol = NULL
|
||||
if $rows != 0 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
print =============== step5
|
||||
sql create table tt using $mt tags( NULL )
|
||||
|
|
|
@ -38,8 +38,6 @@ while $i < $tbNum
|
|||
$i = $i + 1
|
||||
endw
|
||||
|
||||
sleep 100
|
||||
|
||||
print =============== step2
|
||||
$i = 1
|
||||
$tb = $tbPrefix . $i
|
||||
|
|
|
@ -38,8 +38,6 @@ while $i < $tbNum
|
|||
$i = $i + 1
|
||||
endw
|
||||
|
||||
sleep 100
|
||||
|
||||
print =============== step2
|
||||
$i = 1
|
||||
$tb = $tbPrefix . $i
|
||||
|
|
|
@ -38,8 +38,6 @@ while $i < $tbNum
|
|||
$i = $i + 1
|
||||
endw
|
||||
|
||||
sleep 100
|
||||
|
||||
print =============== step2
|
||||
$i = 1
|
||||
$tb = $tbPrefix . $i
|
||||
|
|
|
@ -38,8 +38,6 @@ while $i < $tbNum
|
|||
$i = $i + 1
|
||||
endw
|
||||
|
||||
sleep 100
|
||||
|
||||
print =============== step2
|
||||
$i = 1
|
||||
$tb = $tbPrefix . $i
|
||||
|
|
|
@ -1,9 +1,9 @@
|
|||
system sh/stop_dnodes.sh
|
||||
system sh/deploy.sh -n dnode1 -i 1
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
sleep 50
|
||||
sql connect
|
||||
|
||||
|
||||
print =============== create database
|
||||
sql create database `database`
|
||||
sql create database `DataBase`
|
||||
|
@ -184,23 +184,6 @@ print =============== stop and restart taosd
|
|||
system sh/exec.sh -n dnode1 -s stop -x SIGINT
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
|
||||
$loop_cnt = 0
|
||||
check_dnode_ready:
|
||||
$loop_cnt = $loop_cnt + 1
|
||||
sleep 200
|
||||
if $loop_cnt == 10 then
|
||||
print ====> dnode not ready!
|
||||
return -1
|
||||
endi
|
||||
sql show dnodes
|
||||
print ===> $rows $data00 $data01 $data02 $data03 $data04 $data05
|
||||
if $data00 != 1 then
|
||||
return -1
|
||||
endi
|
||||
if $data04 != ready then
|
||||
goto check_dnode_ready
|
||||
endi
|
||||
|
||||
sql show databases
|
||||
print rows: $rows
|
||||
print $data00 $data01
|
||||
|
|
|
@ -1,10 +1,6 @@
|
|||
system sh/stop_dnodes.sh
|
||||
|
||||
system sh/deploy.sh -n dnode1 -i 1
|
||||
system sh/cfg.sh -n dnode1 -c walLevel -v 1
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
|
||||
sleep 2000
|
||||
sql connect
|
||||
|
||||
$i = 0
|
|
@ -271,23 +271,6 @@ print =============== stop and restart taosd, then again do query above
|
|||
system sh/exec.sh -n dnode1 -s stop -x SIGINT
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
|
||||
$loop_cnt = 0
|
||||
check_dnode_ready:
|
||||
$loop_cnt = $loop_cnt + 1
|
||||
sleep 200
|
||||
if $loop_cnt == 10 then
|
||||
print ====> dnode not ready!
|
||||
return -1
|
||||
endi
|
||||
sql show dnodes
|
||||
print ===> $rows $data00 $data01 $data02 $data03 $data04 $data05
|
||||
if $data00 != 1 then
|
||||
return -1
|
||||
endi
|
||||
if $data04 != ready then
|
||||
goto check_dnode_ready
|
||||
endi
|
||||
|
||||
print =============== query data from child table
|
||||
sql select * from ct1
|
||||
print rows: $rows
|
||||
|
|
|
@ -2,6 +2,7 @@ system sh/stop_dnodes.sh
|
|||
system sh/deploy.sh -n dnode1 -i 1
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
sql connect
|
||||
|
||||
print =============== create database
|
||||
sql create database d1
|
||||
sql show databases
|
||||
|
|
|
@ -1,7 +1,6 @@
|
|||
system sh/stop_dnodes.sh
|
||||
system sh/deploy.sh -n dnode1 -i 1
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
sleep 50
|
||||
sql connect
|
||||
|
||||
print =============== create database
|
||||
|
@ -64,23 +63,6 @@ reboot_and_check:
|
|||
system sh/exec.sh -n dnode1 -s stop -x SIGINT
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
|
||||
$loop_cnt = 0
|
||||
check_dnode_ready:
|
||||
$loop_cnt = $loop_cnt + 1
|
||||
sleep 200
|
||||
if $loop_cnt == 10 then
|
||||
print ====> dnode not ready!
|
||||
return -1
|
||||
endi
|
||||
sql show dnodes
|
||||
print ===> $rows $data00 $data01 $data02 $data03 $data04 $data05
|
||||
if $data00 != 1 then
|
||||
return -1
|
||||
endi
|
||||
if $data04 != ready then
|
||||
goto check_dnode_ready
|
||||
endi
|
||||
|
||||
print =============== insert duplicated records to memory - loop $reboot_max - $reboot_cnt
|
||||
sql use db
|
||||
sql insert into ct1 values ('2022-05-01 18:30:27.001', 0.0);
|
||||
|
|
|
@ -1,10 +1,6 @@
|
|||
system sh/stop_dnodes.sh
|
||||
|
||||
system sh/deploy.sh -n dnode1 -i 1
|
||||
system sh/cfg.sh -n dnode1 -c walLevel -v 1
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
|
||||
sleep 2000
|
||||
sql connect
|
||||
|
||||
$tbNum = 10
|
||||
|
@ -19,7 +15,7 @@ $stb = stb
|
|||
|
||||
sql drop database $db -x step1
|
||||
step1:
|
||||
sql create database $db ctime 30
|
||||
sql create database $db
|
||||
print ====== create tables
|
||||
sql use $db
|
||||
sql create table $stb (ts timestamp, c1 int) tags(t1 int)
|
||||
|
@ -43,13 +39,9 @@ print ====== tables created
|
|||
|
||||
print ================== restart server to commit data into disk
|
||||
system sh/exec.sh -n dnode1 -s stop -x SIGINT
|
||||
sleep 3000
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
print ================== server restart completed
|
||||
|
||||
sql reset query cache
|
||||
sleep 1000
|
||||
|
||||
sql use $db
|
||||
sql drop table tb5
|
||||
$i = 0
|
||||
|
@ -69,13 +61,9 @@ endw
|
|||
|
||||
print ================== restart server to commit data into disk
|
||||
system sh/exec.sh -n dnode1 -s stop -x SIGINT
|
||||
sleep 3000
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
print ================== server restart completed
|
||||
|
||||
sql reset query cache
|
||||
sleep 1000
|
||||
|
||||
sql use $db
|
||||
|
||||
sql create table tb5 using $stb tags(5)
|
|
@ -1,7 +1,6 @@
|
|||
system sh/stop_dnodes.sh
|
||||
system sh/deploy.sh -n dnode1 -i 1
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
sleep 50
|
||||
sql connect
|
||||
|
||||
print =============== create database
|
||||
|
@ -211,66 +210,48 @@ endi
|
|||
#===================================================================
|
||||
|
||||
#print =============== query data from stb
|
||||
#sql select * from stb
|
||||
#print ===>
|
||||
#print ===> rows: $rows
|
||||
#print ===> rows0: $data00 $data01 $data02 $data03 $data04
|
||||
#if $rows != 4 then
|
||||
# return -1
|
||||
#endi
|
||||
sql select * from stb
|
||||
print ===>
|
||||
print ===> rows: $rows
|
||||
print ===> rows0: $data00 $data01 $data02 $data03 $data04
|
||||
if $rows != 12 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
#print =============== select count(*) from supter table
|
||||
#sql select count(*) from stb
|
||||
#print $data00 $data01 $data02
|
||||
#if $rows != 1 then
|
||||
# return -1
|
||||
#endi
|
||||
#if $data00 != 12 then
|
||||
# return -1
|
||||
#endi
|
||||
sql select count(*) from stb
|
||||
print $data00 $data01 $data02
|
||||
if $rows != 1 then
|
||||
return -1
|
||||
endi
|
||||
if $data00 != 12 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
#print =============== select count(column) from supter table
|
||||
#sql select count(ts), count(c1), count(c2), count(c3) from stb
|
||||
#print $data00 $data01 $data02 $data03
|
||||
#if $data00 != 12 then
|
||||
# return -1
|
||||
#endi
|
||||
#if $data01 != 8 then
|
||||
# return -1
|
||||
#endi
|
||||
#if $data02 != 8 then
|
||||
# return -1
|
||||
#endi
|
||||
#if $data03 != 8 then
|
||||
# return -1
|
||||
#endi
|
||||
sql select count(ts), count(c1), count(c2), count(c3) from stb
|
||||
print $data00 $data01 $data02 $data03
|
||||
if $data00 != 12 then
|
||||
return -1
|
||||
endi
|
||||
if $data01 != 8 then
|
||||
return -1
|
||||
endi
|
||||
if $data02 != 8 then
|
||||
return -1
|
||||
endi
|
||||
if $data03 != 8 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
#===================================================================
|
||||
#===================================================================
|
||||
|
||||
print =============== stop and restart taosd, then again do query above
|
||||
system sh/exec.sh -n dnode1 -s stop -x SIGINT
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
|
||||
print ===> waiting dnode ready
|
||||
$loop_cnt = 0
|
||||
check_dnode_ready:
|
||||
$loop_cnt = $loop_cnt + 1
|
||||
sleep 200
|
||||
if $loop_cnt == 10 then
|
||||
print ====> dnode not ready!
|
||||
return -1
|
||||
endi
|
||||
sql show dnodes
|
||||
print ===> $rows $data00 $data01 $data02 $data03 $data04 $data05
|
||||
if $data00 != 1 then
|
||||
return -1
|
||||
endi
|
||||
if $data04 != ready then
|
||||
goto check_dnode_ready
|
||||
endi
|
||||
#===================================================================
|
||||
|
||||
#===================================================================
|
||||
#===================================================================
|
||||
print =============== query data from child table
|
||||
sql select * from ct1
|
||||
print ===> select * from ct1
|
||||
|
@ -292,15 +273,15 @@ endi
|
|||
if $data03 != 3.000000000 then
|
||||
return -1
|
||||
endi
|
||||
#if $data41 != -14 then
|
||||
# return -1
|
||||
#endi
|
||||
#if $data42 != -2.40000 then
|
||||
# return -1
|
||||
#endi
|
||||
#if $data43 != -3.400000000 then
|
||||
# return -1
|
||||
#endi
|
||||
if $data41 != 12 then
|
||||
return -1
|
||||
endi
|
||||
if $data42 != 2.20000 then
|
||||
return -1
|
||||
endi
|
||||
if $data43 != NULL then
|
||||
return -1
|
||||
endi
|
||||
|
||||
print =============== select count(*) from child table
|
||||
sql select count(*) from ct1
|
||||
|
@ -435,40 +416,39 @@ if $data92 != 3.600000000 then
|
|||
return -1
|
||||
endi
|
||||
#===================================================================
|
||||
#===================================================================
|
||||
|
||||
#print =============== query data from stb
|
||||
#sql select * from stb
|
||||
#print ===>
|
||||
#print ===> rows: $rows
|
||||
#print ===> rows0: $data00 $data01 $data02 $data03 $data04
|
||||
#if $rows != 4 then
|
||||
# return -1
|
||||
#endi
|
||||
#print =============== select count(*) from supter table
|
||||
#sql select count(*) from stb
|
||||
#print $data00 $data01 $data02
|
||||
#if $rows != 1 then
|
||||
# return -1
|
||||
#endi
|
||||
#if $data00 != 12 then
|
||||
# return -1
|
||||
#endi
|
||||
print =============== query data from stb
|
||||
sql select * from stb
|
||||
print ===>
|
||||
print ===> rows: $rows
|
||||
print ===> rows0: $data00 $data01 $data02 $data03 $data04
|
||||
if $rows != 12 then
|
||||
return -1
|
||||
endi
|
||||
print =============== select count(*) from supter table
|
||||
sql select count(*) from stb
|
||||
print $data00 $data01 $data02
|
||||
if $rows != 1 then
|
||||
return -1
|
||||
endi
|
||||
if $data00 != 12 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
#print =============== select count(column) from supter table
|
||||
#sql select count(ts), count(c1), count(c2), count(c3) from stb
|
||||
#print $data00 $data01 $data02 $data03
|
||||
#if $data00 != 12 then
|
||||
# return -1
|
||||
#endi
|
||||
#if $data01 != 8 then
|
||||
# return -1
|
||||
#endi
|
||||
#if $data02 != 8 then
|
||||
# return -1
|
||||
#endi
|
||||
#if $data03 != 8 then
|
||||
# return -1
|
||||
#endi
|
||||
print =============== select count(column) from supter table
|
||||
sql select count(ts), count(c1), count(c2), count(c3) from stb
|
||||
print $data00 $data01 $data02 $data03
|
||||
if $data00 != 12 then
|
||||
return -1
|
||||
endi
|
||||
if $data01 != 8 then
|
||||
return -1
|
||||
endi
|
||||
if $data02 != 8 then
|
||||
return -1
|
||||
endi
|
||||
if $data03 != 8 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
system sh/exec.sh -n dnode1 -s stop -x SIGINT
|
||||
|
|
|
@ -1,11 +1,6 @@
|
|||
system sh/stop_dnodes.sh
|
||||
|
||||
|
||||
system sh/deploy.sh -n dnode1 -i 1
|
||||
system sh/cfg.sh -n dnode1 -c walLevel -v 1
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
|
||||
sleep 2000
|
||||
sql connect
|
||||
|
||||
$i = 0
|
||||
|
@ -190,7 +185,7 @@ clear:
|
|||
|
||||
sql drop database $db
|
||||
sql show databases
|
||||
if $rows != 0 then
|
||||
if $rows != 2 then
|
||||
return -1
|
||||
endi
|
||||
|
|
@ -1,11 +1,6 @@
|
|||
system sh/stop_dnodes.sh
|
||||
|
||||
|
||||
system sh/deploy.sh -n dnode1 -i 1
|
||||
system sh/cfg.sh -n dnode1 -c walLevel -v 1
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
|
||||
sleep 2000
|
||||
sql connect
|
||||
|
||||
$i = 0
|
||||
|
@ -175,7 +170,7 @@ clear:
|
|||
|
||||
sql drop database $db
|
||||
sql show databases
|
||||
if $rows != 0 then
|
||||
if $rows != 2 then
|
||||
return -1
|
||||
endi
|
||||
|
|
@ -1,11 +1,6 @@
|
|||
system sh/stop_dnodes.sh
|
||||
|
||||
|
||||
system sh/deploy.sh -n dnode1 -i 1
|
||||
system sh/cfg.sh -n dnode1 -c walLevel -v 1
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
|
||||
sleep 2000
|
||||
sql connect
|
||||
|
||||
$i = 0
|
||||
|
@ -19,15 +14,7 @@ sql drop database -x step1
|
|||
step1:
|
||||
sql create database $db
|
||||
sql use $db
|
||||
|
||||
$x = 0
|
||||
create1:
|
||||
$x = $x + 1
|
||||
sleep 1000
|
||||
if $x == 20 then
|
||||
return -1
|
||||
endi
|
||||
sql create table $tb (ts timestamp, speed int) -x create1
|
||||
sql create table $tb (ts timestamp, speed int)
|
||||
|
||||
#commit to file will trigger if insert 82 rows
|
||||
$N = 82
|
||||
|
@ -204,7 +191,7 @@ clear:
|
|||
|
||||
sql drop database $db
|
||||
sql show databases
|
||||
if $rows != 0 then
|
||||
if $rows != 2 then
|
||||
return -1
|
||||
endi
|
||||
|
|
@ -1,11 +1,6 @@
|
|||
system sh/stop_dnodes.sh
|
||||
|
||||
|
||||
system sh/deploy.sh -n dnode1 -i 1
|
||||
system sh/cfg.sh -n dnode1 -c walLevel -v 1
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
|
||||
sleep 2000
|
||||
sql connect
|
||||
|
||||
$i = 0
|
||||
|
@ -167,7 +162,7 @@ endi
|
|||
|
||||
sql drop database $db
|
||||
sql show databases
|
||||
if $rows != 0 then
|
||||
if $rows != 2 then
|
||||
return -1
|
||||
endi
|
||||
|
|
@ -1,11 +1,6 @@
|
|||
system sh/stop_dnodes.sh
|
||||
|
||||
|
||||
system sh/deploy.sh -n dnode1 -i 1
|
||||
system sh/cfg.sh -n dnode1 -c walLevel -v 1
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
|
||||
sleep 2000
|
||||
sql connect
|
||||
|
||||
$i = 0
|
||||
|
@ -20,14 +15,7 @@ step1:
|
|||
sql create database $db
|
||||
sql use $db
|
||||
|
||||
$x = 0
|
||||
create1:
|
||||
$x = $x + 1
|
||||
sleep 1000
|
||||
if $x == 20 then
|
||||
return -1
|
||||
endi
|
||||
sql create table $tb (ts timestamp, speed int) -x create1
|
||||
sql create table $tb (ts timestamp, speed int)
|
||||
|
||||
#commit to file will trigger if insert 82 rows
|
||||
|
||||
|
@ -202,7 +190,7 @@ clear:
|
|||
|
||||
sql drop database $db
|
||||
sql show databases
|
||||
if $rows != 0 then
|
||||
if $rows != 2 then
|
||||
return -1
|
||||
endi
|
||||
|
|
@ -1,11 +1,6 @@
|
|||
system sh/stop_dnodes.sh
|
||||
|
||||
|
||||
system sh/deploy.sh -n dnode1 -i 1
|
||||
system sh/cfg.sh -n dnode1 -c walLevel -v 1
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
|
||||
sleep 2000
|
||||
sql connect
|
||||
|
||||
$i = 0
|
||||
|
@ -20,14 +15,7 @@ step1:
|
|||
sql create database $db
|
||||
sql use $db
|
||||
|
||||
$x = 0
|
||||
create1:
|
||||
$x = $x + 1
|
||||
sleep 1000
|
||||
if $x == 20 then
|
||||
return -1
|
||||
endi
|
||||
sql create table $tb (ts timestamp, speed int) -x create1
|
||||
sql create table $tb (ts timestamp, speed int)
|
||||
|
||||
$N = 20000
|
||||
|
||||
|
@ -49,7 +37,7 @@ endi
|
|||
|
||||
sql drop database $db
|
||||
sql show databases
|
||||
if $rows != 0 then
|
||||
if $rows != 2 then
|
||||
return -1
|
||||
endi
|
||||
|
|
@ -1,10 +1,7 @@
|
|||
system sh/stop_dnodes.sh
|
||||
|
||||
system sh/deploy.sh -n dnode1 -i 1
|
||||
system sh/cfg.sh -n dnode1 -c walLevel -v 1
|
||||
system sh/cfg.sh -n dnode1 -c debugflag -v 131
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
|
||||
sleep 2000
|
||||
sql connect
|
||||
|
||||
sql create database d1;
|
|
@ -239,5 +239,131 @@ if $data32 != 6 then
|
|||
goto loop0
|
||||
endi
|
||||
|
||||
print step 4
|
||||
|
||||
sql create database test1 vgroups 1
|
||||
sql use test1
|
||||
sql create stable st(ts timestamp, a int, b int, c int, d double) tags(ta int,tb int,tc int);
|
||||
sql create table t1 using st tags(1,1,1);
|
||||
sql create table t2 using st tags(2,2,2);
|
||||
|
||||
sql create stream streams11 trigger at_once into streamt as select _wstart, count(*) c1, sum(a) c3 , max(b) c4, min(c) c5 from t1 interval(10s, 5s);
|
||||
sql create stream streams12 trigger at_once into streamt2 as select _wstart, count(*) c1, sum(a) c3 , max(b) c4, min(c) c5 from st interval(10s, 5s);
|
||||
|
||||
sql insert into t1 values(1648791213000,1,2,3,1.0);
|
||||
sql insert into t1 values(1648791223001,2,2,3,1.1);
|
||||
sql insert into t1 values(1648791233002,3,2,3,2.1);
|
||||
sql insert into t1 values(1648791243003,4,2,3,3.1);
|
||||
sql insert into t1 values(1648791213004,4,2,3,4.1);
|
||||
|
||||
sql insert into t2 values(1648791213000,1,2,3,1.0);
|
||||
sql insert into t2 values(1648791223001,2,2,3,1.1);
|
||||
sql insert into t2 values(1648791233002,3,2,3,2.1);
|
||||
sql insert into t2 values(1648791243003,4,2,3,3.1);
|
||||
sql insert into t2 values(1648791213004,4,2,3,4.1);
|
||||
|
||||
$loop_count = 0
|
||||
|
||||
loop1:
|
||||
sleep 300
|
||||
|
||||
$loop_count = $loop_count + 1
|
||||
if $loop_count == 10 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
sql select * from streamt
|
||||
|
||||
# row 0
|
||||
if $data01 != 2 then
|
||||
print =====data01=$data01
|
||||
goto loop1
|
||||
endi
|
||||
|
||||
if $data02 != 5 then
|
||||
print =====data02=$data02
|
||||
goto loop1
|
||||
endi
|
||||
|
||||
# row 1
|
||||
if $data11 != 1 then
|
||||
print =====data11=$data11
|
||||
goto loop1
|
||||
endi
|
||||
|
||||
if $data12 != 2 then
|
||||
print =====data12=$data12
|
||||
goto loop1
|
||||
endi
|
||||
|
||||
# row 2
|
||||
if $data21 != 1 then
|
||||
print =====data21=$data21
|
||||
goto loop1
|
||||
endi
|
||||
|
||||
if $data22 != 3 then
|
||||
print =====data22=$data22
|
||||
goto loop1
|
||||
endi
|
||||
|
||||
# row 3
|
||||
if $data31 != 1 then
|
||||
print =====data31=$data31
|
||||
goto loop1
|
||||
endi
|
||||
|
||||
if $data32 != 4 then
|
||||
print =====data32=$data32
|
||||
goto loop1
|
||||
endi
|
||||
|
||||
print step 5
|
||||
|
||||
sql select * from streamt2
|
||||
|
||||
# row 0
|
||||
if $data01 != 4 then
|
||||
print =====data01=$data01
|
||||
goto loop1
|
||||
endi
|
||||
|
||||
if $data02 != 10 then
|
||||
print =====data02=$data02
|
||||
goto loop1
|
||||
endi
|
||||
|
||||
# row 1
|
||||
if $data11 != 2 then
|
||||
print =====data11=$data11
|
||||
goto loop1
|
||||
endi
|
||||
|
||||
if $data12 != 4 then
|
||||
print =====data12=$data12
|
||||
goto loop1
|
||||
endi
|
||||
|
||||
# row 2
|
||||
if $data21 != 2 then
|
||||
print =====data21=$data21
|
||||
goto loop1
|
||||
endi
|
||||
|
||||
if $data22 != 6 then
|
||||
print =====data22=$data22
|
||||
goto loop1
|
||||
endi
|
||||
|
||||
# row 3
|
||||
if $data31 != 2 then
|
||||
print =====data31=$data31
|
||||
goto loop1
|
||||
endi
|
||||
|
||||
if $data32 != 8 then
|
||||
print =====data32=$data32
|
||||
goto loop1
|
||||
endi
|
||||
|
||||
system sh/stop_dnodes.sh
|
|
@ -1,13 +1,12 @@
|
|||
system sh/stop_dnodes.sh
|
||||
system sh/deploy.sh -n dnode1 -i 1
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
sleep 2000
|
||||
sql connect
|
||||
|
||||
print =============== create database
|
||||
sql create database db
|
||||
sql show databases
|
||||
if $rows != 1 then
|
||||
if $rows != 3 then
|
||||
return -1
|
||||
endi
|
||||
|
|
@ -213,23 +213,6 @@ endi
|
|||
system sh/exec.sh -n dnode1 -s stop -x SIGINT
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
|
||||
$loop_cnt = 0
|
||||
check_dnode_ready:
|
||||
$loop_cnt = $loop_cnt + 1
|
||||
sleep 200
|
||||
if $loop_cnt == 10 then
|
||||
print ====> dnode not ready!
|
||||
return -1
|
||||
endi
|
||||
sql show dnodes
|
||||
print ===> $rows $data00 $data01 $data02 $data03 $data04 $data05
|
||||
if $data00 != 1 then
|
||||
return -1
|
||||
endi
|
||||
if $data04 != ready then
|
||||
goto check_dnode_ready
|
||||
endi
|
||||
|
||||
print =============== query data
|
||||
sql select * from c1
|
||||
print rows: $rows
|
||||
|
|
|
@ -1,7 +1,6 @@
|
|||
system sh/stop_dnodes.sh
|
||||
system sh/deploy.sh -n dnode1 -i 1
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
sleep 2000
|
||||
sql connect
|
||||
|
||||
print =============== one table
|
||||
|
@ -21,11 +20,11 @@ endi
|
|||
|
||||
print =============== show
|
||||
sql show databases
|
||||
if $data02 != 2 then
|
||||
if $data22 != 2 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
if $data03 != 1 then
|
||||
if $data24 != 1 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
@ -34,7 +33,7 @@ if $data00 != 2 then
|
|||
return -1
|
||||
endi
|
||||
|
||||
if $data01 != 2 then
|
||||
if $data01 != d1 then
|
||||
return -1
|
||||
endi
|
||||
|
|
@ -1,13 +1,12 @@
|
|||
system sh/stop_dnodes.sh
|
||||
system sh/deploy.sh -n dnode1 -i 1
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
sleep 2000
|
||||
sql connect
|
||||
|
||||
print =============== create database
|
||||
sql create database db
|
||||
sql show databases
|
||||
if $rows != 1 then
|
||||
if $rows != 3 then
|
||||
return -1
|
||||
endi
|
||||
|
|
@ -1,9 +1,6 @@
|
|||
system sh/stop_dnodes.sh
|
||||
system sh/deploy.sh -n dnode1 -i 1
|
||||
system sh/cfg.sh -n dnode1 -c walLevel -v 1
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
|
||||
sleep 2000
|
||||
sql connect
|
||||
|
||||
$i = 0
|
||||
|
@ -66,7 +63,7 @@ endi
|
|||
|
||||
sql drop database $db
|
||||
sql show databases
|
||||
if $rows != 0 then
|
||||
if $rows != 2 then
|
||||
return -1
|
||||
endi
|
||||
|
|
@ -1,9 +1,6 @@
|
|||
system sh/stop_dnodes.sh
|
||||
system sh/deploy.sh -n dnode1 -i 1
|
||||
system sh/cfg.sh -n dnode1 -c walLevel -v 1
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
|
||||
sleep 2000
|
||||
sql connect
|
||||
|
||||
$i = 0
|
||||
|
@ -56,7 +53,7 @@ endi
|
|||
|
||||
sql drop database $db
|
||||
sql show databases
|
||||
if $rows != 0 then
|
||||
if $rows != 2 then
|
||||
return -1
|
||||
endi
|
||||
|
|
@ -1,9 +1,6 @@
|
|||
system sh/stop_dnodes.sh
|
||||
system sh/deploy.sh -n dnode1 -i 1
|
||||
system sh/cfg.sh -n dnode1 -c walLevel -v 1
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
|
||||
sleep 2000
|
||||
sql connect
|
||||
|
||||
$i = 0
|
||||
|
@ -85,7 +82,7 @@ endi
|
|||
|
||||
sql drop database $db
|
||||
sql show databases
|
||||
if $rows != 0 then
|
||||
if $rows != 2 then
|
||||
return -1
|
||||
endi
|
||||
|
|
@ -1,9 +1,6 @@
|
|||
system sh/stop_dnodes.sh
|
||||
system sh/deploy.sh -n dnode1 -i 1
|
||||
system sh/cfg.sh -n dnode1 -c walLevel -v 1
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
|
||||
sleep 2000
|
||||
sql connect
|
||||
|
||||
print =============== step1
|
||||
|
@ -19,7 +16,7 @@ endi
|
|||
|
||||
sql drop database db
|
||||
sql show databases
|
||||
if $rows != 0 then
|
||||
if $rows != 2 then
|
||||
return -1
|
||||
endi
|
||||
|
|
@ -1,9 +1,6 @@
|
|||
system sh/stop_dnodes.sh
|
||||
system sh/deploy.sh -n dnode1 -i 1
|
||||
system sh/cfg.sh -n dnode1 -c walLevel -v 1
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
|
||||
sleep 2000
|
||||
sql connect
|
||||
|
||||
$i = 0
|
||||
|
@ -79,7 +76,7 @@ endi
|
|||
|
||||
sql drop database $db
|
||||
sql show databases
|
||||
if $rows != 0 then
|
||||
if $rows != 2 then
|
||||
return -1
|
||||
endi
|
||||
|
|
@ -1,9 +1,6 @@
|
|||
system sh/stop_dnodes.sh
|
||||
system sh/deploy.sh -n dnode1 -i 1
|
||||
system sh/cfg.sh -n dnode1 -c walLevel -v 1
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
|
||||
sleep 2000
|
||||
sql connect
|
||||
|
||||
$i = 0
|
||||
|
@ -78,7 +75,7 @@ endi
|
|||
|
||||
sql drop database $db
|
||||
sql show databases
|
||||
if $rows != 0 then
|
||||
if $rows != 2 then
|
||||
return -1
|
||||
endi
|
||||
|
|
@ -1,9 +1,6 @@
|
|||
system sh/stop_dnodes.sh
|
||||
system sh/deploy.sh -n dnode1 -i 1
|
||||
system sh/cfg.sh -n dnode1 -c walLevel -v 1
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
|
||||
sleep 2000
|
||||
sql connect
|
||||
|
||||
$i = 0
|
||||
|
@ -68,7 +65,7 @@ endi
|
|||
|
||||
sql drop database $db
|
||||
sql show databases
|
||||
if $rows != 0 then
|
||||
if $rows != 2 then
|
||||
return -1
|
||||
endi
|
||||
|
|
@ -1,13 +1,12 @@
|
|||
system sh/stop_dnodes.sh
|
||||
system sh/deploy.sh -n dnode1 -i 1
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
sleep 3000
|
||||
sql connect
|
||||
|
||||
print =============== create database
|
||||
sql create database db
|
||||
sql show databases
|
||||
if $rows != 1 then
|
||||
if $rows != 3 then
|
||||
return -1
|
||||
endi
|
||||
|
|
@ -1,9 +1,6 @@
|
|||
system sh/stop_dnodes.sh
|
||||
system sh/deploy.sh -n dnode1 -i 1
|
||||
system sh/cfg.sh -n dnode1 -c walLevel -v 1
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
|
||||
sleep 2000
|
||||
sql connect
|
||||
|
||||
$i = 0
|
||||
|
@ -27,18 +24,18 @@ if $data00 != @17-01-01 08:00:00.001@ then
|
|||
endi
|
||||
|
||||
print =============== step2
|
||||
sql insert into $tb values ('2017-08-28 00:23:46.429+ 1a', 2)
|
||||
#sql insert into $tb values ('2017-08-28 00:23:46cd .429', 2)
|
||||
sql_error insert into $tb values ('2017-08-28 00:23:46.429+ 1a', 2)
|
||||
sql_error insert into $tb values ('2017-08-28 00:23:46cd .429', 2)
|
||||
sql select ts from $tb
|
||||
if $rows != 2 then
|
||||
if $rows != 1 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
print =============== step3
|
||||
#sql insert into $tb values ('1970-01-01 08:00:00.000', 3)
|
||||
#sql insert into $tb values ('1970-01-01 08:00:00.000', 3)
|
||||
sql_error insert into $tb values ('1970-01-01 08:00:00.000', 3)
|
||||
sql_error insert into $tb values ('1970-01-01 08:00:00.000', 3)
|
||||
sql select ts from $tb
|
||||
if $rows != 2 then
|
||||
if $rows != 1 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
@ -57,7 +54,7 @@ print =============== step5
|
|||
sql_error insert into $tb values ('9999-12-31 213:59:59.999', 13)
|
||||
sql select ts from $tb
|
||||
print $rows
|
||||
if $rows != 8 then
|
||||
if $rows != 7 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
@ -65,7 +62,7 @@ print =============== step6
|
|||
sql_error insert into $tb values ('9999-12-99 23:59:59.999', 13)
|
||||
|
||||
sql select ts from $tb
|
||||
if $rows != 8 then
|
||||
if $rows != 7 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
@ -83,7 +80,7 @@ endi
|
|||
|
||||
sql drop database $db
|
||||
sql show databases
|
||||
if $rows != 0 then
|
||||
if $rows != 2 then
|
||||
return -1
|
||||
endi
|
||||
|
|
@ -1,9 +1,6 @@
|
|||
system sh/stop_dnodes.sh
|
||||
system sh/deploy.sh -n dnode1 -i 1
|
||||
system sh/cfg.sh -n dnode1 -c walLevel -v 1
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
|
||||
sleep 2000
|
||||
sql connect
|
||||
|
||||
$i = 0
|
||||
|
@ -40,7 +37,7 @@ sql drop table $table
|
|||
|
||||
sql drop database $db
|
||||
sql show databases
|
||||
if $rows != 0 then
|
||||
if $rows != 2 then
|
||||
return -1
|
||||
endi
|
||||
|
|
@ -1,9 +1,6 @@
|
|||
system sh/stop_dnodes.sh
|
||||
system sh/deploy.sh -n dnode1 -i 1
|
||||
system sh/cfg.sh -n dnode1 -c walLevel -v 1
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
|
||||
sleep 2000
|
||||
sql connect
|
||||
|
||||
$i = 0
|
||||
|
@ -42,7 +39,7 @@ endi
|
|||
|
||||
sql drop database $db
|
||||
sql show databases
|
||||
if $rows != 0 then
|
||||
if $rows != 2 then
|
||||
return -1
|
||||
endi
|
||||
|
|
@ -1,9 +1,6 @@
|
|||
system sh/stop_dnodes.sh
|
||||
system sh/deploy.sh -n dnode1 -i 1
|
||||
system sh/cfg.sh -n dnode1 -c walLevel -v 1
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
|
||||
sleep 2000
|
||||
sql connect
|
||||
|
||||
$i = 0
|
||||
|
@ -91,7 +88,7 @@ endi
|
|||
|
||||
sql drop database $db
|
||||
sql show databases
|
||||
if $rows != 0 then
|
||||
if $rows != 2 then
|
||||
return -1
|
||||
endi
|
||||
|
|
@ -1,9 +1,6 @@
|
|||
system sh/stop_dnodes.sh
|
||||
system sh/deploy.sh -n dnode1 -i 1
|
||||
system sh/cfg.sh -n dnode1 -c walLevel -v 1
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
|
||||
sleep 2000
|
||||
sql connect
|
||||
|
||||
$i = 0
|
||||
|
@ -91,7 +88,7 @@ endi
|
|||
|
||||
sql drop database $db
|
||||
sql show databases
|
||||
if $rows != 0 then
|
||||
if $rows != 2 then
|
||||
return -1
|
||||
endi
|
||||
|
|
@ -1,9 +1,6 @@
|
|||
system sh/stop_dnodes.sh
|
||||
system sh/deploy.sh -n dnode1 -i 1
|
||||
system sh/cfg.sh -n dnode1 -c walLevel -v 1
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
|
||||
sleep 2000
|
||||
sql connect
|
||||
|
||||
$i = 0
|
||||
|
@ -27,12 +24,10 @@ if $data01 != NULL then
|
|||
endi
|
||||
|
||||
print =============== step2
|
||||
sql insert into $tb values (now+1m, -2147483648) -x step2
|
||||
return -1
|
||||
step2:
|
||||
sql insert into $tb values (now+1m, NULL)
|
||||
sql insert into $tb values (now+1m, -2147483648)
|
||||
sql insert into $tb values (now+2m, NULL)
|
||||
sql select * from $tb order by ts desc
|
||||
if $rows != 2 then
|
||||
if $rows != 3 then
|
||||
return -1
|
||||
endi
|
||||
if $data01 != NULL then
|
||||
|
@ -40,9 +35,9 @@ if $data01 != NULL then
|
|||
endi
|
||||
|
||||
print =============== step3
|
||||
sql insert into $tb values (now+2m, 2147483647)
|
||||
sql insert into $tb values (now+3m, 2147483647)
|
||||
sql select * from $tb order by ts desc
|
||||
if $rows != 3 then
|
||||
if $rows != 4 then
|
||||
return -1
|
||||
endi
|
||||
if $data01 != 2147483647 then
|
||||
|
@ -50,12 +45,10 @@ if $data01 != 2147483647 then
|
|||
endi
|
||||
|
||||
print =============== step4
|
||||
sql insert into $tb values (now+3m, 2147483648) -x step4
|
||||
return -1
|
||||
step4:
|
||||
sql insert into $tb values (now+3m, NULL)
|
||||
sql_error insert into $tb values (now+4m, 2147483648)
|
||||
sql insert into $tb values (now+5m, NULL)
|
||||
sql select * from $tb order by ts desc
|
||||
if $rows != 4 then
|
||||
if $rows != 5 then
|
||||
return -1
|
||||
endi
|
||||
if $data01 != NULL then
|
||||
|
@ -63,10 +56,10 @@ if $data01 != NULL then
|
|||
endi
|
||||
|
||||
print =============== step5
|
||||
sql_error insert into $tb values (now+4m, a2)
|
||||
sql insert into $tb values (now+4m, 0)
|
||||
sql_error insert into $tb values (now+6m, a2)
|
||||
sql insert into $tb values (now+7m, 0)
|
||||
sql select * from $tb order by ts desc
|
||||
if $rows != 5 then
|
||||
if $rows != 6 then
|
||||
return -1
|
||||
endi
|
||||
if $data01 != 0 then
|
||||
|
@ -74,19 +67,8 @@ if $data01 != 0 then
|
|||
endi
|
||||
|
||||
print =============== step6
|
||||
sql_error insert into $tb values (now+5m, 2a)
|
||||
sql insert into $tb values (now+5m, 2)
|
||||
sql select * from $tb order by ts desc
|
||||
if $rows != 6 then
|
||||
return -1
|
||||
endi
|
||||
if $data01 != 2 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
print =============== step7
|
||||
sql_error insert into $tb values (now+6m, 2a'1)
|
||||
sql insert into $tb values (now+6m, 2)
|
||||
sql_error insert into $tb values (now+8m, 2a)
|
||||
sql insert into $tb values (now+9m, 2)
|
||||
sql select * from $tb order by ts desc
|
||||
if $rows != 7 then
|
||||
return -1
|
||||
|
@ -95,18 +77,19 @@ if $data01 != 2 then
|
|||
return -1
|
||||
endi
|
||||
|
||||
print =============== step8
|
||||
sql insert into $tb values (now+8m, "NULL")
|
||||
print =============== step7
|
||||
sql_error insert into $tb values (now+10m, 2a'1)
|
||||
sql insert into $tb values (now+11m, 2)
|
||||
sql select * from $tb order by ts desc
|
||||
if $rows != 8 then
|
||||
return -1
|
||||
endi
|
||||
if $data01 != NULL then
|
||||
if $data01 != 2 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
print =============== step9
|
||||
sql insert into $tb values (now+9m, 'NULL')
|
||||
print =============== step8
|
||||
sql insert into $tb values (now+12m, "NULL")
|
||||
sql select * from $tb order by ts desc
|
||||
if $rows != 9 then
|
||||
return -1
|
||||
|
@ -115,19 +98,29 @@ if $data01 != NULL then
|
|||
return -1
|
||||
endi
|
||||
|
||||
print =============== step10
|
||||
sql insert into $tb values (now+10m, -123)
|
||||
print =============== step9
|
||||
sql insert into $tb values (now+13m, 'NULL')
|
||||
sql select * from $tb order by ts desc
|
||||
if $rows != 10 then
|
||||
return -1
|
||||
endi
|
||||
if $data01 != NULL then
|
||||
return -1
|
||||
endi
|
||||
|
||||
print =============== step10
|
||||
sql insert into $tb values (now+14m, -123)
|
||||
sql select * from $tb order by ts desc
|
||||
if $rows != 11 then
|
||||
return -1
|
||||
endi
|
||||
if $data01 != -123 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
sql drop database $db
|
||||
sql show databases
|
||||
if $rows != 0 then
|
||||
if $rows != 2 then
|
||||
return -1
|
||||
endi
|
||||
|
|
@ -1,11 +1,6 @@
|
|||
system sh/stop_dnodes.sh
|
||||
system sh/deploy.sh -n dnode1 -i 1
|
||||
system sh/cfg.sh -n dnode1 -c walLevel -v 1
|
||||
system sh/cfg.sh -n dnode1 -c maxtablesPerVnode -v 129
|
||||
system sh/cfg.sh -n dnode1 -c maxVgroupsPerDb -v 8
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
|
||||
sleep 2000
|
||||
sql connect
|
||||
|
||||
print ============================ dnode1 start
|
||||
|
@ -17,10 +12,10 @@ $db = $dbPrefix . $i
|
|||
$tb = $tbPrefix . $i
|
||||
|
||||
print =================== step 0
|
||||
sql create database $db
|
||||
sql create database $db vgroups 8
|
||||
sql use $db
|
||||
sql show vgroups
|
||||
if $rows != 0 then
|
||||
if $rows != 8 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
@ -87,7 +82,7 @@ endi
|
|||
|
||||
sql drop database $db
|
||||
sql show databases
|
||||
if $rows != 0 then
|
||||
if $rows != 2 then
|
||||
return -1
|
||||
endi
|
||||
|
|
@ -1,9 +1,6 @@
|
|||
system sh/stop_dnodes.sh
|
||||
system sh/deploy.sh -n dnode1 -i 1
|
||||
system sh/cfg.sh -n dnode1 -c walLevel -v 1
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
|
||||
sleep 2000
|
||||
sql connect
|
||||
|
||||
$i = 0
|
||||
|
@ -28,12 +25,10 @@ if $data01 != NULL then
|
|||
endi
|
||||
|
||||
print =============== step2
|
||||
sql insert into $tb values (now+1m, -32768) -x step2
|
||||
return -1
|
||||
step2:
|
||||
sql insert into $tb values (now+1m, NULL)
|
||||
sql insert into $tb values (now+1m, -32768)
|
||||
sql insert into $tb values (now+2m, NULL)
|
||||
sql select * from $tb order by ts desc
|
||||
if $rows != 2 then
|
||||
if $rows != 3 then
|
||||
return -1
|
||||
endi
|
||||
if $data01 != NULL then
|
||||
|
@ -41,9 +36,9 @@ if $data01 != NULL then
|
|||
endi
|
||||
|
||||
print =============== step3
|
||||
sql insert into $tb values (now+2m, 32767)
|
||||
sql insert into $tb values (now+3m, 32767)
|
||||
sql select * from $tb order by ts desc
|
||||
if $rows != 3 then
|
||||
if $rows != 4 then
|
||||
return -1
|
||||
endi
|
||||
if $data01 != 32767 then
|
||||
|
@ -51,12 +46,12 @@ if $data01 != 32767 then
|
|||
endi
|
||||
|
||||
print =============== step4
|
||||
sql insert into $tb values (now+3m, 32768) -x step4
|
||||
sql insert into $tb values (now+4m, 32768) -x step4
|
||||
return -1
|
||||
step4:
|
||||
sql insert into $tb values (now+3m, NULL)
|
||||
sql insert into $tb values (now+5m, NULL)
|
||||
sql select * from $tb order by ts desc
|
||||
if $rows != 4 then
|
||||
if $rows != 5 then
|
||||
return -1
|
||||
endi
|
||||
if $data01 != NULL then
|
||||
|
@ -64,10 +59,10 @@ if $data01 != NULL then
|
|||
endi
|
||||
|
||||
print =============== step5
|
||||
sql_error insert into $tb values (now+4m, a2)
|
||||
sql insert into $tb values (now+4m, 0)
|
||||
sql_error insert into $tb values (now+6m, a2)
|
||||
sql insert into $tb values (now+7m, 0)
|
||||
sql select * from $tb order by ts desc
|
||||
if $rows != 5 then
|
||||
if $rows != 6 then
|
||||
return -1
|
||||
endi
|
||||
if $data01 != 0 then
|
||||
|
@ -75,19 +70,8 @@ if $data01 != 0 then
|
|||
endi
|
||||
|
||||
print =============== step6
|
||||
sql_error insert into $tb values (now+5m, 2a)
|
||||
sql insert into $tb values (now+5m, 2)
|
||||
sql select * from $tb order by ts desc
|
||||
if $rows != 6 then
|
||||
return -1
|
||||
endi
|
||||
if $data01 != 2 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
print =============== step7
|
||||
sql_error insert into $tb values (now+6m, 2a'1)
|
||||
sql insert into $tb values (now+6m, 2)
|
||||
sql_error insert into $tb values (now+8m, 2a)
|
||||
sql insert into $tb values (now+9m, 2)
|
||||
sql select * from $tb order by ts desc
|
||||
if $rows != 7 then
|
||||
return -1
|
||||
|
@ -96,9 +80,20 @@ if $data01 != 2 then
|
|||
return -1
|
||||
endi
|
||||
|
||||
print =============== step7
|
||||
sql_error insert into $tb values (now+10m, 2a'1)
|
||||
sql insert into $tb values (now+11m, 2)
|
||||
sql select * from $tb order by ts desc
|
||||
if $rows != 8 then
|
||||
return -1
|
||||
endi
|
||||
if $data01 != 2 then
|
||||
return -1
|
||||
endi
|
||||
return
|
||||
sql drop database $db
|
||||
sql show databases
|
||||
if $rows != 0 then
|
||||
if $rows != 2 then
|
||||
return -1
|
||||
endi
|
||||
|
|
@ -1,9 +1,6 @@
|
|||
system sh/stop_dnodes.sh
|
||||
system sh/deploy.sh -n dnode1 -i 1
|
||||
system sh/cfg.sh -n dnode1 -c walLevel -v 1
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
|
||||
sleep 2000
|
||||
sql connect
|
||||
|
||||
print ============================ dnode1 start
|
||||
|
@ -200,16 +197,15 @@ if $data01 != 7 then
|
|||
endi
|
||||
|
||||
print =============== step10
|
||||
$i = 1
|
||||
$tb = $tbPrefix . $i
|
||||
sql create table $tb (ts timestamp, val tinyint, val2 tinyint)
|
||||
sql_error create table $tb (ts timestamp, val tinyint, val2 tinyint)
|
||||
sql show tables
|
||||
if $rows != 7 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
print =============== step11
|
||||
sql create table $tb (ts timestamp, val float, val2 double)
|
||||
sql_error create table $tb (ts timestamp, val float, val2 double)
|
||||
sql show tables
|
||||
if $rows != 7 then
|
||||
return -1
|
||||
|
@ -217,7 +213,7 @@ endi
|
|||
|
||||
sql drop database $db
|
||||
sql show databases
|
||||
if $rows != 0 then
|
||||
if $rows != 2 then
|
||||
return -1
|
||||
endi
|
||||
|
|
@ -1,9 +1,6 @@
|
|||
system sh/stop_dnodes.sh
|
||||
system sh/deploy.sh -n dnode1 -i 1
|
||||
system sh/cfg.sh -n dnode1 -c walLevel -v 1
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
|
||||
sleep 2000
|
||||
sql connect
|
||||
|
||||
$i = 0
|
||||
|
@ -98,7 +95,7 @@ step8:
|
|||
|
||||
sql drop database $db
|
||||
sql show databases
|
||||
if $rows != 0 then
|
||||
if $rows != 2 then
|
||||
return -1
|
||||
endi
|
||||
|
|
@ -1,9 +1,6 @@
|
|||
system sh/stop_dnodes.sh
|
||||
system sh/deploy.sh -n dnode1 -i 1
|
||||
system sh/cfg.sh -n dnode1 -c walLevel -v 1
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
|
||||
sleep 2000
|
||||
sql connect
|
||||
|
||||
$i = 0
|
||||
|
@ -27,12 +24,10 @@ if $data01 != NULL then
|
|||
endi
|
||||
|
||||
print =============== step2
|
||||
sql insert into $tb values (now+1m, -128) -x step2
|
||||
return -1
|
||||
step2:
|
||||
sql insert into $tb values (now+1m, NULL)
|
||||
sql insert into $tb values (now+1m, -128)
|
||||
sql insert into $tb values (now+2m, NULL)
|
||||
sql select * from $tb order by ts desc
|
||||
if $rows != 2 then
|
||||
if $rows != 3 then
|
||||
return -1
|
||||
endi
|
||||
if $data01 != NULL then
|
||||
|
@ -40,9 +35,9 @@ if $data01 != NULL then
|
|||
endi
|
||||
|
||||
print =============== step3
|
||||
sql insert into $tb values (now+2m, 127)
|
||||
sql insert into $tb values (now+3m, 127)
|
||||
sql select * from $tb order by ts desc
|
||||
if $rows != 3 then
|
||||
if $rows != 4 then
|
||||
return -1
|
||||
endi
|
||||
if $data01 != 127 then
|
||||
|
@ -50,12 +45,12 @@ if $data01 != 127 then
|
|||
endi
|
||||
|
||||
print =============== step4
|
||||
sql insert into $tb values (now+3m, 128) -x step4
|
||||
sql insert into $tb values (now+4m, 128) -x step4
|
||||
return -1
|
||||
step4:
|
||||
sql insert into $tb values (now+3m, NULL)
|
||||
sql insert into $tb values (now+5m, NULL)
|
||||
sql select * from $tb
|
||||
if $rows != 4 then
|
||||
if $rows != 5 then
|
||||
return -1
|
||||
endi
|
||||
if $data01 != NULL then
|
||||
|
@ -63,10 +58,10 @@ if $data01 != NULL then
|
|||
endi
|
||||
|
||||
print =============== step5
|
||||
sql_error insert into $tb values (now+4m, a2)
|
||||
sql insert into $tb values (now+4m, 0)
|
||||
sql_error insert into $tb values (now+6m, a2)
|
||||
sql insert into $tb values (now+7m, 0)
|
||||
sql select * from $tb order by ts desc
|
||||
if $rows != 5 then
|
||||
if $rows != 6 then
|
||||
return -1
|
||||
endi
|
||||
if $data01 != 0 then
|
||||
|
@ -74,19 +69,8 @@ if $data01 != 0 then
|
|||
endi
|
||||
|
||||
print =============== step6
|
||||
sql_error insert into $tb values (now+5m, 2a)
|
||||
sql insert into $tb values (now+5m, 2)
|
||||
sql select * from $tb order by ts desc
|
||||
if $rows != 6 then
|
||||
return -1
|
||||
endi
|
||||
if $data01 != 2 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
print =============== step7
|
||||
sql_error insert into $tb values (now+6m, 2a'1)
|
||||
sql insert into $tb values (now+6m, 2)
|
||||
sql_error insert into $tb values (now+8m, 2a)
|
||||
sql insert into $tb values (now+9m, 2)
|
||||
sql select * from $tb order by ts desc
|
||||
if $rows != 7 then
|
||||
return -1
|
||||
|
@ -95,9 +79,20 @@ if $data01 != 2 then
|
|||
return -1
|
||||
endi
|
||||
|
||||
print =============== step7
|
||||
sql_error insert into $tb values (now+10m, 2a'1)
|
||||
sql insert into $tb values (now+11m, 2)
|
||||
sql select * from $tb order by ts desc
|
||||
if $rows != 8 then
|
||||
return -1
|
||||
endi
|
||||
if $data01 != 2 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
sql drop database $db
|
||||
sql show databases
|
||||
if $rows != 0 then
|
||||
if $rows != 2 then
|
||||
return -1
|
||||
endi
|
||||
|
|
@ -1,12 +1,8 @@
|
|||
system sh/stop_dnodes.sh
|
||||
system sh/deploy.sh -n dnode1 -i 1
|
||||
system sh/cfg.sh -n dnode1 -c walLevel -v 1
|
||||
system sh/cfg.sh -n dnode1 -c maxVgroupsPerDb -v 4
|
||||
system sh/cfg.sh -n dnode1 -c maxTablesPerVnode -v 4
|
||||
system sh/exec.sh -n dnode1 -s start
|
||||
|
||||
sleep 2000
|
||||
sql connect
|
||||
|
||||
print ============================ dnode1 start
|
||||
|
||||
$i = 0
|
||||
|
@ -16,10 +12,10 @@ $db = $dbPrefix . $i
|
|||
$tb = $tbPrefix . $i
|
||||
|
||||
print =================== step 1
|
||||
sql create database $db
|
||||
sql create database $db vgroups 4
|
||||
sql use $db
|
||||
sql show vgroups
|
||||
if $rows != 0 then
|
||||
if $rows != 4 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
@ -28,7 +24,7 @@ sql create table table2 (ts timestamp, speed int)
|
|||
sql create table table3 (ts timestamp, speed int)
|
||||
sql create table table4 (ts timestamp, speed int)
|
||||
sql show vgroups
|
||||
if $rows != 1 then
|
||||
if $rows != 4 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
@ -37,7 +33,7 @@ sql create table table6 (ts timestamp, speed int)
|
|||
sql create table table7 (ts timestamp, speed int)
|
||||
sql create table table8 (ts timestamp, speed int)
|
||||
sql show vgroups
|
||||
if $rows != 2 then
|
||||
if $rows != 4 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
@ -46,7 +42,7 @@ sql create table table10 (ts timestamp, speed int)
|
|||
sql create table table11 (ts timestamp, speed int)
|
||||
sql create table table12 (ts timestamp, speed int)
|
||||
sql show vgroups
|
||||
if $rows != 3 then
|
||||
if $rows != 4 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
@ -58,7 +54,7 @@ endi
|
|||
|
||||
sql drop table table13
|
||||
sql show vgroups
|
||||
if $rows != 3 then
|
||||
if $rows != 4 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
@ -72,10 +68,10 @@ print =================== step 2
|
|||
$i = 1
|
||||
$db = $dbPrefix . $i
|
||||
|
||||
sql create database $db
|
||||
sql create database $db vgroups 2
|
||||
sql use $db
|
||||
sql show vgroups
|
||||
if $rows != 0 then
|
||||
if $rows != 2 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
@ -88,13 +84,13 @@ $db = $dbPrefix . $i
|
|||
sql use $db
|
||||
sql create table table2 (ts timestamp, speed int)
|
||||
sql show vgroups
|
||||
if $rows != 1 then
|
||||
if $rows != 2 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
sql drop table table2
|
||||
sql show vgroups
|
||||
if $rows != 0 then
|
||||
if $rows != 2 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
@ -104,7 +100,7 @@ sql create table table3 (ts timestamp, speed int)
|
|||
sql create table table4 (ts timestamp, speed int)
|
||||
sql drop table table1
|
||||
sql show vgroups
|
||||
if $rows != 1 then
|
||||
if $rows != 2 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
@ -133,7 +129,7 @@ sql create database $db
|
|||
sql use $db
|
||||
|
||||
sql show databases
|
||||
if $rows != 5 then
|
||||
if $rows != 7 then
|
||||
return -1
|
||||
endi
|
||||
|
||||
|
@ -144,7 +140,7 @@ while $i < 5
|
|||
$i = $i + 1
|
||||
endw
|
||||
sql show databases
|
||||
if $rows != 0 then
|
||||
if $rows != 2 then
|
||||
return -1
|
||||
endi
|
||||
|
|
@ -46,7 +46,6 @@ while $i < 10
|
|||
endw
|
||||
|
||||
print =============== step2
|
||||
sleep 100
|
||||
sql select * from $tb
|
||||
if $rows != $rowNum then
|
||||
return -1
|
||||
|
|
|
@ -46,7 +46,6 @@ while $i < 10
|
|||
endw
|
||||
|
||||
print =============== step2
|
||||
sleep 100
|
||||
sql select * from $tb
|
||||
if $rows != $rowNum then
|
||||
return -1
|
||||
|
|
|
@ -46,7 +46,6 @@ while $i < 10
|
|||
endw
|
||||
|
||||
print =============== step2
|
||||
sleep 100
|
||||
sql select * from $tb
|
||||
if $rows != $rowNum then
|
||||
return -1
|
||||
|
|
|
@ -46,7 +46,6 @@ while $i < 10
|
|||
endw
|
||||
|
||||
print =============== step2
|
||||
sleep 100
|
||||
sql select * from $tb
|
||||
if $rows != $rowNum then
|
||||
return -1
|
||||
|
|
|
@ -46,7 +46,6 @@ while $i < 10
|
|||
endw
|
||||
|
||||
print =============== step2
|
||||
sleep 100
|
||||
sql select * from $tb
|
||||
if $rows != $rowNum then
|
||||
return -1
|
||||
|
|
|
@ -46,7 +46,6 @@ while $i < 10
|
|||
endw
|
||||
|
||||
print =============== step2
|
||||
sleep 100
|
||||
sql select * from $tb
|
||||
if $rows != $rowNum then
|
||||
return -1
|
||||
|
|
|
@ -46,7 +46,6 @@ while $i < 10
|
|||
endw
|
||||
|
||||
print =============== step2
|
||||
sleep 100
|
||||
sql select * from $tb
|
||||
if $rows != $rowNum then
|
||||
return -1
|
||||
|
|
|
@ -46,7 +46,6 @@ while $i < 10
|
|||
endw
|
||||
|
||||
print =============== step2
|
||||
sleep 100
|
||||
sql select * from $tb
|
||||
if $rows != $rowNum then
|
||||
return -1
|
||||
|
|
|
@ -41,8 +41,6 @@ while $i < $tbNum
|
|||
$i = $i + 1
|
||||
endw
|
||||
|
||||
sleep 100
|
||||
|
||||
print =============== step2
|
||||
$i = 1
|
||||
$tb = $tbPrefix . $i
|
||||
|
|
|
@ -37,8 +37,6 @@ while $i < $tbNum
|
|||
$i = $i + 1
|
||||
endw
|
||||
|
||||
sleep 100
|
||||
|
||||
print =============== step2
|
||||
$i = 1
|
||||
$tb = $tbPrefix . $i
|
||||
|
|
|
@ -37,8 +37,6 @@ while $i < $tbNum
|
|||
$i = $i + 1
|
||||
endw
|
||||
|
||||
sleep 100
|
||||
|
||||
print =============== step2
|
||||
$i = 1
|
||||
$tb = $tbPrefix . $i
|
||||
|
|
|
@ -37,8 +37,6 @@ while $i < $tbNum
|
|||
$i = $i + 1
|
||||
endw
|
||||
|
||||
sleep 100
|
||||
|
||||
print =============== step2
|
||||
$i = 1
|
||||
$tb = $tbPrefix . $i
|
||||
|
|
|
@ -37,8 +37,6 @@ while $i < $tbNum
|
|||
$i = $i + 1
|
||||
endw
|
||||
|
||||
sleep 100
|
||||
|
||||
print =============== step2
|
||||
$i = 1
|
||||
$tb = $tbPrefix . $i
|
||||
|
|
|
@ -37,8 +37,6 @@ while $i < $tbNum
|
|||
$i = $i + 1
|
||||
endw
|
||||
|
||||
sleep 100
|
||||
|
||||
print =============== step2
|
||||
$i = 1
|
||||
$tb = $tbPrefix . $i
|
||||
|
|
|
@ -37,8 +37,6 @@ while $i < $tbNum
|
|||
$i = $i + 1
|
||||
endw
|
||||
|
||||
sleep 100
|
||||
|
||||
print =============== step2
|
||||
$i = 1
|
||||
$tb = $tbPrefix . $i
|
||||
|
|
|
@ -37,8 +37,6 @@ while $i < $tbNum
|
|||
$i = $i + 1
|
||||
endw
|
||||
|
||||
sleep 100
|
||||
|
||||
print =============== step2
|
||||
$i = 1
|
||||
$tb = $tbPrefix . $i
|
||||
|
|
|
@ -37,8 +37,6 @@ while $i < $tbNum
|
|||
$i = $i + 1
|
||||
endw
|
||||
|
||||
sleep 100
|
||||
|
||||
print =============== step2
|
||||
$i = 1
|
||||
$tb = $tbPrefix . $i
|
||||
|
|
|
@ -37,8 +37,6 @@ while $i < $tbNum
|
|||
$i = $i + 1
|
||||
endw
|
||||
|
||||
sleep 100
|
||||
|
||||
print =============== step2
|
||||
$i = 1
|
||||
$tb = $tbPrefix . $i
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue