SHOW DATABASES
SO what is the equivalent sql statement in Postgresql:
select datname from pg_database;
To get list of tables in a postgres database:
SELECT * FROM pg_tables;
Offcourse you can get list of tables using \dt from the command
prompt for postgres.I am just telling about doing it using sql
query which you can also use outside of command prompt for
postgres.
very simple indeed.. Isn't it;P
2 comments:
Thanks babu, it is quite handy.
Really great. definitely useful. I am eager to know how I can get the list of all the procedures in a particular database?
Post a Comment