Cannot be since you are allowed to have the same companynumber several times for type
2 - but you are right in refering to 'id' - in fact the design is faulty. Quite
obviously the 'type' is an attribute of the company, not of the employee. There is no
way but a trigger to check it, but it should
Hi,
Unique(companynumber, type)
or
you combine 2 columns together
CompanyNumber_Type (this can become primary key, I don't think you need the id column,
pseudo column rownum is the same)
You have lesser indexing
123_1
123_2
Sinardy
-Original Message-
Sent: 29 August 2003 18:24
Sounds like 'Companynumber' and 'Type' should be either a compound Primary
Key, or a unique index. Which begs the question of what 'Id' is doing -
perhaps you don't need it.
peter
-Original Message-
Sent: Friday, August 29, 2003 10:39 AM
To: Multiple recipients of list ORACLE-L
Hallo,
>Hallo,
>
>I would like to gets ome help on this:
>
>I have this table
>
>IdCompanynumber First Name LastName
>Type
>
>1 123 Jim Andersson 1
>2 234 Tom Perkins
> 2
>3 565 Henry Ford1
>
>
>I wo
Hi
I think the only way to do this is by using a (before insert) trigger.
Jack
-Original Message-
Sent: Friday, August 29, 2003 11:39 AM
To: Multiple recipients of list ORACLE-L
Hallo,
I would like to gets ome help on this:
I have this table
IdCompanynumber First Name Las