I need to restore a Postgresql dump file to get some data out of it (note never used Postgresql before)
I've tried using the command line using the following (with relevant details filled in)
psql -U {user-name} -d {desintation_db}-f {dumpfilename.sql}
And initially it looks like it's working, lot's of drops and alters flashing up. But then it ends and nothing's in the db. Looking through the dump file it doesn't look like it actually got to the end either.
I've also tried just opening the dump file in a SQL Editor and executing it on my db, but a short way into the file it errors with "syntax error at or near "1" on this line
--
-- Data for Name: admin_groups; Type: TABLE DATA; Schema: public; Owner: postgres
--
COPY admin_groups (ref, title, is_locked, created, updated) FROM stdin;
1 Default t 2011-05-25 15:13:46.474025 2011-05-25 15:13:46.474025
2 Root t 2011-05-25 15:13:54.137801 2011-05-25 15:13:54.137801
\.
Any ideas?