diff --git a/src/system/detail/src/mgmtUser.c b/src/system/detail/src/mgmtUser.c index 89b83e3553f26a3d2cc755709086d8f5c4fa7f3f..b854a62630a51557c7700c55de4814b2c7f79a99 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;