Re: Batch Definitions - Need Help

From: John DeSoi <desoi(at)pgedit(dot)com>
To: Michael Avila <mavila(at)mich(dot)com>
Cc: Pgsql-Novice Novice <pgsql-novice(at)postgresql(dot)org>
Subject: Re: Batch Definitions - Need Help
Date: 2005-06-14 11:39:50
Message-ID: 64609be852bdff1eefb820b4b05edda5@pgedit.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: 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

In response to

Browse pgsql-novice by date

  From Date Subject
Next Message Havasvölgyi Ottó 2005-06-14 16:31:09 Re: need suggestion for server sizing
Previous Message Greg Sabino Mullane 2005-06-14 03:27:06 Re: Wrong SQLSTATE returned?