Skip to page contentSkip to chat
ServiceNow support
    • Community
      Ask questions, give advice, and connect with fellow ServiceNow professionals.
      Developer
      Build, test, and deploy applications
      Documentation
      Find detailed information about ServiceNow products, apps, features, and releases.
      Impact
      Accelerate ROI and amplify your expertise.
      Learning
      Build skills with instructor-led and online training.
      Partner
      Grow your business with promotions, news, and marketing tools
      ServiceNow
      Learn about ServiceNow products & solutions.
      Store
      Download certified apps and integrations that complement ServiceNow.
      Support
      Manage your instances, access self-help, and get technical support.
Cannot print Multi Row Var set on Email notifications - Known Error
  • >
  • Knowledge Base
  • >
  • Known Error (Knowledge Base)
  • >
  • Cannot print Multi Row Var set on Email notifications
KB0832118

Cannot print Multi Row Var set on Email notifications


3627 Views Last updated : Sep 5, 2024 public Copy Permalink
KB Summary by Now Assist

Description

  • Having a generic notification used for all our catalog items (about 300 ones).
  • GlideappVariablePoolQuestionSet returns the variables in the correct order.
  • However, there is no sign of MRVS in there.

Steps to Reproduce

The problem is that the OOTB function method only prints flat variables:

var set = new GlideappVariablePoolQuestionSet();
set.setRequestID(sc_req_item.sys_id);
set.load();
var vs = set.getFlatQuestions();


Workaround

  • The issue will not be fixed as the end user can always use a mail script in order to print the variable in multi row var set.
  1. Try to access variables and sending notification using a workflow.
  2. Or you can try below code in the email script by getting the MRVS used in a particular request (Even if few are getting visible/display on the basis of some UI policy)
var ritmGR = new GlideRecord('sc_req_item');if (ritmGR.get(current.sys_id)) //Here you need to get the current request's sys_id
{
mrvs = ritmGR.variables.book_details; //multi row variable set info. Here insted of giving specific name you can use name of MRVS returned after querying variable set of a catalog item
rowCount = mrvs.getRowCount();
for (var a = 0; a < rowCount; a++) {
var row = mvrs.getRow(a);
template.print( "<tr>" );
template.print( "<td><center>" +row.type + "</center></td>" );
template.print( "<td><left>" +row.title + "</left></td>" );
}
  • If you choose the above code option, use it in mail script before trying with workflow.

Related Problem: PRB1406382

The world works with ServiceNow.

Sign in for more! There's more content available only to authenticated users Sign in for more!
Did this KB article help you?
Did this KB article help you?

How would you rate your Now Support digital experience?

*

Very unsatisfied

Unsatisfied

Neutral

Satisfied

Very satisfied

Very unsatisfied

Unsatisfied

Neutral

Satisfied

Very satisfied

What can we improve? Please select all that apply.

What are we doing well? Please select all that apply.

Tell us more

*

Do you expect a response from this feedback?

  • Terms and conditions
  • Privacy statement
  • GDPR
  • Cookie policy
  • © 2025 ServiceNow. All rights reserved.