How to import reference values to List type column table

SamuelChang
Tera Contributor

Hi all,

 

 

Can someone helps me or point me to the right direction on how to import data to reference field? I have created a custom table that holds: Role, Access level, Environment, and Approval Group Name (List type, reference 'sys_user_group' table) 

 

My approach is include the group sys_id separated by comma in the Spreadsheet, then use the Data Source to import the data. I imported the data, but only captured the first group but not the rest. 

 

In this case it have multiple groups, but only capture the first DBA group and the rest got cut off

SamuelChang_0-1721760110159.png

When I open the record

SamuelChang_2-1721760220742.png

SamuelChang_3-1721760245750.png

 

If only one group then it's fine

SamuelChang_1-1721760186032.png

 

This is my spreadsheet with the "approval group sys_id"

SamuelChang_4-1721760345593.png

 

Thank you!

1 ACCEPTED SOLUTION

Is there also a import set row table involved? Check the field length there. I just notice immediately that you have one valid record (sys_id=32 chars) + ", 5fbe55" which is 8 chars = total 40 chars, which is the default field length set.

 

Kind regards,

 

Mark Roethof

Independent ServiceNow Consultant

10x ServiceNow MVP

---

 

~444 Articles, Blogs, Videos, Podcasts, Share projects - Experiences from the field

LinkedIn

View solution in original post

6 REPLIES 6

Mark Roethof
Tera Patron

Hi there,

 

Are you perhaps also using a import set row table? Have you double checked the field length there? If its for example the default out-of-box 40 length, then the first value of 32 chars sys_id will be fine, though the seconds value obviously cut off, a bit like your image with "5fbe55".

 

Please double check the field length.

 

Kind regards,

 

Mark Roethof

Independent ServiceNow Consultant

10x ServiceNow MVP

---

 

~444 Articles, Blogs, Videos, Podcasts, Share projects - Experiences from the field

LinkedIn

Ohhh great point, but my table is set to 32 length if that's the case then it should trim down to one group no?

SamuelChang_0-1721763046325.png

 

Is there also a import set row table involved? Check the field length there. I just notice immediately that you have one valid record (sys_id=32 chars) + ", 5fbe55" which is 8 chars = total 40 chars, which is the default field length set.

 

Kind regards,

 

Mark Roethof

Independent ServiceNow Consultant

10x ServiceNow MVP

---

 

~444 Articles, Blogs, Videos, Podcasts, Share projects - Experiences from the field

LinkedIn

Mark,

You're indeed correct

SamuelChang_0-1721767291306.png

 

I also tested with a different Transform map, new Data source. I configured under the field map 'Choice Action' to 'create' which it will create a group if not found. I also tested to ignore but then the field will populate the sys_id

SamuelChang_3-1721767550558.png

 

Any idea on how to approach this?