pg_dump and large objects

From: "Vadim B(dot) Mikheev" <vadim(at)sable(dot)krasnoyarsk(dot)su>
To: hackers(at)postgresql(dot)org
Subject: pg_dump and large objects
Date: 1998-02-25 04:01:04
Message-ID: 34F39780.40822842@sable.krasnoyarsk.su
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

This is from AA van Raalte (alvin(at)camberlo(dot)demon(dot)co(dot)uk) and shows that
we have some problems when dumping tables with LO:
>
> 3/ The following script causes pg_dump to fail with a Segmentation fault. On my
> system pg_dump tries to generate an index on a large object. The SELECT statement
> in pg_dump that obtains the list of objects to be dumped explicitly rejects large
> objects. This SELECT statement is returning an incorrect value!.
>
> --------cut-------------
> db=testdump
> a=1
>
> destroydb $db
> createdb $db
> psql -c "create table hobs_log1 (id text, obj oid);" $db
>
> while [ $a -lt 100 ]; do
> psql -c "insert into hobs_log1 (id, obj) values ('$a', lo_import('/home/alvin/pg2'));" $db
> pg_dump $db || exit $?
> a=`expr $a + 1`
> done
>
> echo success
> -------cut---------------
>
> The following is the output of the above script on my system.
> Note the rather garbled line containing xinv18337, this is a CREATE INDEX
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
> command and should never have been generated.
>
> --------cut--------------
> CREATE
> INSERT 18351 1
> \connect - alvin
> CREATE TABLE hobs_log1 (id text, obj oid);
> COPY hobs_log1 FROM stdin;
> 1 18337
> \.
> @" int4_ops );xinx18337 on xinv18337 using btree ( "qdR
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
> INSERT 18383 1
> \connect - alvin
> CREATE TABLE hobs_log1 (id text, obj oid);
> COPY hobs_log1 FROM stdin;
> 1 18337
> 2 18369
> \.
> ------------cut-------------

Vadim

Browse pgsql-hackers by date

  From Date Subject
Next Message The Hermit Hacker 1998-02-25 04:29:07 Re: [HACKERS] Re: [QUESTIONS] Snapshot has not compiled in a couple of days
Previous Message Thomas G. Lockhart 1998-02-25 03:27:42 Re: [HACKERS] Re: [QUESTIONS] Snapshot has not compiled in a couple of days