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.

Reporting on Variables

Natsufab3
Kilo Guru

i need to find a way to report on variables where each variable question is my column in record. i have seen few post on database views but it dint work although i was able to generate variable question as column names there isnt any record related to it.

Does anyone have any idea regarding this? It would be helpfull

Thank you

1 ACCEPTED SOLUTION

This 1 way i am trying to generate report is as table being question answer, and with each question as a condition filter with table name as incident and value not being empty. and it is working out although i couldnt get the variables as column name, i get them like rows. Something is better than nothing aint it!



Thank you


View solution in original post

12 REPLIES 12

Don't know of a good way to do it for Record Producers.  
One thing to consider:   If the data you're trying to extract from the variable needs to be consistently reported, perhaps it should be a FIELD on the Incident table, instead of just a variable.


Yes actually i though the same to create a field on incident table for these variables to get mapped to. but the problem is there are more than 30k incidents. and do you think if i create a field now and map the variables to fields will work? what i mean to ask is will all the previous variables also come into as the fields?


Record Producers only work their "variable name-to-field name" magic on insert.  


You could write a script to copy data from the variable to the new field for all your legacy incidents though.   (practice on sub-prod though!)


i do know 1 thing though that all these variable values are stored in question_answer table. now using this option can we generate the report with variable names as column name? we cannot generate directly on question_answer table because it doesnt show variable as column but instead it shows as a question and value. any ideas on how it can be achieved?


Nope.   That's the classic problem with variable reporting.   You always end up with the question/answer pairs rendering as rows, not columns.