Search
 
SCRIPT & CODE EXAMPLE
 

SQL

postgresql restore from dump

psql -U postgres -h localhost -p 5432 -f data_dump.sql
Comment

restore postgres database from dump

psql -U username -d dbname < filename.sql
Comment

postgresql dump and restore db

#To dump a database called mydb into a SQL-script file:
pg_dump mydb > db.sql

#To reload such a script into a (freshly created) database named newdb:
psql -d newdb -f db.sql
Comment

how to take database dump in postgresql

pg_dump dbname > outfile
Comment

restore postgresql database from dump file

pg_restore -U sam -d SamDataBase -1 SamDataBaseBackup.sql
Comment

PREVIOUS NEXT
Code Example
Sql :: csv to sqlite python 
Sql :: date between in mysql 
Sql :: mac install mysql 
Sql :: get all tables using like 
Sql :: oracle sql create table from select 
Sql :: count characters of string mysql 
Sql :: mysql database is not starting in xampp 
Sql :: add column if not exists mysql 
Sql :: sql cheat sheet pdf 
Sql :: oracle desc table primary key 
Sql :: cannot drop database because it is currently in use 
Sql :: postgres create extension if not exists 
Sql :: mysql delete all except 
Sql :: plsql print 
Sql :: phpmyadmin reset root password 
Sql :: sql update table set text to lowercase 
Sql :: mysql command not working in linux 
Sql :: create or replace view postgress 
Sql :: oracle pagination query rownum 
Sql :: check postgresql version in rails console 
Sql :: default constraint in ms sql 
Sql :: oracle revoke grant 
Sql :: mysql connection w3 
Sql :: add bool column in sql 
Sql :: What is dialect for Postgres 
Sql :: difference between primary key and unique key 
Sql :: mysql update two tables at once 
Sql :: oracle drop sequence if exists 
Sql :: avg sql 
Sql :: mysql age by birthdate 
ADD CONTENT
Topic
Content
Source link
Name
3+1 =