Re: Garbage character inserted at the beginning of every SQL file on OSX - Mailing list pgadmin-support

From Josh Berkus
Subject Re: Garbage character inserted at the beginning of every SQL file on OSX
Date
Msg-id 4B7DABF2.4020705@agliodbs.com
Whole thread Raw
In response to Re: Garbage character inserted at the beginning of every SQL file on OSX  (Josh Berkus <josh@agliodbs.com>)
List pgadmin-support
On 2/17/10 2:52 PM, Josh Berkus wrote:
>> It's not garbage, it's a Unicode BOM.
>>
>> If your other software cannot read Unicode files properly, you can
>> turn off Unicode file writing under File -> Options.
> 
> psql is apparently unhappy with the BOM.
> 
> Thanks, I'll let you know if that fixes the issue; if it does, that
> should go in the FAQ.

This appears to fix the problem.  I suggest the following FAQ item:

Q: Why do I get "Error On Line 1" trying to load SQL files created with
pgAdmin using psql or other command-line tools?

A: The command-line tools you are using are not unicode-friendly, or are
not configured to be.  You should turn off Unicode in the pgAdmin
preferences for the Editor.

--Josh Berkus



pgadmin-support by date:

Previous
From: Dave Page
Date:
Subject: Re: Garbage character inserted at the beginning of every SQL file on OSX
Next
From: Mario Splivalo
Date:
Subject: Graphical Query Builder - usage stats?