admin servicenow
admin servicenow
Ldap (docs )
basic config. Settings are not getting changed
Events, notifications
https://chatgpt.com/share/670cfd3e-e2fc-8001-a776-06256057cc73
docs.servicenow.com
community.servicenow.com :- any doubt to ask from community
developer.servicenow.com
https://developer.servicenow.com/dev.do#!/learn/learning-plans/washingtondc/
new_to_servicenow/
app_store_learnv2_buildmyfirstapp_washingtondc_servicenow_basics_objectives
This is where deleteMultiple() comes into play. This GlideRecord method is a powerful
tool for deleting all records that match a specified query.
Servicenow is an American based company was founded in 2004 by fred luddy (previous CTO
of software companies like peregrine systems and remedy corporation). serviceNow gives
automatice upgrades, purely a web based platform, custom subscriptions, native mobile
interface. Aspen was the first version of servicenow. It is ITIL based.
The servicenow data centers consists of thousands of servers that take on the role of load
balancer, web servers, application servers, database servers and much much more.
The general flow of servicenow :- when a client request and incident record, there request will
go over the internet and will go to the load balancer, the load balancer will then determine
which server has extra resources to allocate to process the request, the request will then go to
web server and then to application server.
The application server will perform the actual logic and will then send the query to the database
server. The database server will then send the respond to the application server, the application
server sends the response to web server and from web server to client through internet.
Server has access to :- server side api’s, script include, database
Client has access to :- client side api, UI elements(DOM), form, fileds
Other competetors of servicenow are, hp service manager, bmc remedy, ca technologies.
These 3 certifications are available in serviceNow
Upgrades in SeviceNow
Release
Purpose Scope Frequency Example
Type
Feature New workflows in a
Adds new functionality Larger Quarterly/yearly
Release module
Patch Fixes minor bugs, Performance
Moderate Monthly
Release enhances stability improvements
Fixes urgent, critical Very Emergency security
Hotfix On-demand
issues narrow vulnerability fix
These are the technologies used to develop serviceNow.
Careers in ServiceNow
serviceNow business analyst
serviceNow quality analyst
serviceNow administrator
serviceNow developer
serviceNow architect
serviceNow manager
ServiceNow is built using Java and Tomcat web server running on Linux. Although to develop
new modules and applications in ServiceNow the JavaScript knowledge is sufficient.
Currently ServiceNow Chairman & CEO, Bill McDermott
Major customers – Netflix, facebook, dell, vitas, Barclays, Capgemini, healthpartners, NHS,
twitter
ServiceNow is primarily considered a Platform as a Service (PaaS). It provides a cloud-based
platform that allows organizations to develop, manage, and deploy applications. Here are some
key points about ServiceNow as a PaaS:
1. Development Environment: ServiceNow offers a robust development environment
where developers can create custom applications and workflows tailored to specific
business needs.
2. Integration Capabilities: It supports integration with various third-party applications
and services, enabling seamless data exchange and collaboration across platforms.
3. Workflow Automation: ServiceNow allows users to automate workflows and processes,
enhancing efficiency and reducing manual effort.
4. Scalability: As a cloud-based platform, ServiceNow provides scalability to accommodate
the growing needs of organizations.
5. Security: It includes built-in security features to ensure data protection and compliance
with industry standards.
6. User-Friendly Interface: The platform has an intuitive interface that simplifies
application development and management for users, even those with limited technical
expertise.
ServiceNow offers a wide range of applications that cater to various aspects of IT service
management (ITSM), IT operations management (ITOM), IT business management (ITBM),
HR management and more. Here are some of the key applications provided by ServiceNow:
IT service management
IT operations management
Software asset management
IT business management
Customer service management
Performance analytics
Hr service delivery
Security operations
Governance, risk and compliance
Event Management: Monitors IT infrastructure for events and alerts to help resolve
issues before they impact users.
Discovery: Automatically identifies and maps IT assets and their relationships within the
infrastructure.
Service Mapping: Visualizes application dependencies and configurations for better
understanding and management.
3. IT Business Management (ITBM)
Project Portfolio Management (PPM): Manages project portfolios, resources, and
financials to align projects with business objectives.
Application Portfolio Management: Evaluates and manages the application portfolio to
ensure optimal performance and cost-effectiveness.
4. Security Operations
Security Incident Response: Automates the process of responding to security incidents
and threats.
Vulnerability Response: Manages and prioritizes vulnerabilities to ensure timely
remediation.
Threat Intelligence: Integrates threat intelligence feeds to improve security posture.
5. Customer Service Management (CSM)
Case Management: Manages customer inquiries, complaints, and support requests.
Knowledge Management: Helps customers find answers to their questions through a
self-service portal.
6. HR Service Delivery
Employee Service Center: Provides a centralized portal for employees to access HR
services and information.
Case Management: Manages HR-related cases and inquiries efficiently.
7. Governance, Risk, and Compliance (GRC)
Policy and Compliance Management: Ensures policies are followed and compliance
requirements are met.
Risk Management: Identifies and manages risks within the organization.
8. DevOps
DevOps Management: Integrates development and operations processes to improve
collaboration and accelerate software delivery.
9. Performance Analytics
Dashboards and Reporting: Provides real-time insights into key performance indicators
(KPIs) and metrics.
10. Field Service Management
Work Order Management: Manages and tracks field service requests and tasks for
efficient service delivery.
Change Management
Change Management in ServiceNow is a structured process used to control the lifecycle of
changes to IT systems, services, and infrastructure. The main goal of change management is to
minimize the risk and impact of change-related activities on the business while improving the
effectiveness of IT services. This process ensures that changes are introduced in a controlled
and coordinated manner to avoid unintended disruptions or downtime.
Key Concepts in Change Management:
1. Change Request (CR): A formal request to modify an IT service, system, or component.
It documents the details of the change, including why it’s needed, how it will be
implemented, and what risks are involved.
2. Types of Changes:
o Standard Change: A low-risk, pre-authorized change that follows a well-
established procedure (e.g., regular software updates).
o Normal Change: A non-emergency change that follows the complete change
management process, including approval, risk assessment, and implementation.
o Emergency Change: A change that must be implemented quickly due to a critical
issue or incident. It bypasses some parts of the standard change process due to its
urgency but still requires post-change review.
3. Change Workflow: The steps involved in processing a change request, which typically
includes:
o Submission: A change request is created, providing all necessary details about the
proposed change.
o Assessment: The change is evaluated for risks, potential impacts, and resource
requirements.
o Approval: The change must be approved by appropriate stakeholders (e.g.,
Change Advisory Board) before implementation.
o Implementation: The approved change is deployed in a planned and controlled
manner.
o Review: After the change is implemented, a post-change review is conducted to
evaluate its success and identify any issues.
4. Change Advisory Board (CAB): A group of stakeholders responsible for reviewing,
approving, or rejecting change requests. CAB meetings are held to discuss high-risk or
significant changes and ensure that all potential risks have been considered before
proceeding.
Change Management Process in ServiceNow:
1. Change Request Creation:
o A Change Request (CR) is created in ServiceNow by a user or technician,
detailing the nature of the change, the affected systems, and the justification for the
change.
o Each change request is associated with relevant fields, such as change type,
priority, risk, schedule, and implementation plan.
2. Risk and Impact Assessment:
o The system or a designated person assesses the risk and potential business impact
of the change.
o Risk is evaluated based on various factors like the complexity of the change, the
criticality of the affected system, and potential downtime.
3. Approval Workflow:
o Depending on the type of change, different approval workflows are triggered. For
example, a normal change may require approval from the CAB, while a standard
change may bypass approval if it's pre-authorized.
o ServiceNow uses workflows to route the change request through the approval
process based on predefined conditions.
4. Planning and Scheduling:
o The change is scheduled to minimize disruption to business operations, often
planned during maintenance windows or low-activity periods.
o ServiceNow allows setting a change calendar and planning windows to schedule
changes efficiently.
5. Implementation:
o Once the change is approved, it is implemented according to the defined plan. The
system tracks the change implementation process, ensuring that everything is
recorded for future reference.
o Technicians or teams assigned to the change can update the status and progress
during implementation.
6. Post-Implementation Review:
o After implementation, a post-change review is conducted to assess whether the
change achieved its objectives and to identify any issues.
o The review ensures that any problems caused by the change are addressed, and
lessons learned are recorded for future reference.
7. Closure:
o Once the change is successfully reviewed and all related tasks are completed, the
change request is closed.
Key Features of Change Management in ServiceNow:
Change Templates: Predefined templates for common change types to streamline the
process for repetitive tasks (e.g., standard changes like system patching).
Change Risk Assessment: Automated risk calculation based on factors such as the
criticality of the service, the scope of the change, and the history of previous changes.
Change Calendar: A visual calendar view of scheduled changes, allowing IT teams to
plan changes effectively without causing conflicts.
Change Approval Workflows: Configurable workflows that route change requests to
the appropriate approvers based on change type, risk, or affected service.
Integration with Incident and Problem Management: Change management is tightly
integrated with incident and problem management. For example, changes can be created
as a result of problems, and incidents can be linked to change requests.
Automated Notifications: Automated alerts and notifications keep stakeholders
informed throughout the change process, from submission to closure.
Types of Change Requests:
1. Standard Change:
o Low-risk and pre-approved changes that follow a documented procedure.
o Example: Routine software patching or adding a new user to the system.
2. Normal Change:
o Changes that require a full review and approval process. These can be higher-risk
or more complex changes.
o Example: Upgrading a critical business application.
3. Emergency Change:
o High-urgency changes that are made to address an ongoing incident or critical
situation. These may be fast-tracked but still need post-change approval.
o Example: Fixing a critical security vulnerability.
Change Management Integration:
Incident Management: When an incident is resolved with a workaround or a temporary
fix, a change request can be created to implement a permanent solution.
Problem Management: Problems identified from recurring incidents may require
changes to fix the root cause, linking change requests with problem records.
Configuration Management Database (CMDB): The CMDB is used to track the
configuration items (CIs) impacted by the change. This helps assess the potential impact
of the change and ensures that all related services are considered during planning.
Example Change Request Workflow:
1. A user submits a change request to upgrade a server’s operating system.
2. The change request is evaluated for risk and business impact.
3. The request is reviewed and approved by the Change Advisory Board (CAB).
4. The change is scheduled during a maintenance window to minimize business disruption.
5. The IT team implements the upgrade during the scheduled time.
6. After the upgrade, a post-change review is conducted to ensure the success of the change.
7. The change request is closed, and the CMDB is updated with the new server information.
Benefits of Change Management:
Reduced Risk: By following a structured change process, organizations can reduce the
risk of service outages, disruptions, or security breaches.
Better Planning: With a well-defined change calendar and approval process, changes
can be planned and scheduled effectively, reducing the likelihood of conflicts.
Improved Communication: The change management process involves communication
with all stakeholders, ensuring that everyone is aware of the change’s impact, schedule,
and status.
Increased Efficiency: Standardized change processes and workflows streamline the
change lifecycle, making it easier for IT teams to manage changes.
In summary, Change Management in ServiceNow helps organizations manage changes to IT
services in a controlled, systematic manner. It reduces risk, ensures proper planning, and
facilitates collaboration between stakeholders to maintain service quality during change
implementation.
ITIL
The ITIL (Information Technology Infrastructure Library) framework is a set of best practices
for delivering IT services effectively and efficiently. It provides guidelines for managing and
delivering IT services, focusing on aligning IT services with the needs of the business. ITIL is
widely used in organizations to ensure that IT services meet the expectations of customers and
provide value.
Key Concepts of ITIL:
1. Service Strategy: Understanding customer needs, market conditions, and offering the
right services.
2. Service Design: Designing IT services that meet business goals, including processes,
technology, and tools.
3. Service Transition: Managing changes, releases, and transitioning new services into the
live environment.
4. Service Operation: Managing day-to-day operations of IT services, ensuring smooth
service delivery and handling incidents and problems.
5. Continual Service Improvement (CSI): Constantly improving IT services based on
feedback, monitoring, and evaluation.
ITIL has undergone several revisions, with the latest version being ITIL 4, released in 2019.
ITIL 4 introduces a more flexible approach to service management, incorporating modern
concepts such as Agile, DevOps, and Lean.
Example of entire ITIL process Let us take an example of a startup BookWorm ltd., which sells
books online through their website. The company is planning to launch a book rental service in
selected cities. This service provides facility for doorstep delivery and return of the rented
books. The company has adopted an ITIL framework, since its establishment and since, this is a
new service, it should undergo various stages of ITIL. Service strategy The service proposal is
first presented to the stakeholders. The discussions on customer base, return on investment
(ROI), prices, market research, competitors and business model takes place in this phase.
Service design The blueprint of the service is prepared by the experts in the respective fields.
The technology that will be used to deliver the service to the customer, subscription plans,
payment method, online portal design, delivery and return model and charges are finalised in
this stage. Service transition At this point of time, scope and design of the service is already
defined. In service transition, the preparation to implement the service starts. The change
request is raised for the new service and activities like software development, budgeting,
approval, acquisitions, inventory management is undertaken by the respective teams. The
roadmap for the service is finalised and milestone dates are set for the service to go live.
Service operation The service is now in production and each and every issue (whether one time
or recurring) reported during the service delivery by the customers, users or internal team is
tracked and managed by the Service operation. Continual Service Improvement In this
continuous process, the opportunities are identified to make service better, for example, internal
IT team suggests a new CMS (content management system) tool for their website, which
provides improved metrics, easy access and enhanced features. in this example what i have
figured out is that servicenow will come into picture during the service operation phase
ITIL in ServiceNow
Incident Management
Problem Management
Change Management
Request Fulfillment
Service Level Management
Asset and Configuration Management (CMDB)
Knowledge Management
Continual Service Improvement
Incident management –
an employee is getting issue to start the computer or browser not connecting to internet. There
are 2 ways to solve
1. By doing a temp fix
2. Analying the root cause and solving that root cause which is called problem management.
Steps in Incident Management
1. Detect and record (manually or automatically)
2. Classify and prioritise
Classifying the category of the problem software, hardware or network. Prioritizing
them as urgent or not so urgent issue. Impact (amount of users getting impacted) +
Urgency = Priority
Impact – measures the effect of incident on business processes
Criteria:-
No of users affected.
No of services affected.
Reputation.
Urgency :- The extent to which an incident resolution can bear delay.
Priority :- depends upon urgency and criteria.
3.
The records(row) in servicenow are stored in the database table, in databse there are many
tables(incident, changes, problem, user etc etc) each record has a unique key sys_id generated
by servicenow platform to uniquely identify each record.
Context Menu – It is the menu that appears when we click on the hamburger icon. Context
Menus are analogous to the application menus of a program on your computer
Personalization list/form – any user can do personalizations in their instance.
Configurations list/form – can only be done by admin and will get applied to every user’s
interface.
1. Service now request/response – Client (Browser) Request: When a user interacts with
ServiceNow (e.g., submitting a form or loading a page), a request is made from the
browser (client) to the ServiceNow application server.
2. Application Server: The ServiceNow application server processes this request. It
determines what data or actions are required and sends the appropriate request to the
data center where ServiceNow's databases are stored.
3. ServiceNow Data Centers: The ServiceNow data centers host all the customer data and
backend infrastructure. When the application server requests specific data (e.g., an
incident or change request), the data center fetches the required data from the databases
and sends it back to the application server.
4. Application Server Response: The application server then processes the data received
from the data center and prepares it in a format (usually HTML, JSON, etc.) that can be
sent back to the browser.
5. Browser (Client) Response: The formatted data is sent back to the user's browser, where
it's displayed as part of the webpage.
Roundtrip Time
The roundtrip time refers to the total time it takes for a request to travel from the client
(browser) to the data center and for the response to be returned to the client.
Latency: Even if a user has a fast internet connection, there is inherent latency in this
process because the request must:
o Travel from the user's browser to the application server.
o Be processed by the application server, which then queries the data center.
o The data center retrieves the data and sends it back to the application server.
o The application server then sends the response back to the browser.
This entire process takes time, especially if the data center is located far from the user or if
the data processing involves complex queries. This latency is often not related to the user's
internet speed, but rather to the time it takes for the ServiceNow infrastructure to process the
request.
Field Labels
The Field Labels [sys_documentation] table, also called the Language File, contains
information about the labels and hints for each table and column in the system.
Access the language file in one of these ways:
To see the list view, navigate to System Definition > Language File.
To see the field label for a particular field, right-click the field label on the form.
The following image shows the language file filtered to display only labels on the Incident
table.
System dictionary
View a list of all tables in columns in your instance from the system dictionary.
Each row in the system dictionary represents either a table or a column in one of the tables. The
system dictionary provides options for administrators to modify tables and fields, which in turn
define lists and forms.
Use caution when changing system dictionary records because changes can have a high impact
on functionality. In particular, changes to dictionary entries for system tables, which are tables
that begin with sys_, can create system-wide issues such as the inability to use update sets.
Dictionary changes are difficult to reverse. Also, dictionary changes automatically apply to all
extended tables unless a dictionary override is defined
Table relationships
You can create relationships between tables by extending tables, referencing records in another
table, creating many-to-many relationships, and joining tables in a database view.
Tables can be related to each other in several ways.
Extensions
A table can extend another table. The table doing the extending (child class) includes all of the
fields of the other table (parent class) and adds its own fields. For instance, the Incident
[incident] table has all of the Task [task] table fields (because an incident is a special form of
task) and has its own incident-specific tasks.
One-to-many
Within a table, a field can hold a reference to a record on another table. There are three types of
one-to-many relationship fields.
Reference fields
Allow a user to select a record on a table defined by the reference field. For instance,
the Caller field on the Incident table allows the user to select any record on the User table.
Glide lists
Allow a user to select multiple records on a table defined by the glide list. For instance,
the Watch list field on the Incident [incident] table allows the user to select records on the User
[sys_user] table.
Document ID fields
Allow a user to select a record on any table in the instance. These fields are much less common,
but one example is the Document field on the Translated Text [sys_translated_text] table.
Many-to-many
Two tables can have a bi-directional relationship, so that the related records are visible from
both tables in a related list.
Database views
Two tables can be joined virtually in a database view to enable reporting on data that might be
stored over more than one table.
Table extension and classes
Administrators and application developers typically extend tables to create a set of related
records that share information. For example, in the base system, the Task and the Configuration
Item tables have multiple extensions:
A table that extends another table is called a child class, and the table it extends is the parent
class. A table can be both a parent and child class both extending and providing extensions for
other tables. A parent class that is not an extension of another table is called a base class.
Administrators can use these tools to see the relationships between classes.
Schema map
System dictionary
Tables module
Extension models
The Now Platform offers these extension models.
Table per class
Table per hierarchy
Table per partition
5. Records Replicated:
o No record replication is needed.
o All records for the parent and child tables are stored in the single parent table.
o Example:
The Task table contains all records from child classes like Incident,
Problem, and Change.
This avoids duplication and ensures a unified storage system.
How Table Per Partition Works
1. Tables Created:
o One primary database table is created for the parent class.
o This table stores all records, including those for child classes.
o When the database table reaches a storage limit, the system dynamically creates
additional storage tables (partitions) to store new records.
Example:
o The Base Configuration Item (cmdb) table serves as the parent table for child
classes like:
Configuration Item (cmdb_ci)
Hardware (cmdb_ci_hardware)
6. Records Replicated:
o No record replication is needed.
o All records are stored in the parent table and managed across partitions as needed.
Example:
o The Base Configuration Item (cmdb) table contains all records for its child
classes:
Application (cmdb_ci_appl)
Computer (cmdb_ci_computer)
Hardware (cmdb_ci_hardware)
No, you don't explicitly choose one of these models when extending a table in ServiceNow.
The platform inherently uses one of the models based on the type of table being extended and
its architecture. Here’s how it works:
Why Glomming?
Space Optimization: By allowing sibling elements to share columns, it reduces the need
for excessive physical columns in the database.
Logical Separation: Each child table appears to have its own fields, but they are stored
more efficiently in the parent table.
Practical Takeaways
When working with Table per hierarchy, storage aliases and glomming ensure optimal
storage and seamless logical representation.
The sys_class_name column is critical for differentiating child table records within a
single parent table.
Glomming in ServiceNow refers to a mechanism used in a Table per Hierarchy extension
model where multiple logical fields (from child tables) share a single physical column in the
parent table's database schema.
It is a way of optimizing database storage and improving performance by reducing the number
of physical columns in the parent table.
IMPORTANT
Related Links
gsftSubmit() is mostly used in UI actions that have a client side and a server side script.
At the end of the client side script, gsftSubmit(null, g_form.getFormElement(), "Action
name") triggers the UI Action again which is specified in the 3rd parameter, this time
only the server side code gets executed.
In general, when we need to execute both client-side and server-side scripts from a UI
Action in ServiceNow, we often use the gsftSubmit() method within the client script of the UI
Action. However, this method involves DOM manipulation, which is not recommended in
ServiceNow. The reason is that DOM manipulation requires referencing elements in the DOM
by their IDs or CSS selectors. When dealing with out-of-box DOM elements, there’s a risk that
their IDs or positions within the DOM structure may change, potentially causing the code to fail
or generate errors.
To avoid these types of issues, it’s better to explore alternative approaches to execute server-
side scripts in a UI Action while still incorporating client-side logic. One such approach is
using GlideAjax. Below is an example use case demonstrating this approach:
I created a UI Action named "Create Task" on the Incident form, which is displayed when the
incident is in the New state. Upon clicking the button, a confirmation prompt (handled on the
client side) is displayed. If the user confirms, the UI Action invokes a Script Include via
GlideAjax to create an Incident Task for the current incident.
The Resolved, Update, Submit, and similar buttons in ServiceNow are all examples of UI
Actions. Each of these buttons triggers a specific task or action either on the client side or the
server side when clicked.
Here's a breakdown of common UI Actions:
1. Update Button:
o Action: When the Update button is clicked, it usually saves the current form data
and updates the record in the database.
o Server-side: This is a server-side UI Action because it sends data to the server to
update the record in the database.
2. Resolved Button:
o Action: When the Resolved button is clicked (typically in an Incident form), it can
trigger a series of actions, such as setting the Incident state to "Resolved," updating
the resolution fields, and notifying the user.
o Client or Server-side: This can be client-side (e.g., changing some fields) or
server-side (e.g., saving data, sending notifications).
3. Submit Button:
o Action: When you click the Submit button, it usually creates a new record in the
database and submits the form.
o Server-side: This sends the data to the server to create a new record.
4. Cancel Button:
o Action: When clicked, this usually cancels the action and redirects the user
without saving any changes.
o Client-side: Often handled on the client side by just redirecting the user to another
page without submitting any form data.
Example
As part of a UI action script, you can redirect a user to a URL. For example, you might add
links to a form or open a new record after it is created from a UI action. To redirect a user to a
URL from a UI action, use this syntax in the Script field to define the redirect link:
action.setRedirectURL ( 'http://www.mysite.com/mypage.htm' );
To direct a user to a record, use this syntax, where new_record is the variable name for
the GlideRecord:
action.setRedirectURL (new_record );
GlideRecord is a powerful class used in server-side scripts to interact with tables in the
platform's database. With GlideRecord, you can query, create, update, and delete records in any
table.GlideRecord provides a programmatic way to interact with ServiceNow tables. It allows
you to define queries, retrieve data, and perform operations on records. It’s especially useful in
Business Rules, Script Includes, and UI Actions for implementing custom logic.
Here's a breakdown of what GlideRecord does:
Querying Records: Retrieve records from a table based on specific conditions.
Creating New Records: Insert new records into a table.
Updating Existing Records: Modify records in a table.
Deleting Records: Remove records from a table.
Example of Using GlideRecord to Retrieve a Record
Suppose you want to retrieve an Incident record with a specific sys_id:
var gr = new GlideRecord('incident'); // Specifies the table to query
gr.get('sys_id_value_here'); // Retrieves the record by sys_id
In this example:
new GlideRecord('incident') creates a GlideRecord instance for the Incident table.
gr.get('sys_id_value_here') fetches the record with the specified sys_id if it exists.
Explanation of action.setRedirectURL(new_record)
This code is often used in UI Actions to redirect the user to a specific record after an action
is performed.
action: Refers to the UI Action itself, allowing you to control what happens after the
action completes.
setRedirectURL(): A method used to specify where the user should be redirected after
the action finishes.
new_record: This variable is typically a GlideRecord object pointing to the specific
record you want to redirect the user to.
📌 UI Page in ServiceNow
A UI Page in ServiceNow is a custom web page that allows you to create and display dynamic
content using HTML, Jelly (ServiceNow’s UI scripting language), and server-side scripts
(Glide APIs). It is commonly used for:
✅ Modals & Dialogs (Custom pop-ups for confirmations)
✅ Custom Forms (When the default form view isn’t enough)
✅ Dashboards & Custom Pages (For advanced UI designs)
✅ Custom Actions (Such as invoking scripts, running processes, or displaying external content)
🚀 Features of GlideModalForm
✅ Displays a form inside a modal
✅ Used for record creation or updates
✅ Supports UI actions (Submit, Cancel, etc.)
✅ Works with GlideRecord to interact with database tables
Business Rules
Business Rules in ServiceNow are server-side scripts that run whenever a record is
inserted, updated, deleted, or queried from a database table. They allow you to apply
business logic to data being processed in the system. Business rules are a powerful tool in
ServiceNow for enforcing rules, automating processes, and controlling data integrity.
Key Features of Business Rules:
5. Server-Side Execution: Business rules are executed on the server, not the client-side
(browser).
6. Triggered by Database Operations: They are triggered by insert, update, delete, or
query operations on records in the database.
7. Flexible Timing: You can set the timing of a business rule to run before or after the
database action, or asynchronously.
1. Operation to Perform:
You need to define what type of database operation will trigger the business rule. These
operations are:
Insert: The rule is triggered when a new record is created in the table.
Update: The rule is triggered when an existing record is updated.
Delete: The rule is triggered when a record is deleted.
Query: The rule is triggered when a record or records are queried (i.e., retrieved from the
database).
You can choose one or more operations depending on when you want your business rule to
execute.
2. When to Apply (Timing):
You also need to specify when the business rule should run relative to the database operation.
The timing options are:
Before: The rule is applied before the database action (insert, update, delete) occurs. This
is typically used to modify data before it's saved to the database.
After: The rule is applied after the database action. This is useful for actions like sending
notifications or logging information.
Async: The rule is applied after the action but is executed asynchronously (in the
background). This is used for operations that don’t need to occur immediately, which
helps improve performance.
Display: The rule is applied before the data is sent to the client (when the form is
loaded). This can be used to prepare data for display on the form.
Abort action button in business rules
the Abort Action option in a Business Rule is used to stop the execution of the current
database operation. It prevents the record from being inserted, updated, deleted, or queried
based on the logic in the Business Rule.
Where is Abort Action Used?
The Abort Action checkbox is available in Before Business Rules because it needs to stop the
operation before it is committed to the database.
How It Works
When Abort Action is enabled:
The database operation being performed (e.g., insert, update, delete) is terminated.
Any further processing of the record is stopped.
The record changes are not saved to the database.
OR
In the context of Business Rules in ServiceNow, the Query option refers to Query Business
Rules. These rules are executed when a query is made to retrieve data from the database for a
specific table. They allow you to modify or filter the query dynamically before the data is
fetched and presented to the user or processed by the system.
Data policies
Use Data Policies when you need to ensure that certain data integrity rules apply
universally, regardless of how the data is entered. For instance, if you want to ensure that a field
is always mandatory whenever a record is created or updated, regardless of whether it's done
via the UI, script or an API call.
Use UI Policies when you want to control the visibility and interactivity of fields on a form
based on user input. For example, you might want to hide or show certain fields based on the
selection in a dropdown menu to improve the user experience.
These are all the checkboxes that you can tick, and handle to apply data policies when data is
coming form them
Apply to import sets
Apply to SOAP
Use as UI Policy on client
Schedules Jobs
Scheduled jobs are used to schedule
Report
Scripts
Charts
Incident, change, ci requests
etc
In ServiceNow, Scheduled Jobs (also known as Scheduled Scripts or Scheduled Jobs under
"Scheduled Script Executions") are automated tasks that run scripts at predefined intervals or
specific times. They are ideal for performing regular maintenance tasks, data processing, or
other background tasks without manual intervention.
Key Concepts of Scheduled Jobs
1. Definition:
o Scheduled Jobs are server-side scripts that run based on a schedule defined by the
user. They can perform various tasks, such as data cleanup, record updates,
notifications, or external integrations.
2. Accessing Scheduled Jobs:
o You can create and manage Scheduled Jobs by navigating to System Definition >
Scheduled Jobs in ServiceNow. Here, you can define the scripts and set their
schedules.
3. Components of a Scheduled Job:
o Name: A descriptive name to identify the job.
o Active: A checkbox to enable or disable the job. Only active jobs will run
according to their schedule.
o Run As: Specifies the user whose permissions will be applied when the job
executes. This setting controls the access rights of the script.
o Run: Defines the schedule frequency, such as Daily, Weekly, Monthly, or Once.
Custom cron expressions are also available for more specific timing.
o Time: Sets the exact time of execution. For example, if the schedule is Daily, you
can choose the time of day it will run.
o Condition: Defines any additional conditions for the job to run. This can be a filter
or a specific criteria that must be met for the job to execute.
o Script: The actual script logic that the job will execute. This is where you add the
code for the actions you want to automate, such as querying records, updating
fields, or sending notifications.
1️⃣ Scheduled Script Execution
🔹 What is it?
A server-side script that runs at a specific time or interval without requiring user
interaction.
Uses GlideScheduleManager, GlideRecord, and script logic to perform background
tasks.
Commonly used for custom automation that isn't tied to ServiceNow's job framework.
🔹 Where is it stored?
It is stored in the sysauto_script table.
🔹 How is it executed?
Runs automatically at a scheduled time.
Can be manually triggered using:
javascript
CopyEdit
SncTriggerSynchronizer.executeNow(rec);
Executes independently of the Scheduled Job engine.
🔹 Use Cases: ✅ Custom business logic automation
✅ Deleting or updating records at a specific time
✅ Performing database maintenance tasks
✅ Automating external API calls or integrations
2️⃣ Scheduled Jobs
🔹 What is it?
A predefined ServiceNow job that can execute different types of tasks (script execution,
data cleanup, email notifications, etc.).
Configurable through the Scheduled Jobs module (sys_trigger table).
🔹 Where is it stored?
It is stored in the sys_trigger table.
🔹 How is it executed?
Can be configured through System Definition → Scheduled Jobs.
Some jobs execute built-in ServiceNow actions (e.g., SLA processing, event handling).
Can be triggered manually or on a set schedule.
🔹 Use Cases:
✅ Running cleanup scripts at scheduled intervals
✅ Automating email notifications or system maintenance
✅ Processing workflows and business rules
✅ Managing background processes
Update Set
In ServiceNow, an Update Set is a mechanism used to capture and transfer customizations and
configurations between ServiceNow instances. Update Sets are essential for managing changes
in a structured way, making it easier to move changes from development to testing and
production environments. Here’s a detailed overview of what Update Sets are, their purpose,
how they work, and best practices for using them.
Key Features of Update Sets:
1. Change Management: Update Sets allow you to bundle changes (like scripts, forms,
tables, etc.) into a single package, which can be moved and applied to other instances.
This is particularly useful for managing and deploying changes in a controlled manner.
2. Version Control: By using Update Sets, you can keep track of different versions of
customizations and revert to previous versions if necessary.
3. Incremental Changes: Update Sets can be created incrementally, meaning you can add
new changes to an existing Update Set rather than creating a new one every time.
4. Cross-instance Migration: Update Sets facilitate the transfer of changes across different
ServiceNow instances, such as from a development instance to a test or production
instance.
How Update Sets Work:
1. Creating an Update Set:
o Navigate to System Update Sets > Local Update Sets in the application
navigator.
o Click on the New button to create a new Update Set.
o Provide a name and description for the Update Set and set its status to In
Progress.
2. Capturing Changes:
o As you make changes (like modifying a form, adding a business rule, etc.),
ServiceNow automatically captures these changes into the active Update Set.
o You can also manually add existing records to an Update Set by right-clicking on
the record and selecting Add to Update Set.
3. Completing an Update Set:
o Once you have captured all desired changes, you can mark the Update Set as
Complete.
o This prevents any further changes from being added to the Update Set.
4. Exporting an Update Set:
o To move an Update Set to another instance, you need to export it. This creates an
XML file containing all the changes.
o Navigate to the Update Set record and click on Export > XML.
5. Importing an Update Set:
o On the target instance, navigate to System Update Sets > Retrieved Update Sets.
o Click on Import Update Set from XML and upload the exported XML file.
o After importing, you can preview the Update Set to see which changes will be
applied.
6. Applying an Update Set:
o After reviewing the Update Set, you can commit it to apply the changes to the
instance.
Best Practices for Using Update Sets:
1. Limit the Scope: Keep your Update Sets focused on specific changes related to a
particular project or enhancement to make tracking easier.
2. Avoid Conflicts: Be cautious when working with multiple developers or teams; ensure
that they are not modifying the same elements simultaneously, which can lead to
conflicts.
3. Test Before Applying: Always test Update Sets in a sub-production instance before
applying them to production. This helps identify any potential issues.
4. Document Changes: Use the description field to document what changes are included in
the Update Set. This can help during the review process.
5. Regularly Cleanup: Regularly review and clean up Update Sets that are no longer
needed to keep your environment organized.
Changes Tracked by Update Sets
1. Forms and Fields:
o Modifications to existing forms (e.g., adding/removing fields, changing field
types).
o Changes to field properties (e.g., labels, help text, default values).
2. Tables:
o Creation and modification of tables.
o Changes to table relationships (e.g., creating or modifying reference fields).
3. Business Rules:
o Creation and modifications of business rules, including script changes.
4. Client Scripts:
o Changes to client scripts that run on the client side to manipulate form fields.
5. UI Policies:
o Modifications to UI policies, including conditions and actions.
6. Access Control Rules:
Changes Not Tracked by Update Sets
1. Data Records:
o Individual data records (e.g., incidents, problems, changes) are not tracked. Only
schema changes (like new fields or changes to tables) are captured.
2. System Properties:
o Changes made to system properties are not captured by Update Sets. You need to
manually document and transfer those if necessary.
3. Out-of-the-box (OOB) Changes:
o Changes made to out-of-the-box elements in ServiceNow may not be tracked
effectively, especially if they involve modifications that conflict with future
updates.
4. User Roles and Groups:
o Changes to user roles, groups, or permissions are not tracked. These need to be
managed separately.
5. Some Configuration Changes:
o Certain configuration changes, especially those made directly to the platform
settings or configurations that do not have an associated record in the system (like
some UI settings), may not be tracked.
6. Non-Catalog Items:
o Changes made to non-catalog items or custom applications may not be captured in
Update Sets.
7. Attachments and Comments:
o Attachments and comments associated with records are not tracked.
8. Knowledge Base Articles:
o Changes to knowledge base articles and their metadata are not tracked.
Summary
Update Sets are a powerful feature for tracking and transferring specific configuration changes
within ServiceNow, focusing primarily on customizations to tables, forms, scripts, workflows,
and similar elements. However, they do not capture data records, system properties, and various
configuration changes that are essential for the complete migration and management of an
instance. Therefore, it is crucial for administrators to have a clear understanding of what is
tracked and what is not to ensure a smooth development and deployment process.
Backout update set
backout refers to the process of reverting or undoing changes applied through an update
set. It’s a way to roll back an update set's changes if something goes wrong or the changes are
no longer needed.
Backout Process:
A backout can be performed on an update set that is imported but not yet
committed in the target instance.
For example:
o If you import an update set into the test environment and decide not to
commit it, you can back it out there, and the changes will not apply.
o However, once the update set is committed, the backout option is no longer
available.
Environment Independence:
After an update set is committed in a target instance (e.g., Test or Production), it is
treated as a separate process from its source instance (e.g., Development).
Backing out the update set in Development will not roll back changes in Test or
Production because these instances are independent of each other.
Why Backout is Important:
The reasons listed earlier—errors, incorrect deployments, incomplete testing, and
conflicts—are all valid for backing out an update set before committing it in the
target environment. If you realize an issue after committing, you will need to
manually revert the changes or deploy a new update set to undo them.
You are absolutely right that backout refers to reverting or undoing changes made by an update
set. However, my earlier statement that backing out an update set in one instance (e.g.,
Development) does not affect another instance (e.g., Test or Production) still holds true.
Here's the Clarification:
1. Backout Process:
o A backout can be performed on an update set that is imported but not yet
committed in the target instance.
o For example:
If you import an update set into the test environment and decide not to
commit it, you can back it out there, and the changes will not apply.
However, once the update set is committed, the backout option is no longer
available.
2. Environment Independence:
o After an update set is committed in a target instance (e.g., Test or Production), it is
treated as a separate process from its source instance (e.g., Development).
o Backing out the update set in Development will not roll back changes in Test or
Production because these instances are independent of each other.
3. Why Backout is Important:
o The reasons listed earlier—errors, incorrect deployments, incomplete testing, and
conflicts—are all valid for backing out an update set before committing it in the
target environment. If you realize an issue after committing, you will need to
manually revert the changes or deploy a new update set to undo them.
Example to Clarify:
Scenario:
You create an update set in Development and push it to the Test environment.
The update set introduces bugs in the Test environment.
Options in Test Environment:
1. Backout (if not committed yet):
o You can back out the update set before committing, and the changes won't be
applied.
2. Manual Reversion (if committed):
o If you've already committed the update set, backout is no longer an option. You
must either:
Create a new update set to undo the changes.
Manually remove or revert the changes.
Impact on Development Environment:
Backing out or modifying the update set in Development does not undo changes in Test
or Production because they are independent environments.
Plugins
In ServiceNow, plugins are add-on modules that provide additional functionalities, features, or
integrations to enhance the core capabilities of the platform. They are pre-built applications or
components created by ServiceNow that allow you to enable specific functions without
extensive custom development.
Key Aspects of Plugins
1. Purpose: Plugins extend the core functionality of ServiceNow to meet various business
requirements, such as IT Service Management (ITSM), IT Operations Management
(ITOM), IT Asset Management (ITAM), and more.
2. Activation: Most plugins can be enabled directly in the instance, but some may require
specific permissions, licensing, or requests to ServiceNow support. Admin users can
activate plugins from System Definition > Plugins.
3. Scoped Applications: Some plugins are scoped applications, meaning they are contained
in a defined namespace to separate them from the global scope and protect them from
unintentional changes.
4. Dependencies: Certain plugins may have dependencies on other plugins, meaning they
require other plugins to be activated first to function properly.
In ServiceNow, applications like Incident Management, Change Management, Problem
Management, and other ITSM-related modules are often provided as plugins. They are typically
pre-installed in the platform but may require activation, especially if they aren't enabled by
default in your ServiceNow instance.
Key Points about Plugins in ServiceNow
1. Default Plugins: Some plugins come pre-activated, depending on the ServiceNow
edition or version (like Incident Management, change management, problem
management, discovery, orchestration, event management, and Service Catalog in most
ITSM-focused instances).
2. Optional Plugins: Many other applications or advanced features are available as plugins
but need to be activated manually. For instance, if you see a module in the Application
Navigator but can't access it, it's likely because the plugin hasn't been activated.
3. Plugin Activation: You can activate plugins as an admin:
o Navigate to System Definition > Plugins.
o Search for the desired plugin by name (like "Incident Management" or "Change
Management").
o Click on the plugin, and then click Activate/Upgrade.
4. Dependent Plugins: Some plugins have dependencies, meaning activating one might
automatically enable another.
Access Control List
https://www.servicenow.com/docs/bundle/xanadu-platform-security/page/administer/
contextual-security/concept/acl-rule-types.html
Any table > hamburger menu > security rules :- you can see the acls attacted to that table
In ServiceNow, an Access Control List (ACL) is a set of rules that defines what data users can
access and what operations they can perform on that data. The ACL governs security by
controlling user access to tables, fields, and records based on conditions, roles, or scripts.
In ServiceNow, Access Controls (ACLs) can be created or customized by users with the
security_admin role. While users with the admin role have broad access to the system, they
cannot modify or create ACL rules without elevating their privileges to security_admin.
Key Aspects of ACL in ServiceNow:
Security Rules:
ACL rules specify the permissions required to access a resource, such as a table,
record, or field in ServiceNow.
Condition: The criteria that must be met for the rule to apply.
Script: Optional JavaScript that can provide additional logic to control access.
“ACL with operation execute doesn't restrict the user from running business rules or
UI policies or client scripts. It is mainly used for client callable script includes and
Rest endpoint executions”
list_edit : access to update data from list view
Order of Execution:
This processing order ensures that users gain access to more specific objects before gaining
access to more general objects. A user must pass both table and field ACL rules to access a
record object.
If a user fails a table ACL rule, the user is denied access to all fields in the table, even if
the user passes a field ACL rule.
If a user passes a table ACL rule, but fails a field ACL rule, the user cannot access the
field described by the field ACL rule.
Field-level ACL: Controls access to specific fields within a table. For example, a user
may be able to read a record but not be able to see or edit certain sensitive fields.
Example of ACL Rule: Suppose you want only users with the "admin" role to delete
incidents. You would create a rule for the incident table with the operation delete and specify
that only the admin role can perform this operation.
7.
o Changes to access control lists (ACLs) that control record access.
o Access control is a record in the sys_security_acl
o Access control are assigned to roles
o Roles are assigned to groups
o Groups are assigned to users
o Roles can directly be assigned to users but it’s a best practice to assign roles to
groups.
8. Email Notifications:
o Modifications to email notifications, including template changes.
9. Workflows:
o Changes to workflows and associated activities.
10.Script Includes:
o Creation and changes to script includes used for server-side scripting.
11.Scheduled Jobs:
o Modifications to scheduled jobs that automate processes.
12.Business Services:
o Changes related to IT service management, including changes to business services.
Tables
A table is a collection of records in the database. Each record corresponds to a row in a table,
and each field on a record corresponds to a column on that table. Applications use tables and
records to manage data and processes
The table name can only be lowercase and contains underscore.
Tables created by user are prefixed with u (for eg :- u_my_custome_table)
We can also provide roles to a new table that will provide ACL to the created table.
For deleting a table first delete all records of the table. Deleting a table delete all the related
links, acls, references of that table.
Out of box tables cant be deleted like (problem, incident, user, group). Only user created tables
can be deleted
Extended tables :- we can also inherit table in servicenow, there can be a parent table and a
child table (inherited from parent table) , like incident table is inherited (extended ) from task
table.
We can view the schema map of the table to see a map that shows which table is extended or
referenced from the selected table.
In ServiceNow, when a table like the Incident table is extended from a parent table like the
Task table, it inherits all fields from the parent table (Task) but shows only a subset of those
fields by default on the Incident form view. This means:
1. Inherited Fields Are Available: All fields from the Task table are still available in the
Incident table, so you can use or reference these fields in forms, workflows, and scripts.
2. Limited Fields Displayed on the Form by Default: The Incident form shows only the
fields configured specifically for it by default. Fields inherited from the Task table won’t
automatically appear on the Incident form unless you add them manually.
3. Adding Task Fields to Incident Forms:
o You can customize the form view for Incident to include additional fields from the
Task table if needed.
o To do this, go to Form Layout (right-click on the form header and choose
Configure > Form Layout) and add the required fields from the Task table to the
Incident form.
4. Usage in Business Rules, UI Actions, etc.: Even if these fields aren’t visible on the
Incident form, they can still be referenced and used in scripts, business rules, UI actions,
or other parts of ServiceNow for Incident records.
Application studio :-
Only works for scope application not for global application
Delegate Users
In ServiceNow, delegate in a user record refers to assigning another user the ability to act on
behalf of the original user for certain tasks or actions. This is often done when the original user
is unavailable (e.g., on vacation or leave) and someone else needs to manage their
responsibilities temporarily.
When a user delegates their role, the delegate can:
Approve or reject requests.
Receive notifications on their behalf.
Perform tasks like managing incidents, change requests, or service catalog tasks,
depending on the specific permissions given.
LDAP
LDAP is used to authenticate and manage user credentials by connecting to a central directory
service like Active Directory (AD).
Purpose: LDAP integration helps ServiceNow sync users, groups, and roles from
external directory services (such as Microsoft AD) to manage authentication and user
provisioning centrally.
How it works:
o ServiceNow does not store user passwords directly but communicates with the
LDAP server to verify user credentials.
o Users enter their credentials in ServiceNow, which forwards them to the LDAP
server for validation
Key benefits:
Centralized user management: Manage user access from a single directory.
Sync groups and roles: ServiceNow can import groups and roles directly from LDAP
directories.
In an enterprise environment, user data (like usernames, passwords, roles, and other details) is
typically stored in a centralized database or directory service, such as Active Directory (AD)
or another LDAP-compliant directory. Here's how LDAP fits into this process:
1. Data Storage: User information (such as usernames, passwords, departments, roles, etc.)
is stored in an LDAP directory, like Active Directory or other directory services. This
directory serves as a central repository for managing users across the organization.
2. Authentication with LDAP: When a user tries to log in to an application (like
ServiceNow or other enterprise systems), the application uses LDAP to verify the user's
credentials.
o The application sends the username and password to the LDAP server.
o The LDAP server checks the provided credentials against the stored information.
o If the credentials match, the user is authenticated and allowed access to the
application.
3. Authorization: After authentication (i.e., confirming the identity of the user), the
application can also check additional attributes, such as the user’s role, to determine what
resources or actions the user is authorized to access.
4. Enterprise Database for Other Data: While LDAP is primarily used for authentication
and storing user profiles and credentials, other business data (such as records,
transactions, etc.) is typically stored in separate databases or systems (e.g., SQL
databases, NoSQL databases). LDAP handles the user management part.
LOOKUP
Data Lookup in ServiceNow is a feature used to automatically set field values in a record
based on specific conditions. It simplifies the process of populating fields by matching criteria
from one or more fields and using predefined mappings to determine the appropriate value for
another field.
How Data Lookup Works:
Data Lookup rules allow administrators to define which fields should be automatically
populated based on certain conditions. It works by comparing the current record’s data with
predefined rules and then setting the matching values in target fields.
Key Components of Data Lookup:
1. Data Lookup Rule: A rule that defines which field(s) should be evaluated and how the
matching field(s) should be populated.
2. Data Lookup Table: A table that contains mappings between the source fields and target
fields. It stores the reference data used to make decisions about what values should be
populated. This table ends to be extended from Data lookup matcher rule table
3. Condition Fields: The fields that trigger the data lookup action. When conditions on
these fields are met, the rule will apply.
4. Target Fields: The fields that will be automatically populated based on the result of the
data lookup.
1️⃣ Create a Data Lookup Table (or Matcher Table)
This table stores the mapping of conditions and values that will be used to automatically
populate fields.
2️⃣ Create a Data Lookup Definition
Defines the relationship between the source table (where the data comes from) and the
lookup table (where predefined values are stored). Set the matcher field and setter field.
Specifies which fields should be auto-populated when certain conditions are met.
3️⃣ Create Data Lookup Rules
Defines the conditions for when the lookup should be applied.
Maps the input field (triggering field) to the output field (auto-filled field).
No, Data Lookup in ServiceNow cannot be used directly to filter the options available in a
dependent field (like filtering Subcategory based on Category).
Why?
Data Lookup is used to auto-populate fields, not dynamically filter choices.
It can set a single value in a field but cannot dynamically update dropdown options
based on another field's selection.
SLA
SLAs in ServiceNow:
In ServiceNow, SLAs can be attached to records (like Incidents, Problems, Requests, etc.) to
track and enforce timelines. Here's how they work:
1. SLA Definitions: In ServiceNow, you define an SLA through the SLA Definition
module. This includes:
o The type of SLA (SLA, OLA, UC).
o The task table it applies to (e.g., Incident, Request).
o There are 2 targets – response, resolution
o The conditions for when it should start, pause, reset or stop.
o The timeline for response and resolution.
2. SLA Workflow: ServiceNow uses workflows to track SLAs:
o If an incident is created, the SLA clock starts.
o The system monitors the SLA progress.
o If the SLA is breached (not met within the specified time), notifications can be
sent, and escalations can happen.
3. SLA Breach and Escalation: If the service provider fails to meet the SLA, it can trigger
escalations, notifications, or additional actions (such as flagging the issue, reassigning to
higher-priority support teams, or sending reminders).
4. SLA Indicators:
o Breached: Indicates that the SLA commitment has been violated (e.g., the ticket
wasn’t resolved within the given timeframe).
o In Progress: Shows that the SLA is still active and has not been breached yet.
o Met: Shows that the SLA has been successfully completed.
Example in ServiceNow:
An Incident is created for a user’s request, and based on the priority of the incident (like
High Priority), an SLA gets applied to ensure that it will be responded to in 1 hour and
resolved within 4 hours.
The SLA timer starts when the incident is opened.
If the incident isn't resolved within the defined time, the SLA is breached, and an alert is
sent to the manager.
Benefits of SLAs:
Accountability: Ensures service providers are responsible for meeting performance
standards.
Customer Satisfaction: Helps maintain and improve customer trust by ensuring timely
resolution of issues.
Performance Tracking: Provides metrics for monitoring service performance, which
can help in future improvements.
Note :- SLA’s are set to pause when resolved and to stop when closed, because an incident (or
problem or change etc) can go from resolved state to new state again if not resolved properly.
OLA (operational level agreement)
an Operational Level Agreement (OLA) is a type of agreement that defines the internal
service support agreements between different teams or departments within an organization.
These agreements are critical to ensuring that teams collaborate effectively to meet overall
Service Level Agreements (SLAs) committed to end users or customers.
Key Concepts of OLA in ServiceNow
1. Definition:
o An OLA is a documented agreement between internal support teams to ensure they
fulfill their respective responsibilities to achieve SLA compliance.
o Example: A network team agrees to resolve connectivity issues within 2 hours to
support the SLA for incident resolution.
2. Purpose:
o To align internal operations and ensure seamless collaboration between teams.
o To track and measure performance at the team level, enabling accountability.
3. Relation to SLA:
o While SLAs focus on commitments to customers, OLAs focus on commitments
between internal teams to support those SLAs.
o OLAs act as a building block to meet SLA goals.
Catalog Management
Catalog Management involves creating and maintaining a service catalog, which is a
comprehensive list of IT services offered by an organization. It provides users with information
about available services, including how to request them, their features, and associated service
levels.
Catalog Management in IT Service Management (ITSM) refers to the process of creating,
maintaining, and managing a Service Catalog—a centralized repository of all available IT
services offered to users or customers. It is a key component of IT service delivery that helps
streamline service requests, standardize service offerings, and improve user satisfaction.
Key Components of Catalog Management
1. Service Catalog: A structured list of all IT services that an organization offers, often
organized by categories (e.g., hardware, software, network, and support services). Each
service has a detailed description, availability, service level agreements (SLAs), pricing
(if applicable), and dependencies.
2. Service Offerings: Catalog management includes defining the specifics of each service.
This includes scope, description, target audience, fulfillment steps, cost, SLA, and any
dependencies on other services.
3. Approval and Request Processes: Catalog management streamlines how users can
request services, automates approvals, and provides guidance on fulfillment steps,
reducing delays.
4. Service Level Agreements (SLAs): For each service in the catalog, defined SLAs
outline the time frames for request fulfillment and response, setting clear expectations for
service delivery.
5. Cost Management: Some catalogs track associated costs with services, allowing the
organization to charge back departments or understand IT expenses.
Benefits of Catalog Management
Improves Efficiency: Catalog management automates and standardizes service request
processes, reducing manual intervention and speeding up fulfillment times.
Increases Transparency: Provides a clear, accessible overview of all available services,
helping users understand their options.
Enhances User Experience: A well-organized catalog with clear descriptions helps users
quickly find and request the services they need.
Facilitates Self-Service: With an online service catalog, users can request services
directly, without needing to contact IT support.
Example of Catalog Management in Action
A company's IT Service Catalog might include offerings like:
Hardware: Laptop procurement, desktop upgrades, printer setup
Software: Software installation or license requests (e.g., Office 365, Adobe)
Network: VPN setup, access requests for Wi-Fi, or firewall exceptions
User Support: Password resets, troubleshooting, user training sessions
Onboarding/Offboarding Services: Employee account setup or termination processes,
provisioning access to required applications, etc.
When an employee joins the company, they might request a new laptop and specific software
through the service catalog. Catalog management streamlines the request approval, tracks order
fulfillment, and ensures SLAs are met, making the process efficient and transparent for both IT
and the user.
Overall, catalog management simplifies the management and delivery of IT services by
centralizing, organizing, and automating service requests, which supports improved service
quality and customer satisfaction.
Operational Status of cI
Note: CIs that are not discovered for more than 60 days will be set to Retired state.
The meaning behind the values in the Operational Status can be explained as follows:
>> Operational = The CI is currently in use and functioning as expected. This status is used for
CIs that are active and performing their intended roles. Operational CIs may be actively
monitored and managed by ITOM and ITSM processes. Incidents and changes can be related to
these CIs. For example: A server that is currently hosting applications and services for the
organization.
>> Non-Operational = The CI is not currently in use or not functioning correctly. This status is
used for CIs that are either broken, in maintenance, or not required at the moment. These CIs
might be targeted for repair or maintenance work. Incidents and problems can be linked to these
CIs. For example: A server that is down for maintenance or experiencing a hardware failure.
>> Repair in Progress = The CI is currently undergoing repair. This status is used for CIs that
are being actively repaired due to malfunction or failure. During this status, incident
management processes might be involved. Change management might also track the repair
activities. Monitoring and alerting systems may suppress alerts for these CIs. For example: A
server that has experienced a hardware failure and is being repaired by the IT team.
>> DR Standby = The "DR Standby" (Disaster Recovery Standby) operational status for a
Configuration Item (CI) in ServiceNow indicates that the CI is part of a disaster recovery
(DR) plan and is in a standby state, ready to be activated in case of a disaster or failure of the
primary CI. This status is typically used for backup systems, redundant servers, or failover
infrastructure that is not actively in use but is prepared to take over if needed.
>> Ready = The CI is fully configured and ready for use but not yet put into operation. This
status is used for CIs that are fully set up and tested, waiting for deployment or activation. Asset
management might track this status to ensure that resources are available for deployment. ITSM
processes might involve change requests to move the CI to an operational state. For example: A
server that has been installed, configured, and tested but is waiting for a go-live date.
>> Retired = The CI is no longer in use but has not been disposed of. This status is used for CIs
that have been taken out of service but still exist in the inventory. Retired CIs may still have
historical records and data that are valuable for reporting and audits. For example: A server that
has been replaced by a new model but is still stored in a spare parts inventory.
>>Pipieline = The "Pipeline" operational status for a Configuration Item (CI) in ServiceNow
indicates that the CI is in the process of being deployed, configured, or provisioned, but it
is not yet ready for use. This status is typically used for CIs that are in the early stages of their
lifecycle, such as being ordered, built, or configured, but not yet operational.
1. Issues Related to the Deployment Process:
o If there is a problem with the deployment, configuration, or provisioning of the CI
(e.g., delays, errors, or failures), it is appropriate to create an incident to track and
resolve the issue.
o Example: A server in the pipeline is not being deployed on time due to a
configuration error.
Dependencies on the CI:
If other systems, processes, or users are blocked or impacted because the CI in the
pipeline is not yet ready, an incident can be created to address the dependency issue.
Service catalog
There are many tables for service catalog
In ServiceNow (or similar ITSM platforms), the SC (Service Catalog) tables store various
aspects of service catalog requests and items. Here's an overview of what each of these tables
stores:
1. sc_request (Request Table):
o Purpose: Stores high-level information about a service request.
o Contents: Contains the overall details of the service request, such as requester
details, request date, status, and total cost. This is essentially a "parent" record for
multiple catalog items that may be included in a single request.
o Example: When a user submits a request for new hardware (e.g., a laptop and a
monitor), a single entry is created in the sc_request table to represent the request as
a whole.
2. sc_req_item (Requested Item Table):
o Purpose: Tracks each individual item within a service request.
o Contents: Contains detailed information about each catalog item requested,
including item name, cost, quantity, and status. Each request item (e.g., "Laptop"
or "Monitor") within a single sc_request will have its own record in sc_req_item.
o Example: If a user requests a laptop and a monitor, two separate entries are
created in the sc_req_item table—one for the laptop and one for the monitor.
3. sc_cart (Cart Table):
o Purpose: Represents a user's shopping cart before they finalize the request.
o Contents: Holds details of items that a user has added to their cart but has not yet
submitted. It temporarily saves the items and quantities until the user confirms and
submits the request.
o Example: When a user adds a laptop and a monitor to their cart but hasn’t yet
submitted the request, these items are stored in sc_cart.
4. sc_task (Catalog Task Table):
o Purpose: Stores individual tasks associated with fulfilling a service request.
o Contents: Contains information about specific tasks needed to fulfill a request
item, including assigned group, task status, and task details.
o Example: For a "Laptop" request item, sc_task records could include "Procure
laptop," "Install operating system," and "Configure user settings." Each task is
assigned to different teams or users for completion.
5. sc_cat_item (Catalog Item Table):
o Purpose: Stores the definitions and configurations of catalog items that users can
request.
o Contents: Contains catalog item details like item name, description, pricing, and
associated workflows or approval processes. This table acts as the master list of all
available catalog items in the Service Catalog.
1. Order Guide
Description: An Order Guide in ServiceNow allows users to order multiple catalog items
simultaneously as part of a single request.
Purpose: It simplifies complex ordering processes by guiding users through a structured
sequence of questions or choices.
Example: An "Employee Onboarding" order guide could include catalog items like
"Laptop," "Email Account Setup," and "Access Card" in a single guided ordering
process.
2. Record Producers
Description: Record Producers are forms within the Service Catalog that create records
in any table of servicenow through more user friendly form view other than the default
service request tables. We can apply the script logic by taking details from variables to
fill the rest of the details of tha table
Purpose: They help users submit specific types of requests, like incident reports or
service requests, without navigating directly to the target table.
Example: A "New Hire Request" record producer could create a record in the HR case
table, automatically routing it to the appropriate HR team for processing.
3. User Criteria
Description: User Criteria define the visibility and access permissions for Service
Catalog items, categories, and other resources.
Purpose: They control which users can view or order catalog items based on attributes
like role, department, location, or other conditions.
Example: You might create a User Criteria that only allows employees in the "IT"
department to request specific hardware upgrades.
4. Workflow
Description: A Workflow in ServiceNow is an automated process that manages the
sequence of tasks or activities to fulfill a request.
Purpose: Workflows streamline and automate the lifecycle of a service request, including
approvals, task assignments, notifications, and escalations.
Example: A "Laptop Request" workflow could include tasks like manager approval,
inventory check, hardware configuration, and delivery notification.
5. Variable Sets
Description: Variable Sets are collections of variables grouped together for reusability
across multiple catalog items.
Purpose: They help organize related variables (form fields) for different catalog items
and reduce repetitive work by allowing common configurations.
Example: A "Shipping Information" variable set could include variables for address,
contact number, and delivery instructions. This set could be reused across multiple
catalog items that require shipping details
Maintain Items –
has a list of all the catalog items in servicenow
Meta :- meta field in maintain item, can be used to put comma seperated keywords, so that if
the user search any of these keyword your CI will appear.
Annotations :- contains the description or hint that appears when we hover over an element.
Breakdown of Variables and Rule-Based Logic:
1. Variables:
o Purpose: Variables are the actual fields on the form where users enter information.
They can be different types, such as text fields, dropdowns, checkboxes, or date
pickers.
o Examples:
For a "New Hire Request," variables could include fields like Employee
Name, Start Date, Department, and Role.
Custom fields created specifically for catalog items or forms.
They do not exist as columns directly in the main table (e.g., sc_req_item).
Instead, they are stored in a separate table (sc_item_option and sc_item_option_mtom)
and are dynamically linked to the request.
Run the workflow: Workflow(s) start in succession according to the Order column each time an inserted record
matches the condition.
Run if no other workflows matched yet: The workflow starts when a record matches the condition, only if no
other workflows are running on the record.
Run if no other workflows matched yet (Deprecated): The workflow only runs if no other workflows are
running on the execution thread that started this workflow. Avoid using.
Run if no other workflows matched: The workflow only runs if no other workflows are running on a specific
record.
None: The workflow does not start unless it is triggered by a subflow or script.
Inputs
The Inputs section lists all the activities in the current workflow that input data, the data type,
and the default value. The Inputs section is only available after a workflow has been created. To
create a variable, click New.
Field Description
The Input section in workflow properties in ServiceNow defines the data inputs required by
the workflow to execute. These inputs act as parameters that can be dynamically passed to the
workflow at runtime, allowing for customization and reuse across different scenarios.
10.Reusability:
o Inputs allow workflows to be reused across different contexts by simply passing
different data values during execution.
NOTE:-
var readValue = workflow.inputs.variable_name;
workflow.inputs is used in sub-workflows when you call sub-workflow from main workflow
and send some values to sub-workflow.
The statement "The Stages section appears if you select a table with Type = Workflow"
means that the Stages section in the workflow properties will only be visible when you
configure a workflow that is associated with a table explicitly set up for workflow processing.
Here’s a detailed breakdown of what this means:
Example:
Scenario 1:
You are creating a workflow for the Incident table, which is configured as a Workflow table.
The Stages section appears in the workflow properties, allowing you to define stages like:
New
In Progress
Resolved
Closed
Scenario 2:
You are creating a workflow for a custom table that stores static data, not configured as a
Workflow table. The Stages section does not appear because the table is not expected to track
progress or use stages.
No, when a workflow is checked out in ServiceNow, it cannot be used by the system. The
checked-out version is a draft that is only accessible to the user who checked it out. The
system continues to use the published (active) version of the workflow until the checked-
out workflow is published.
If the workflow table is Request Item [sc_req_item], then the stage field is automatically set to
the Stage column of that table and cannot be changed.
Note: If you are creating a workflow with a table other than Request Item [sc_req_item], you
must select a Stage field in the workflow properties for the workflow to have stages.
APPROVAL > GENERATE ACTIVITY
The Generate Workflow Activity in ServiceNow is used to pre-generate tasks or approvals in
a workflow, even though those tasks or approvals are not yet "active" or being executed. Here’s
what that means in simpler terms:
How It Works
1. Workflow Path:
o Place the Generate activity in the workflow path before task or approval
activities.
2. Execution:
o When the workflow reaches the Generate activity, it creates all the subsequent
task and approval records associated with the workflow.
o These tasks and approvals remain inactive but are visible in the system.
3. Activation:
o When the workflow progresses and reaches a task or approval activity, that
specific task or approval becomes active.
Example Use Case
Scenario:
You have a workflow for onboarding a new employee. The onboarding involves:
1. Task 1: Assign a desk (Desk Assignment).
2. Task 2: Set up a laptop (IT Equipment Setup).
3. Task 3: Provide training (Employee Orientation).
Without Generate Activity:
Task 1 is created when the workflow reaches the Desk Assignment step.
Task 2 is created only after Task 1 is completed.
Task 3 is created only after Task 2 is completed.
With Generate Activity:
All three tasks are created as soon as the workflow reaches the Generate activity.
However, only Task 1 is active initially. Task 2 and Task 3 remain inactive.
When Task 1 is completed, Task 2 becomes active. Then Task 3 becomes active after
Task 2 is completed.
Conclusion
The Generate activity is used to create tasks or approvals in advance, but it doesn’t alter their
execution order. This makes workflows more transparent while maintaining control over the
sequence of tasks or approvals.
https://www.servicenow.com/docs/bundle/xanadu-build-workflows/page/administer/workflow-
activities/concept/wf-activity-overview.html
Ending workflows with multiple branches
A workflow is complete when it reaches the End activity, even if there are still active branches
of the workflow in progress. To ensure that both branches are completed, add a Join activity to
resolve the branches.
For example, the following figure shows a workflow with two branches that execute
independently. When Task 1 and Task 2 of Branch B are completed, the workflow is marked
complete even if the Branch A tasks are not completed.
For both branches to complete, add a Join activity to resolve the branches. When one branch
reaches the join, the workflow waits for the other branch. When both branches are complete, the
workflow reaches the end. The Incomplete condition of the a Join activity is met only if one of
the branches cannot be completed.
Week 1-2: Introduction to ServiceNow
1. Introduction to ServiceNow
o Overview of the platform
o ServiceNow interface, navigation, and modules
o Understanding ITIL and ITSM fundamentals
2. ServiceNow Overview & Core Features
o Tables and records
o Forms, lists, and UI actions
o ServiceNow Application Navigator
Resources:
ServiceNow docs: "Getting Started"
ITIL/ITSM basics on YouTube or Udemy
Week 3-4: Basic Configuration & Administration
1. User Administration
o Roles, groups, and users
o Access controls (ACLs)
2. Form and List Layouts
o Modifying forms and lists
o Dictionary entries, form designer, list layouts
3. ServiceNow Studio
o Installing and using ServiceNow Studio for app development
Resources:
ServiceNow Admin Fundamentals training
Community discussions and tutorials
Week 5-6: Scripting & Business Logic
1. Introduction to Scripting in ServiceNow
o Client-side vs. server-side scripting
o GlideForm, GlideRecord APIs
2. Client Scripts & UI Policies
o Writing basic client-side scripts (onChange, onLoad, onSubmit)
o UI policies, data policies
3. Business Rules & Script Includes
o Writing business rules for server-side logic
o Understanding script includes for reusable code
Resources:
ServiceNow scripting documentation
ServiceNow Developer YouTube channel
Week 7-8: Workflow & Automation
1. Workflows & Flow Designer
o Understanding workflow editor
o Building workflows, stages, and activities
o Introduction to Flow Designer (codeless automation)
2. Notifications
o Email notifications and templates
o Triggers, conditions, and events
3. Service Catalog
o Creating catalog items, record producers, and variables
Resources:
ServiceNow Developer training on workflows
Flow Designer documentation
Week 9-10: Integration & REST APIs
1. Integration Basics
o IntegrationHub and REST API fundamentals
o Creating REST API connections
2. Inbound and Outbound REST APIs
o Working with REST API Explorer
o Scripted REST APIs, transforming data
3. ServiceNow Integration Best Practices
o Integrating with third-party systems
Resources:
ServiceNow IntegrationHub documentation
REST API tutorials
Week 11: Advanced Topics
1. Custom Applications Development
o Building custom applications using ServiceNow Studio
o Working with scoped applications
2. Service Portal Development
o Creating custom pages, widgets, and themes
o Portal best practices
Resources:
Custom Application Development (CAD) documentation
ServiceNow Portal training
Week 12: Practice & Certification Preparation
1. Real-World Projects
o Develop a mini project involving workflows, custom apps, and catalog items
o Automating business processes (use Flow Designer)
2. ServiceNow Certification
o ServiceNow Certified System Administrator (CSA) exam preparation
o Go through exam guides and sample questions
Resources:
ServiceNow Developer Program (free resources)
Certification blueprint
Metrics
Metric_definition :- contains the metric definition for the data.
Metric_instance :- Instance stores the actual result calculated by metric definition.
a Metric is a way to measure and track the performance, trends, or changes of records over
time. It provides valuable insights into how processes, incidents, tasks, or other records evolve,
enabling organizations to monitor and improve their workflows effectively.
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.
A metric can often be easily obtained from the data. To find the number of incidents created
today, a report counts the number of incidents in the incident table with a Created date of today.
However, metrics must be gathered as data is updated. For example, determining how long an
incident was assigned to a certain group requires collecting information about assignment
changes and calculating the duration of each assignment.
The Metric plugin provides an easy, declarative way of defining metrics. Once defined, the data
for the metric is gathered, and instances of the metric are calculated and stored. For example,
the "Assigned to Duration" metric measures the amount of time an incident is assigned to an
individual. To define this metric, you create a metric definition of the type "Field value
duration" and select the "Assigned to" field from the Incident table. A metric instance is created
for each incident assignment showing its duration. Reporting on the duration of incident
assignments becomes easy.
Field value duration: This type of metric measures the duration of time from when the
value of the specified field is set until it’s changed. A Field value duration metric can
optionally specify a script. The script can either return a duration value or set the answer
variable to false to stop processing the metric. For example, the baseline incident metrics
stop calculating duration when the Active field of an incident is set to false. The script
can also carry out any other action such as closing the duration of other metrics defined
on the same record. For more information, see Sample field value duration script.
Script calculation: This type of metric creates a metric instance using a script. The script
has access to the current row in the table (for example an incident) and the metric
definition. The script must perform metric calculations and insert data into the
metric_instance table. The calculation doesn’t have to result in a duration. It can calculate
any type of value and store it in the metric instance value.
Comparison Table
function createMetric() {
var mi = new MetricInstance(definition, current);
if (mi.metricExists())
return;
var gr = mi.getNewRecord();
gr.start = current.sys_created_on;
gr.end = current.sys_updated_on;
gr.duration = gs.dateDiff(gr.start.getDisplayValue(), gr.end.getDisplayValue());
gr.calculation_complete = true;
gr.insert();
}
Summary of Workflow:
1. Check if the incident_state meets the condition (>= 6).
2. Instantiate MetricInstance with the provided definition and current.
3. Avoid duplicate metrics by verifying with metricExists().
4. Create and populate a new metric record with start, end, and duration values.
5. Save the metric record for further analysis and reporting.
2. Code Explanation
Variables Available:
current: A GlideRecord object representing the current incident record.
definition: A GlideRecord object representing the metric definition.
Code Breakdown:
1. Fetch Incident State:
var s = current.incident_state;
if (s >= 6)
createMetric();
o This retrieves the incident_state of the current record.
o If the incident_state is 6 or greater (typically indicating a resolved or closed state),
the createMetric() function is executed.
2. Function: createMetric:
function createMetric() {
o This function handles the creation of the metric instance based on the provided
definition and current record.
3. Instantiate MetricInstance:
var mi = new MetricInstance(definition, current);
o Creates an instance of the MetricInstance script include.
o Purpose: Manages metric calculations and records.
o Parameters:
definition: Specifies the metric's configuration.
current: Specifies the target record (in this case, an incident).
4. Check if Metric Exists:
if (mi.metricExists())
return;
o The metricExists() method checks if a metric has already been created for this
definition and record.
o If the metric exists, the function exits early.
5. Create a New Metric Record:
var gr = mi.getNewRecord();
o The getNewRecord() method generates a new metric instance record in the system.
6. Set Metric Details:
gr.start = current.sys_created_on;
gr.end = current.sys_updated_on;
gr.duration = gs.dateDiff(gr.start.getDisplayValue(), gr.end.getDisplayValue());
gr.calculation_complete = true;
o gr.start: Set to the record's creation time (sys_created_on).
o gr.end: Set to the record's last updated time (sys_updated_on).
o gr.duration: Calculates the time difference between start and end using the
gs.dateDiff method, likely in seconds or minutes.
o gr.calculation_complete: Marks the metric as fully calculated.
7. Insert Metric Record:
gr.insert();
o Saves the new metric record to the database.
A related list in ServiceNow is a feature that displays a list of records from one table that are
related to the current record being viewed in another table. It provides a way to view and
manage relationships between different tables directly from the form view of a record.
Example Workflow
Let’s consider an example where you need to import employee data from a MySQL database:
1. Setup the Data Source:
o Name: Employee Data Import
o Server: 192.168.1.100
o Database Name: company_db
o Username: admin_user
o Password: secure_password
o Port: 3306
o Query: SELECT id, name, email, department FROM employees
2. Test the Connection:
o ServiceNow attempts to connect to the database using the provided credentials and
server details.
o If the connection succeeds, the data source is ready for use.
3. Run the Data Import:
o Execute the import to fetch data from the external database and store it in an
Import Set Table in ServiceNow.
4. Map and Transform Data:
o Use a Transform Map to map fields like id, name, email, and department from the
Import Set Table to the target ServiceNow table (e.g., cmn_users).
5. Insert Data into the Target Table:
o After transformation, the data is inserted into the target table.
schedule imports
you can schedule imports in ServiceNow! This is a powerful feature that allows you to
automate the process of importing data from external sources at regular intervals, ensuring that
your data remains up-to-date.
The Customer Experience feature in Field Service Management provides customers with timely
updates about their reported issues, enabling them to track the location of agents and provide
agent feedback.
Key Concepts in FSM
1. Work Orders
o A work order represents a task or service that needs to be performed, often
initiated from customer issues, equipment failures, or scheduled maintenance.
o Work orders include details like:
Customer information.
Task description.
Service location.
Technician assignment.
Priority level.
o Work orders are broken into Work Order Tasks (WOTs), which are smaller units
of work.
2. Work Order Lifecycle
o Created: A work order is generated, either manually or from a service request or
case.
o Assigned: The dispatcher assigns it to a technician based on skills, availability, and
location.
o Scheduled: The work is scheduled, and notifications are sent.
o In Progress: The technician is actively working on the task.
o Completed: The task is marked as complete, and reports are updated.
o Closed: The work order is closed after validation or customer feedback.
3. Service Locations
o Locations where the service will be performed. These can include customer sites,
warehouses, or offices.
4. Assets
o Assets represent the equipment or items that require servicing.
o Assets are linked to customers, locations, or both.
o Technicians use asset details to understand the history, configurations, and
previous issues.
5. SLA (Service Level Agreements)
o Defines the expected timeframes for resolving issues or completing tasks.
o Ensures compliance with service agreements between customers and the
organization.
FSM Workflow
1. Initiation
A case is created through Customer Service Management (CSM), a service request, or
a direct input from a customer.
For internal maintenance, requests can be initiated by employees or system alerts.
2. Qualification
A Qualifier reviews the case:
o Checks service coverage (e.g., warranty or SLA).
o Ensures all necessary details are captured (e.g., location, customer, issue
description).
o Confirms that the issue is ready for escalation to field service.
3. Dispatching
Dispatchers use tools like the Dispatcher Workspace to:
o Assign work orders to the most suitable technician.
o Optimize scheduling and routing to reduce travel time.
o Prioritize tasks based on urgency and SLA compliance.
4. Execution
Technicians receive work orders via the Mobile App.
o Access task details, service history, and customer information.
o Use checklists or instructions for standard processes.
o Record work details, including parts used or issues encountered.
Updates are sent in real-time to the FSM system.
5. Completion
Technicians mark tasks as complete, providing detailed reports and obtaining customer
sign-off if needed.
6. Validation and Closure
Supervisors or agents review completed work orders for accuracy and quality before
closing them.
ing
1. List Reports
Description: Display records in a tabular format, similar to a grid view.
Use Case: Ideal for simple data display, sorting, and exporting to Excel or PDF.
Commonly used for task tracking or user lists.
How to Use:
1. Go to Reports > Create New > List.
2. Select the table and define the columns to display.
3. Apply filters to refine the data.
4. Save and share/export the report.
2. Bar Charts
Description: Represent data using vertical or horizontal bars.
Use Case: Useful for comparing data across categories, such as the number of incidents
by priority or department.
How to Use:
1. Go to Reports > Create New > Bar Chart.
2. Choose the table and group data by a specific field.
3. Configure the X-axis and Y-axis to represent data appropriately.
4. Customize the chart appearance (e.g., colors, labels).
3. Pie Charts
Description: Display data as slices of a pie, representing proportions.
Use Case: Best for showing percentages or distributions, such as incident resolution
states.
How to Use:
1. Go to Reports > Create New > Pie Chart.
2. Select the table and grouping field.
3. Define the conditions and labels.
4. Save the chart and add it to a dashboard if needed.
4. Line Charts
Description: Use lines to show trends over time.
Use Case: Great for tracking metrics like incident counts, SLA breaches, or system
performance over days, weeks, or months.
How to Use:
1. Go to Reports > Create New > Line Chart.
2. Define the table and time-related grouping field (e.g., "Created on").
3. Customize the time intervals and data points.
4. Save and analyze the report for trend insights.
5. Column Charts
Description: Similar to bar charts but display data in vertical columns.
Use Case: Compare multiple categories or fields, such as open incidents per user group.
How to Use:
1. Go to Reports > Create New > Column Chart.
2. Define the X-axis categories and Y-axis data points.
3. Configure grouping and color-coding options for better visualization.
6. Heatmaps
Description: Visualize data density or frequency using color intensity.
Use Case: Helpful for analyzing resource utilization, ticket distribution, or time-based
patterns.
How to Use:
1. Go to Reports > Create New > Heatmap.
2. Select the data set and the criteria for the heatmap.
3. Configure color gradients to represent values.
7. Pivot Tables
Description: Create matrix-style reports for multi-dimensional data analysis.
Use Case: Useful for summarizing large datasets, such as incident counts by priority and
assignment group.
How to Use:
1. Go to Reports > Create New > Pivot Table.
2. Define rows and columns based on fields to be analyzed.
3. Add aggregations (e.g., count, sum) to summarize data.
8. Maps
Description: Plot geographic data on a map.
Use Case: Useful for visualizing location-based data, such as incident hotspots or assets
by location.
How to Use:
1. Go to Reports > Create New > Map.
2. Use location-related fields (e.g., city or latitude/longitude).
3. Configure map settings to display markers or regions.
9. Donut Charts
Description: A circular chart similar to a pie chart but with a central hole.
Use Case: Provides a visually distinct way to show proportions or distributions.
How to Use:
1. Go to Reports > Create New > Donut Chart.
2. Define the data set and grouping field.
3. Save and use in dashboards for visual appeal.
Examples of CIs:
1. Hardware:
Physical devices used in IT infrastructure.
o Servers, desktops, laptops.
o Network devices (routers, switches, firewalls).
o Storage devices (SAN, NAS).
o Mobile devices (smartphones, tablets).
2. Software:
Applications or systems.
o Operating systems (e.g., Windows, Linux).
o Databases (e.g., MySQL, MongoDB).
o Middleware (e.g., Apache Tomcat).
o Business applications (e.g., CRM, ERP).
3. Services:
Logical entities that deliver value to users or customers.
o IT services (e.g., email service, web hosting, database as a service).
o Business services (e.g., payroll, e-commerce platform).
o Cloud services (e.g., AWS Lambda, Azure Functions).
4. Other Components:
Anything that needs to be tracked for IT management.
o Documentation (e.g., policies, SLAs).
o Virtual resources (e.g., VMs, containers).
o Licenses (e.g., software licenses).
o Network configurations (e.g., VPNs).
cmdb Table
Purpose:
The cmdb table is the base table in the CMDB hierarchy.
It contains generic attributes shared across all records in the CMDB, including
Configuration Items (CIs) and other entities.
Attributes:
Stores attributes common to all CMDB records, such as:
o sys_id (unique identifier).
o created_on (record creation timestamp).
o updated_on (last update timestamp).
Scope:
Broadest table in the CMDB structure.
Includes all records, whether they are CIs or not.
Key Usage:
Provides a foundation for extending specialized tables like cmdb_ci.
Facilitates uniformity across all CMDB records.
cmdb_ci Table
Purpose:
The cmdb_ci table is a specialized child table of cmdb designed specifically for
Configuration Items (CIs).
It acts as the parent table for all CI-related tables (e.g., servers, applications, network
devices).
Attributes:
Stores attributes common to all CIs, such as:
o name
o manufacturer
o model
o operational_status
Scope:
Focused only on Configuration Items (CIs).
Further extended by tables like cmdb_ci_server and cmdb_ci_application for more
specialized CI types.
Key Usage:
Defines common properties of CIs.
Serves as the base for more specific CI types.
4. Key Advantages
Scalability:
o Adding new CI types requires only extending the appropriate table.
Efficiency:
o Common attributes are centralized, while specialized attributes are isolated.
Flexibility:
o CIs and their relationships are easily extensible to fit unique organizational needs.
2. Compliance
Definition: Ensures that the CIs meet governance and policy standards, such as naming
conventions, field formats, and supported versions.
Checks:
o Are naming conventions followed (e.g., server names must follow a specific
pattern)?
o Are software versions compliant with organizational standards?
Examples of Issues:
o CIs that don’t comply with naming standards.
o CIs with unsupported or outdated software versions.
How to Improve:
o Implement CMDB Governance Policies to standardize CI data.
o Use Data Certification to ensure compliance with predefined rules.
3. Correctness
Definition: Ensures the data in the CMDB is accurate and reflects the current state of the
IT environment.
Checks:
o Are CI attributes (e.g., IP address, status) accurate?
o Are there duplicate or stale CIs?
Examples of Issues:
o Incorrect IP address or status (e.g., a CI marked as "active" but decommissioned).
o Duplicate or outdated (stale) CIs.
How to Improve:
o Use Discovery to update the CMDB regularly.
o Deduplicate records using Identification and Reconciliation Rules.
1. Orphan CI
An Orphan CI (Configuration Item) is a CI in the CMDB that lacks valid relationships with
other CIs.
Characteristics:
It does not have parent or child relationships defined.
It is "isolated" within the CMDB, which makes it difficult to understand its role in the IT
infrastructure.
Orphan CIs typically indicate a lack of proper dependency mapping or missing
relationships.
Why It's a Problem:
Without relationships, an orphan CI cannot contribute to service mapping or impact
analysis.
It reduces the effectiveness of incident management, change management, and
disaster recovery processes because its dependencies and impacts are unclear.
Example:
A server that is listed in the CMDB but has no relationships defined with applications or
services running on it.
Resolution:
Use tools like Service Mapping or Discovery to identify and establish accurate
relationships for orphan CIs.
Regularly review and update dependency mappings.
2. Stale CI
A Stale CI is a CI in the CMDB that has not been updated within a defined timeframe,
indicating that it may no longer be accurate or relevant.
Characteristics:
The last update timestamp is older than the configured threshold (e.g., 90 days or
more).
It may represent an asset that has been decommissioned, replaced, or changed without
the CMDB being updated.
Why It's a Problem:
Stale CIs introduce data inaccuracies into the CMDB.
They can lead to incorrect impact analysis, inefficient resource allocation, and challenges
in compliance reporting.
Stale data makes it difficult to trust the CMDB for decision-making.
Example:
A network device that was replaced three months ago but still exists in the CMDB with
outdated details.
Resolution:
Use Discovery, Event Management, or other data sources to regularly update the
CMDB.
Establish thresholds for stale data and monitor them through the CMDB Health
Dashboard.
Implement processes to retire or archive outdated CIs.
Advanced Condition
Use a server-side script to evaluate conditions that cannot be created using the Condition field.
The script has access to two global variables:
current: The target table record associated with the notification (All notifications).
event: The event object that triggered the notification (only available for notifications
sent when Event is fired).
The script must set the answer variable to either true or false. If there is no script, the field
returns true. Both the Condition and Advanced Condition fields must return true for the
notification to be sent.
The demo script shown compares the month and day of the Occasion date to today to see if it
matches today's date. The script also checks that the occasion is a Work Anniversary.
Note :- we can define the script for notification in the “notification email script” module and
can call this script in our notification by adding this “$
{mail_script:CountOverdueNeedItTasksAssignedTo}”” in the “what it will contain” section.
Notifications that have the same target table and recipients are considered duplicates if the
weights are different. If weights are same, an additional evaluation is done to check if the
subject and the body (excluding watermark) are same to qualify as duplicate notification. When
there are duplicate notifications, the system only sends the notification with the highest weight.
All other notifications are moved from the Outbox to the Skipped mailbox. The default value 0
causes the system to send the notification (assuming the conditions are met).
For example, suppose that a service desk agent adds a comment to an incident and shortly
thereafter closes it. By default, these actions trigger both the Incident commented and Incident
Closed notifications.
However, both notifications are from the Incident table and also notify the incident caller. The
system only sends the notification with the highest weight, which in this case is the Incident
Closed notification.
Note: The SMTP Sender scheduled job determines how often to send email. By default, this job
runs every minute.
Inbound email
https://developer.servicenow.com/dev.do#!/learn/learning-plans/xanadu/
servicenow_administrator/app_store_learnv2_automatingapps_xanadu_inbound_email_actions
Watermark
In simple terms, a watermark in the context of ServiceNow and email communication is a
unique identifier embedded in an email's subject line or body. It acts as a tag that links the
email to a specific record (like an incident or task) in the ServiceNow system.
In Summary
A watermark is:
A unique reference code automatically embedded in emails.
Used by ServiceNow to track and link email replies to specific records.
Essential for automating and streamlining email-based communication workflows
NOTE: By default, inbound emails of the Forward type always generate new incidents
regardless of the presence of a watermark. If this behavior does not match desired business
logic, change the recognized reply and forward prefixes to treat forwards like replies.
Type: Available types are:
New: An email that is not recognized as a reply or forward.
Reply: An email with a watermark, with an In-Reply-To email header, or whose subject
line begins with a recognized reply prefix.
Forward: An email whose subject line begins with a recognized forward prefix, even if
the email also contains a watermark or In-Reply-To header.
The function provided is a typical template for an email action script in ServiceNow, allowing
custom logic to be executed when handling inbound or outbound emails. Here’s a detailed
explanation of each parameter:
1. current:
Type: GlideRecord
Description: Represents the record in the target table that is associated with the email
action.
Purpose:
o You can use it to interact with the associated record.
o For example, if the email is linked to an incident, current would point to the
specific incident record.
The function provided is a typical template for an email action script in ServiceNow, allowing
custom logic to be executed when handling inbound or outbound emails. Here’s a detailed
explanation of each parameter:
1. current:
Type: GlideRecord
Description: Represents the record in the target table that is associated with the email
action.
Purpose:
o You can use it to interact with the associated record.
o For example, if the email is linked to an incident, current would point to the
specific incident record.
Example:
javascript
Copy code
if (current.isValidRecord()) {
current.comments = "Email received and processed.";
current.update();
}
2. event:
Type: GlideRecord
Description: Represents the event that triggered the email action, if applicable.
Purpose:
o Provides context about the triggering event, allowing the script to perform actions
based on event details.
o
3. email:
Type: EmailWrapper
Description: Encapsulates the details of the email being processed.
Purpose:
o Provides access to email content, headers, attachments, etc.
o Useful for extracting information from inbound emails.
Key Properties:
email.subject: The subject line of the email.
email.body_text: The plain-text body of the email.
email.body_html: The HTML body of the email (if available).
email.to: The "To" recipients.
email.from: The sender's email address.
email.attachments: Access to email attachments.
4. logger:
Type: ScopedEmailLogger
Description: Provides logging capabilities specific to the email action.
Purpose:
o Allows logging of messages to facilitate debugging or tracking email processing.
o Log messages appear in the System Logs (System Logs > Email Logs).
Example:
logger.debug("Processing email for record: " + current.number);
logger.error("An error occurred while handling email: " + email.subject);
5. classifier:
Type: EmailClassifier
Description: Contains classification information for the email.
Purpose:
o Provides details about how the system classified the email, such as whether it’s a
reply, forward, or a new message.
o Allows custom handling based on the classification.
Key Properties:
classifier.type: The type of email action (e.g., reply, forward, or new).
classifier.watermark: The watermark extracted from the email (if applicable).
GlideSysAttachment API
The GlideSysAttachment API in ServiceNow allows you to programmatically manage file
attachments in your instance. It provides methods to upload, download, delete, and manipulate
attachments associated with records.
Methods in GlideSysAttachment
1. write(tableName, recordSysId, fileName, fileContent)
Uploads an attachment to a record.
Parameters:
o tableName (string): The name of the table (e.g., "incident").
o recordSysId (string): The sys_id of the record.
o fileName (string): The name of the file.
o fileContent (string): The Base64-encoded content of the file.
Returns: The sys_id of the created attachment record.
2. read(tableName, recordSysId, fileName)
Retrieves the content of a specific attachment.
Parameters:
o tableName (string): The name of the table.
o recordSysId (string): The sys_id of the record.
o fileName (string): The name of the file to read.
3. getAttachments(recordTableName, recordSysId)
Retrieves all attachments associated with a record.
Parameters:
o recordTableName (string): The name of the table.
o recordSysId (string): The sys_id of the record.
Returns: A GlideRecord object containing the attachments.
4. deleteAttachment(sysId)
Deletes a specific attachment by its sys_id.
Parameters:
o sysId (string): The sys_id of the attachment to delete.
Explanation of SLA Repair in ServiceNow
The SLA Repair functionality in ServiceNow is designed to correct SLA records to ensure
their timing and duration information is accurate. This feature is particularly useful when
system anomalies or configuration changes lead to incorrect SLA data. Below is an explanation
of its purpose, usage, and considerations:
Key.album.images[0].url
Key.artists[0].name
Key.name
Key.external_urls
// input = JSON.parse(input);
// console.log("input",input);
// try {
// var r = new sn_ws.RESTMessageV2('spotify', 'search');
// r.setQueryParameter('q', input.userInput );
// var response = r.execute();
// var responseBody = response.getBody();
// responseBody = JSON.parse(responseBody);
// data.result = responseBody;
// console.log(data.result);
// }
// catch (ex) {
// var message = ex.message;
// gs.error('Error: ' + message);
// }
function createRequest(record) {
var id = GlideGuid.generate(null);
var cart = new Cart(id);
var item = cart.addItem('6c82faddc3bb5210807fb7ddd401313b');
var rc = cart.placeOrder();
while (gr.next()) {
if (!gr.u_name || !gr.u_start_date) {
gs.info("Missing fields");
continue;
}
if (gu.get(gr.u_name)) {
var ritm = new GlideRecord('sc_req_item');
ritm.addQuery('requested_for', gr.u_name);
ritm.addQuery('cat_item', '6c82faddc3bb5210807fb7ddd401313b');
ritm.query();
if (!ritm.next()) {
var requestID = createRequest(gr);
var newRitm = new GlideRecord('sc_req_item');
newRitm.addQuery('request', requestID);
newRitm.query();
if(newRitm.next()){
gs.info("founded");
}
} else {
gs.info("RITM already created for: " + gu.name);
}
} else {
var incidentGR = new GlideRecord('incident');
incidentGR.initialize();
incidentGR.short_description = 'User not found: ' + gr.u_name;
incidentGR.caller_id = '6816f79cc0a8016401c5a33be04be441'; // System admin
var incID = incidentGR.insert();
gs.info("Incident created for: ");
}
} else {
gs.info("Start date is in the past");
continue;
}
}
var gr = new GlideRecord('u_employee_data_import_set');
gr.query();
while (gr.next()) {
if (!gr.u_name || !gr.u_start_date) {
gs.info("Missing fields");
continue;
}
if (gu.get(gr.u_name)) {
var ritm = new GlideRecord('sc_req_item');
ritm.addQuery('requested_for', gr.u_name);
ritm.addQuery('cat_item', '6c82faddc3bb5210807fb7ddd401313b');
ritm.query();
if (!ritm.next()) {
// var requestID = createRequest(gr);
var newRitm = new GlideRecord('sc_req_item');
newRitm.initialize();
newRitm.requested_for = gr.getValue('u_name');
newRitm.cat_item = '6c82faddc3bb5210807fb7ddd401313b';
var id = newRitm.insert();
gs.info("created : " + id.number);
} else {
gs.info("RITM already created for: " + gu.name);
}
} else {
var incidentGR = new GlideRecord('incident');
incidentGR.initialize();
incidentGR.short_description = 'User not found: ' + gr.u_name;
incidentGR.caller_id = '6816f79cc0a8016401c5a33be04be441'; // System admin
var incID = incidentGR.insert();
gs.info("Incident created for: ");
}
} else {
gs.info("Start date is in the past");
continue;
}
}