Copy Device variable value to a field on software installation task table

UjwalaBedarkar
Tera Expert

Hi all,

 

I have created a string field on " sn_sam_software_installation_task" table called as Name, I want to copy the variable called "device" value into Name field So I am using the flow designer but I am getting below error.

 

UjwalaBedarkar_0-1744023231070.jpeg

 

but when I tried to add logs I am getting the correct value.

 

1 ACCEPTED SOLUTION

@UjwalaBedarkar 

if the field is on parent and you are creating record on child table then that field will be inherited so no issue in that.

I hope it's not the reverse

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

View solution in original post

14 REPLIES 14

Ankur Bawiskar
Tera Patron
Tera Patron

@UjwalaBedarkar 

seems you are using toString() on a empty or null value and hence it gave this error.

Is that variable i.e. name an empty string?

share that detail, but you are not setting "name" field in your Field Values

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

Hi@Ankur Bawiskar ,

 

I am setting the values as below,

UjwalaBedarkar_0-1744023822835.png

In logs it showing correctly,

UjwalaBedarkar_1-1744023908146.jpeg

 

 

@UjwalaBedarkar 

so the variable "device" is reference type and you are dot walking and getting the name?

but where are you setting it in "sn_sam_software_installation_task" step in "Create Record"?

I couldn't see it in this below image

Did you hard-code name field and see if it creates that record?

AnkurBawiskar_0-1744024298004.png

 

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

Hi @Ankur Bawiskar ,

yes device variable is reference field and  I am setting the values in create task at last step as below:

UjwalaBedarkar_0-1744024920450.png

also the same thing is working for some devices and throwing error for some other.