Re: duplicates - Mailing list pgsql-admin

From Tsirkin Evgeny
Subject Re: duplicates
Date
Msg-id Pine.LNX.4.58.0409061050190.20694@p-roman.jct.ac.il
Whole thread Raw
In response to Re: duplicates  ("Andrei Bintintan" <klodoma@ar-sd.net>)
List pgsql-admin
On Mon, 6 Sep 2004, Andrei Bintintan wrote:

> If still got problems, please post some queries, be more specific.
>
> Best regards,
> Andy.
>
Ok i will try:
CREATE TABLE schedule (
       studentid    decimal(9),
       groupid      decimal(10),
       maslulsignid decimal(7),
       tfusot        varchar(29)
);

that is the table for writing down the courses/groups
a students takes.note there is NO unique constrain here
(maybe it should be but that the way it is and probably
can't can't be changed).while changing groups for a student
the applic. deletes all the groups the student had :
delete from schedule where studentid=11111;
and then inserts the new groups (regular inserts).
Now sometimes we got duplicates of the same groupid and
studentid in the table(everything is same).i thought that \
maybe the delete do not delete but the insert succeed?

Note :I know that there could be created the a unique key and
a constrain but befor we have to understand why the duplicates
were created.

--
Evgeny.

pgsql-admin by date:

Previous
From: "Andrei Bintintan"
Date:
Subject: Re: duplicates
Next
From: "Andrei Bintintan"
Date:
Subject: Re: duplicates