Location showing empty on incident listview

Vinod S Patil
Tera Contributor

Hello Everyone

In incident list view for some incidents location is empty but location value present in form view.

Please suggest

@Dr Atul G- LNG 
@Community Alums 

2 ACCEPTED SOLUTIONS

swathisarang98
Giga Sage
Giga Sage

Hi @Vinod S Patil ,

 

Check all below possibilities, 

If the data is not saved  in the database it will look empty in the list view, so once you load the form or open form try saving it and then go to list view and check,

 

Or 

the data might be populating through business rule and current.update() is not included 

Support article,

https://support.servicenow.com/kb?id=kb_article_view&sysparm_article=KB0725733 

 

if the field is reference check below article,

https://support.servicenow.com/kb?id=kb_article_view&sysparm_article=KB0758245 

 

Please mark this comment as Correct Answer/Helpful if it helped you.

Regards,

Swathi Sarang

View solution in original post

Robbie
Kilo Patron
Kilo Patron

Hi @Vinod S Patil,

 

Believe it or not, this is not uncommon and typically seen when a field is populated on load or has a default value however the record has not been saved since the the onLoad Script or Default field logic has been implemented.

 

A great way to check this is to open one of the records which displays an empty value in the list view yet has a value when you open the record on the form.

At the top of the record (In the form view), right-click to pop up a menu and click on 'View XML' - this will show you what is actually stored at the DB level of the record at the time. If you see that the location field is empty in the XML but visible on the form, this means the record has indeed not been updated since the logic / default value has been set.

You may need to create a fix script to handle these records to ensure historical records reflect current data logic.

 

To help others (or for me to help you more directly), please mark this response correct by clicking on Accept as Solution and/or Helpful.

 

Thanks, Robbie

View solution in original post

10 REPLIES 10

Robbie
Kilo Patron
Kilo Patron

Hi @Vinod S Patil,

 

Believe it or not, this is not uncommon and typically seen when a field is populated on load or has a default value however the record has not been saved since the the onLoad Script or Default field logic has been implemented.

 

A great way to check this is to open one of the records which displays an empty value in the list view yet has a value when you open the record on the form.

At the top of the record (In the form view), right-click to pop up a menu and click on 'View XML' - this will show you what is actually stored at the DB level of the record at the time. If you see that the location field is empty in the XML but visible on the form, this means the record has indeed not been updated since the logic / default value has been set.

You may need to create a fix script to handle these records to ensure historical records reflect current data logic.

 

To help others (or for me to help you more directly), please mark this response correct by clicking on Accept as Solution and/or Helpful.

 

Thanks, Robbie

@Robbie 

I did xml check, no data/value available in the form.
can you help with background script to update empty records in the incident listview.

Hi @Vinod S Patil

I sure can. I just want to clarify your response.... 

When you check the XML, you see the location XML tag as empty right? This means, as I suspected, either a default value is set (but not saved) or an onLoad script is called and again not saved.

 

A background script is very easy to implement, the key question is, to what value should the location be set? Is it the same location value for all of the empty records? I suspect it will be based on some logic such as the caller field.

 

Thanks, Robbie

@Robbie  location cant be same for all the incidents as user/caller from different location. location we should pick from sys_user table and update in location incident listview.

Hi @Vinod S Patil,

 

As I suspected, it would be dynamic and based on data.

Let me quickly put that together for you. Can I clarify, when you say the location is based on the user - are we referring to the Caller? (Caller ID field?) Please confirm and I'll have the script for you...

 

To help others (or for me to help you more directly), please mark this response correct by clicking on Accept as Solution and/or Helpful.

 

Thanks, Robbie