Skip site navigation (1) Skip section navigation (2)

pgsql-server/src backend/commands/sequence.c b ...

From: momjian(at)postgresql(dot)org (Bruce Momjian - CVS)
To: pgsql-committers(at)postgresql(dot)org
Subject: pgsql-server/src backend/commands/sequence.c b ...
Date: 2003-03-20 05:18:15
Message-ID: 20030320051815.72194475C3D@postgresql.org (view raw or flat)
Thread:
Lists: pgsql-committers
CVSROOT:	/cvsroot
Module name:	pgsql-server
Changes by:	momjian(at)postgresql(dot)org	03/03/20 00:18:15

Modified files:
	src/backend/commands: sequence.c 
	src/bin/pg_dump: pg_dump.c 
	src/include/commands: sequence.h 

Log message:
	> > - Move SEQ_MAXVALUE, SEQ_MINVALUE definitions to sequence.h
	> >
	> > - Add check in pg_dump to see if the value returned is the max /min
	> > values and replace with NO MAXVALUE, NO MINVALUE.
	> >
	> > - Change START and INCREMENT to use START WITH and INCREMENT BY syntax.
	> > This makes it a touch easier to port to other databases with sequences
	> > (Oracle).  PostgreSQL supports both syntaxes already.
	>
	> +       char            bufm[100],
	> +                               bufx[100];
	>
	> This seems to be an arbitary size. Why not set it to the actual maximum
	> length?
	>
	> Also:
	>
	> +       snprintf(bufm, 100, INT64_FORMAT, SEQ_MINVALUE);
	> +       snprintf(bufx, 100, INT64_FORMAT, SEQ_MAXVALUE);
	>
	> sizeof(bufm), sizeof(bufx) is probably the more
	> maintenance-friendly/standard way to do it.
	
	I changed the code to use sizeof - but will wait for a response from
	Peter before changing the size.  It's consistent throughout the sequence
	code to be 100 for this purpose.
	
	Rod Taylor <rbt(at)rbt(dot)ca>


pgsql-committers by date

Next:From: Bruce Momjian - CVSDate: 2003-03-20 05:19:27
Subject: pgsql-server/src/backend/utils/adt formatting.c
Previous:From: Bruce Momjian - CVSDate: 2003-03-20 05:06:55
Subject: pgsql-server/src/backend/catalog information_s ...

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group