Search
 
SCRIPT & CODE EXAMPLE
 

SQL

restore postgres database from sql file

psql -d database_name -f backup.sql
Comment

restore database postgresql

docker exec -it (container-name) bash # inter container
# go dump file location it will easy to target restore file
psql -U username -d dbname < filename.sql # then run this for restore 
-- For Postgres versions 9.0 or earlier
psql -U username -d dbname -1 -f filename.sql
Comment

PREVIOUS NEXT
Code Example
Sql :: how to insert json value in mysql 
Sql :: select random sql 
Sql :: mysql two column combination unique 
Sql :: sql #region 
Sql :: delete ids between sql 
Sql :: sql convert float to string 
Sql :: linq join 
Sql :: postgres extract day from date 
Sql :: Select without null values sql 
Sql :: how to create a table in sql 
Sql :: restore backup to new database sql server 
Sql :: How to pass password to mysql command line 
Sql :: update one column from another column in same table 
Sql :: adding generated time in row mysql workbench 
Sql :: create database in mysql 
Sql :: mysql collation for all languages 
Sql :: postgressql uuid 
Sql :: row to value to json in sql server 
Sql :: regexp in mysql 
Sql :: database timezone 
Sql :: sql cast 
Sql :: postgresql filter on 
Sql :: dump heroku database to sql 
Sql :: mysql select count 
Sql :: oracle dependencies table 
Sql :: view table sql 
Sql :: mysql order by date asc null last 
Sql :: sql remove duplicates 
Sql :: sql select if two columns are equal 
Sql :: to_date postgresql 
ADD CONTENT
Topic
Content
Source link
Name
1+8 =