PostgreSQL: Show tables in PostgreSQL

后端 未结 24 2665
醉梦人生
醉梦人生 2020-11-28 16:58

What\'s the equivalent to show tables (from MySQL) in PostgreSQL?

24条回答
  •  半阙折子戏
    2020-11-28 17:45

    (For completeness)

    You could also query the (SQL-standard) information schema:

    SELECT
        table_schema || '.' || table_name
    FROM
        information_schema.tables
    WHERE
        table_type = 'BASE TABLE'
    AND
        table_schema NOT IN ('pg_catalog', 'information_schema');
    

提交回复
热议问题