Hello, I'm from Venezuela, and I've been making some modifications
to Postgre's Catalog, but it seems to be a problem creating the Template1
Database.

When the creation of the database is starting this is what happens:

[EMAIL PROTECTED]:~> /home/luis/pgsql/bin/initdb -D /home/luis/pgsql/data/

The files belonging to this database system will be owned by user "luis".
This user must also own the server process.

The database cluster will be initialized with locale es_ES.UTF-8.
The default database encoding has accordingly been set to UTF8.

fixing permissions on existing directory /home/luis/pgsql/data ... ok
creating directory /home/luis/pgsql/data/global ... ok
creating directory /home/luis/pgsql/data/pg_xlog ... ok
creating directory /home/luis/pgsql/data/pg_xlog/archive_status ... ok
creating directory /home/luis/pgsql/data/pg_clog ... ok
creating directory /home/luis/pgsql/data/pg_subtrans ... ok
creating directory /home/luis/pgsql/data/pg_twophase ... ok
creating directory /home/luis/pgsql/data/pg_multixact/members ... ok
creating directory /home/luis/pgsql/data/pg_multixact/offsets ... ok
creating directory /home/luis/pgsql/data/base ... ok
creating directory /home/luis/pgsql/data/base/1 ... ok
creating directory /home/luis/pgsql/data/pg_tblspc ... ok
selecting default max_connections ... 100
selecting default shared_buffers ... 1000
creating configuration files ...
ok
creating template1 database in /home/luis /pgsql/data/base/1 ... FATAL:  incorrect number of columns in row (expected 32, got 29)
child process exited with exit code 1
initdb: removing contents of data directory "/home/luis/pgsql/data"


I just added three more fields to pg_class structure (pg_class.h) just like this:

.
.
bool             relhasfrequency;    /* has time frequency */
NameData     relfrequencytype;  /* table time frequency type (REAL_TIME, HISTORIC)*/
NameData    relfrequency ;         /* class time frequency value*/
.
.
.
.
#define Natts_pg_class_fixed                 31
#define Natts_pg_class                          32
#define Anum_pg_class_relname            1
#define Anum_pg_class_relnamespace  2
.
.
.
DATA(insert OID = 1259 (  pg_class        PGNSP 83 PGUID 0 1259 0 0 0 0 0 f f r 32 0 0 0 0 0 t f f f f null 0 f _null_ ));
.
.
.

-pg_class- has originally 25 fields, and one of my friends has added four more
with no problems, but it seems to be a problem with the changes I've made, and
we don't know witch is it...


I also made the next changes to pg_attribute.h:
.
.
.
{ 1259, {"relhasfrequency"},16, -1,    1, 29, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0 }, \
{ 1259, {"relfrequencytype"},       19, -1, NAMEDATALEN, 30, 0, -1, -1, false, 'p', 'i', true, false, false, true, 0 }, \
{ 1259, {"relfrequency"},    19, -1, NAMEDATALEN, 31, 0, -1, -1, false, 'p', 'i', true, false, false, true, 0 }, \
{ 1259, {"relacl"},         1034, -1, -1, 32, 1, -1, -1, false, 'x', 'i', false, false, false, true, 0 }
.
.
.
DATA(insert ( 1259,relhasfrequency    16 -1 1 29  0 -1 -1 t p c t f f t 0));
DATA(insert ( 1259,relfrequencytype        19 -1 NAMEDATALEN    30 0 -1 -1 f p i t f f t 0));
DATA(insert ( 1259,relfrequency            19 -1 NAMEDATALEN    31 0 -1 -1 f p i t f f t 0));
DATA(insert ( 1259 relacl          1034 -1 -1 32 1 -1 -1 f x i f f f t 0));
.
.
.

If anyone could help me on this I would be very grateful, because this is the final
project of my Career... THANKS

--
Luis D. García M.
Telf: 0414-3482018

- FACYT - UC -
- Computación -

Reply via email to