Re: How to import *.sql file to postgresql database - Mailing list pgsql-general

From Szymon Guz
Subject Re: How to import *.sql file to postgresql database
Date
Msg-id AANLkTimtfJVqyAyNVde4iIfDiU2Q2GnNlifqI0esD9Zg@mail.gmail.com
Whole thread Raw
In response to How to import *.sql file to postgresql database  (Andre Lopes <lopes80andre@gmail.com>)
Responses Re: How to import *.sql file to postgresql database  (Andre Lopes <lopes80andre@gmail.com>)
List pgsql-general


2010/7/18 Andre Lopes <lopes80andre@gmail.com>
Hi,

I have a DUMP file with INSERT's commands. I need to import this data to postgresql database with the "psql" command.

How can I do this task?

Best Regards,

Hi,
you can do that for example using the following command:

psql <database> < file.sql

where <datatabase> is the name of the database you use.

regards
Szymon Guz

pgsql-general by date:

Previous
From: Andre Lopes
Date:
Subject: How to import *.sql file to postgresql database
Next
From: Osvaldo Kussama
Date:
Subject: Re: How to import *.sql file to postgresql database