Christopher Browne cbbrowne
Tue Apr 4 10:02:02 PDT 2006
Miguel <mmiranda at 123.com.sv> writes:

> hi, this a design database question , i have a detail table that only 
> have 4 columns, i want ot replicate it with slony:
>
> CREATE TABLE horarios_general
> (
>   idplan int4 NOT NULL,
>   idhorario int4 NOT NULL,
>   dia_inicio int4 NOT NULL,
>   dia_fin int4 NOT NULL,
>   hora_inicio time NOT NULL,
>   hora_fin time NOT NULL
> )
>
> it doesnt have a primary key, would it be a problem if the key is 
> confirmed of all the table's columns?, is that recommended?

You MUST have a candidate for primary key.

It tends to be most efficient if the PK has fewer columns rather than
more, but really, your decision should be based on what the best sort
of primary key should be for the table.
-- 
output = ("cbbrowne" "@" "ca.afilias.info")
<http://dba2.int.libertyrms.com/>
Christopher Browne
(416) 673-4124 (land)



More information about the Slony1-general mailing list