Int_aggregate/pgstattuple minor fix

From: "Dave Page" <dpage(at)vale-housing(dot)co(dot)uk>
To: "PostgreSQL-patches" <pgsql-patches(at)postgresql(dot)org>
Subject: Int_aggregate/pgstattuple minor fix
Date: 2004-10-01 13:35:08
Message-ID: E7F85A1B5FF8D44C8A1AF6885BC9A0E4306853@ratbert.vale-housing.co.uk
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-patches

The patch below removes attempts to drop objects before creating them
from the int_aggregate and pgstattuple SQL scripts. This causes the
script to fail on databases where the affected objects don't already
exist when the script is executed by the Win32 installer, pgAdmin or any
other interface that executes scripts 'as-is'. None of the other contrib
scripts appear do this.

Please apply.

Regards, Dave

Index: int_aggregate.sql.in
===================================================================
RCS file:
/projects/cvsroot/pgsql-server/contrib/intagg/int_aggregate.sql.in,v
retrieving revision 1.5
diff -u -r1.5 int_aggregate.sql.in
--- int_aggregate.sql.in 14 May 2003 03:25:56 -0000 1.5
+++ int_aggregate.sql.in 1 Oct 2004 13:23:25 -0000
@@ -17,7 +17,7 @@

-- The aggration funcion.
-- uses the above functions to create an array of integers from an
aggregation.
-DROP AGGREGATE int_array_aggregate(int4);
+-- DROP AGGREGATE int_array_aggregate(int4);
CREATE AGGREGATE int_array_aggregate (
BASETYPE = int4,
SFUNC = int_agg_state,
Index: pgstattuple.sql.in
===================================================================
RCS file:
/projects/cvsroot/pgsql-server/contrib/pgstattuple/pgstattuple.sql.in,v
retrieving revision 1.8
diff -u -r1.8 pgstattuple.sql.in
--- pgstattuple.sql.in 12 Jun 2003 08:02:53 -0000 1.8
+++ pgstattuple.sql.in 1 Oct 2004 13:30:27 -0000
@@ -1,7 +1,7 @@
-- Adjust this setting to control where the objects get created.
SET search_path = public;

-DROP TYPE pgstattuple_type CASCADE;
+-- DROP TYPE pgstattuple_type CASCADE;
CREATE TYPE pgstattuple_type AS (
table_len BIGINT, -- physical table length in
bytes
tuple_count BIGINT, -- number of live tuples

Responses

Browse pgsql-patches by date

  From Date Subject
Next Message Sergej Sergeev 2004-10-01 13:47:11 Re: plperl features
Previous Message Bruce Momjian 2004-10-01 12:23:26 Re: Preliminary patch for FRONTEND