0% found this document useful (0 votes)
40 views3 pages

8 ASSIGNMENT GlideRecord

servicenow practice assignment

Uploaded by

Shiva Gopi
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
40 views3 pages

8 ASSIGNMENT GlideRecord

servicenow practice assignment

Uploaded by

Shiva Gopi
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 3

ASSIGNMENT 8.

0:
GlideRecord

Here we will perform CRUD operations (create,read,update,delete) with help of GlideRecord .


Execute it in background script to see the results

GlideRecord docs

TASK 8.1 Read:

1. Query incident table and display incident number,caller name,priority,state,short


description where category is Software in below format
Example:-

Incident :INC0000055
caller:Carol Coughlin
priority: 1 - Critical
State:In Progress
Short description: SAP Sales app is not accessible

Incident :INC0000016
caller:Bow Ruggeri
priority: 1 - Critical
State:In Progress
Short description: Can't launch 64-bit Windows 7

2. Display 10 incidents(number,caller,category) which were created between 1 january 2022 and 1


march 2023 and category is hardware . HINT: use LIMIT function

3. Create an incident manually in the system and display that incident number,caller,short
description same as in above format.
4. Display incidents(number,caller,category) which were opened in the last 6 months. NOTE:- last 6
months is not equal to 180 days .Print the number of records at the end
5. Query change table(change_request) and display change number,Requested
By,category,type,short description where change type is Normal in below format.

Change : CHG0040007
Requested By:Carol Coughlin
category: server reboot
Type : Normal
Short description: Please reboot ApplicationServerPeopleSoft

6. Query change table(change_request) and display (change number,Requested


By,category,type,risk) where change type is emergency OR normal AND category is Network OR
Hardware and also print the number of records .
Use the above given format from the previous question.
TASK 8.2 Create:

1. Create a new record via script on cmdb_ci_hardware that is hardware table. Inputs will
be as follows :-

NAME: Router
ASSIGNED TO: Abel Tuter
INSTALL STATUS: On Order
INSTALLED: 2024-03-12 11:05:34

2. Create an incident via background script with below information:

CALLER: Abel Tuter


SHORT DESCRIPTION: server is down
IMPACT : High
URGENCY: Medium
CATEGORY: Network

In the same script once you created the incident ,create another incident with below
information:

CALLER: Joe Employee


SHORT DESCRIPTION: server is down
IMPACT : High
URGENCY: Medium
CATEGORY: Network
PARENT INCIDENT: <incident created above by abel tuter>

HINT:- gr.insert returns sys_id of the incident. Store and use this as a parent for the next
incident.
TASK 8.3 Update:

1. Update the hardware record “router” created in 8.2.1 above. With help of background
script update the incident to category= Network ,install status = Installed
2. Update all the incidents where category = Hardware AND priority = 5 - Planning.
set impact = High and Urgency = Medium .Also copy the short description to description
of the incident .
3. Update all the incidents created last year AND category=hardware OR category=
software . set the state to closed and assignment group to Service Desk.
4. In the previous question 8.2.2 where parent incident is linked to child incident. Update
the parent incident service as Email and update the child incident service as Email also.
5. Query the cmdb_ci_server table and update all the CIs where class = windows server
OR class = Linux server AND status = installed AND created last year. You have to
update the status to retired for all those CIs.

TASK 8.4 Delete:

1. Delete the hardware asset created from 8.2.1 via background script.
2. Delete All the servers from cmdb_ci_server where the manufacturer starts with dell OR
contains microsoft AND created after 31 dec 2019. Display the count of deleted records.
3. Delete the child incident from 8.2.2 as well as the parent incident record in one script
execution
4. Delete all change requests where Type= normal OR type = emergency AND created
before 3 months from now.

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy