softpac Posted January 10, 2007 Posted January 10, 2007 How do you enforce at the table level uniqueness over tow fields in the same table? The Unique check box under the Validation tab is for the current field. But I need it to be over two fields.
mr_vodka Posted January 10, 2007 Posted January 10, 2007 Do you mean that the value can only be used one time in either of the fields? In other words, if you type the word "blue" into any record in either one of the fields, you do not want the user to be able to type "blue" into either field for any record again. If so, what is the purpose of doing this?
softpac Posted January 11, 2007 Author Posted January 11, 2007 No, I mean where the combination of the two fields is unique for the table. Eg. Field A and Field B may have the following values: blue, cat red, dog green, bird red, bird the above are all unique. But repeating any of the records would be non-unique.
softpac Posted January 11, 2007 Author Posted January 11, 2007 yes it does. thanks so much. I have chosen the method of creating an extra field in the table, using auto-calc to concatenate the two fields, then under validation tab, ticking the unique box for this auto-entry field. Being a newbie to FM, but an old hat at SQL, its a paradigm shift for me. Eg in any SQL language I know (Oracle, DB2, MySQL and even Access), you never need to create an extra field in order to achieve uniqueness - hence the reason why I did not think along this line). But I am slowly coming to speed on the FM way of thinking :)
Recommended Posts
This topic is 6585 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now