From 1a5bf61d84055e2dbf6457aa6e611e558aa19f29 Mon Sep 17 00:00:00 2001 From: root Date: Thu, 26 Mar 2020 17:25:14 +0800 Subject: [PATCH] [TD-50] --- src/system/detail/src/mgmtUser.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/system/detail/src/mgmtUser.c b/src/system/detail/src/mgmtUser.c index 89b83e3553..b854a62630 100644 --- a/src/system/detail/src/mgmtUser.c +++ b/src/system/detail/src/mgmtUser.c @@ -184,6 +184,12 @@ int mgmtGetUserMeta(SMeterMeta *pMeta, SShowObj *pShow, SConnObj *pConn) { pSchema[cols].bytes = htons(pShow->bytes[cols]); cols++; + pShow->bytes[cols] = TSDB_USER_LEN; + pSchema[cols].type = TSDB_DATA_TYPE_BINARY; + strcpy(pSchema[cols].name, "account"); + pSchema[cols].bytes = htons(pShow->bytes[cols]); + cols++; + pMeta->numOfColumns = htons(cols); pShow->numOfColumns = cols; @@ -230,6 +236,10 @@ int mgmtRetrieveUsers(SShowObj *pShow, char *data, int rows, SConnObj *pConn) { *(int64_t *)pWrite = pUser->createdTime; cols++; + pWrite = data + pShow->offset[cols] * rows + pShow->bytes[cols] * numOfRows; + strcpy(pWrite, pUser->acct); + cols++; + numOfRows++; } pShow->numOfReads += numOfRows; -- GitLab