The trick is to not make this a field of type calculation.
Change the field type to text.
Then select the Calculation option on the auto-enter tab. You should find that you already have the calculation you need there from when it was defined as a calculation field. If not, type it in.
Now you can set the unique values validation and it will work.
You'll need to think about whether or not to clear the "do not replace existing values" check box. It depends on how the two id's are assigned values as two whether you need this option cleared or not.
I can't reproduce your issue. Do you use lastest update of FM14?
It was and is a text field. It uses a simple calculation to insert two id numbers concatenated by underscore. It is indexed. But I can not save the validation for unique vales.
I am thinking now that either it is a bug with unknown source, or my file is corrupted.
I have used this method any times on join tables to get a "unique value pair" and have never had a problem doing so.
Compare your set up to what I specified for the UniquePairTest field in this demo file...
UniqueValuePair.fmp12.zip 67.5 K
I tested myself.
The file I have is NOT working. So, there is no check on unique values.
Just now I created another file and tested. It worked.
After looking at the original file, I found that it seems to be corrupted. There is a table that was restored by Filemaker itself and i did not notice. I am not sure what it means, but it is obviously a defect that appeared after some kind of a crash. I ran it through restoring the file, but there are no errors reported. Strange.
Ohhhhhh - I fear I have to recreate the database and the whole application or go back to some older saved copy as I do not know when this started to happen. But that means also to lose at least a week of work. (((
Well, I see that even after again restoring the file, it does not work in this file. No unique value can be set on the combined id-field. But it is ok in fields just id or name.
For those interested, I am uploading a stripped-down and early version for testing. The same error already appeared here. I removed the passwords. It comes without a password in Guest or Admin. It does not contain sensitive data.
The table: PARTYPROJECT
The field "partyProject_idx"
You still have to enter "admin" as the account name before you can open the file.
The field definitely appears corrupted. Very flaky behavior for any field option changes you might make. Sometimes they "take" and sometimes they don't. Unique values was never selectable.
But if I defined a brand new field with the same calculation, I could specify unique values for it.