sqlhana

HANA list / show tables SQL Command


How to show / list all tables in SAP HANA via SQL?


Solution

  • SAP HANA provides a database catalog (just like most other DBMS) via system tables like TABLES, VIEWS, USERS, etc. ... These are the ANSI-92 compliant metadata views.

    Instead of the INFORMATION_SCHEMA SAP HANA provides these views in the PUBLIC schema (again, like other DBMS do that).

    Example:

    select * from tables
    select * from public.tables
    

    The M_TABLES provides information about the runtime objects that represent tables.