How to set record producer variable to choice field in target record form without duplicates
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-13-2023 07:22 AM
I have a variable request type which of type "Question Choice" and has Question Choices on record producer. It need to be mapped for Sub Category. When i use the below script, Its creating a duplicate.
current.sub_category = producer.request_type
Sub_Category field already had this choice.
Could you please help.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-15-2023 09:27 PM
You need to check the Question Choice value should match the sub_category value.
try below code
current.sub_category = producer.getValue('request_type');
Regards,
RJ
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-15-2023 09:29 PM
@Rahul RJ Thank You for your reply. But, It is creating duplicate entry in choices of sub_category in the target record.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-15-2023 09:32 PM
Probably this is because the backend values didnt match as per my understanding.
1. Can you configure the dictionary and check the value of subcategory choice which is already present.
2. Go to the question choice an check the value there
These both should have the same value, then only it will not create duplicate. If they are not same then you need to align the code accordingly.
Please mark correct if my response has solved your query.
Cheers,
Mohammed Basheer Ahmed.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-15-2023 10:42 PM - edited 01-15-2023 10:49 PM
@yaminikoduri333 This is due to choice value. The same value should be present in Questions choices and target records choices.
Ex - Question choice - Hardware(DisplayValue) and hardware (value)
The same should be present in question choice options as well as target field choice.
Regards,
RJ