Advertisement
econz

Firebird - Listar tabelas com mais colunas

Apr 20th, 2018
219
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
SQL 0.25 KB | None | 0 0
  1. SELECT
  2.    TABS.RDB$RELATION_NAME AS NOME_TABELA ,
  3.    ( SELECT COUNT(1) FROM RDB$RELATION_FIELDS CAMPS WHERE CAMPS.RDB$RELATION_NAME = TABS.RDB$RELATION_NAME ) AS NUM_CAMPOS
  4. FROM RDB$RELATIONS TABS
  5. WHERE
  6.    TABS.RDB$SYSTEM_FLAG=0
  7. ORDER BY
  8.    2 DESC, 1
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement