Personal portfolio - Mauricio Aznar

Postgresql

 

Quick commands

dump database into file

pg_dump -U postgres --format=c  note_dev > note_dev

insert dump into database

 pg_restore -U postgres -v -d note_prod note_dev

create database

 create database m;

drop database

drop database m;

list all foreign keys for a table

List all foreign keys for a column

List all databases

\list

\l

Drop column in table

run script


what tools does postgres offer?