What´s the best way to check that two or more properties are unique?

Hi Community,

maybe somebody knows a simple solution for this use case. My Part table has the following properties. Nothing really exotic:

item_number | erp_number | major_rev | name | ..

Both item_number and erp_number shall be unique values. When I tick the unique checkbox in the ItemType definition for both properties, a combination of the two properties will be used for the uniquness check. 

There are use cases were this kind of unified uniquenss check is extremely helpful, like Part Goals. But in my use case I want to check item_number and erp_number indepented for their uniqueness. 

What´s the most easy way to achieve this? Is there a way to prevent using a Method?

Thanks for any idea!

Angela

Parents
  • Hi Chris and Amitosh,

    many thanks for your help! I didn´t expect to get such detailed response to this question.

    That are a lot of suggestions an I like all of them! It really depends on the use case which one fits best. In my case, I propably will use one of the SQL based options, as our ERP number field is automatically filled by the ERP-system.

    But there are many usecases where these kind of uniqueness check is useful. This thread give a nice overview of the options we have.

    Angela

Reply
  • Hi Chris and Amitosh,

    many thanks for your help! I didn´t expect to get such detailed response to this question.

    That are a lot of suggestions an I like all of them! It really depends on the use case which one fits best. In my case, I propably will use one of the SQL based options, as our ERP number field is automatically filled by the ERP-system.

    But there are many usecases where these kind of uniqueness check is useful. This thread give a nice overview of the options we have.

    Angela

Children
No Data