Re: Help loading data. Error code page 850

From: Christopher Patrouch <cpatrouch(at)gmail(dot)com>
To: Michael Wood <esiotrot(at)gmail(dot)com>
Cc: PostgreSQL List - Novice <pgsql-novice(at)postgresql(dot)org>
Subject: Re: Help loading data. Error code page 850
Date: 2011-03-02 19:52:18
Message-ID: AANLkTi=Ccb=tLp0p=iM9LjjNt8XRR45Kxyr+qo94AU8S@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice

Glad to report that all is fine.

Reinstalled PostgreSQL under a different Windows user name. Used the
default path for the data files. Changed the pg_hba.conf file permissions.
Learned the difference between the PostgreSQL psql prompt and the Windows
cmd prompt. Remembered to put quotes around file paths (where needed), and
eliminated some external variables (such as an accented Windows user account
name).

So all seems to be working pretty well and I'm enjoying it. Thanks again
for your response to my initial inquiry. And, Michael, you were right --
turned out not to have anything to do with the Open Office files.

On Sat, Feb 19, 2011 at 7:48 AM, Michael Wood <esiotrot(at)gmail(dot)com> wrote:

> Hi
>
> I've added the mailing list back in.
>
> On 19 February 2011 00:12, Christopher Patrouch <cpatrouch(at)gmail(dot)com>
> wrote:
> > Hi Michael,
> >
> > Thanks so much for getting back to me.
> >
> > You outlined four steps. I followed them all (until now, I didn't know I
> > could click on the icon on the cmd prompt, properties, font. There it
> was,
> > Lucida console.)
> >
> > Then I open the PSQL console, and I still get the warning about console
> page
> > 850 differing from 1252. I'm actually getting confused about which one I
> > should be going for. Here's a lot of detail, but maybe I'm on the right
> > track:
>
> OK, I don't know what you mean by "open the PSQL console". Did you
> run "psql" from the console where you changed the code page and font?
>
> > 1. I opened up a command prompt from my user directory so I typed in cd\
> to
> > get to the root directory. From there, I typed cmd.exe /c chcp 1252. My
> > computer os is in French, so I got a message that translates to "page
> code
> > activated: 1252"
>
> OK, after this you should change the font for this Command Prompt
> window (or else use the "Update shortcut" option to change it
> permanently for all future Command Prompt windows). Then, from this
> command prompt window, run the psql command or whatever non-GUI tool
> you were using to import the data.
>
> > 2. IPostGIS, using PgAdmin III Shape Loader, I tried to load a Shape
> file
> > (associated with two other files of the same name, one of which should
> have
> > a .dbf extension) again, but it fails (saying it can't find the .dbf
> file;
> > this is inicidental...but it shows up in the directory as an Open Office
> > file, even though when I open in Open Office, it shows up with a .dbf
> > extension .... hmmm. I just double-clicked on it and I get a menu
> "Import
> > DBase Files, Character set" and it offers me a long list of choices,
> > including Western Europe (Windows-1252/WinLatin 1); so I selected that
> one.
> > I open it, then save it. Use the latest ODF format or Keep Format. I
> > chose Keep Current Format. I get an error message regarding max number
> of
> > characters and decimal places, 19 and 11, respectively. There are 20
> > characters (including the decimal point). So couldn't save it in the
> > current format.
>
> .dbf is normally used for DBase files (or similar database files), but
> I don't know if that's true for your files. I am not sure opening the
> files in OpenOffice is a good idea, and saving them again from
> OpenOffice is not likely to do any good, and might corrupt the results
> too.
>
> I am not familiar with IPostGIS and have not used PgAdmin III, so I'm
> not sure how this is meant to work, but I assume they are both GUI
> tools and therefore should not be affected by the settings in the
> Command Prompt window.
>
> > Clearly I'm on to something regarding this particular data set, if not
> the
> > problem in general.
>
> I'm not convinced :)
>
> > 3. When I typed cmd.exe chcp 1252, I saw nothing afterwards except the
> > message about the activated code page. Then I navigated to the directory
> in
> > which I find my psql file. I ran the command psql and was prompted for
> my
> > password, which I understand should be the same as that which I gave when
> > installing PostgreSQL. I got a FATAL: password authentication failed
> for
> > user "Cristòbal" (except the ò showed up in DOS as a Greater than or
> Equal
>
> You might need to specify the username to use instead of your Windows
> username. The username for accessing PostgreSQL needn't have anything
> to do with the Windows username.
>
> > sign -- When I got my computer, I set it up using the Spanish spelling of
> my
> > name, Cristòbal... and needless to say that has caused a lot of problems.
> > I'll never use a accent marks again for that type of thing).
> >
> > For now, I'm still stuck at the beginning. Maybe I should reboot?
>
> Rebooting is unlikely to improve the situation.
>
> > Thanks again,
>
> No problem. I hope my e-mail helps.
>
> > Chris
>
> --
> Michael Wood <esiotrot(at)gmail(dot)com>
>

In response to

Browse pgsql-novice by date

  From Date Subject
Next Message Chetan Suttraway 2011-03-03 05:25:49 Re: General question about memory usage
Previous Message Alan Hodgson 2011-03-02 19:14:08 Re: Any One Else Getting Spam?