Merge pull request #22700 from taosdata/fix/TD-26104

fix: select tags from child table error
This commit is contained in:
dapan1121 2023-09-04 09:56:46 +08:00 committed by GitHub
commit d09f166b84
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 18 additions and 0 deletions

View File

@ -373,6 +373,11 @@ static bool tagScanNodeHasTbname(SNode* pKeys) {
static int32_t tagScanSetExecutionMode(SScanLogicNode* pScan) {
pScan->onlyMetaCtbIdx = false;
if (pScan->tableType == TSDB_CHILD_TABLE) {
pScan->onlyMetaCtbIdx = false;
return TSDB_CODE_SUCCESS;
}
if (tagScanNodeListHasTbname(pScan->pScanPseudoCols)) {
pScan->onlyMetaCtbIdx = false;
return TSDB_CODE_SUCCESS;

View File

@ -127,4 +127,17 @@ if $data01 != @1aa@ then
return -1
endi
sql select tags t,b from ctt11
print $rows
print $data00 $data01
if $rows != 1 then
return -1
endi
if $data00 != @1@ then
return -1
endi
if $data01 != @1aa@ then
return -1
endi
system sh/exec.sh -n dnode1 -s stop -x SIGINT