Re: Developers page is down

From: Gaetano Mendola <mendola(at)bigfoot(dot)com>
To: Shahbaz Javeed <sjaveed(at)gmail(dot)com>
Cc: Christopher Browne <cbbrowne(at)acm(dot)org>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: Developers page is down
Date: 2004-09-05 09:40:05
Message-ID: 413ADEF5.3040906@bigfoot.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-cygwin pgsql-hackers pgsql-hackers-win32

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Shahbaz Javeed wrote:
| I've always considered a table definition to be an unordered hash so
| the concept of putting something in the "middle of a table" from that
| view doesn't seem to have a point.
|
| Just my $0.02

I already wrote my motivation, and I'll do again.
In our development environment we have a .sql file
for each table, view, function. The schema creation
is Makefile driven and the development three is
divided in packages / projects. Each project and
packages are composed by various components.
I try to organize the table definition grouping the
homogeneous field together:

Suppose that this is the definition of a table:

CREATE TABLE foo (
a1 INTEGER,
~ a2 VARCHAR,
~ ...
~ an FLOAT,
~ b1 ....
~ ...
~ bn ...
);

some time ( fortunately not so often ) you need to add
a field to that table that for homogeneity is a(n+1).
Some time is also not possible to split foo in two tables
for various reasons:

~ - is not possible define multitable constraint, of course
~ is possible with triggers but is more work: a function
~ trigger to maintain and test.

~ - is not possible to define a multitable index and no
~ work around for this, in my knowledge at least.

What we do actually is put that field at the end and not in
his logical place, this because before to apply the new schema
in production I do a diff between the production schema and the
development schema. You can argue that is the diff tool that must
be fixed however is hard to work with a table in production that
is dumped/displayed by various tools: pgaccess, dbvisualizer,
pgadminII/III, enterprise architect, visio,... in a different
way your development table.

This is why in our coding rule we have
- New fields must be added at the end.

Regards
Gaetano Mendola

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.4 (MingW32)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org

iD8DBQFBOt717UpzwH2SGd4RAuuZAJwKkDVpwgRNI0vQJ4TC7qllQjH5XgCgmrKv
kqwKVVO3ha+FUsQHggyfyvU=
=z9y4
-----END PGP SIGNATURE-----

In response to

Browse pgsql-cygwin by date

  From Date Subject
Next Message marlon alexis 2004-09-07 15:19:32 postgreSQL-cygwin
Previous Message Terry Branscombe 2004-09-05 06:42:53 [newbie] Postmaster service on W2K

Browse pgsql-hackers by date

  From Date Subject
Next Message Gaetano Mendola 2004-09-05 10:01:19 Re: invalid string enlargment PG 7.4.5 ( SOLVED )
Previous Message Shahbaz Javeed 2004-09-05 03:24:23 Re: Developers page is down

Browse pgsql-hackers-win32 by date

  From Date Subject
Next Message Magnus Hagander 2004-09-05 19:00:34 Re: Compiling beta2 with openssl on XP Pro
Previous Message Shahbaz Javeed 2004-09-05 03:24:23 Re: Developers page is down