Re: How do I import table information? - Mailing list pgsql-general

From Patrick Welche
Subject Re: How do I import table information?
Date
Msg-id 20010118190453.C24380@quartz.newn.cam.ac.uk
Whole thread Raw
In response to How do I import table information?  (Jeff Self <jself@greatbridge.com>)
List pgsql-general
On Thu, Jan 18, 2001 at 12:57:47PM -0500, Jeff Self wrote:
..
> But I'm getting an error because
> there are comments in the file.  If I remove the comments, the file works.
> I am using the command:  psql -e database < /home/dir/database.sql
>
> An example of the database.sql is this:
>
> # Table structure for table 'adminblock'
> #
...
> Is there a way to run this script without removing the comments?

How about

sed s/^#/--/

to get the standard SQL comment character(s)?

Cheers,

Patrick

pgsql-general by date:

Previous
From: Patrick Welche
Date:
Subject: Re: Re: date/time
Next
From: "Zolof"
Date:
Subject: pl/pgSQL & transaction