Re: porting question: funky uid names? - Mailing list pgsql-hackers

From Peter Eisentraut
Subject Re: porting question: funky uid names?
Date
Msg-id Pine.LNX.4.30.0103092152180.929-100000@peter.localdomain
Whole thread Raw
In response to porting question: funky uid names?  (Mark Bixby <mark@bixby.org>)
Responses Re: porting question: funky uid names?
List pgsql-hackers
Mark Bixby writes:

> Creating global relations in /blah/blah/blah
> ERROR:  pg_atoi: error in "BIXBY": can't parse "BIXBY"
> ERROR:  pg_atoi: error in "BIXBY": can't parse "BIXBY"
> syntax error 25 : -> .

I'm curious about that last line.  Is that the shell complaining?

The offending command seems to be

insert OID = 0 ( POSTGRES PGUID t t t t _null_ _null_ )

in the file global1.bki.source.  (This is the file the creates the global
relations.)  The POSTGRES and PGUID quantities are substituted when initdb
runs:

cat "$GLOBAL" \   | sed -e "s/POSTGRES/$POSTGRES_SUPERUSERNAME/g" \         -e "s/PGUID/$POSTGRES_SUPERUSERID/g" \   |
"$PGPATH"/postgres$BACKENDARGS template1
 

For some reason the line probably ends up being

insert OID = 0 ( MGR BIXBY 484 t t t t _null_ _null_ )                   ^
which causes the observed failure to parse BIXBY as user id.  This brings
us back to why the dot disappears, which seems to be related to the error
message

syntax error 25 : -> .                   ^^^

Can you try using a different a sed command (e.g, GNU sed)?

-- 
Peter Eisentraut      peter_e@gmx.net       http://yi.org/peter-e/



pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: Internationalized error messages
Next
From: Peter Eisentraut
Date:
Subject: Re: undefined reference pq