terça-feira, 5 de julho de 2011

Postgresql: show tables, show databases, show columns

mysql: SHOW TABLES
postgresql: \d
or
postgresql: SELECT table_name FROM information_schema.tables WHERE table_schema = 'public';

mysql: SHOW DATABASES
postgresql: \l
or
postgresql: SELECT datname FROM pg_database;

mysql: SHOW COLUMNS
postgresql: \d table
or
postgresql: SELECT column_name FROM information_schema.columns WHERE table_name ='table';

Nenhum comentário:

Postar um comentário

Drunk Penguins

Drunk Penguins
Drunk Penguins