<h2>Types of service catalog variables</h2><br/><div style="overflow-x:auto"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"><head><meta content="text/html; charset=UTF-8" /><meta name="copyright" content="(C) Copyright 2025" /><meta name="DC.rights.owner" content="(C) Copyright 2025" /><meta name="generator" content="DITA-OT" /><meta name="DC.type" content="reference" /><meta name="DC.title" content="Types of service catalog variables" /><meta name="abstract" content="Variables allow you to specify questions for a catalog item. Several types of service catalog variables are provided. Some variable types accept variable attributes." /><meta name="description" content="Variables allow you to specify questions for a catalog item. Several types of service catalog variables are provided. Some variable types accept variable attributes." /><meta name="DC.subject" content="variable types" /><meta name="keywords" content="variable types" /><meta name="DC.relation" scheme="URI" content="../../../product/service-catalog-management/concept/c_ServiceCatalogVariables.html" /><meta name="DC.relation" scheme="URI" content="../../../administer/general/concept/capabilities-bundle-landingpage.html" /><meta name="DC.relation" scheme="URI" content="../../../administer/general/concept/manage-services.html" /><meta name="DC.relation" scheme="URI" content="../../../product/service-catalog-management/concept/service-catalog.html" /><meta name="DC.relation" scheme="URI" content="../../../product/service-catalog-management/concept/service-catalog-reference.html" /><meta name="DC.relation" scheme="URI" content="../../../product/service-catalog-management/reference/variables-availability.html" /><meta name="DC.creator" content="ServiceNow" /><meta name="DC.date.created" content="2023-08-03" /><meta name="DC.date.modified" content="2024-02-01" /><meta name="mini-toc" content="yes" /><meta name="page-type" content="platform" /><meta name="DC.format" content="XHTML" /><meta name="DC.identifier" content="r_VariableTypes" /><link rel="stylesheet" type="text/css" href="../../../CSS/commonltr.css" /><title>Types of service catalog variables</title></head><body id="r_VariableTypes"> <div class="breadcrumb"><a class="link" href="../../../administer/general/concept/capabilities-bundle-landingpage.html" title="Extend the ServiceNow AI Platform with additional applications and features.">Extend ServiceNow AI Platform capabilities</a> > <a class="link" href="../../../administer/general/concept/manage-services.html" title="Give your customers tailored catalogs for products, and create portals for service requests, using the ServiceNow Service Catalog app.">Manage service capabilities</a> > <a class="link" href="../../../product/service-catalog-management/concept/service-catalog.html" title="Use the ServiceNow Service Catalog application to create service catalogs that provide your customers with self-service opportunities. Customize portals where your customers can request catalog items such as service and product offerings. You can also standardize request fulfillment to ensure the accuracy and availability of the items in the catalogs.">Service Catalog</a> > <a class="link" href="../../../product/service-catalog-management/concept/service-catalog-reference.html" title="Reference topics provide additional information about the lists and forms.">Service Catalog Reference</a> > </div> <h1 class="title topictitle1" id="ariaid-title1">Types of service catalog variables</h1> <div class="body refbody"><p class="shortdesc">Variables allow you to specify questions for a catalog item. Several types of service catalog variables are provided. Some variable types accept variable attributes.</p> <div class="section"> <p class="p">See the following sections for more details on each variable type. For details on creating a variable, see <a class="xref" href="../task/t_CreateAVariableForACatalogItem.html" title="Create service catalogs variables to gather information from users ordering a catalog item, for example, to ask users which options they want for the item.">Create a service catalog variable</a>. You can also provide help text for any service catalog variable. For information on defining help information, see <a class="xref" href="../task/t_DefineHelpInformation.html" title="Enter help information for a variable to help users determine what info they must provide for a service catalog variable.">Define help information for a service catalog variable</a>.</p> </div> <div class="section" id="r_VariableTypes__ServicePortalSupport"><h2 class="title sectiontitle">Support in various channels</h2> <p class="p">Service Catalog variables are supported in various channels. For information on their availability, see <a class="xref" href="variables-availability.html" title="Service Catalog variables are supported in various channels.">Variable support in various channels</a>.</p> </div> <div class="section" id="r_VariableTypes__section_csv_yfm_ylb"><h2 class="title sectiontitle">Attachment</h2> <div class="p">When submitting a catalog item request, this variable lets you upload an attachment for a question of the item. After you upload the attachment, you can also download, update, and delete it. Even when fulfilling the request, you can download, update, and delete the attachment in a requested item or catalog task. You can specify restrictions for file size and extensions using the <span class="keyword parmname">max_file_size</span> and <span class="keyword parmname">allowed_extensions</span> variable attributes. For information on these variable attributes, see <a class="xref" href="variable-attributes.html" title="There are a few Service Catalog variables support specific attributes to define the behavior and restrictions for variables.">Service Catalog variable attributes</a>.<div class="note important"><span class="importanttitle">Important:</span> <ul class="ul" id="r_VariableTypes__ul_wvx_1zt_3mb"><li class="li">You should specify only an integer value for the following:<ul class="ul" id="r_VariableTypes__ul_qm3_2h5_3mb"><li class="li">The max_file_size variable attribute</li><li class="li">The <span class="keyword parmname"> glide.sc.variable.attachment.default_max_size</span> system property (catalog-level). The default value is 20.</li></ul> </li><li class="li">If the max_file_size variable attribute is not specified, the <span class="keyword parmname">glide.sc.variable.attachment.default_max_size</span> system property value is considered as the upper limit for the attachment file size.</li><li class="li">Irrespective of the file size allowed in the variable, the attachment file size cannot exceed the size specified in <span class="keyword parmname">com.glide.attachment.max_size</span> system property, which is applicable for attachments across <span class="ph">ServiceNow AI Platform</span>.</li><li class="li">The <span class="keyword apiname">g_form.setValue()</span> API is supported in catalog client scripts.</li></ul> </div> </div> <div class="p"><div class="note"><span class="notetitle">Note:</span> When you edit an attachment, the existing attachment is removed and a new attachment is uploaded.</div> </div> <p class="p">When you upload an attachment to this variable, an entry is created in the Attachment [sys_attachment] table. The variable is not updated until you submit the item request, add it to the cart, or save the record while editing it (in fulfiller flows). If you delete or update the attachment before submitting the corresponding catalog item, the entry in the Attachment [sys_attachment] table is cleared.</p> <div class="p">The attachment uploaded for this variable is copied in the following scenarios:<ul class="ul" id="r_VariableTypes__ul_bxv_3wy_dmb"><li class="li">In an order guide, when the variable is cascaded to a catalog item in the rule base<div class="note important"><span class="importanttitle">Important:</span> The individual variable attributes are not honored for the catalog items in the rule base. For example, let us consider that a variable in the <span class="ph uicontrol">Describe Needs</span> section allows a .pdf attachment and the variable of a catalog item in the rule base allows a .txt attachment. When you upload an attachment of .pdf type for a variable in the <span class="ph uicontrol">Describe Needs</span> section, it is initially cascaded to the variable in the catalog item as well and the variable attributes specified in the catalog item are not honored. However, if you delete this initially cascaded attachment from an individual item and try to upload a new attachment, then the individual variable attributes of the catalog item are honored.</div> </li><li class="li">In a record producer, when the variable is mapped to a task table field. This variable can be mapped only to the File Attachment field type of a task table.</li></ul> <div class="note important"><span class="importanttitle">Important:</span> After an attachment is copied, the changes to the individual attachments are independent. For example, any change to an attachment in the order guide does not impact the same attachment cascaded to the catalog item in the rule base.</div> </div> <div class="note warning"><span class="warningtitle">Warning:</span> Since the attachments are copied, a larger size can lead to performance issues.</div> <div class="p">If the system-wide anti-virus check is enabled, the anti-virus check is performed on the attachment when you:<ul class="ul" id="r_VariableTypes__ul_vvr_fw4_3mb"><li class="li">Submit a request for the corresponding catalog item</li><li class="li">Add the catalog item to the cart or wish list</li></ul> </div> <div class="p"><div class="note"><span class="notetitle">Note:</span> <ul class="ul" id="r_VariableTypes__ul_vzg_qvg_bmb"><li class="li">This variable is not supported in a multi-row variable set.</li><li class="li">This variable is supported in flows and workflows.</li><li class="li">This variable is available in condition builder</li><li class="li">For this variable, item variable assignment is not supported in order guide.</li></ul> </div> </div> <div class="p"><div class="fig fignone" id="r_VariableTypes__fig_z3t_vp5_3mb"><span class="figcap"><span class="fig--title-label">Figure 1. </span>Attachment variable</span> <img class="image" id="r_VariableTypes__image_ajt_vp5_3mb" src="../image/AttachmentVariable.png" alt="The Attachment variable" /> </div> </div> </div> <div class="section" id="r_VariableTypes__sect_Break"><h2 class="title sectiontitle">Break</h2> <p class="p">The break variable displays a horizontal line across the form. This line is a formatting element that does not collect data.</p> <div class="p"><div class="fig fignone" id="r_VariableTypes__fig_pwk_tgw_dq"><span class="figcap"><span class="fig--title-label">Figure 2. </span>Example: break variable</span> <img class="image" id="r_VariableTypes__image_cwn_nyh_q5" src="../image/VariableBreakG.png" alt="A break variable" /> </div> </div> </div> <div class="section" id="r_VariableTypes__sect_CheckBox"><h2 class="title sectiontitle">Check box</h2> <p class="p">The check box variable lets you enable and disable options by selecting and clearing it.</p> <p class="p">To make a check box mandatory, select the <span class="ph uicontrol">Selection Required</span> option when you create the variable. For example, use this option to require users to select the <span class="ph uicontrol">I agree</span> check box for an agreement form. If users try to submit the agreement form without selecting the check box, an alert message is displayed to tell users that they must select the check box.</p> <p class="p">A group of check box variables is created when you create consecutive check box variables. These check box variables are sorted by their order within the group. If you want to define a custom label for the group of check boxes, create a <a class="xref" href="r_VariableTypes.html#r_VariableTypes__sect_Label">label</a> variable at the start of the consecutive check box variables. The label is then considered a part of this group and acts a label of the group. If there is no custom label, check boxes are grouped under an <span class="ph uicontrol">Options</span> label by the application.</p> <div class="p">In a group of check box variables:<ul class="ul" id="r_VariableTypes__ul_hdr_kw5_sfb"><li class="li">If any check box variable in the group is mandatory, the entire group becomes mandatory irrespective of the visibility of the mandatory check box variable. An asterisk (*) is then displayed next to the group label and you must select at least one of these check boxes.</li><li class="li">Hiding the label hides the entire group.</li><li class="li">If all other check box variables of a mandatory check box group are hidden and not selected, the following scenarios are applicable:<ul class="ul" id="r_VariableTypes__ul_sn3_mw5_sfb"><li class="li">The group remains mandatory as long as there is one check box in the group that is visible and not selected.</li><li class="li">The last check box of this group cannot be hidden if it is not selected.</li></ul> </li></ul> </div> <p class="p">In Service Portal, to make a group of check box variables mandatory, set at least one of the check box variables as mandatory. While defining the label for a group of check boxes, setting a label mandatory does not make the group of check box variables mandatory.</p> <div class="p">In catalog builder, the following scenarios are applicable:<ul class="ul" id="r_VariableTypes__ul_cww_j5t_h4b"><li class="li">If there are two consecutive check boxes, then a virtual container is created for a group of check boxes. Only check box variable types can be added inside the group</li><li class="li">Even if a check box variable is added immediately after a group of check boxes, it is automatically added to the group.</li></ul> </div> <div class="p">Under the <span class="ph uicontrol">Type Specifications</span> tab, you can specify the price in different currency types. Also, you can configure the price in the following pricing models:<ul class="ul" id="r_VariableTypes__ul_svg_yrn_tz"><li class="li">Calculated</li><li class="li">Fixed</li><li class="li">Multiple</li></ul> For information on the pricing models, see <a class="xref" href="../administer/currency/concept/price-fields.html" target="_blank" rel="noopener noreferrer">Price fields</a> .</div> <div class="p"> <div class="fig fignone" id="r_VariableTypes__fig_jdc_1hw_dq"><span class="figcap"><span class="fig--title-label">Figure 3. </span>Example: check box variable</span> <img class="image" id="r_VariableTypes__image_xy3_yxh_q5" src="../image/VariableCheckBoxG.png" alt="A check box variable" /> </div> </div> </div> <div class="section" id="r_VariableTypes__sect_Container"><h2 class="title sectiontitle">Container start, container split, and container end</h2> <p class="p">The container start, container split, and container end variables define a layout for a container that can hold more variables. Use the container start and container end variables to define the start and end points of a container layout. The container end must be used along with the container start to close a container.</p> <p class="p">A container layout can be split into two or three columns using the container split variable. By default, the split is calculated at the 50% mark.</p> <p class="p">A container is similar to a <a class="xref" href="../concept/c_ServiceCatalogVariableSets.html" title="Administrators and catalog administrators often define multiple catalog items that use the same group of service catalog variables. Catalog managers and catalog editors can attach a variable set for items to which they are assigned. However, catalog managers and catalog editors cannot create a variable set.">variable set</a>. Unlike a variable set, containers can be used anywhere, including inside a variable set. Containers can also be nested inside each other.</p> <p class="p">For more help with selecting the appropriate container type, see the <a class="xref" href="https://support.servicenow.com/kb_view.do?sysparm_article=KB0539982" target="_blank" rel="noopener noreferrer">Determining if you are using the correct container variable [KB0539982]</a> article in the HI Knowledge Base.</p> <div class="note"><span class="notetitle">Note:</span> <ul class="ul" id="r_VariableTypes__ul_tlh_rsy_dz"><li class="li">The container variables are not yet supported on mobile devices.</li><li class="li">Container start, container split, and container end variables are supported in Service Portal. However, if the settings are done on the top-level container, a maximum of two-column layouts can be achieved.</li><li class="li">Variable sets are also considered as containers. So, a container start variable with a two-column layout under a variable set is not supported in Service Portal.</li></ul> </div> <div class="p">To reproduce the container shown in the following figure, enter the following settings when creating a container start variable:<ul class="ul" id="r_VariableTypes__ul_tzg_xjw_dq"><li class="li">Select a <span class="ph uicontrol">Layout</span> with <span class="keyword option">2 Columns Wide, alternating sides</span>.</li><li class="li">Select the <span class="ph uicontrol">Display title</span> check box to use a collapsible title bar.</li></ul> </div> <div class="p"><div class="fig fignone" id="r_VariableTypes__fig_x2l_nhw_dq"><span class="figcap"><span class="fig--title-label">Figure 4. </span>Example: container variable</span> <img class="image" id="r_VariableTypes__image_i2f_2xh_q5" src="../image/VariableContainerG.png" alt="A variable container" /> </div> </div> </div> <div class="section" id="r_VariableTypes__sect_Date"><h2 class="title sectiontitle">Date</h2> <p class="p">The date variable creates a widget with a field and calendar to select a date.</p> <div class="p"><div class="fig fignone" id="r_VariableTypes__fig_rhh_jkw_dq"><span class="figcap"><span class="fig--title-label">Figure 5. </span>Example: date variable</span> <img class="image" id="r_VariableTypes__image_zr2_qwh_q5" src="../image/Date.png" alt="A variable date" /> </div> </div> </div> <div class="section" id="r_VariableTypes__sect_DateTime"><h2 class="title sectiontitle">Date and time</h2> <p class="p">The date and time variable creates a widget with a calendar and fields to select a date and time. The time value is stored in Greenwich Mean Time (GMT) and displayed in your time zone.</p> <div class="p"><div class="fig fignone" id="r_VariableTypes__fig_efj_4kw_dq"><span class="figcap"><span class="fig--title-label">Figure 6. </span>Example: date and time variable</span> <img class="image" id="r_VariableTypes__image_aq3_nwh_q5" src="../image/DateTime.png" alt="The date and time variable" /> </div> </div> </div> <div class="section"><h2 class="title sectiontitle">Duration</h2> <p class="p">Use the duration variable to specify the duration for which a catalog item is available.</p> <div class="p">For attributes supported by this variable, see <a class="xref" href="variable-attributes.html" title="There are a few Service Catalog variables support specific attributes to define the behavior and restrictions for variables.">variable attributes</a>.<div class="note"><span class="notetitle">Note:</span> Enter the duration in the DD HH:MM:SS format when setting the default value of the variable, and specifying in the g_form.getValue() and g_form.setValue() functions.</div> </div> <div class="p"><div class="fig fignone" id="r_VariableTypes__fig_pfh_mr2_cz"><span class="figcap"><span class="fig--title-label">Figure 7. </span>Example: duration variable</span> <img class="image" id="r_VariableTypes__image_qfh_mr2_cz" src="../image/VarDuration.png" alt="The Duration variable" /> </div> </div> </div> <div class="section" id="r_VariableTypes__sect_Email"><h2 class="title sectiontitle">Email</h2> <p class="p">The email variable creates a widget to enter and select an email address. The variable accepts only valid email expressions containing @ and domain information.</p> <div class="note"><span class="notetitle">Note:</span> Variable validation is not supported in Service Portal.</div> <div class="p"><div class="fig fignone" id="r_VariableTypes__fig_vxw_ppl_cw"><span class="figcap"><span class="fig--title-label">Figure 8. </span>Example: email variable</span> <img class="image" id="r_VariableTypes__image_wxw_ppl_cw" src="../image/Email.png" alt="An email variable" /> </div> </div> </div> <div class="section" id="r_VariableTypes__sect_HTML"><h2 class="title sectiontitle">HTML</h2> <p class="p">The HTML variable lets you provide content with advanced formatting, including images, for a catalog item.</p> <p class="p">Use the variable to create fields for user input. You can also use the variable for reusable content when put into a variable set, such as terms and conditions.</p> <p class="p">The variable is available in two modes: edit and read-only. In edit mode, a toolbar is available, and links do not work. In read-only mode, the toolbar is disabled, and links work. To switch between modes, use entitlements or create a UI policy to set the HTML field to read-only mode.</p> <div class="note"><span class="notetitle">Note:</span> HTML variables are not supported for display on the shopping cart summary or approval summary screens.</div> <div class="p"><div class="fig fignone" id="r_VariableTypes__fig_m1r_flm_2x"><span class="figcap"><span class="fig--title-label">Figure 9. </span>Example: HTML variable</span> <img class="image" id="r_VariableTypes__image_n1r_flm_2x" src="../image/HtmlVariable.png" alt="An HTML variable" /> </div> </div> </div> <div class="section" id="r_VariableTypes__IPAddress"><h2 class="title sectiontitle">IP Address</h2> <p class="p">Use the IP address variable to specify the IPv4 and IPv6 data for a catalog item. Under the <span class="ph uicontrol">Validation Scripts</span> submodule, a validation script type associated with this variable is available.</p> <div class="note"><span class="notetitle">Note:</span> <ul class="ul" id="r_VariableTypes__ul_mvn_rbq_ddb"><li class="li">Variable validation is not supported in Service Portal.</li><li class="li">When you set the default value for the <span class="ph uicontrol">IP Address</span> variable, or specify its value in the g_form.getValue() and g_form.setValue() functions, the delimiter is (.).</li></ul> </div> <div class="p"><div class="fig fignone" id="r_VariableTypes__fig_upx_nxm_4z"><span class="figcap"><span class="fig--title-label">Figure 10. </span>Example: IP address variable</span> <img class="image" id="r_VariableTypes__image_vpx_nxm_4z" src="../image/IPAddressVariable.png" alt="Screenshot for the IP Address variable" /> </div> </div> </div> <div class="section" id="r_VariableTypes__sect_Label"><h2 class="title sectiontitle">Label</h2> <p class="p">The label variable displays a label across the form. Labels are formatting elements. No data is collected.</p> <p class="p">You can use labels to arrange questions into sections. You can also use labels for questions with multiple options. For example, label <a class="xref" href="r_VariableTypes.html#r_VariableTypes__sect_CheckBox">check boxes</a> for the different options for a question.</p> <p class="p">You cannot set a Label variable as mandatory. However, you can make mandatory, a group of check box variables preceded by a Label variable.</p> <div class="p"><div class="fig fignone" id="r_VariableTypes__fig_azx_wmw_dq"><span class="figcap"><span class="fig--title-label">Figure 11. </span>Example: label variable</span> <img class="image" id="r_VariableTypes__image_vyw_bwh_q5" src="../image/VariableLabelG.png" alt="A label variable" /> </div> </div> </div> <div class="section" id="r_VariableTypes__sect_ListCollector"><h2 class="title sectiontitle">List collector</h2> <p class="p">The list collector variable creates an interface that lets you select and add multiple records from a table. For attributes supported by this variable, see <a class="xref" href="variable-attributes.html" title="There are a few Service Catalog variables support specific attributes to define the behavior and restrictions for variables.">variable attributes</a>.</p> <div class="p"><div class="fig fignone" id="r_VariableTypes__fig_dlv_hnw_dq"><span class="figcap"><span class="fig--title-label">Figure 12. </span>Example: list collector variable</span> <img class="image" id="r_VariableTypes__image_cgt_pvh_q5" src="../image/VariableListCollectorG.png" alt="A list collector variable" /> </div> </div> <div class="p"> <div class="note"><span class="notetitle">Note:</span> <ul class="ul" id="r_VariableTypes__ul_dbs_mjt_scb"><li class="li">The Reference Qualifier and glide_list attribute applies to releases from Helsinki onward only. The attribute does not apply to Geneva.</li><li class="li">You can set a value for this variable using the <span class="keyword apiname">g_form.setValue()</span> function in a catalog client script.</li><li class="li">When the glide_list attribute is not true, you can only set the value that is visible in the <span class="ph uicontrol">Available</span> list using the <span class="keyword apiname">g_form.setValue()</span> function. This functionality is not applicable when the <span class="keyword apiname">setValue()</span> function is called onLoad.</li><li class="li">Table with large data causes performance issues when loading the page. Use reference qualifiers to reduce data or use the glide_list attribute.</li><li class="li">The values in the referenced table do not appear if the user is not logged in.</li><li class="li">The list collector displays a maximum of 100 items in a list. After moving items to the <span class="ph uicontrol">Selected</span> list, you can click <span class="ph uicontrol">Run Filter</span> to refresh the <span class="ph uicontrol">Available</span> list. This action will add more available items to the list, to a maximum of 100 items.</li></ul> </div> </div> </div> <div class="section" id="r_VariableTypes__sect_LookupMultipleChoice"><h2 class="title sectiontitle">Lookup multiple choice</h2> <p class="p">The lookup multiple choice variable creates radio buttons using data from a table. Its functionality is similar to the <a class="xref" href="r_VariableTypes.html#r_VariableTypes__sect_LookupSelectBox">lookup select box</a> variable, which creates a choice list from queried data. For attributes supported by this variable, see <a class="xref" href="variable-attributes.html" title="There are a few Service Catalog variables support specific attributes to define the behavior and restrictions for variables.">variable attributes</a>.</p> <div class="note"><span class="notetitle">Note:</span> <ul class="ul" id="r_VariableTypes__ul_i5k_pw1_j3b"><li class="li">Table with large data causes performance issues when loading the page. Use reference qualifiers to reduce data or use the reference type variable.</li><li class="li">You cannot add more than 10,000 choices.</li></ul> </div> <div class="p"><div class="fig fignone" id="r_VariableTypes__fig_ncc_44w_dq"><span class="figcap"><span class="fig--title-label">Figure 13. </span>Example: lookup multiple choice variable</span> <img class="image" id="r_VariableTypes__image_yw5_3vh_q5" src="../image/VariableLookupMultChoiceG.png" alt="A lookup multiple choice variable" /> </div> </div> </div> <div class="section" id="r_VariableTypes__sect_LookupSelectBox"><h2 class="title sectiontitle">Lookup select box</h2> <p class="p">The lookup select box variable creates a choice list using data queried from a table. Its functionality is similar to the <a class="xref" href="r_VariableTypes.html#r_VariableTypes__fig_ncc_44w_dq">lookup multiple choice</a> variable, which creates radio buttons from queried data. For attributes supported by this variable, see <a class="xref" href="variable-attributes.html" title="There are a few Service Catalog variables support specific attributes to define the behavior and restrictions for variables.">variable attributes</a>.</p> <div class="p">To create the lookup select box, enter the following values when creating the variable:<ul class="ul" id="r_VariableTypes__ul_z51_2rw_dq"><li class="li"><span class="ph uicontrol">Lookup from table</span>: <code class="ph codeph">Incident [incident]</code></li><li class="li"><span class="ph uicontrol">Lookup value field</span>: <code class="ph codeph">Sys ID</code></li><li class="li"><span class="ph uicontrol">Lookup label field</span>: <code class="ph codeph">number, category, priority</code></li><li class="li"><span class="ph uicontrol">Reference qual</span>: <code class="ph codeph">caller_id=javascript:gs.getUserID()^active=true</code></li></ul> </div> <div class="note"><span class="notetitle">Note:</span> <ul class="ul" id="r_VariableTypes__ul_lgj_qw1_j3b"><li class="li">Table with large data causes performance issues when loading the page. Use reference qualifiers to reduce data or use the reference type variable.</li><li class="li">You cannot add more than 10,000 choices.</li></ul> </div> </div> <div class="section" id="r_VariableTypes__sect_Macro"><h2 class="title sectiontitle">Custom</h2> <p class="p">This variable inserts a UI macro into the catalog item.</p> <p class="p">UI macros in the service catalog do not support the following glide_list functions: clickthrough, slushbucket editing, and email field.</p> <ul class="ul" id="r_VariableTypes__ul_dmc_h4m_cz"><li class="li">Use <a class="xref" href="../script/general-scripting/concept/c_ExtensionsToJellySyntax.html" target="_blank" rel="noopener noreferrer">phase one</a> Jelly only for any UI macros added as variables. Phase two Jelly within the macro is not processed and appears on the page as standard content.</li><li class="li">This variable is not yet supported on Classic Mobile devices.</li><li class="li">This variable is supported in Service Portal through widgets. Create a widget with the same functionality as that of a macro and link the widget with the variable.</li></ul> <div class="p"><div class="fig fignone" id="r_VariableTypes__fig_pgj_srw_dq"><span class="figcap"><span class="fig--title-label">Figure 14. </span>Example: Custom variable</span> <img class="image" id="r_VariableTypes__image_wtt_rrw_dq" src="../image/Macro.png" alt="A Custom variable" /> </div> </div> </div> <div class="section" id="r_VariableTypes__sect_MacroWithLabel"><h2 class="title sectiontitle">Custom with label</h2> <p class="p">This variable inserts a UI macro with a label.</p> <ul class="ul" id="r_VariableTypes__ul_jsm_j4m_cz"><li class="li">This variable is not yet supported on Classic Mobile devices.</li><li class="li">This variable is supported in Service Portal through widgets. Create a widget with the same functionality as that of a macro with label, and link it with the variable.</li></ul> <div class="p"><div class="fig fignone" id="r_VariableTypes__fig_adn_p1p_rw"><span class="figcap"><span class="fig--title-label">Figure 15. </span>Example: Custom with label variable</span> <img class="image" id="r_VariableTypes__image_bdn_p1p_rw" src="../image/MacroWithLabel.png" alt="A Custom with label variable" /> </div> </div> </div> <div class="section" id="r_VariableTypes__sect_Masked"><h2 class="title sectiontitle">Masked</h2> <p class="p">The masked variable inserts a field that masks the text entered. Each character entered is displayed as an asterisk (*). Use this variable to ask users for sensitive or confidential data such as passwords.</p> <div class="p">By selecting the <span class="ph uicontrol">Use encryption</span> check box, you can configure the variable to encrypt its value using various encryption algorithms before storing in the database. These values can only be decrypted by using now_GR.variables.var_name.getDecryptedValue() on RITM, Catalog Task, or any task extension record created using a record producer.<div class="note"><span class="notetitle">Note:</span> By default, the <span class="ph uicontrol">Use encryption</span> field is set to true to ensure secure storage of information.</div> </div> <p class="p">On the variable editor, you can also decrypt and encrypt the values of a masked variable using the <span class="ph uicontrol">Show</span> and <span class="ph uicontrol">Hide</span> buttons. These buttons are not available for a fulfiller (itil) without the catalog_view_masked role. You can only view the value that you specified while requesting.</p> <div class="p"> <div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="r_VariableTypes__table_lrq_5vv_vdb" class="table" frame="border" border="1" rules="all"><caption><span class="tablecap"><span class="table--title-label">Table 1. </span>Actions on an encrypted variable</span></caption><colgroup><col /><col /><col /><col /></colgroup><tbody class="tbody"><tr class="row sub-head"><td class="entry cellrowborder" rowspan="2" style="vertical-align:top;">Action</td><td class="entry cellrowborder" colspan="3" style="vertical-align:top;">Roles</td></tr><tr class="row sub-head"><td class="entry cellrowborder" style="vertical-align:top;">Requester</td><td class="entry cellrowborder" style="vertical-align:top;">Fulfiller with the catalog_view_masked role</td><td class="entry cellrowborder" style="vertical-align:top;">Fulfiller without the catalog_view_masked role</td></tr><tr class="row"><td class="entry cellrowborder" style="vertical-align:top;">View or hide the encrypted value on catalog forms</td><td class="entry cellrowborder" style="vertical-align:top;">Yes</td><td class="entry cellrowborder" style="vertical-align:top;">Not applicable</td><td class="entry cellrowborder" style="vertical-align:top;">Not applicable</td></tr><tr class="row"><td class="entry cellrowborder" style="vertical-align:top;">Edit the encrypted value on catalog forms</td><td class="entry cellrowborder" style="vertical-align:top;">Yes</td><td class="entry cellrowborder" style="vertical-align:top;">Not applicable</td><td class="entry cellrowborder" style="vertical-align:top;">Not applicable</td></tr><tr class="row"><td class="entry cellrowborder" style="vertical-align:top;">View or hide the encrypted value on the variable editor</td><td class="entry cellrowborder" style="vertical-align:top;">Yes</td><td class="entry cellrowborder" style="vertical-align:top;">Yes</td><td class="entry cellrowborder" style="vertical-align:top;">No</td></tr><tr class="row"><td class="entry cellrowborder" style="vertical-align:top;">Edit the encrypted value on the variable editor</td><td class="entry cellrowborder" style="vertical-align:top;">Yes<div class="note"><span class="notetitle">Note:</span> If the masked variable is read-only on the variable editor, the variable value is not editable</div> </td><td class="entry cellrowborder" style="vertical-align:top;">Yes<div class="note"><span class="notetitle">Note:</span> If the masked variable is read-only on the variable editor, the variable value is not editable</div> </td><td class="entry cellrowborder" style="vertical-align:top;">No</td></tr></tbody></table> </div> </div> <div class="p"><div class="fig fignone" id="r_VariableTypes__fig_ull_5pf_1r"><span class="figcap"><span class="fig--title-label">Figure 16. </span>Example: masked variable</span> <img class="image" id="r_VariableTypes__image_vb3_ktn_q5" src="../image/VariableMaskedVarTypesG.png" alt="A masked variable" /> </div> </div> </div> <div class="section" id="r_VariableTypes__sect_MultiLineText"><h2 class="title sectiontitle">Multi-line text</h2> <p class="p">The multi-line text variable creates a field that lets you enter multiple lines of text.</p> <div class="p"><div class="fig fignone" id="r_VariableTypes__fig_fqg_gsw_dq"><span class="figcap"><span class="fig--title-label">Figure 17. </span>Example: multi-line text variable</span> <img class="image" id="r_VariableTypes__image_lsx_n5h_q5" src="../image/VariableAdditionalCommentsG.png" alt="A multi-line text variable" /> </div> </div> </div> <div class="section" id="r_VariableTypes__sect_MultipleChoice"><h2 class="title sectiontitle">Multiple choice</h2> <p class="p">The multiple choice variable creates radio buttons for question choices.</p> <div class="p"><div class="fig fignone" id="r_VariableTypes__fig_upy_5sw_dq"><span class="figcap"><span class="fig--title-label">Figure 18. </span>Example: multiple choice variable</span> <img class="image" id="r_VariableTypes__image_xrm_k5h_q5" src="../image/VariableMultipleChoiceG.png" alt="A multiple choice variable" /> </div> </div> </div> <div class="section" id="r_VariableTypes__sect_NumericScale"><h2 class="title sectiontitle">Numeric scale</h2> <p class="p">The numeric scale variable creates a set of radio buttons for a range of options, like a Likert scale.</p> <div class="p"><div class="fig fignone" id="r_VariableTypes__fig_bqx_gtw_dq"><span class="figcap"><span class="fig--title-label">Figure 19. </span>Example: numeric scale variable</span> <img class="image" id="r_VariableTypes__image_t3p_g5h_q5" src="../image/VariableNumericScaleG.png" alt="A numeric scale variable" /> </div> </div> </div> <div class="section" id="r_VariableTypes__sect_Reference"><h2 class="title sectiontitle">Reference</h2> <p class="p">A reference variable references a record in another table. For example, a variable named point_of_contact references the User [sys_user] table. For attributes supported by this variable, see <a class="xref" href="variable-attributes.html" title="There are a few Service Catalog variables support specific attributes to define the behavior and restrictions for variables.">variable attributes</a>.</p> <div class="p">Keep the following information in mind when you create a reference variable:<ul class="ul" id="r_VariableTypes__ul_ksn_15w_dq"><li class="li">Reference variables use the <a class="xref" href="../administer/field-administration/concept/c_AutoCompleteForReferenceFields.html" target="_blank" rel="noopener noreferrer">auto-complete feature</a> . To ensure that users have enough information to make the selection, configure the <a class="xref" href="../administer/field-administration/concept/c_ReferenceLookup.html" target="_blank" rel="noopener noreferrer">reference lookup list</a> .</li><li class="li">Reference variables store the sys_id of the selected record (like reference fields). To use the display value in a script, use the same methods as for a reference field.</li></ul> </div> <pre class="pre codeblock"><code>current.variables.<variable name>.getDisplayValue()</code></pre> <div class="p"><div class="fig fignone" id="r_VariableTypes__fig_nyw_wtw_dq"><span class="figcap"><span class="fig--title-label">Figure 20. </span>Example: reference variable</span> <img class="image" id="r_VariableTypes__image_mdh_15h_q5" src="../image/VariableReferenceG.png" alt="A reference variable" /> </div> </div> </div> <div class="section" id="r_VariableTypes__RequestedFor"><h2 class="title sectiontitle">Requested For</h2> <p class="p">Before submitting a catalog item request, this variable helps you specify who this request can be submitted for. You should specify this information while answering catalog item questions.</p> <div class="note important"><span class="importanttitle">Important:</span> <ul class="ul" id="r_VariableTypes__ul_w4m_1d3_hmb"><li class="li">You can only specify users from the User [sys_user] table.</li><li class="li">If you don’t specify the default value for this variable, the current logged-in user requesting the item is considered as the default Requested For variable value.</li><li class="li">You can submit the request for a user based on access to a catalog item. The <span class="ph uicontrol">Access Type</span> field of the catalog item can be used to specify if a request can be submitted for a user who does not have access to the catalog item.</li><li class="li">For this variable, item variable assignment is not supported in the rule base of an order guide. If the order guide contains the Requested For variable, the value would be cascaded to the equivalent variable of items in the rule base as read-only.</li></ul> </div> <p class="p">Using the <span class="ph uicontrol">Enable also request for</span> field of the Requested For variable, you can request a catalog item for different users under one request.</p> <p class="p">For information about delegated request experience, see <a class="xref" href="../concept/delegated-request-exp.html" title="You can request a catalog item on behalf of another user or multiple users using the Requested For variable.">Delegated request experience</a>.</p> <div class="note important"><span class="importanttitle">Important:</span> <ul class="ul" id="r_VariableTypes__ul_hft_vpx_gmb"><li class="li">You can add this variable to a catalog item or variable set. However, when submitting the request, a catalog item can have only one Requested For variable.</li><li class="li">You can add only one Requested For variable for a variable set.</li><li class="li">This variable is not supported in a multi-row variable set.</li><li class="li">After the request is submitted, this variable value is visible in the variable editor and variable summarizer.</li></ul> </div> <div class="p"><div class="fig fignone" id="r_VariableTypes__fig_sdh_zp5_3mb"><span class="figcap"><span class="fig--title-label">Figure 21. </span>Requested For variable</span> <img class="image" id="r_VariableTypes__image_tdh_zp5_3mb" src="../image/ReqForVariable.png" alt="Screenshot for the Requested For variable" /> </div> </div> </div> <div class="section" id="r_VariableTypes__section_nlg_cgm_ylb"><h2 class="title sectiontitle">Rich Text Label</h2> <p class="p">This variable displays a formatted label on a catalog item form. In the TinyMCE rich text editor, you can format the label and add images or links. This variable supports the HTML tags.</p> <div class="p"><div class="note"><span class="notetitle">Note:</span> <ul class="ul" id="r_VariableTypes__ul_jhp_zzc_2mb"><li class="li">You can make this variable visible using catalog client scripts and catalog UI policies.</li><li class="li">You cannot cascade this variable in an order guide.</li><li class="li">You cannot set this variable as mandatory.</li><li class="li">In the Automated Test Framework, this variable is only supported in the Variable State Validation step to check the visibility.</li><li class="li">This variable is not supported in the following:<ul class="ul" id="r_VariableTypes__ul_q52_31d_2mb"><li class="li">Variable summarizer</li><li class="li">Multi-row variable set</li><li class="li">Condition builders and reports</li></ul> </li><li class="li">You cannot specify the following for this variable:<ul class="ul" id="r_VariableTypes__ul_a34_l1d_2mb"><li class="li">Help text and instructions</li><li class="li">Tool tip</li><li class="li">Permissions</li><li class="li">Variable width</li><li class="li">Example text</li></ul> </li><li class="li">The <span class="keyword apiname">g_form.setValue()</span>, <span class="keyword apiname">g_form.setReadOnly()</span>, and <span class="keyword apiname">g_form.setMandatory()</span> APIs are not supported in catalog client scripts. Only the <span class="keyword apiname">g_form.setVisible()</span> API is supported.</li></ul> </div> </div> <div class="p"><div class="fig fignone" id="r_VariableTypes__fig_xsj_bq5_3mb"><span class="figcap"><span class="fig--title-label">Figure 22. </span>Rich Text Label variable</span> <img class="image" id="r_VariableTypes__image_ysj_bq5_3mb" src="../image/RichTextVariable.png" alt="The Rich Text Label variable" /> </div> </div> </div> <div class="section" id="r_VariableTypes__sect_SelectBox"><h2 class="title sectiontitle">Select box</h2> <p class="p">The select box variable creates a list from predefined question choices. For attributes supported by this variable, see <a class="xref" href="variable-attributes.html" title="There are a few Service Catalog variables support specific attributes to define the behavior and restrictions for variables.">variable attributes</a>.</p> <div class="p"><div class="fig fignone" id="r_VariableTypes__fig_bxd_55w_dq"><span class="figcap"><span class="fig--title-label">Figure 23. </span>Example: select box variable</span> <img class="image" id="r_VariableTypes__image_nbs_vth_q5" src="../image/VariableSelectBoxG.png" alt="A select box variable" /> </div> </div> </div> <div class="section" id="r_VariableTypes__sect_SingleLineText"><h2 class="title sectiontitle">Single-line text</h2> <p class="p">The single-line text variable creates a field to enter a single line of text. For attributes supported by this variable, see <a class="xref" href="variable-attributes.html" title="There are a few Service Catalog variables support specific attributes to define the behavior and restrictions for variables.">variable attributes</a>.</p> <div class="p"><div class="fig fignone" id="r_VariableTypes__fig_ngd_4vw_dq"><span class="figcap"><span class="fig--title-label">Figure 24. </span>Example :single-line text variable</span> <img class="image" id="r_VariableTypes__image_ds3_rth_q5" src="../image/VariableSingleLineTextG.png" alt="A single-line text variable" /> </div> </div> </div> <div class="section" id="r_VariableTypes__sect_UIPage"><h2 class="title sectiontitle">UI page</h2> <p class="p">The UI page variable inserts a UI page into the catalog item.</p> <ul class="ul" id="r_VariableTypes__ul_krq_44m_cz"><li class="li">Use phase one Jelly only for any UI macros added as variables. Phase two Jelly within the macro is not processed and appears on the page as standard content.</li><li class="li">This variable is not yet supported on Classic Mobile devices and in Service Portal.</li></ul> </div> <div class="section" id="r_VariableTypes__sect_URL"><h2 class="title sectiontitle">URL</h2> <p class="p">The URL variable creates a widget for users to enter URLs. URLs are validated for the following protocols: HTTP, HTTPS, FTP.</p> <div class="note"><span class="notetitle">Note:</span> <ul class="ul" id="r_VariableTypes__ul_xsx_kpq_jkb"><li class="li">Variable validation is not supported in Service Portal.</li><li class="li">This variable is not editable on Now Mobile.</li></ul> </div> <div class="p"><div class="fig fignone" id="r_VariableTypes__fig_irs_yql_cw"><span class="figcap"><span class="fig--title-label">Figure 25. </span>Example: URL variable</span> <img class="image" id="r_VariableTypes__image_jrs_yql_cw" src="../image/URL.png" height="NaN" width="NaN" alt="A URL variable" /> </div> </div> </div> <div class="section" id="r_VariableTypes__sect_WideSingleLineText"><h2 class="title sectiontitle">Wide single-line text</h2> <p class="p">The wide single-line text variable creates a field that spans the form, letting users enter longer lines of text. For attributes supported by this variable, see<a class="xref" href="variable-attributes.html" title="There are a few Service Catalog variables support specific attributes to define the behavior and restrictions for variables.">variable attributes</a>.</p> <div class="p"><div class="fig fignone" id="r_VariableTypes__fig_zbv_jxw_dq"><span class="figcap"><span class="fig--title-label">Figure 26. </span>Example: wide single-line text variable</span> <img class="image" id="r_VariableTypes__image_dj2_jth_q5" src="../image/VariableWideSingleLineG.png" alt="A wide single-line text variable" /> </div> </div> </div> <div class="section" id="r_VariableTypes__sect_YesNo"><h2 class="title sectiontitle">Yes/No</h2> <p class="p">The Yes or No variable creates a choice list with <span class="ph uicontrol">Yes</span> and <span class="ph uicontrol">No</span> as options.</p> <div class="p"><div class="fig fignone" id="r_VariableTypes__fig_egk_yxw_dq"><span class="figcap"><span class="fig--title-label">Figure 27. </span>Example: Yes or No variable</span> <img class="image" id="r_VariableTypes__image_bcc_ysh_q5" src="../image/VariableYesNoG.png" alt="A Yes or No variable" /> </div> </div> </div> </div> <div class="related-links"> <ul class="ullinks"><li class="link ulchildlink"><strong><a href="../../../product/service-catalog-management/reference/variables-availability.html">Variable support in various channels</a></strong><br /> <span class="ph">Service Catalog</span> variables are supported in various channels.</li></ul> <div class="familylinks"> <div class="parentlink"><strong>Parent Topic:</strong> <a class="link" href="../../../product/service-catalog-management/concept/c_ServiceCatalogVariables.html" title="Service catalog variables capture and pass on information about choices a customer makes when ordering a catalog item. Variables help define the structure of a catalog item form that is displayed to the customer.">Service catalog variables</a></div> </div> </div></body></html></div>