Join the #BuildWithBuildAgent Challenge! Get recognized, earn exclusive swag, and inspire the ServiceNow Community with what you can build using Build Agent.  Join the Challenge.

Catalog Item Variable Auto populate email disappering in backend

Rajkumar Bokken
Tera Contributor

Hi All,

 

I have issue on a catalog item variable autopopulate from backend.

 

I have created a new catalog item

Added 3 Variables 

1. Requested for ( User reference table)

2. User Email ( Auto populate from user reference table dot-walkin EMAIL)

3. Reporting Manager ( Auto populate from user reference table dot-walkin EMAIL )

 

RajkumarBokken_1-1704902815635.png

 

 

Issue : After submitting Request in service portal email is getting disappeared in backend (RITM View and SCTASK view) but i see manager field is working .

RajkumarBokken_2-1704904445921.png

 

Email

RajkumarBokken_5-1704904596812.png

 

 

Manager

RajkumarBokken_3-1704904534998.png

 

 

1 ACCEPTED SOLUTION

Brad Bowman
Kilo Patron
Kilo Patron

User Email is a reference field, on the sys_user table, so it needs to populate the sys_id of a user record, which is what the Manager variable is doing since the Manager field on the user table is a reference to sys_user.  The Email field is a type of email, which needs to be populated into a single line text type variable.  You can populate this with an onChange Catalog Client Script using getReference. 

https://docs.servicenow.com/bundle/tokyo-api-reference/page/app-store/dev_portal/API_reference/Glide... 

Give the script a shot, and let me know if you get stuck.

View solution in original post

3 REPLIES 3

Brad Bowman
Kilo Patron
Kilo Patron

User Email is a reference field, on the sys_user table, so it needs to populate the sys_id of a user record, which is what the Manager variable is doing since the Manager field on the user table is a reference to sys_user.  The Email field is a type of email, which needs to be populated into a single line text type variable.  You can populate this with an onChange Catalog Client Script using getReference. 

https://docs.servicenow.com/bundle/tokyo-api-reference/page/app-store/dev_portal/API_reference/Glide... 

Give the script a shot, and let me know if you get stuck.

Rajkumar Bokken
Tera Contributor

Thanks @Brad Bowman  ,

 

Changed Variable type to Single line text and It worked  🙂

 

Thanks,

Rajkumar Bokkena

Glad to hear.  You are welcome!