ServiceNow CAD Practice Test Questions and Exam Dumps Part15 Q281-300

View Full ServiceNow CAD Exam Dumps and Practice Test Dumps.

 

Question 281

Which ServiceNow feature is used to restrict the records displayed in a reference field based on specific conditions?

  1. Data Policy
  2. Reference Qualifier
  3. UI Action
  4. Transform Map

Correct Answer: 2

Explanation

A Reference Qualifier is used to filter the records that users can select from a reference field. It can apply conditions based on values in the current record, related records, or other dynamic information. Reference Qualifiers are useful when only a subset of records should be presented to users. For example, a reference field could be configured to display only active users or groups belonging to a particular department. Qualifiers can be simple or scripted depending on the requirement. They improve usability and data quality, but they should not be considered a replacement for ACLs because they primarily control record selection rather than security.

Question 282

Which object is commonly used to create a new GlideRecord without immediately retrieving an existing record?

  1. initialize()
  2. query()
  3. next()
  4. get()

Correct Answer: 1

Explanation

The initialize() method prepares a GlideRecord object for creating a new database record. After initializing the object, developers can assign values to the appropriate fields and then call insert() to create the record. For example, a script can create a GlideRecord for a target table, call initialize(), set fields such as short description and assignment group, and finally call insert(). The query() method retrieves records, next() moves through query results, and get() retrieves a specific record. Using initialize() is therefore an important part of the standard GlideRecord record-creation pattern.

Question 283

Which type of Business Rule is designed to make server-side information available when a form is being displayed?

  1. Before
  2. After
  3. Display
  4. Async

Correct Answer: 3

Explanation

A Display Business Rule executes when a record is being prepared for display to the user. One common use is to place server-side information into the g_scratchpad object so that client-side scripts can access it when the form loads. This can be useful when client-side behavior depends on information that must be obtained from the server. Before Business Rules run before database operations, After Business Rules execute after the database operation, and Async Business Rules run asynchronously. Display Business Rules should be used specifically for display-time server-to-client data transfer rather than routine record updates.

Question 284

Which ServiceNow component is used to define reusable automation logic that can be invoked by Flow Designer?

  1. Business Rule
  2. UI Policy
  3. Custom Action
  4. Dictionary Entry

Correct Answer: 3

Explanation

A Custom Action in Flow Designer allows developers to create reusable automation logic that can be used within flows and other automation. Custom Actions can accept inputs, perform operations, and return outputs that subsequent flow steps can use. They are especially useful when standard Flow Designer actions do not provide the required functionality. A Business Rule is triggered by database operations, a UI Policy controls form behavior, and a Dictionary Entry defines field metadata. Custom Actions therefore provide an extensible way to add application-specific capabilities to Flow Designer while keeping automation logic organized and reusable.

Question 285

Which method can be used to delete the record currently represented by a GlideRecord object?

  1. remove()
  2. deleteRecord()
  3. erase()
  4. delete()

Correct Answer: 2

Explanation

The GlideRecord deleteRecord() method is used to delete the record currently represented by a GlideRecord object. A script generally retrieves or queries a record, confirms that the appropriate record is being processed, and then calls deleteRecord(). Developers should use this operation carefully because deleting a record can trigger associated Business Rules, flows, audit behavior, and other configured processing. Methods such as insert() and update() create or modify records, while query() retrieves records. Before deleting records programmatically, developers should ensure that the query conditions are sufficiently restrictive to prevent unintended deletions.

Question 286

What is the primary role of a Client Script in ServiceNow?

  1. To control behavior in the user’s browser on forms
  2. To perform database backups
  3. To create update sets
  4. To define application scopes

Correct Answer: 1

Explanation

Client Scripts execute in the user’s browser and are primarily used to control or respond to behavior on ServiceNow forms. They can run when a form loads, when a field changes, or when a user attempts to submit a form. Client Scripts commonly use the g_form API to manipulate fields, validate information, and provide dynamic form behavior. They should not normally be used for enforcing server-side security or database integrity because client-side code can be bypassed. Server-side mechanisms such as ACLs and Data Policies should be used when enforcement must occur regardless of the interface used.

Question 287

Which ServiceNow feature is used to define who can read, create, update, or delete records?

  1. UI Policy
  2. Access Control
  3. Form Layout
  4. Application Menu

Correct Answer: 2

Explanation

Access Control rules, or ACLs, determine whether users can perform operations such as read, create, write, and delete on ServiceNow resources. ACLs can be defined at table, record, and field levels. Their evaluation can involve roles, conditions, and scripts. This makes ACLs a fundamental part of ServiceNow security. UI Policies control form behavior but are not security mechanisms, while Form Layout determines which fields appear on a form and Application Menus organize navigation. Developers should carefully design ACLs so that sensitive information and operations are protected appropriately across all supported interfaces.

Question 288

Which API is commonly used to access server-side functionality from a client-side script?

  1. GlideRecord
  2. GlideAggregate
  3. GlideAjax
  4. GlideUser

Correct Answer: 3

Explanation

GlideAjax provides a mechanism for client-side scripts to call server-side functionality. It is commonly paired with a client-callable Script Include. The client script sends parameters through GlideAjax, the Script Include performs the required server-side processing, and a response is returned to the client. This approach is useful when information must be obtained from the database or server-side logic without exposing database operations directly in browser code. GlideRecord is a server-side database API, GlideAggregate handles aggregation, and GlideUser provides user-related information. GlideAjax therefore serves as an important bridge between client-side and server-side application logic.

Question 289

Which field type creates a relationship where a record references a record in another table?

  1. Reference
  2. Integer
  3. String
  4. Boolean

Correct Answer: 1

Explanation

A Reference field stores a relationship to a record in another ServiceNow table. Instead of simply storing descriptive text, the field points to a specific record, typically using its sys_id internally. The platform can then display a human-readable value from the referenced record. Reference fields are widely used for relationships such as assigning a task to a user, linking an incident to a configuration item, or associating a record with a group. Reference Qualifiers can further restrict which records are available for selection. This relational capability is fundamental to ServiceNow’s data model and application design.

Question 290

Which ServiceNow feature is primarily used to test application functionality through automated test steps?

  1. Update Set
  2. Application Menu
  3. Automated Test Framework
  4. Data Policy

Correct Answer: 3

Explanation

The Automated Test Framework, commonly called ATF, provides tools for creating and executing automated tests in ServiceNow. Developers and administrators can use ATF to validate application functionality, form behavior, workflows, and other supported processes. Automated testing helps identify regressions after configuration or development changes and can reduce the amount of repetitive manual testing required. ATF tests can contain multiple test steps that simulate user actions or verify expected results. Update Sets package configuration changes, Application Menus organize navigation, and Data Policies enforce data requirements. ATF therefore focuses specifically on repeatable application testing.

Question 291

Which ServiceNow object is commonly used to execute reusable server-side functions from multiple scripts?

  1. Script Include
  2. Client Script
  3. UI Policy
  4. Form Layout

Correct Answer: 1

Explanation

A Script Include is designed to contain reusable server-side JavaScript logic. Instead of duplicating the same code in multiple Business Rules or other server-side components, developers can place the functionality in a Script Include and call it whenever required. Script Includes can contain functions or classes and can be configured for particular use cases, including client-callable functionality when used with GlideAjax. This promotes modular application design and easier maintenance. Client Scripts and UI Policies are mainly associated with client-side behavior, while Form Layout controls the presentation of fields on a form.

Question 292

Which method is used to retrieve a field’s underlying value from a GlideRecord?

  1. getDisplayValue()
  2. getValue()
  3. setDisplayValue()
  4. getLabel()

Correct Answer: 2

Explanation

The getValue() method retrieves the underlying value of a field from a GlideRecord. This is especially important for reference fields because their stored value is generally a sys_id, while the display value may be a person’s name or another readable description. getDisplayValue() returns the user-facing representation instead. Developers should select the appropriate method based on what the script needs. For database comparisons, processing, or constructing queries, the underlying value may be required. For messages or user-facing output, the display value may be more appropriate.

Question 293

Which component can be used to execute server-side logic when a record is inserted, updated, or deleted?

  1. Client Script
  2. UI Policy
  3. Business Rule
  4. Reference Qualifier

Correct Answer: 3

Explanation

Business Rules are server-side scripts that can execute when specified database operations occur. They can be configured to run during insert, update, delete, or other supported contexts. Depending on the selected timing, a Business Rule can execute before the database operation, after it, asynchronously, or during display processing. Business Rules are commonly used for server-side validation, setting values, triggering events, and implementing business logic. Client Scripts operate primarily in the browser and are not a substitute for server-side enforcement. Properly designed Business Rules help centralize application logic and automate record-related processing.

Question 294

Which ServiceNow feature is used to organize fields and their placement on a form?

  1. Form Layout
  2. Transform Map
  3. Scheduled Script
  4. ACL

Correct Answer: 1

Explanation

Form Layout is used to configure which fields appear on a form and the order in which they are displayed. Developers and administrators can use form configuration to make important fields easily accessible and organize information logically for users. Form Layout affects presentation rather than database structure or security. Transform Maps are used during data imports, Scheduled Script Executions automate server-side jobs, and ACLs control access to data and operations. Proper form layout improves usability and helps ensure that users see the information they need without unnecessary fields cluttering the interface.

Question 295

Which ServiceNow object can be used to prevent a form from being submitted when validation fails?

  1. Display Business Rule
  2. onSubmit Client Script
  3. Scheduled Script Execution
  4. Notification

Correct Answer: 2

Explanation

An onSubmit Client Script executes when a user attempts to submit a form and can perform client-side validation before the submission proceeds. If the required conditions are not satisfied, the script can return false to prevent the form from being submitted. This is useful for checking user input or enforcing interactive form requirements. However, onSubmit validation is client-side and should not be treated as a complete security mechanism. For requirements that must be enforced regardless of how data enters the system, server-side controls such as Data Policies or appropriate Business Rules may also be required.

Question 296

Which ServiceNow feature allows an administrator to store configurable application settings that can vary between environments?

  1. UI Action
  2. Script Include
  3. System Property
  4. Transform Map

Correct Answer: 3

Explanation

System Properties are commonly used to store configurable application settings. They allow developers to separate configuration values from hard-coded script logic, making applications easier to maintain and deploy across different environments. For example, a development instance might use one configuration value while production uses another. Administrators can change appropriate property values without modifying the underlying application script. System Properties are therefore useful for feature flags, thresholds, integration settings, and other configurable values. Developers should choose meaningful property names and document their purpose so that configuration remains understandable and manageable.

Question 297

Which Flow Designer component is generally used to start automation when a specified condition or event occurs?

  1. Trigger
  2. Action
  3. Subflow
  4. Data Pill

Correct Answer: 1

Explanation

A Trigger determines when a Flow Designer flow should begin execution. Depending on the flow configuration, a trigger can start automation because of a record event, schedule, application event, or another supported condition. Once triggered, the flow proceeds through actions and other configured steps. Actions perform specific operations, while Subflows provide reusable sequences of automation. Data Pills represent data that can be passed between steps. Understanding the distinction between triggers and actions is important when designing Flow Designer solutions because the trigger establishes the event or condition that initiates the automation.

Question 298

Which ServiceNow feature provides a temporary staging table for data before it is transformed into target records?

  1. Business Rule
  2. Import Set
  3. UI Policy
  4. Application Menu

Correct Answer: 2

Explanation

An Import Set provides a staging area for externally imported data before that data is transformed into records in a target ServiceNow table. External information can first be loaded into an Import Set table, allowing the data to be processed without immediately changing production records. A Transform Map then defines how the staged fields should map to the destination table and how matching or transformation should occur. This separation helps developers validate and transform imported data systematically. Import Sets are commonly used for integrations, file imports, and recurring data-loading processes from external systems.

Question 299

Which method can be used to retrieve a specific record when its unique identifier is known?

  1. next()
  2. addQuery()
  3. get()
  4. query()

Correct Answer: 3

Explanation

The GlideRecord get() method can retrieve a specific record when its unique identifier, such as a sys_id, is known. For example, a script can call gr.get(sys_id) to load the corresponding record into the GlideRecord object. This is different from query(), which executes a query and can return multiple records. The next() method is generally used to move through records returned by a query, while addQuery() defines query conditions. Using get() is convenient when the application already knows exactly which record needs to be accessed.

Question 300

Which ServiceNow mechanism is primarily responsible for controlling whether a user can access a particular field?

  1. Application Menu
  2. UI Policy
  3. Field-level ACL
  4. Form Layout

Correct Answer: 3

Explanation

A field-level Access Control rule, or field ACL, controls whether a user can perform operations such as reading or modifying a particular field. Field ACLs are an important part of ServiceNow security because they can restrict sensitive information even when the user has access to the underlying record. UI Policies can hide, make mandatory, or make fields read-only on forms, but they do not provide the same security enforcement as ACLs. Form Layout controls presentation, while Application Menus provide navigation. For security-sensitive requirements, developers should use appropriate ACL rules rather than relying solely on client-side form behavior.