Sungchul Park <scpark@gen128.com> writes:
> Fo2Me=# CREATE TABLE dirinfo(
> Fo2Me(# code VARCHAR(8) PRIMARY KEY,
> Fo2Me(# level SMALLINT NOT NULL,
> Fo2Me(# name TEXT NOT NULL,
> Fo2Me(# count SMALLINT NOT NULL DEFAULT 0
> Fo2Me(# );
> NOTICE: CREATE TABLE/PRIMARY KEY will create implicit index 'dirinfo_pkey'
> for table 'dirinfo'
> CREATE
> Fo2Me=# INSERT INTO dirinfo (code, level, name) VALUES('hbcol', 1, 'abc');
> INSERT 63411 1
> Fo2Me=# INSERT INTO dirinfo (code, level, name) VALUES('hbcrf', 1, 'zzz');
> ERROR: Cannot insert a duplicate key into unique index dirinfo_pkey
> The version of postgresql is 7.0.2 and the database created with EUC_KR encoding.
I cannot duplicate this failure with current REL7_0 sources
(7.0.3-to-be) and EUC_KR encoding. Either it's been fixed since
7.0.2 (but there are no likely-looking patches in the CVS logs),
or there is something platform- or environment-specific about the
problem.
One possible environment issue: what LOCALE are you running the
postmaster in? (Check environment variables used when postmaster
is started for LOCALE or LC_xxx variables.)
I don't believe you mentioned what platform you are on, either.
regards, tom lane