RE: Uniqueness

  • From: "Mercadante, Thomas F (LABOR)" <Thomas.Mercadante@xxxxxxxxxxxxxxxxx>
  • To: <jacintakean@xxxxxxxxx>, <oracle-l@xxxxxxxxxxxxx>
  • Date: Wed, 18 May 2005 08:00:59 -0400

You can also:

Select id, count(*)
From mytbl
Group by id
Having count(*) > 1
/


-----Original Message-----
From: oracle-l-bounce@xxxxxxxxxxxxx
[mailto:oracle-l-bounce@xxxxxxxxxxxxx] On Behalf Of Kean Jacinta
Sent: Wednesday, May 18, 2005 2:12 AM
To: oracle-l@xxxxxxxxxxxxx
Subject: Uniqueness

Hi again,

Is there a way to check for uniqueness of a value ?
Apart from set the column to be unique ?

For example :

Table : mytbl
PK ID
----
1
2
3

Insert into mytbl (id) values (2);
=20
Oracle will give error.=20


__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around=20
http://mail.yahoo.com=20
--
//www.freelists.org/webpage/oracle-l
--
//www.freelists.org/webpage/oracle-l

Other related posts: