提交 ed268d42 编写于 作者: Z zhaoyanggh

[TD-10456]taosdemo support rest insert to normal table without stable

上级 3271b2f3
...@@ -2660,6 +2660,8 @@ static int printfInsertMeta() { ...@@ -2660,6 +2660,8 @@ static int printfInsertMeta() {
} }
} }
if (g_Dbs.use_metric)
{
printf(" super table count: \033[33m%"PRIu64"\033[0m\n", printf(" super table count: \033[33m%"PRIu64"\033[0m\n",
g_Dbs.db[i].superTblCount); g_Dbs.db[i].superTblCount);
for (uint64_t j = 0; j < g_Dbs.db[i].superTblCount; j++) { for (uint64_t j = 0; j < g_Dbs.db[i].superTblCount; j++) {
...@@ -2771,6 +2773,14 @@ static int printfInsertMeta() { ...@@ -2771,6 +2773,14 @@ static int printfInsertMeta() {
} }
printf("\n"); printf("\n");
} }
}
else
{
printf(" number of tables: \033[33m%"PRId64"\033[0m\n",
g_args.ntables);
printf(" insertRows: \033[33m%"PRId64"\033[0m\n",
g_args.insertRows);
}
printf("\n"); printf("\n");
} }
...@@ -4474,7 +4484,7 @@ static void* createTable(void *sarg) ...@@ -4474,7 +4484,7 @@ static void* createTable(void *sarg)
for (uint64_t i = pThreadInfo->start_table_from; for (uint64_t i = pThreadInfo->start_table_from;
i <= pThreadInfo->end_table_to; i++) { i <= pThreadInfo->end_table_to; i++) {
if (0 == g_Dbs.use_metric) { if (!g_Dbs.use_metric) {
snprintf(pThreadInfo->buffer, buff_len, snprintf(pThreadInfo->buffer, buff_len,
"CREATE TABLE IF NOT EXISTS %s.%s%"PRIu64" %s;", "CREATE TABLE IF NOT EXISTS %s.%s%"PRIu64" %s;",
pThreadInfo->db_name, pThreadInfo->db_name,
...@@ -10286,8 +10296,7 @@ static void startMultiThreadInsertData(int threads, char* db_name, ...@@ -10286,8 +10296,7 @@ static void startMultiThreadInsertData(int threads, char* db_name,
b = ntables % threads; b = ntables % threads;
} }
if ((stbInfo) if (REST_IFACE == g_args.iface) {
&& (stbInfo->iface == REST_IFACE)) {
if (convertHostToServAddr( if (convertHostToServAddr(
g_Dbs.host, g_Dbs.port, &(g_Dbs.serv_addr)) != 0) { g_Dbs.host, g_Dbs.port, &(g_Dbs.serv_addr)) != 0) {
ERROR_EXIT("convert host to server address"); ERROR_EXIT("convert host to server address");
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册