Hollis, Virginia
hollisvj at pgdp.usec.com
Thu Nov 19 06:49:24 CST 2009
William got the idea. I guess I am not explaining it right. This is for
ordering & tracking supplies.
Each record contains a different supply consisting of the name of the
supply item and its description. The name & description together need to
be different on each record. So each distinct record name & description
when paired together are different.
Like Williams example. They can't put Red & Blue in record 1 & then
again in record 2. It can be Red & Green for record 2.
I don't want duplicate records based on the supplies item name &
matching description. One record for each name & description together.
However, checking that the same data isn't entered in both fields is a
good idea to check for too. I didn't think of that.
**************
Virginia
1) to ensure that no two distinct records have the same data in the two
fields
ID ItemName ItemDesc
1 red blue
2 red blue
set a unique index using both fields in the index ...this will gen
an error when record two is entered use the error to gen a custom dialog
2) to ensure that a distinct record does not have the same data in both
fields set a table level validation check constraint
[ItemName] <> [ItemDesc]
zero code and it works in the background however the data in those two
fields are edited
hth
William