Can't set fields Unique

Tony M
Kilo Expert

Hi Everyone,

I Just can't set fields to Unique no matter what I do, I have the personalize_dictionary role, I created the field from scratch, I even indexed It as suggested in other thread but nothing works, fields are still getting duplicated even with the option checked. BTW the table was extended from CI

find_real_file.png

find_real_file.png

Related topics

https://docs.servicenow.com/bundle/orlando-platform-administration/page/administer/field-administrat...

https://community.servicenow.com/community?id=community_question&sys_id=96f647e5db1cdbc01dcaf3231f96...

 

Thanks for any ideas

1 ACCEPTED SOLUTION

Swapnil Soni1
Giga Guru

Hi,

Personalize Dictionary for that field. If the Unique checkbox is not on the Dictionary form, personalize the form layout for the Dictionary form and add it. Check it for your field, and update the Dictionary record.

Then a unique constraint will be enforced for that field. Note that the field must not have duplicate values already, or doing what I described will fail.

 

Or you can try this

Screen Shot 2017-01-27 at 4.19.11 PM.png

 

 

 

 

Let me know if this works!!

Thanks

View solution in original post

10 REPLIES 10

Swapnil Soni1
Giga Guru

Hi,

Personalize Dictionary for that field. If the Unique checkbox is not on the Dictionary form, personalize the form layout for the Dictionary form and add it. Check it for your field, and update the Dictionary record.

Then a unique constraint will be enforced for that field. Note that the field must not have duplicate values already, or doing what I described will fail.

 

Or you can try this

Screen Shot 2017-01-27 at 4.19.11 PM.png

 

 

 

 

Let me know if this works!!

Thanks

Guess that's the way to go and the only exception is with the CI table.

 

Many thanks!

Ashutosh Munot1
Kilo Patron
Kilo Patron

HI,

This BR :SNC Create Unique Index doesnot allow this to set it unique. You need to deactivate this and make the field unique and activate BR again.

Thanks,
Ashutosh

Tony M
Kilo Expert

@Swapnil Soni 

Thanks I've actually tried it added Unique to the form + indexing it without success, fortunately I found out that it's related to the CI table since making unique + indexed fields in other tables work correctly.

find_real_file.png

Don't get why is this behaviour related to tables extended to CI table but that seems to be the problem.

 

@Ashutosh Munot 

Thanks, Do you know the purpose of this BR: SNC Create Unique Index by setting Unique to false? 

Hi,

It ensures that the index exists for the field you are marking unique. If not then it will not allow you to mark the field as unique.


Thanks,
Ashutosh