schemaless: fix errors about modify_column
This commit is contained in:
parent
ae58e4cb60
commit
a243d2b91d
|
@ -891,12 +891,12 @@ static int32_t insertChildTableBatch(TAOS* taos, char* cTableName, SArray* cols
|
||||||
|
|
||||||
if (code == TSDB_CODE_APP_NOT_READY ||
|
if (code == TSDB_CODE_APP_NOT_READY ||
|
||||||
code == TSDB_CODE_TDB_INVALID_TABLE_ID || code == TSDB_CODE_VND_INVALID_VGROUP_ID) {
|
code == TSDB_CODE_TDB_INVALID_TABLE_ID || code == TSDB_CODE_VND_INVALID_VGROUP_ID) {
|
||||||
// TAOS_RES* res2 = taos_query(taos, "RESET QUERY CACHE");
|
TAOS_RES* res2 = taos_query(taos, "RESET QUERY CACHE");
|
||||||
// int32_t code2 = taos_errno(res2);
|
int32_t code2 = taos_errno(res2);
|
||||||
// if (code2 != TSDB_CODE_SUCCESS) {
|
if (code2 != TSDB_CODE_SUCCESS) {
|
||||||
// tscError("SML:0x%" PRIx64 " insert child table. reset query cache. error: %s", info->id, taos_errstr(res2));
|
tscError("SML:0x%" PRIx64 " insert child table. reset query cache. error: %s", info->id, taos_errstr(res2));
|
||||||
// }
|
}
|
||||||
// taos_free_result(res2);
|
taos_free_result(res2);
|
||||||
if (tryAgain) {
|
if (tryAgain) {
|
||||||
taosMsleep(50 * (2 << try));
|
taosMsleep(50 * (2 << try));
|
||||||
}
|
}
|
||||||
|
|
|
@ -1518,7 +1518,6 @@ static int32_t mnodeChangeSuperTableColumn(SMnodeMsg *pMsg) {
|
||||||
// update
|
// update
|
||||||
SSchema *schema = (SSchema *) (pStable->schema + col);
|
SSchema *schema = (SSchema *) (pStable->schema + col);
|
||||||
ASSERT(schema->type == TSDB_DATA_TYPE_BINARY || schema->type == TSDB_DATA_TYPE_NCHAR);
|
ASSERT(schema->type == TSDB_DATA_TYPE_BINARY || schema->type == TSDB_DATA_TYPE_NCHAR);
|
||||||
schema->bytes = pAlter->schema[0].bytes;
|
|
||||||
|
|
||||||
if (pAlter->schema[0].bytes <= schema->bytes) {
|
if (pAlter->schema[0].bytes <= schema->bytes) {
|
||||||
mError("msg:%p, app:%p stable:%s, modify column len. column:%s, len from %d to %d", pMsg, pMsg->rpcMsg.ahandle,
|
mError("msg:%p, app:%p stable:%s, modify column len. column:%s, len from %d to %d", pMsg, pMsg->rpcMsg.ahandle,
|
||||||
|
@ -1526,6 +1525,7 @@ static int32_t mnodeChangeSuperTableColumn(SMnodeMsg *pMsg) {
|
||||||
return TSDB_CODE_MND_INVALID_COLUMN_LENGTH;
|
return TSDB_CODE_MND_INVALID_COLUMN_LENGTH;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
schema->bytes = pAlter->schema[0].bytes;
|
||||||
pStable->sversion++;
|
pStable->sversion++;
|
||||||
mInfo("msg:%p, app:%p stable %s, start to modify column %s len to %d", pMsg, pMsg->rpcMsg.ahandle, pStable->info.tableId,
|
mInfo("msg:%p, app:%p stable %s, start to modify column %s len to %d", pMsg, pMsg->rpcMsg.ahandle, pStable->info.tableId,
|
||||||
name, schema->bytes);
|
name, schema->bytes);
|
||||||
|
|
Loading…
Reference in New Issue