Thu Apr 14 09:20:24 PDT 2005
- Previous message: [Slony1-general] Table has no unique index - is this a bug?
- Next message: [Slony1-general] Slony-I version 1.1 beta released
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
> Hi. > > > I'm using: > > > PostgreSQL 8.0.2 > Slony 1.0.5 > > > initialized with the following script: > > > ######## > > > #! /bin/bash > > > . testenv.sh > > > psql master <<_EOPSQL_ drop table test2; create table test2 (testid int > unique not null); _EOPSQL_ > > > ## slony init stuff goes here > .... > ## init stuff end > > > set add table (set id=1, origin=1, id=2, fully qualified name = > 'public.test2', key = 'testid' ); > ######### > > > 'set add table' fails with error: > > > <stdin>:14: PGRES_FATAL_ERROR select > "_test".determineIdxnameUnique('public.test2', 'testid'); - ERROR: > Slony-I: table public.test2 has nounique index testid As you might have noticed, when creating that table: NOTICE: CREATE TABLE / UNIQUE will create implicit index "test2_testid_key" for table "test2" The name of the unique index is "test2_testid_key". If you enter that name in key="", then it should work. set add table (set id=1, origin=1, id=2, fully qualified name = 'public.test2', key = 'test2_testid_key' ); > I can add a table _only_ if I create primary key, but sometimes I > cannot do this (because of existing multi-column PKEYs). > > Is this a bug, or I'm missing something? >
- Previous message: [Slony1-general] Table has no unique index - is this a bug?
- Next message: [Slony1-general] Slony-I version 1.1 beta released
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Slony1-general mailing list