System-Tables

如何獲取 Netezza 中所有表的行數?

  • December 18, 2019

Netezza 中是否有顯示每個表的記錄數的系統表或視圖?

怎麼樣:

SELECT TABLENAME,
      OBJTYPE,
      OWNER,
      CREATEDATE,
      USED_BYTES,
      USED_BYTES/1073741824 as USED_GB, 
      RELTUPLES as "ROWS"
FROM _V_TABLE_ONLY_STORAGE_STAT
WHERE OBJCLASS = 4905 OR OBJCLASS = 4911
ORDER BY TABLENAME;

請為表“_v_table”嘗試此視圖。並查看此“_v_view”

祝你好運

引用自:https://dba.stackexchange.com/questions/68896