Re: [BUGS] pg_dumpall - Mailing list pgsql-bugs

From Peter Eisentraut
Subject Re: [BUGS] pg_dumpall
Date
Msg-id Pine.LNX.4.21.0003040345530.489-100000@localhost.localdomain
Whole thread Raw
In response to pg_dumpall  ("Kardos, Dr. Andreas" <kardos@repas-aeg.de>)
Responses Re: [BUGS] pg_dumpall
List pgsql-bugs
Kardos, Dr. Andreas writes:

> The pg_dumpall script is not compatible with 7.0 psql and createdb.

Darn me! I'll look into this. Some of the stuff in pg_dumpall can be
solved more elegantly by now.

> 1. pgsql -l delivers a different output (Owner instead of User ID).
> Therefore in the following command "usesysid" has to be replaced by
> "usename":
>
>  POSTGRES_USER="`echo \" \
>   select usename \
>   from pg_shadow \
>   where usesysid = $DBUSERID; \" | \
>   psql -A -q -t template1`"

Huh? Doesn't it look like that now?


> 2. createdb -help in the following line tries to connect the host "elp".
>
>  if createdb -help|grep encoding >/dev/null
>  then
>   echo "create database $DATABASE with encoding='`pg_encoding $ENCODING`';"
>  else
>   echo "create database $DATABASE;"
>  fi

I'd be inclined to say that you can leave off the encoding phrase if the
encoding is 'SQL_ASCII' (or 0). That is always the case if you don't use
multibyte.


> 3. QNX4 only: The double quotes in
>
>  POSTGRES_USER="`echo \" \
>
> etc. must not be escaped with a backslash.

Technically, it should just work without them (the backslash, that is).
Then again, I'm not the greatest portable shell programmer.

I'll see what I can do.

--
Peter Eisentraut                  Sernanders väg 10:115
peter_e@gmx.net                   75262 Uppsala
http://yi.org/peter-e/            Sweden

pgsql-bugs by date:

Previous
From: Peter Eisentraut
Date:
Subject: Re: [BUGS] Can't find a default operator class for type 1296.
Next
From: Peter Eisentraut
Date:
Subject: Re: [BUGS] initdb and version 7