Re: Batch Definitions - Need Help - Mailing list pgsql-novice

From John DeSoi
Subject Re: Batch Definitions - Need Help
Date
Msg-id 64609be852bdff1eefb820b4b05edda5@pgedit.com
Whole thread Raw
In response to Re: Batch Definitions - Need Help  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-novice
On Jun 13, 2005, at 8:45 PM, Tom Lane wrote:

> Either
> psql mydb <batchfile
> or
> psql -f batchfile mydb
>
> ... edit out MySQL-isms, lather rinse repeat ...
>
> I don't know exactly what a MySQL batch file looks like, in particular
> whether they do anything nonstandard for bulk data load.  To the extent
> that the file contains reasonably-standard SQL commands, though, it
> should work.


To start you will need to replace any single line comments that start
with '#' to use the SQL standard '--'

You might find some helpful tools here to perform some of the
conversion task:

http://sqlfairy.sourceforge.net/



John DeSoi, Ph.D.
http://pgedit.com/
Power Tools for PostgreSQL


pgsql-novice by date:

Previous
From: "Greg Sabino Mullane"
Date:
Subject: Re: Wrong SQLSTATE returned?
Next
From: Havasvölgyi Ottó
Date:
Subject: Re: need suggestion for server sizing