171) Define Wait for WF Event activity in workflow?
The Wait for WF Event activity causes the workflow to wait at this activity until the
specified event is fired. Use this activity to wait for another activity to fire an event.
172) Define SLA Percentage Timer activity in workflow?
The SLA Percentage Timer activity pauses the workflow for duration equal to a
percentage of an SLA. A workflow must run on the Task SLA table to use this activity.
173) Define Timer activity in workflow?
The Timer activity pauses the workflow for a set period of time. This duration can be an
absolute time value or a relative value based on a defined schedule.
174) Define Rollback to activity in workflow?
When conditions in a workflow triggers a Rollback To activity, the workflow moves
processing backward to a specified activity in the workflow and resets certain activities
that have already executed back to their original state.
175) Define Generate activity in workflow?
The Generate activity immediately creates task or approval records from any task or
approval activities placed after the Generate activity in the workflow execution path.
176) Define Approval Coordinator activity in workflow?
The Approval Coordinator activity is used as a container for one or more Approval –
User, Approval – Group and Manual Approval activities. When the Approval
Coordinator activity completes, all pending approvals that were created by any of the
Approval Coordinator approval activities are immediately set to No Longer Required.
177) Define Approval Action activity in workflow?
The Approval Action activity sets an approval action on the current task. Use this activity
to mark the current task record as approved or rejected.
178) Define Metric.
A metric measures and evaluates the effectiveness of IT service management processes.
For example, a metric could measure the effectiveness of the incident resolution process
by calculating how long it takes to resolve an incident.
179) How many types of Metrics are there?
There are two types of Metrics:
• Field Value Duration
• Script Calculation
180) On which table metrics can be configured only?
Metrics are configured to work on the task table only.
181) What will you do if you want to configure the metrics on other table
apart from task table?
To apply metrics to other tables, duplicate the metric events business rule that currently
runs on the task table for the other table. For example, To apply metrics to cmdb_ci tables,
duplicate the metric events business rule that currently runs on the task table for the
cmdb_ci table. Without the events created, no metric processing can occur.
182) Define Metric Instance.
A metric instance is a record in the metric_instance table.
183) Define Database view.
A database view defines table joins for reporting purposes. For example, a database view
can join the Incident table to the Metric Definition and Metric Instance tables. This view
can be used to report on incident metrics and may include fields from any of these three
tables.
184) What are the Limitations of Database views?
The limitations of Database View are:
Database views cannot be created on tables that participate in table rotation.
It is not possible to edit data within a database view.
185) What do you mean by Data Lookup?
Data Lookup is used to define rules that automatically set one or more field values when
certain conditions are met. For example, on Incident forms, there are priority lookup rules
for the sample data that automatically set the incident Priority based on the incident
Impact and Urgency values. Note:
The custom table must extend the Data Lookup Matcher Rules [dl_matcher] table.
The columns of a data lookup table contain both matcher and setter field data.
186) Define Correlation id.
These fields are typically used for Integration purposes. Correlation id is often used for
storing third-party ids. Like with the SCCM integration, it stores the SCCM resource_id in
the ServiceNow correlation_id field.
187) Define correlation Display.
The correlation Display field can contain a free-form descriptive label of what third party
system is replicating or tied to this record. For example, if you are tying incident records
to a third party ticketing system when they are created within ServiceNow, the
corresponding ticket ID from the third party would be stored in the correlation ID field.
You could also set the correlation display field to be “JIRA”, or “REMEDY”, or
whatever you want to indicate the third party system using this ticket.
188) Define Script Include.
Script include is basically re-usable code that are used to store JavaScript that runs on the
server.
189) Why Script Include is preferred more than Global Business Rule?
Because script includes are only loaded on request.
190) Define Service Portal.
Service Portal is use to create more attractive, user-friendly interface for your users.
191) Define Update Set.
An update set is a group of customizations that can be moved from one instance to
another.
192) In which table Update Set is stored?
Each update set is stored in the Update Set [sys_update_set] table.
193) In which table customizations that are associated with the update set is
stored?
Customizations are stored in Customer Update [sys_update_xml] table.
194) What do you mean by View?
A view defines the elements that appear when a user opens a form or a list. Views are
form layouts that you can use to present the same record information in various ways. For
example, end users see a simplified view of the incident record and ITIL users see more
fields. It‟s the same data, just displayed in different ways – or views
195) In which table View records are saving?
All view records are saved in the UI View [sys_ui_view] table.
196) What do you mean by Coalesce?
Coalesce means the field will be used as a unique key. In an import sets, If a match is
found using the coalesce field; the existing record will be updated with the information
being imported. If a match is not found, then a new record will be inserted into the
database.
197) In Import, how can you update only?
To only update records where a match is found, and skip records where a match is not
found, specify a coalesce field and add the following script as an OnBefore script to the
transform map. if (action == „insert‟) ignore = true;
198) Are Schedule and Schedule jobs captured in update set?
No, both are not captured in update sets.
199) How can you add Applications and Homepage to Update Set?
Applications automatically include any homepages and content pages that are created
within or associated to an application. We can manually add homepages and content
pages to update sets:
To manually add a page to an update set:
Navigate to Homepage Admin > Pages.
Right-click a homepage record.
Select Unload Portal Page.
200) What do you mean by Homepage?
A homepage is a dashboard that consists of navigational elements, functional controls,
and system information. When a user logs on Service Now, the default homepage defined
for their role appears.
201) How you can secure you Homepage?
Homepages have two types of roles: read and write. Read roles limit who can view the
page. Write roles limit who can make edits to the page rename, such as moving around
gauges or deleting the homepage.
• Navigate to Homepage Admin > Pages.
• Select the homepage you want to secure.
• Click the lock icons next to Write roles or Read roles.
• Move the roles you want to restrict homepage access to from the Available column to the
selected column.
• Click Update.
202) How can you create global homepage or Homepage for specific users?
We can create it by following these steps:
Navigate to the Homepage Admin > Pages.
Click New.
Complete the fields on the form (see table).
Right-click the header and select Save.
Click the Edit Homepage related link to see the homepage.
Add content as needed.
203) Why it is very important to click on Edit Homepage related link while
creating global Homepage or Homepage for specific users?
We must click Edit Homepage to make changes to a global homepage that take effect for
all users who can access the homepage. If you click View Homepage and make changes, a
personal homepage is automatically created for you and those changes take effect only on
that personal homepage.
204) How can you specify a Login Landing Page using System Property?
To specify a login landing page for all users, change the property value on the
sys_properties table:
Type sys_properties.list in the navigation filter.
Locate the glide.login.home system property.
In the Value field, enter the name of the page that all users will see upon login.
Use <page name>.do; you may omit the http://”instance”.service-now.com/ portion of the
URL. To determine the page name or the URL of a page in the system, you can point to a
link. Some possible pages are: incident.do
205) Difference between Service Request and Record Producer.
A Service Request works with the cart where you can add multiple and then you can
order. On the other end it creates a request, request item, and possibly approvals and tasks
depending on its workflow.
A record producer is nothing but task based record. Record Producer uses a script or
template to create task based records, ideally not a Request.
206) What happens if a Default update set is marked as complete?
If the Default update set is marked Complete, the system creates another update set named
Default1 and uses it as the default update set.
207) Define Business Rule.
A business rule is a server-side script that runs when a record is displayed, inserted,
updated, or deleted, or when a table is queried.
The database operation that the system takes on the record.
Option When the rule run
Insert When the user creates a new record and the system inserts it into the
database.
Update Query When the user modifies an existing record.
Before a query for a record or list of records is sent to the database.
Typically you should use query for before business rules.
Delete When the user deletes a record.
208) Difference between Script Include and BR?
Script includes load only on request while global business rules load on every page in the
system.
209) What is the objective of display?
The primary objective of display rules is to use a shared scratchpad object, g_scratchpad,
which is also sent to the client as part of the form. This can be useful when you need to
build client scripts that require server data that is not typically part of the record being
displayed.
210) How can you remove/hide filter of List Collector?
Set no_filter in Variable attributes of the variable.
211) What is the difference between g_form and g_user?
g_form is a global object in the GlideForm class that references the currently active form.
g_user is a global object in GlideUser that references the currently active user .It contains
information about the current user.
Note:- Both runs on Client Side.
236) What is Global in client script?
It is the Indicator of whether the script applies to all views. When Global is selected, the
script runs regardless of what view is being displayed. When Global is not selected, this
script runs only if the current view matches the script's view.
Global application in client script means the script can be used globally meaning to all
your applications. While the other options are the name of your other application, if one of
the applications is selected, it limits the client script to be use on the current application
you've chosen.
237) Execution of UI action for server side?
UI action runs the server side code only until you check the client checkbox.
The client is always false if you want executing the UI action in server level.
238) Weight in email notifications?
Email notification weight is defined as a required numerical value for this notification‟s
priority relative to other notifications:
With the same target table and recipients
The system only sends the notification with the highest weight
239) What is ACL?
An ACL is access control list that defines what data a user can access and how they can
access it in service now.
Types:
Match the object against field ACL rules
Match the object against table ACL rules.
Objects:
Client-callable script includes
Processors
UI pages
Record
240) What do you mean by star-dot-star in ACL’s (*.* in ACL)??
*.* - means first star represents all tables and second star represents all fields on those
table.
241) What is the difference between * and None in ACL?
The * when applied with table.* applies to all the fields so it is at field level.
The None when applied with table none applies at the table level.
242) What is a data policy?
Data policy checks the mandatory and read-only of a field whenever a record is inserted or
updated through a web-service or import set. For example: If a mandatory field in the
incoming record (from import set or web-service) is empty then the data policy will not
allow to insert that record into the table.
The System Policy > Data Policies module displays a list of all data polices and where
they apply.
243) What is Formatter?
A formatter is a form element used to display information that is not a field in the record.
Some examples of formatters in the base platform include:
Activity formatter: Displays the list of activities, or history, on a task form.
Process flow formatter: Displays the different stages in a linear process flow across the top
of a record.
Parent breadcrumbs formatter: Provides breadcrumbs to show the parent or parents of the
current task
Approval summarizer formatter: Displays dynamic summary information about the
request being approved.
CI relations formatter: Displays on the CI form a toolbar for viewing the relationships
between the current CI and related CIs.
To create a custom formatter, perform these tasks:
Create a UI macro to define content for the formatter.
Create a formatter that refers to the UI macro.
Add the formatter to a form.
244) What is UI Macros?
UI macros are typically controls that provide inputs or information not provided by
existing field types.
245) Why do we use UI Macro and UI Page as variables for Service Catalog?
UI Macros and UI pages can be used when you need further flexibility to build solutions
that could not be built using the other catalog variable types. You can think of these like a
"block" in your catalog which you can customize as per your desire.
246) What is UI page?
UI pages can be used to create and display forms, dialogs, lists and other UI components.
Use UI pages as widgets on homepages. To find the UI Pages, navigate to System UI > UI
Pages.
247) Slush bucket?
Slushbuckets allow users to select multiple items from a list of available items. They are
used in many operations, such as personalizing lists, adding items to related lists,
and service catalog list collector variables.
The slushbucket interface has two columns: the available items on the left and the selected
items on the right.
249) Business rule that calls email notification?
Send notification through business rule?
You need to create a notification event or modify it existing business rule which is defined
in the system for the incident/problem/change etc.
Once it is defined there whenever business rule qualification will met then that event or
business rule will trigger and associated notification will be sent.
1. Search (Events) in the business rule.
2 check if any events matches your requirement.
3. Create a new notification records in notification module in service now.
4. Attach the same event which you created in the events business rule or modified.
5. Once business rule will matches then events will be fired and associated notification
will be sent to the user.
250) What is Record producer?
A record producer is a type of a catalog item that allows users to create task-based records
from the service catalog. For example you can create a change record or problem record
using record producer. Record producers provide an alternative way to create records
through service catalog.
251) How to Fetch Current user?
Get current username of logged in user?
Use gs.getUserName() to return you current logged in username. You can put this as query
in GlideRecord as
gs.addQuery('user_name',gs.getUserName());
252) Fetch value of reference field?
You can use g_form.getDisplayBox('field_name');
253) On Cell edit client script best practices?
Select "Admin overrides" checkbox to true in the particular ACL so that they can pass the
permission check with this ACL rule.
254) Reverse if false in UI policy?
Reverse if false: Option for specifying that the UI policy action should be reversed when
its UI policy's conditions evaluate to false. In other words, when the conditions are true,
actions are taken and when they change back to false, the actions are reversed (undone).
255) Can we call br (business rule) from cs (client script)?
Yes we can call BR from CS. Any GlideRecord query should be on the Server Side
(Business Rule). You should instead write a Glide AJAX call in this scenario where you
need to pass server side data to the client.
256) Fetch count of record in table?
getRowCount()
257) Events in ServiceNow?
Event are special records the system uses to log when certain conditions occur and to take
some kind of action in response to the conditions.
The system uses business rules to monitor for system conditions and to generate event
records in the Event [sysevent] table, which is also known as the event log or event queue.
Event-generating business rules typically use this script logic:
If [some condition is true for the current record], then [add a specific event to the queue].
For example, here are some of the conditions in the incident event business rule:
If a user adds a comment to an incident record, add an incident.commented event.
If a user adds an incident record, add an incident.inserted event.
If a user updates an incident record, add an incident.updated event.
Event-generating business rules use the GlideSystem eventQueue method to insert event
records, which typically contain this information:
Event fields –
Name, Parm1, Parm2, Table, Instance
Event registry –
261) What is the difference b/w next() and hasNext()?
hasNext() : hasNext() method returns true if iterator have more elements.
next(): next() method returns the next element and also moves to the next element.
262) What is difference b/w Record producer and Service Catalog?
A catalog item works with the cart where you can add multiple and then you can order. On
the other end it creates a request, request item, and possibly approvals and tasks depending
on its workflow.
A record producer is nothing but task based record, most commonly create an incident.
263) Difference b/w Catalogs, Record producer and Order guide?
Catalog Items: Create and edit catalog items, the actual goods or services available to
order from a catalog.
Record Producers: Enable records to be created directly from the service catalog. For
example, allow customers to raise incidents from the service catalog.
Order Guides: Create and edit standard groups of related items, allowing end users to
easily order these items in one request.
264) Scripts – Background module?
Background script?
Administrators can use the Scripts - Background module to run arbitrary JavaScript code
from the server.
The Scripts - Background module consists of the following components.
A text field to enter JavaScript
A selector to specify the application scope
A Run script button
A list of available scripts
Administrators can run any valid JavaScript that uses the Glide API. The system displays
results, information, and error messages at the top of the screen.
265) What is HTML sanitizer
The HTML sanitizer automatically cleans up HTML markup in HTML fields and
translated HTML fields to remove unwanted code and protect against security concerns
such as cross-site scripting attacks.
The HTML sanitizer works by checking the built-in white list for markup that you always
want to preserve. The sanitizer provides the HTML Sanitizer Config script include that
administrators can use to modify the built-in white list. Items can also be added to the
black list, which overrides the white list, to remove HTML markup.
The following types of items can be added to white and black lists:
Global attributes
Any HTML elements
Note: By default, URL attributes like href and src support only these protocols:
http
https
mailto
266) What is watermark in service now?
By default, the system generates a watermark label at the bottom of each notification
email to allow matching incoming email to existing records.
The watermark always includes "Ref:" and a customizable prefix, followed by the auto-
numbered identifier of the source record, such as incident, problem, or change request.
The default prefix is MSG. For example, Ref: MSG3846157.
Watermarks are always generated, but you can configure them to:
Create a custom watermark prefix for each instance to prevent accidentally triggering
events in the wrong instance.
Have custom prefix characters after MSG
Be hidden globally
Be omitted from individual email messages
267) Troubleshooting UI actions
Description”
When UI actions are not working as expected, there can be a number of causes for this
behavior. This article covers the most common factors that contribute to this issue. It is
important to remember that UI actions are client-side rather than server-side. For this
reason, other client side components can affect UI actions.
Symptoms
Symptoms may include the following:
Field removed from form
Cannot change field
Form is broken
UI policy not working
UI action not working
Client scripts not working
Form sections not loading
Comments
Post a Comment