Re: pg_dump error - LOCALIZATION PROBLEM - Mailing list pgsql-general

From Peter Eisentraut
Subject Re: pg_dump error - LOCALIZATION PROBLEM
Date
Msg-id Pine.LNX.4.30.0109141709410.691-100000@peter.localdomain
Whole thread Raw
In response to pg_dump error - LOCALIZATION PROBLEM  ("Erol Öz" <eroloz@esg.com.tr>)
Responses Re: pg_dump error - LOCALIZATION PROBLEM
List pgsql-general
Erol Öz writes:

> I think Tom Lane is right as always. My postgresql server was
> configured with --enable-locale option and it works perfect with
> Turkish stuff. However I could not find a solution to the problem
> below.

Untested, but try this:

Edit src/backend/commands/variable.c, look for the function
parse_XactIsoLevel().  Change the code that looks like this:

        if (strcasecmp(value, "SERIALIZABLE") == 0)
                XactIsoLevel = XACT_SERIALIZABLE;
        else if (strcasecmp(value, "COMMITTED") == 0)
                XactIsoLevel = XACT_READ_COMMITTED;

into:

        if (strcmp(value, "serializable") == 0)
                XactIsoLevel = XACT_SERIALIZABLE;
        else if (strcmp(value, "committed") == 0)
                XactIsoLevel = XACT_READ_COMMITTED;

Recompile and install.

> <eroloz@esg.com.tr> writes:
> >> I get an error when the following command executed;
> >> /usr/local/pgsql/bin/pg_dump trollandtoad > trollandtoad.out
> >>
> >>SET TRANSACTION command failed. Explanation from backend: 'ERROR:  Bad TRAN=
> >>SACTION ISOLATION LEVEL (serializable)
>
> >Hmm.  It would seem that strcasecmp() on your platform reports that the
> >strings "SERIALIZABLE" and "serializable" are not equal.  A locale
> >problem perhaps?

--
Peter Eisentraut   peter_e@gmx.net   http://funkturm.homeip.net/~peter


pgsql-general by date:

Previous
From: Peter Eisentraut
Date:
Subject: Re: Numerical DB/Table Names
Next
From: "Joe Conway"
Date:
Subject: Re: Numerical DB/Table Names