0% found this document useful (0 votes)
81 views

Ps Query 101 Basics Training Manual

Uploaded by

Atomic Chondria
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)
81 views

Ps Query 101 Basics Training Manual

Uploaded by

Atomic Chondria
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/ 110

PS QUERY 101

ctcLink PeopleSoft Query 101 Basics


Data services

July 2016 – Updated June 2018


Paula McDaniel, Data Analytics Learning and Education Instructor
Washington State Board of Community and Technical Colleges, Data Services

ctcLink PS Query 101 Basics by Paula McDaniel is licensed under a Creative Commons Attribution-NonCommercial-
NoDerivatives 4.0 International License

Based on a work at https://www.sbctc.edu/colleges-staff/data-services/ctclink-peoplesoft-reporting.aspx

i
PS QUERY 101

Table of Contents
 Course Goal ..................................................................................................................................................... 1
 Course Learning Objectives ............................................................................................................................. 1
 How to Use This Manual ................................................................................................................................. 1
The PS Query 101 Training Guide is comprised of three sections. ..................................... 1
Each section will include: .................................................................................................... 1
 Section 1 Introduction ..................................................................................................................................... 2
 Introduction to PeopleSoft Query ................................................................................................................... 2
What is a Relational Database? .......................................................................................... 2
ctcLink PeopleSoft Pillars and Modules .............................................................................. 4
Query Development Life Cycle ........................................................................................... 6
Phase I Develop Query in PCD ......................................................................................... 6
Phase II Request Migration to Production (PRD) ............................................................... 7
Phase III Data Services Review and Migration to Production (PRD) ................................. 7
Phase IV Modification of Existing Query ............................................................................. 7
PS Query Terms ................................................................................................................... 7
 Section 1 Review ............................................................................................................................................. 9
 Section 1 Knowledge Test ............................................................................................................................... 9
 Section 2 Introduction ................................................................................................................................... 13
 Using PeopleSoft Query ................................................................................................................................ 13
Accessing PS Query ........................................................................................................... 13
Allow Pop-Up Windows ..................................................................................................... 13
Using PeopleSoft Query Viewer ........................................................................................ 14
Searching Using Query Viewer ......................................................................................... 14
Query Viewer Options ....................................................................................................... 16
Using PeopleSoft Query Manager .................................................................................... 17
Searching Using Query Manager ...................................................................................... 17
Searching Using Wildcards ............................................................................................... 18
Query Manager Options .................................................................................................... 18
 Using PeopleSoft Schedule Query ................................................................................................................. 20
Using PeopleSoft Schedule Query through Query Viewer/Manager ............................... 21
Scheduling a Query to Run Through Query Viewer or Query Manager ........................... 21
 Create Your Own Scheduled Query through Query Viewer/Manager .......................................................... 26
Scheduling through Query Viewer/Manager – Simplified Instructions for a New Run
Control ID .......................................................................................................................... 26
Criteria to Use in the Query .............................................................................................. 26
Scheduling through Query Viewer/Manager – Simplified Instructions for an Existing Run
Control ID .......................................................................................................................... 27
PS QUERY 101

Criteria to Use in the Query ........................................................................................... ‘;[27


Using PeopleSoft Schedule Query through the Schedule Query Menu Path ................... 28
Scheduling a Query to Run Through the Schedule Query Menu Path ............................. 28
 Create Your Own Scheduled Query through the Schedule Query Menu Path .............................................. 33
Schedule Query Menu Path – Simplified Instructions for a New Run Control ID............. 33
Criteria to Use in the Query .............................................................................................. 33
Schedule Query Menu Path – Simplified Instructions for an Existing Run Control ID ..... 35
Criteria to Use in the Query .............................................................................................. 35
 Section 2 Review ........................................................................................................................................... 36
 Section 2 Knowledge Test ............................................................................................................................. 36
 Section 2 Exercises Campus Solutions ........................................................................................................... 38
 Section 2 Exercises Human Capital ................................................................................................................ 39
 Section 2 Exercises Financials ........................................................................................................................ 40
 Section 3 Introduction ................................................................................................................................... 41
 Creating Queries ............................................................................................................................................ 41
Finding Records to Use ..................................................................................................... 41
Tab Overview and Creating a Simple Query - Detailed Instructions ................................ 42
The Records Tab .............................................................................................................. 43
The Query Tab .................................................................................................................. 45
The Prompts Tab .............................................................................................................. 47
The Fields Tab .................................................................................................................. 47
The Criteria Tab ................................................................................................................ 52
View SQL Tab ................................................................................................................... 53
Run Tab ............................................................................................................................ 53
Saving the Query and Hyperlink Options .......................................................................... 54
Query Creation Stages Review ......................................................................................... 56
 Create Your Own Simple Query ..................................................................................................................... 57
Criteria to Use in the Query .............................................................................................. 57
 Creating Joins in PS Query ............................................................................................................................. 58
Join Types .......................................................................................................................... 58
Cartesian Joins ................................................................................................................. 58
Standard Join .................................................................................................................... 59
Outer Join .......................................................................................................................... 60
Creating a Join - Detailed Instructions .............................................................................. 61
Join Methods ..................................................................................................................... 61
 Create Your Own Join .................................................................................................................................... 64
Creating a Join - Simplified Instructions ........................................................................... 64
Use the following criteria when completing this hands on exercise. ................................. 65
PS QUERY 101

 Using Criteria in PS Query ............................................................................................................................. 65


Adding Criteria Using the Criteria Tab – Detailed Instructions......................................... 66
Criteria Properties ............................................................................................................. 67
Logical Operators for Criteria ............................................................................................ 72
Grouping Criteria with Parentheses .................................................................................. 72
 Create Your Own Criteria .............................................................................................................................. 75
Adding Criteria Using the Criteria Tab - Simplified Instructions ....................................... 75
Criteria to Use in the Query .............................................................................................. 75
Adding Criteria Using the Add Criteria Icon - Simplified Instructions .............................. 76
Criteria to Use in the Query .............................................................................................. 76
 Using Prompts to Extend the Life of a Query ................................................................................................ 77
Creating Prompts through the Prompts Tab – Detailed Instructions ............................... 79
Create the Prompt ............................................................................................................. 79
Adding the Prompt as Criteria ........................................................................................... 82
Creating Prompts with the “Add criteria” icon - Detailed Instructions ............................ 85
 Create Your Own Prompt .............................................................................................................................. 87
Required Prompt with Lookup List through the Prompts Tab – Simplified Instructions . 87
Criteria to Use in the Query .............................................................................................. 88
Create the Prompt ............................................................................................................. 88
Add the Prompt as Criteria to the Query ........................................................................... 89
Optional Prompt with Lookup List Through the Add Criteria Icon – Simplified
Instructions ....................................................................................................................... 89
Criteria to Use in the Query .............................................................................................. 89
 Course Review ............................................................................................................................................... 90
 Simplified Instructions ................................................................................................................................... 92
Scheduling through Query Viewer/Manager – Simplified Instructions for a New Run
Control ID .......................................................................................................................... 92
Scheduling through Query Viewer/Manager – Simplified Instructions for an Existing Run
Control ID .......................................................................................................................... 93
Scheduling through Schedule Query Menu Path – Simplified Instructions for a New Run
Control ID .......................................................................................................................... 94
Creating a Simple Query - Simplified Instructions ............................................................ 95
Creating a Join - Simplified Instructions ........................................................................... 95
Adding Criteria Using the Criteria Tab - Simplified Instructions ....................................... 96
Adding Criteria Using the Add Criteria Icon - Simplified Instructions .............................. 96
Required Prompt with Lookup List through the Prompts Tab – Simplified Instructions . 97
Create the Prompt ............................................................................................................. 97
Add the Prompt as Criteria to the Query ........................................................................... 97
PS QUERY 101

Optional Prompt with Lookup List through the Add Criteria Icon – Simplified
Instructions ....................................................................................................................... 98
Date Prompt – Simplified Instructions.............................................................................. 98
Date Range Prompt – Simplified Instructions ................................................................... 99
Optional Numeric Prompt with No Lookup List – Simplified Instructions...................... 101
Prompt with wildcard (%)– Simplified Instructions ........................................................ 102
 PS Query 101 Training Evaluation ............................................................................................................... 104
PS QUERY 101

 Course Goal
The goal of this course is to empower Query Developers with the tools and skills needed to
create and manage basic Queries.

 Course Learning Objectives


At the end of this course users will:
 Be able to explain how Relational Databases work for storing data.
 Effectively employ Query creation and management protocol and conventions.
 Define Query Terms and Definitions.
 Access PeopleSoft Query
o Viewer
o Manager
o Schedule Query
 Search for existing Queries using Wildcards.
 Run Queries to multiple outputs.
 Look up common Records to use in Query development per Pillar.
 Create simple Queries.
 Join multiple records together to create more complex Queries.
 Effectively use Criteria to filter Query results.
 Make Queries more efficient by using Prompts.

 How to Use This Manual


The PS Query 101 Training Guide is comprised of three sections.
 Section 1 covers the introduction to PeopleSoft Query with information on how data is
stored and accessed through Query Viewer and Query Manager as well as protocol
information and helpful terms.
 Section 2 goes over using PeopleSoft Query including Query Viewer and Query Manager as
well as Schedule Query.
 Section 3 covers the “how to” of using Query Manager to create simple Queries, Joins,
Criteria and Prompts.
Each section will include:
 Section Introduction
 Section Review
 Knowledge test
 Hands on exercises where appropriate
Valuable information will be designated throughout the
manual at the appropriate places. As we work our way through the training manual, be on the
lookout for these icons which indicates areas of special interest or exercises.

Page | 1
PS QUERY 101

 Section 1 Introduction
Welcome to PeopleSoft Query! This versatile tool is simple to use and will allow Query Developers to
create Queries in an effective and efficient manner. In this section we will learn about relational
databases, the PeopleSoft Pillars being implemented and the proper protocol for Query
development.
At the end of this section you will:
 Be able to explain how Relational Databases work for storing data.
 Effectively employ Query creation and management protocol and conventions.
 Define Query Terms and Definitions.

 Introduction to PeopleSoft Query


PeopleSoft Query or PS Query is an end-user reporting tool that allows Query Developers to
extract information in the form of a query from the relational database, without the need to
write SQL (Structured Query Language) statements. Queries can be simple or quite complex;
they may be used one time or repeatedly, as necessary. Results can be displayed on a page or
sent to Excel, HTML, XML or scheduled to run at a later time. In its simplest form a query is
basically a compilation of data from certain fields displayed in the way the user has selected.

What is a Relational Database?


A relational database is a way of storing information that organizes data into tables. Though
table is the term traditionally used they are referred to as 'Records' in PS Query and they
consist of columns and rows (imagine an Excel Spreadsheet). The columns represent fields and
the rows detail each instance of stored information. For example, a column or field name
might be 'Name' while the row information would hold 'Mike', 'Sophia', 'Olivia', 'Drake', etc.
Records can be linked by creating a defined relationship. These relationships enable you to
retrieve and combine data from one or more Records with a single Query. They are based on
key fields, or columns that uniquely identify each row of data. If a database only has a single
record it is referred to as a flat database but if there are two or more records which can be
related it is called a relational database.
Imagine that you are responsible for keeping track of all books checked out of the local
library. You might keep a list similar to the following:

Checkout Flat File with Single Name, Address, Book and Due Date Information
First Name Last Name Address Phone Book Title Due Date
Jennifer Smith 13 Elm St 867-5309 Anne of Green Gables 6/28/2015

This flat database record works pretty well at meeting the basic need to keep track of who has
checked out which book, but it does have a few drawbacks in terms of efficiency, space
Page | 2
PS QUERY 101

required, and maintenance time. For example, each time Jennifer checks out another book her
contact information will have to be entered again and again.

Checkout Flat File Record with Multiple Name, Address, Book and Due Date Information
First Name Last Name Address Phone Book Title Due Date
Jennifer Smith 13 Elm St 867-5309 Anne of Green Gables 6/28/2015
1 Freebie
Jane Yellowrock 555-8267 Mercy Blade 7/1/2015
House Lane
Jennifer Smith 13 Elm St 867-5309 Anne of Avonlea 7/13/2015

Jennifer Smith 13 Elm St 867-5309 Ann f Windy Poplars 7/18/2015

This is less efficient and opens the database up to possible errors (maybe the phone number is
entered wrong). Therefore, instead of using flat database, multiple records can be used to
“have a place for everything and everything has a place” as shown in the two records below.

Checkout Record with Book and Due Date Information


Book Title Due Date
Anne of Green Gables 6/28/2015
Mercy Blade 7/1/2015
Anne of Avonlea 7/13/2015
Anne of Windy Poplars 7/18/2015

Checkout Record with Multiple Name and Address Information


First Name Last Name Address Phone
Jennifer Smith 13 Elm St 867-5309
Jane Yellowrock 1 Freebie House Lane 555-8267

Page | 3
PS QUERY 101

So now all that is needed is a way to relate the two Records. The easiest way to do this is to use
a "Key Field", a field whose values uniquely identify the rows in the record. In the example
below, we have created a CUST_ID to identify each customer.

Customer Record with Multiple Name and Address Information (can be joined to other records
via the CUST_ID field)
CUST_ID First Name Last Name Address Phone
123 Jennifer Smith 13 Elm St 867-5309
1 Freebie House
456 Jane Yellowrock 555-8267
Lane

Checkout Record with Multiple Book and Due Date Information (can be joined to other records
via the CUST_ID field)
CUST_ID Book Title Due Date
123 Anne of Green Gables 6/28/2015
456 Mercy Blade 7/1/2015
123 Anne of Avonlea 7/13/2015
123 Anne of Windy Poplars 7/18/2015

ctcLink PeopleSoft Pillars and Modules


The CtcLink implementation of PeopleSoft is composed of three Pillars. These are:
 HCM – Human Capital Management
 CS – Campus Solutions
 FSCM – Financials and Supply Chain Management

Page | 4
PS QUERY 101

Pillars are comprised of modules where data is captured and stored. The list below is a
sampling of available Modules. For the complete list please see: Query Module List by Pillar

Pillar, Module and Module Abbreviation List


Pillar Module Module Abbreviation
CS Academic Advisement AA
CS Academic Structure AC
CS Campus Community CC
CS Curriculum Management CM
CS Financial Aid FA
CS Recruiting and Admissions RA
CS Student Financials SF
CS Student Records SR

FS Asset Management AM
FS Accounts Payable AP
FS Accounts Receivable AR
FS Billing BI
FS Cash Management CM
FS Contracts CO
FS Expenses EX
FS General Ledger GL
FS Grants GR
FS Commitment Control KK
FS Project Costing PC
FS Purchasing PO
FS Projects PR

HC HR Core HR
HC Absence Management AB
HC Payroll PY
HC Time and Labor TL
HC Talent Acquisition Management TM
HC Benefits Administration BA
HC Faculty Workload FW

Page | 5
PS QUERY 101

Each pillar has its own relational database and it is important to note that standard queries
cannot cross pillar boundaries.

Query Development Life Cycle


The following phases pertain the Query Development Life Cycle in PCD (Production College
Development). This is a review of information presented in the QDLC course, which is a
prerequisite of the 101 Basics course. For further information on the QDLC for developing
queries please refer to the QDLC course.

Phase I Develop Query in PCD


 Search for an existing query or report Develop in PCD environment
o Better to use an existing query than develop a new one.
o Minimizes query clutter.
o Easier to find needed query since there are fewer to look through.
o Query is already in production so it reduces wait time for the end-user.
 Use standard naming convention to migrate query to PRD.
o QXX_XX_XXXXXXXX
 Q for Query or V for View Pillar Abbreviation_Module Abbreviation_Description
 QCS_AA_ENROLLED_NO_ADVISOR
o Queries in development not yet ready to move to production must begin with DEV_ or
they will be deleted during the PCD refresh process.
 Add description to query property.
o The Description field is 30 characters. Try to use a description that will best identify the
query and will also facilitate searching
 Add definition to query property.
o Include the following in the Query Definition field:
 Detailed description of purpose of Query.
 Any specific criteria applied, for example “Selects using Student Group SINT".
 Include key search terms.
 Describe any changes or updates made to an existing Query.
 College code and email address of developer, for example,
890: [email protected].
 Date Query was created or updated.
 Business Process Number, if applicable.
 Data that should be redacted per FERPA.
 Effective Dating Logic outside of the default. Specifically for:
 Describe Effective Dating logic (i.e. <= Term End Dates or <= Current Date)
 Is Effective Dating Logic joined on Term End Date for historical reporting?
 Is Effective Dating Logic aligned with Term Dates for prior term reporting?
 Query must be saved as public in order to migrate it.
o Queries saved as private will not be migrated to PRD (Production).
 Add prompts instead of hard coding criteria.
o Queries not using at least one secure prompt will not be migrated.

Page | 6
PS QUERY 101

o Any special cases where a prompt should not be used must first be approved by Data
Services.
 Store in logical folder.
o Queries not stored in a logical folder will not be migrated.
 Test your query for accuracy, performance and data validation.
o Use the Query Migration Form as a guide.

Phase II Request Migration to Production (PRD)


 Submit Service Desk ticket to migrate query to Production.
 Include completed Query Migration Request form with ticket ensuring the query passes all
“Pre-Migration Checklist” requirements.

Phase III Data Services Review and Migration to Production (PRD)


 Query will be tested for compliance and functionality by Data Services.
 Data Services submits migration request to hosting service.
 Query will be added to View Query Search Listing in metaLink. For access to metaLink
please email [email protected] or [email protected].

Phase IV Modification of Existing Query


 Understand how a modification will impact the original purpose
 Determine if a modification is acceptable, or if a new query needs to be developed. If
modifying an existing query, make a copy first
 Check if the change is acceptable to original query writer or if not able to locate this person,
check with Data Services for approval to change.
 Repeat QDLC starting at the second step of Phase I
 If desired, request that the original query be removed from PRD

PS Query Terms
We have already studied in the section above the terminology associated with relational
databases and PS Query. Below is a more complete list of most of the terms that users will
come across in their experiences with PS Query. As PeopleSoft terminology is not always the
same as standard terminology it is important to understand their use and definition. As users
move further on in their training they will learn more terms unique to PS Query, however the
list below will provide a firm foundation.

Relational Database: A database system in which the database is organized and accessed
according to the relationships between data items without the need for any consideration of
physical orientation and relationship. Relationships between data items are expressed by
means of tables (records).

Record/Table: Records/Tables are the foundation of the query tool. A record stores data that is
arranged by rows (entries) and columns (fields). For example, a record/table containing data
about “people” would have a row for each individual person and columns (fields) for each piece

Page | 7
PS QUERY 101

of data stored for that individual (ex: name, address, phone). Records can be added to a query
from the “Records” tab.

Column/Field: In a database context, a field is the same as a column. For example, a record of
people could contain separate fields such as name, address, phone, etc.

Query: A query is a SQL SELECT statement that reads data from records and views within the
database, and returns the result set to the requester. PS Queries cannot change data within the
database.

SQL: Structured Query Language (SQL) is a language that provides an interface to relational
database systems. It was developed by IBM in the 1970s for use in System R. SQL is a de facto
standard, as well as an ISO and ANSI standard. Some people pronounce SQL "sequel".

Criteria: Specifying criteria in your query allows you to set conditions which limit the results
returned by the query to only those data that you are interested in. Criteria are viewed and
maintained on the “Criteria” tab. Example: You may want to set criteria to limit your query to
retrieve a relevant subset of data such as active undergraduate students as opposed to
returning results for all active students.

Join: The process of combining data from two or more records using matching keys.

Public Query: Public Queries are viewable and editable by any user with access to Query
Manager and the proper Record access. Public queries are available for use by many different
users, so please do not save any changes that you make to a public query.

Private Query: Private queries are only viewable by the individual who created the query. They
can be shared with others individually, however.

Key Field: A column in a record whose values uniquely identify each row. A key field value
cannot be NULL.

Definitions courtesy of orafaq.com

Page | 8
PS QUERY 101

 Section 1 Review
In this section we learned about Relational Databases and how they work in efficiently storing
data for easy retrieval for reporting.

We also discussed important Query protocol and conventions ensuring effective Query
migrations, development and maintenance.

Finally we learned some helpful Query terminology ensuring all Query Developers are “on the
same page” and can “speak the same language”.

 Section 1 Knowledge Test


Question 1 1 pts
A relational database is a way of storing information that organizes data into [what]?

Question 2 1 pts
Traditionally in database terminology the term 'Table' is used to define a grouping of rows and columns of
data, however in PeopleSoft Query this grouping is referred to as a [what]?

Enter or Space to move this question.


Question 3 1 pts
Records (or Tables) are related to each other through the use of:

☐ Key Fields
☐ Columns
☐ Rows
☐ All of the Above

Question 4 1 pts
Queries should normally be developed in which environment?

☐ PCD
☐ Production
☐ PDV
ace to move this question.
Question 5 1 pts
The correct naming convention is important because if queries in development in PCD do not begin with
DEV_ they could be [what] during the refresh process?

Page | 9
PS QUERY 101

Question 6 1 pts
Searching for an existing query before developing a new one will:

☐ Minimize query clutter


☐ Make it easier to find needed queries as there will be fewer to look through
☐ Reduce wait time for the end user if the query is already available
☐ Save time and resources
☐ All of the above

Question 7 1 pts
While the query description is only 30 characters, the query definition is limitless and should be used to track
various aspects of query creation including:
 Detailed description of purpose of Query
 Any specific criteria applied
 Key search terms
 Description of any changes or updates made to an existing Query
 College code and email address of developer
 Date Query was created or updated
 Business Process Number, if applicable
 Data that should be redacted per FERPA
 Effective Dating Logic outside of the default. Specifically for:
o Describe Effective Dating logic (i.e. <= Term End Dates or <= Current Date)
o Is Effective Dating Logic joined on Term End Date for historical reporting?
o Is Effective Dating Logic aligned with Term Dates for prior term reporting?
☐ True
☐ False

Question 8 1 pts
Queries created by others are never okay to use, even if you “save as” to save the query to a new name.

☐ True
☐ False

Question 9 1 pts
If a query has a [what] the query will be usable by all colleges as the end user can select their college code.

Question 10 1 pts
Queries which are to be migrated should ALWAYS be saved as:

☐ Public
☐ Private

Page | 10
PS QUERY 101

Question 11 1 pts
A field in a record whose values uniquely identify each row.

☐ Key Field
☐ Relational Database
☐ Record
☐ Query

Question 12 1 pts
A database system in which the database is organized and accessed according to the relationships between
data items without the need for any consideration of physical orientation and relationship.

☐ Query
☐ Field
☐ Relational Database
☐ SQL

Question 13 1 pts
The foundation of the query tool. Stores data that is arranged by rows (entries) and columns (fields).

☐ Criteria
☐ Join
☐ Record
☐ Private Query

Question 14 1 pts
In a database context, this is the same as a column.

☐ SQL
☐ Record
☐ Relational Database
☐ Field

Question 15 1 pts
A SQL SELECT statement that reads data from records and views within the database, and returns the result
set to the requester.

☐ Relational Database
☐ Field
☐ Join
☐ Query

Page | 11
PS QUERY 101

Question 16 1 pts
Structured Query Language

☐ SQL
☐ Join
☐ Key Field
☐ Public Query

Question 17 1 pts
Set of conditions which limit the results returned by the query to only those data that you are interested in.

☐ Join
☐ Criteria
☐ Key Field
☐ Query

Question 19 1 pts
The process of combining data from two or more records using matching key fields

☐ Criteria
☐ Join
☐ Public Query
☐ Record

Question 20 1 pts
Viewable only by the individual who created the query. Can be shared with others individually, however.

☐ Public Query
☐ Criteria
☐ Join
☐ Private Query
pace to move this question.
Question 21 1 pts
Viewable and editable by any user with access to Query Manager and the proper Record access.

☐ Private Query
☐ Public Query
☐ Relational Database

Page | 12
PS QUERY 101

 Section 2 Introduction
In this section we will utilize PS Query as we learn navigation and Query basics such as searching and
running Queries. The exercises provided at the end of this section are Pillar specific. Please do not
do all three sets of exercises, instead select the Pillar you work in and complete that set of exercises.
At the end of this section you will be able to:
 Access PeopleSoft Query
o Viewer
o Manager
o Schedule Query
 Search for existing Queries using Wildcards.
 Run Queries to multiple outputs.

 Using PeopleSoft Query


Accessing PS Query
Once you have logged into PeopleSoft there are three main areas in PS Query you will be able
to access:
o Query Manager
 Query Manager in PCD is used to create and modify Queries and is only available to
Query Developers. Queries can be outputted to HTML, Excel, XML or scheduled to
run through Query Manager.
o Query Viewer
 Query Viewer is accessible by everyone with a PeopleSoft License and can be used
to view Query output in HTML, Excel or XML. Users are also able to schedule a
Query to run through Query Viewer.
o Schedule Query
 Schedule Query is used exclusively for scheduling a Query to run at a future time or
to run Queries with large results.
Use the following menu paths to access PS Query:
 Query Manager: Main Menu > Reporting Tools > Query > Query Manager
 Query Viewer: Main Menu > Reporting Tools > Query > Query Viewer
 Schedule Query: Main Menu > Reporting Tools > Query > Schedule Query

Allow Pop-Up Windows


If ever searching for a query and absolutely nothing is happening in response to clicking search
the first thing to check is that pop-up windows have been allowed. It is generally always the
case when PS Query does not respond in any form that pop-up windows have not been
allowed.

Page | 13
PS QUERY 101

Using PeopleSoft Query Viewer


Query Viewer: Main Menu > Reporting Tools Query > Query Viewer.
Query Viewer is accessible by everyone with a PeopleSoft License and can be used to view
Query output in HTML, Excel or XML. The first screen of Query Viewer will give users the option
to search for a Query as well as display any previously selected Favorite Queries.
Note: Version 8.54 will not allow for downloading results to Excel or XML. Instead run the
query to HTML first in order to accomplish this. This error will be fixed with the next upgrade.

Searching Using Query Viewer

Page | 14
PS QUERY 101

From this screen users are able to search using the Operator “Begins With” by multiple criteria
including:
 Access Group Name – name of the query tree access group
 Description – query description
 Folder Name - search by folder name
 Owner – private or public not the name of the query creator
 Query Name - name of the query
 Type - default is a User Query.
o User queries - Create and run queries to retrieve data from the database
o Archive queries - Define selection criteria to archive data from transactional tables to
history tables
o Process queries - queries that are intended to be run periodically by batch processes
o Role queries - queries that PeopleSoft Workflow uses to determine to whom to send
emails, forms, or worklist entries.
 Uses Field Name – name of a field that is being used in the query.
 Uses Record Name – name of a record that is being used in the query.
Click on the hyperlink "Advanced Search" to the right of the "Search" button in order to access
Advanced Search capability where even more search functionality is available including
different Operators such as:
 <
 <=
 =
 >
 >=
 Begins With
 Between
 Contains
 In
 Not =

Page | 15
PS QUERY 101

SEARCHING USING WILDCARDS


PeopleSoft allows users to use wildcards in place of a single space by using _ or in place of
everything following the wildcard by using %.
 _ matches any single character. For example, _ones matches any five-character string
ending with “ones”, such as "Jones" or "Cones".
 % matches any string of zero or more characters. For example, C% matches any string
starting with C, including C alone.
To use one of the wildcard characters as a literal character (for example, to include a % in your
string), precede the character with a \ (for example, percent\%).

Query Viewer Options


Users are able to further refine search results by selecting folders from the Folder View field.
This field appears only after first performing a search.

The Query results can be ran to:


 HTML
 Excel
 XML
 Schedule
Note that this is also where regularly accessed Queries can be added to Favorites by simply
clicking on the "Favorite" hyperlink. The "Favorite" list appears when the user accesses Query
Viewer and has selected at least one favorite query. It will display below query search results.

Click on the output selection to the right of the desired Query.

Note: Version 8.54 will not allow for downloading results to Excel or XML. Instead run the
query to HTML first in order to accomplish this. This error will be fixed with the next upgrade.
To view the results in a new tab, click on the “HTML” hyperlink from the results list. The results
will display in the new tab below the prompts.
 TIP! When viewing the results in HTML you are able to, in essence, “re-run” the Query
without the need to retype in all the prompt information. Instead, you are able to make

Page | 16
PS QUERY 101

whatever changes you want directly from the new tab.For example, to quickly change the
selected Term – instead of having to re-input Institution and Term, just change the Term.
The new results will display after clicking “View Results”.

Using PeopleSoft Query Manager


Query Manager: Main Menu > Reporting Tools > Query > Query Manager
Query Manager is used to create and modify Queries and is only available to Query
Developers. The first screen of Query Manager will give users the option to search for a Query
as well as display any previously selected Favorite Queries.

Searching Using Query Manager


From this screen users are able to search using the Operator “Begins With” by multiple criteria
including:
 Access Group Name
 Description
 Folder Name
 Owner
 Query Name
 Type
 Uses Field Name
 Uses Record Name

In addition there is an Advanced Search capability where even more search functionality is
available including different operators such as:
 <
 <=
 =
 >
 >=
 Begins With
 Between
 Contains
 In
 Not =

Page | 17
PS QUERY 101

Searching Using Wildcards


PeopleSoft allows users to use wildcards for either a single space by using _ or everything
following the wildcard by using %.
 _ matches any single character. For example, _ones matches any five-character string
ending with "ones", such as "Jones" or "Cones".
 % matches any string of zero or more characters. For example, C% matches any string
starting with C, including C alone.
To use one of the wildcard characters as a literal character (for example, to include a % in your
string), precede the character with a \ (for example, percent\%).

Query Manager Options

REFINE RESULTS BY FOLDER


Users are able to further refine search results by selecting Folders from the Folder View field.
This field will appear only after first performing a search.

EDIT THE QUERY


To edit a query, click on the hyperlink Edit to the right of the query name in the list of results.
This will take the user into the query in Query Manager.

Page | 18
PS QUERY 101

RUN THE QUERY


Additionally the user is able to run results to:
 HTML
 Excel
 XML
 Schedule
Note: Version 8.54 will not allow for downloading results to Excel or XML. Instead run the
query to HTML first in order to accomplish this. This error will be fixed with the next upgrade.
 Remember that if editing a Query, users must first save the Query under a new name in
order not to overwrite any existing data by selecting “Save As”. Please see the QDLC
course for more information on this.

TIP! When viewing the results in HTML you are able to, in essence, “re-run” the Query without
the need to retype in all the prompt information. Instead, you are able to make whatever
changes you want directly from the new tab.
For example, to quickly change the selected Term – instead of having to re-input Institution,
Academic Career and Term, just change the Term. The new results will display after clicking
“View Results”.

Page | 19
PS QUERY 101

In addition Query Manager allows for users to take certain actions on Queries. To the left of
the list of results are checkboxes. One or multiple Queries can be selected.

You can then bring up the list of available actions by selecting the drop down menu from the
Actions field.

Available actions are:


o Add to Favorites - Will add the query to the users list of favorite queries. The "Favorite"
list appears when the user accesses Query Manager and has selected at least one
favorite query. It will display below query search results.
o Copy to User - Used typically with Private Queries. Allows the query creator to share
the private query with one or more other users.
o Delete Selected - Will delete the selected query or queries. Regardless of who created
the query - any Query Manager user is able to delete any query. USE WITH
CAUTION!!!!
o Move to Folder - Will remove the query from its current folder and add it to the newly
selected folder. Query folders are used to organize like queries so be careful when
using this feature.
o Rename Selected - Allows the user to rename the selected query. Every query must
have a unique name, regardless of whether is it private or public.

 Using PeopleSoft Schedule Query


Schedule Query is used for scheduling a query to run at a future time or to run queries with
large results. Queries can be scheduled through Query Viewer or Query Manager as well as
through the PeopleSoft Menu Path. The process varies slightly depending on whether the user
starts using the menu path or Query Viewer/Manager.

Page | 20
PS QUERY 101

Using PeopleSoft Schedule Query through Query Viewer/Manager


The process to schedule a query to run through Query Viewer and Query Manager is the same
whether starting from Query Viewer or Query Manager.

Scheduling a Query to Run Through Query Viewer or Query Manager


The process is the same regardless of whether the user uses Query Viewer or Query
Manager. Search for the desired query and click on "Schedule "from the list of results.

The “Scheduled Query” page will come up with the query name previously selected already
filled in along with designating whether the query is Private or Public. If there is an existing Run
Control ID for the query it will display here.

If there is not an existing Run Control ID the Run Control ID will be blank. If there is an existing
Run Control ID then it will appear in the field. In the image below there is an existing Run
Control ID associated to this query by the user.

A Run Control ID is used to tell the system when and where and how you want the report to
run. For example, you might tell the system to run the report on the database server at 4 am or

Page | 21
PS QUERY 101

every Sunday afternoon, or you might tell it to run the report immediately. For most reports,
you must also set parameters that determine the content of the report, such as the business
unit or time period on which to report. These parameters are based on the prompts used in the
query and are saved by the Run Control ID so they don’t have to be re-entered each time you
use the Run Control ID to run the query. A run control is a database record that provides values
for these settings. Instead of entering the same values each time you run a query, you create
and save a Run Control with those settings.

There is no specific naming convention for the Run Control ID . Run Control ID’s have a 30
character limit and cannot be easily deleted. They are individual to each user and are not
visible by others. Run Control ID’s can be used for a single query to save the parameters or the
user can change the query associated with the Run Control ID.

If the Run Control ID field is not populated then create a new one by clicking on "Add a New
Value" tab, enter the Run Control ID and then click on the “Add” button.

The Schedule Query page will display. The query name will automatically populate based on
the query selected from Query Viewer or Query Manager. Enter a description for the query
Run Control ID in the Description Field. This will be the Report Name.

Note: if there are prompts (parameters) for the Run Control ID they can be updated here by
clicking the Update Parameters hyperlink. You can save these changes to the Run Control ID by
clicking “Save”. This will not, however, schedule the query. To schedule the query click on
“Apply”.

Page | 22
PS QUERY 101

The Process Scheduler Request page will display. Select the Time Zone, Date and Time to run
the query.

The Output Type and Format can also be selected here.

Output Types available are: Format Types available are:


Click “OK”.

You will return to the Schedule Query page. Notice there is now a Process Instance number
now associated with this Scheduled Query.

PROCESS MONITOR
To view the status of your Scheduled Query click the “Process Monitor” hyperlink from the
Schedule Query page. The Process Monitor will display the status of the Scheduled Query.

Page | 23
PS QUERY 101

You are able to see the status of Scheduled Query runs by:
 User ID
 Type
 Number of days past
 Server
 Name
 Instance from and to
 Run Status
 Distribution Status

Another way to access the Process Monitor is through the menu path: Main Menu>
PeopleTools> Process Scheduler> Process Monitor
Once the query has run and you see a status of “Success” click on “Go back to Scheduled
Query”. This will return you to the very first Scheduled Query search page. Note that your Run
Control ID is now filled in so to get to the Scheduled Query page to view the report via Report
Manager click on "Enter". Click on the Report Manager hyperlink to view the query results.

REPORT MANAGER
To view the results of your Scheduled Query click the “Report Manager” hyperlink from the
Schedule Query page in order to access the Report Manager. You may need to click on the
"Administration Tab" in order to view the results of the scheduled query.

Page | 24
PS QUERY 101

Report Manager allows the user to filter displayed reports by:


 Folder
 Instance from and to
 Name
 Created on Date
 Number of Days past
 Date Range
Another way to access the Report Manager is through the menu path: Main Menu>
ReportingTools> Report Manager
Click on the hyperlink found in the Report column to view the output. Remember this report
'name' is the description entered when first scheduling the query.
The query results can then be viewed in the selected format by clicking on the query name in
the Name column.

Page | 25
PS QUERY 101

 Create Your Own Scheduled Query through Query


Viewer/Manager
The exercises below are pillar specific. Select the pillar most worked in and complete the
exercise for that pillar.

Scheduling through Query Viewer/Manager – Simplified Instructions for


a New Run Control ID
The purpose of this exercise is to give users the chance to practice scheduling a query. Count
the exercise as successful if you are able to see that the schedule process ran successfully and
has a status of success and posted. There are two exercises available to complete - scheduling
a query with a brand new Run Control ID and scheduling a query using an existing Run Control
ID.

Criteria to Use in the Query


Use the following criteria when completing this hands on exercise.

PILLAR:
CS – Search for and schedule the query QCS_TRAIN_STDNT_ENRL
HC – Search for and schedule the query QHC_TRAIN_LABWORK_3
FS – Search for and schedule the query QFS_TRAIN_CUSTOMER
ALL:
 Run Control ID - Create the Run Control ID NAME_TRAIN_RUNID where NAME is your
first name
 Description - Use a description of 'Schedule Exercise'
 Type Use a type of 'Web'
 Format Use a format of 'HTM'

INSTRUCTIONS:
 Go to Query Manager or Query Viewer and search for the desired Query and click on the
"Schedule" hyperlink to the right of the query you would like to run.
 The Query name will automatically populate based on the Query selected from Query
Viewer or Query Manager.
 Click on the Add New Value tab and enter a Run Control ID.
 Click on the “Add” button.
 If there are prompts (parameters) in the query a pop up box will appear where they can
be filled in.
 Enter a description for the Query Run Control ID in the Description Field. This will be the
Report Name.
 Click Apply

Page | 26
PS QUERY 101

 On the Process Scheduler page select the Time Zone, Date and Time to run the Query, if
desired. Also change the default output Type and Format, if desired
 Click OK
 Note the Process Instance Number
 View the status of the run via Process Monitor by clicking on the hyperlink.
o When done viewing click "Go back to Scheduled Query" hyperlink.
o Note this will take you ALL the way back to the very beginning page where your
new Run Control ID will be already filled in for you. Click on Search again to go to
the Schedule Query page with the Report Manager and Process Monitor
hyperlinks.
o If you hit the back button it is possible for the "Go back to Schedule Query"
hyperlink from the process monitor page to disappear.
 Alternately view the Process Monitor by navigating to Main Menu >
PeopleTools > Process Scheduler > Process Monitor
 View the results of the report via Report Manager by clicking on the hyperlink. You may
need to click on the "Administration Tab" in order to view the results of the scheduled
query
o Click on the hyperlinked name of the report (the description entered earlier) in
the Report column.
o Click on the hyperlinked name of the query to download the results of the
scheduled query.
 Alternately view the Report Manager by navigating to Main Menu >
Reporting Tools > Report Manager

If you finish the above exercise and would like to try to practice the simplified instructions for
an existing Run Control ID please feel free to use the Run Control ID created in the above
exercise and complete the exercise below as well.

Scheduling through Query Viewer/Manager – Simplified Instructions for


an Existing Run Control ID
The purpose of this exercise is to give users the chance to practice scheduling a query. If the
query returns results is unimportant at this point. Being able to schedule one is
important. Count the exercise as successful if you are able to see that the schedule process ran
successfully and has a status of success and posted.

Criteria to Use in the Query

Use the Run Control ID created in the previous exercise for this hands on exercise.

Page | 27
PS QUERY 101

INSTRUCTIONS:
 Go to Query Manager or Query Viewer and search for the desired Query and click on the
"Schedule" hyperlink to the right of the query you would like to run.
 The Query name will automatically populate based on the Query selected from Query
Viewer or Query Manager.
 Click on Find an Existing Value and search for the Run Control ID.
 Click on the the hyperlink for the Report Name or Run Control ID in the search results.
 If there are prompts (parameters) in the Query a pop up box will appear where they can be
filled in. To update existing parameters click on Update Parameters.
 Click Apply
 On the Process Scheduler page select the Time Zone, Date and Time to run the Query, if
desired. Also change the default output Type and Format, if desired
 Click OK
 Note the Process Instance Number
 View the status of the run via Process Monitor by clicking on the hyperlink.
o When done viewing click "Go back to Scheduled Query" hyperlink.
o Note this will take you ALL the way back to the very beginning page where your new
Run Control ID will be already filled in for you. Click on Search again to go to the
Schedule Query page with the Report Manager and Process Monitor hyperlinks.
o If you hit the back button it is possible for the "Go back to Schedule Query" hyperlink
from the process monitor page to disappear.
 Alternately view the Process Monitor by navigating to Main Menu > PeopleTools
> Process Scheduler > Process Monitor
 View the results of the report via Report Manager by clicking on the hyperlink. You may
need to click on the "Administration Tab" in order to view the results of the scheduled
query
o Click on the hyperlinked name of the report (the description entered earlier) in the
Report column.
o Click on the hyperlinked name of the query to download the results of the scheduled
query.
 Alternately view the Report Manager by navigating to Main Menu > Reporting Tools
> Report Manager

Using PeopleSoft Schedule Query through the Schedule Query Menu Path
Schedule Query is used for scheduling a query to run at a future time or to run queries with
large results. Queries can be scheduled through Query Manager or Query Manager as well as
through the PeopleSoft Menu Path. The process varies slightly depending on whether the user
starts using the menu path or Query Manager/Manager.

Scheduling a Query to Run Through the Schedule Query Menu Path

Page | 28
PS QUERY 101

Navigate to the Schedule Query page by following this menu path: Main Menu > Reporting
Tools > query > Schedule Query

You will be brought to the page to search for an existing scheduled query via:
 Description
 Query Name
 Run Control ID
If the query being searched for has an existing Run Control ID associated with it, the user will be
taken directly to the Schedule Query page after clicking search if there is only one Run Control
ID. If there is more than one Run Control ID a list will display where the user will select the
desired one by clicking on the hyperlink.

If there is not an existing Run Control ID then the message "No results found" will display and
the user will need to enter in a new Run Control ID. Note: this will entail entering the name of
the new Run Control ID before searching for the query to tie it to.

Click Add a New Value tab to create a new Run Control ID. Enter the new Run Control ID in the
Field. Once the Run Control ID has been entered click on the “Add” button.

The Schedule Query page will display. Search for the correct query and add a Run Control ID
description.

Page | 29
PS QUERY 101

Note: Clicking on “Save” will save the Run Control ID for the Scheduled Query request however
it will NOT schedule the query run. To schedule the query run, click on “Run”. Note that this is
different than when accessing Schedule Query through Query Manager or Query Manager
where the "Apply" button is selected to schedule the query.

The Process Scheduler Request page will display. Select the Time Zone, Date and Time to run
the query.

The Output Type and Format can also be selected here.

Output Types available are: Format Types available are:

Click “OK”.

You will return to the Schedule Query page. Notice there is now a Process Instance number
now associated with this scheduled query.

Page | 30
PS QUERY 101

To view the status of your scheduled query click the “Process Monitor” hyperlink.

PROCESS MONITOR

To view the status of your scheduled query click the “Process Monitor” hyperlink from the
Schedule Query page. The Process Monitor will display the status of the scheduled query.

You are able to see the status of scheduled query runs by:
 User ID
 Type
 Number of days past
 Server
 Name
 Instance from and to
 Run Status
 Distribution Status
Another way to access the Process Monitor is through the menu path: Main Menu>
PeopleTools> Process Scheduler> Process Monitor

Once the query has run and you see a status of “Success” click on “Go back to Scheduled
Query”. This will return you to the very first Scheduled Query search page. Note that your Run
Control ID is now filled in so to get to the Scheduled Query page to view the report via Report
Manager click on "Enter". Click on the Report Manager hyperlink to view the query results.

REPORT MANAGER

To view the results of your scheduled query click the “Report Manager” hyperlink from the
Schedule Query page in order to access the Report Manager.

Page | 31
PS QUERY 101

Report Manager allows the user to filter displayed reports by:


 Folder
 Instance from and to
 Name
 Created on Date
 Number of Days past
 Date Range
Another way to access the Report Manager is through the menu path: Main Menu>
ReportingTools> Report Manager

Click on the hyperlink found in the Report column to view the output. Remember this report
'name' is the description entered when first scheduling the query.

Page | 32
PS QUERY 101

The query results can then be viewed in the selected format by clicking on the query Name in
the Name column.

 Create Your Own Scheduled Query through the Schedule Query


Menu Path
The exercises below are pillar specific. Select the pillar most worked in and complete the
exercise for that pillar.

Schedule Query Menu Path – Simplified Instructions for a New Run


Control ID
The purpose of this exercise is to give users the chance to practice scheduling a query. Count
the exercise as successful if you are able to see that the schedule process ran successfully and
has a status of success and posted. There are two exercises available to complete - scheduling
a query with a brand new Run Control ID and scheduling a query using an existing Run Control
ID.

Criteria to Use in the Query


Use the following criteria when completing this hands on exercise.

PILLAR:
 CS – Search for and schedule the query QCS_TRAIN_STDNT_ENRL
 HC – Search for and schedule the query QHC_TRAIN_LABWORK_3
 FS – Search for and schedule the query QFS_TRAIN_CUSTOMER

Page | 33
PS QUERY 101

ALL:
 Run Control ID - Create the run control ID NAME_TRAIN_RUNID2 where NAME is your
first name
 Description - Use a description of 'Schedule Exercise'
 Type - Use a type of 'Web'
 Format - Use a format of 'HTM'

INSTRUCTIONS:

 Navigate to Schedule Query: Main Menu > Reporting Tools > query > Schedule Query.
 Click on Add a New Value to create a new Run Control ID. Enter a Run Control ID.
 Click on the “Add” button.
 Enter the query name or search for the query.
 Enter a description for the query Run Control ID in the Description Field. This will be the
Report Name.
 If there are prompts (parameters) in the query a pop up box will appear where they can
be filled in. To update existing parameters click on Update Parameters.
 Click Run.
 On the Process Scheduler page select the Time Zone, Date and Time to run the query, if
desired.
 Also change the default output Type and Format, if desired.
 Click OK.
 Note the Process Instance Number.
 View the status of the run via Process Monitor by clicking on the hyperlink.
o When done viewing click "Go back to Scheduled query" hyperlink.
o Note this will take you ALL the way back to the very beginning page where your
new run control ID will be already filled in for you. Click on Search again to go to
the Schedule Query page with the Report Manager and Process Monitor
hyperlinks.
o If you hit the back button it is possible for the "Go back to Schedule Query"
hyperlink from the process monitor page to disappear.
 Alternately view the Process Monitor by navigating to Main Menu >
PeopleTools > Process Scheduler > Process Monitor
 View the results of the report via Report Manager by clicking on the hyperlink. You may
need to click on the "Administration Tab" in order to view the results of the scheduled
query
o Click on the hyperlinked name of the report (the description entered earlier) in
the Report column.
o Click on the hyperlinked name of the query to download the results of the
scheduled query.
 Alternately view the Report Manager by navigating to Main Menu >
Reporting Tools > Report Manager

Page | 34
PS QUERY 101

If you finish the above exercise and would like to try to practice the simplified instructions for
an existing run control ID please feel free to use the query you just created a run control ID for
in the above exercise and complete the exercise below as well, time permitting. If there is not
time in class to complete both exercises please feel free to log in at any time to complete them.

Schedule Query Menu Path – Simplified Instructions for an Existing Run


Control ID
The purpose of this exercise is to give users the chance to practice scheduling a query. Count
the exercise as successful if you are able to see that the schedule process ran successfully and
has a status of success and posted.

Criteria to Use in the Query


Use the run control ID created above in this hands on exercise.

INSTRUCTIONS:
 Navigate to Schedule Query: Main Menu > Reporting Tools > query > Schedule Query.
 Click on Find an Existing Value and select the correct Run Control ID
 If there are prompts (parameters) in the query a pop up box will appear where they can
be filled in. To update existing parameters click on Update Parameters.
 Click Run.
 On the Process Scheduler page select the Time Zone, Date and Time to run the query, if
desired. Also change the default output Type and Format, if desired.
 Click OK.
 Note the Process Instance Number.
 View the status of the run via Process Monitor by clicking on the hyperlink.
o When done viewing click "Go back to Scheduled query" hyperlink.
o Note this will take you ALL the way back to the very beginning page where your
new run control ID will be already filled in for you. Click on Search again to go to
the Schedule Query page with the Report Manager and Process Monitor
hyperlinks.
o If you hit the back button it is possible for the "Go back to Schedule Query"
hyperlink from the process monitor page to disappear.
 Alternately view the Process Monitor by navigating to Main Menu >
PeopleTools > Process Scheduler > Process Monitor
 View the results of the report via Report Manager by clicking on the hyperlink. You may
need to click on the "Administration Tab" in order to view the results of the scheduled
query
o Click on the hyperlinked name of the report (the description entered earlier) in
the Report column.
o Click on the hyperlinked name of the query to download the results of the
scheduled query.
 Alternately view the Report Manager by navigating to Main Menu >
Reporting Tools > Report Manager
Page | 35
PS QUERY 101

 Section 2 Review
In this section we learned how to access the three areas of PS Query:

 PS Query Viewer
 PS Query Manager
 Schedule Query

We also learned how to efficiently search for existing Queries using Wildcards; how to output
Query results into different formats such as XLS, HTML or XML and some of the benefits of
viewing Query results in various formats. We also learned how to take actions on Queries such
as adding to a “Favorites” list.

Finally, we learned how to schedule a Query through Schedule Query as well as view the Query
results through this tool.

 Section 2 Knowledge Test


Question 1 1 pts
Query Viewer is available to everyone with access to ctcLink.
☐ True
☐ False
Space to move this question.
Question 2 1 pts
Query Viewer will output results to:
☐ HTML
☐ XLS
☐ XML
☐ All of the Above
Space to move this question.
Question 3 1 pts
Query Manager is available to:
☐ Query Developers
☐ Anyone with access to ctcLink

Page | 36
PS QUERY 101

Question 4 1 pts
Query Manager gives users the ability to:
☐ Create and Manage Queries
☐ Export Query Results
☐ Add Queries to Favorites
☐ Delete Queries
☐ Organize Queries into Folders
☐ All of the Above
Space to move this question.
Question 5 1 pts
What are the two symbols used in searching with Wildcards?

Question 6 1 pts
The percent sign replaces a of characters.
Space to move this question.
Question 7 1 pts
The underscore replaces a character.

Question 8 1 pts
Queries can be scheduled through Query Viewer, Query Manager or Schedule Query
☐ True
☐ False

Question 9 1 pts
A common reason to schedule a query is if the query has a large result set.
☐ True
☐ False

Question 10 1 pts
The Run Control ID is used to tell the system: [answer1], [answer2] and [answer3] the query is to be
scheduled.

Question 11 1 pts
The Process Monitor displays the [answer1] of the query run whereas the Report Manager displays
the [answer2]
Space to move this que on.

Page | 37
PS QUERY 101

 Section 2 Exercises Campus Solutions


1. Navigate to PeopleSoft Query Viewer and search for the Query
QCS_AA_ENROLLED_NO_ADVISOR. Select to run the output to HTML using the following
prompts:
 Institution – WA171
 Term – 2161
 Career – UGRD
List the number of results returned

2. Practice changing the prompts in the HTML output. Change the following:
 Institution - WA220
 Term – 2147
 Career – CNED
List the number of results returned

3. Returning to Query Viewer, select Advanced Search and using the % Wildcard search for all
Queries in folders that begin with: Academic% How many Queries were returned:

4. Still in Advanced Search look for all Queries which use the Field Name DISB_PLAN. You may
practice using Wildcards in this search as well. How many Queries were returned:

5. Go back to Basic Search and look for and select any Query that begins with QC_ then add the
selected Query to your “Favorites”. List the name of the Query here:

6. Navigate to Query Manager and search for QCS_PAULA_STDNT_ENROLL_INSTIT. Run the


Query to Excel. Use the following for the prompts:
 Institution – WA172
 Status – Waiting
 Term - 2163
Open the file in Excel. How many results were returned?

7. Return to Query Manager and this time select to edit the Query
QCS_PAULA_STDNT_ENROLL_INSTIT. Save as a New Query and insert your name in for
Paula. Now Search for your Query in Query Manager and click the checkbox to the left to
select it and from the Action Tab choose to change the name of your Query. Change the
name to: QCS_SR_STDNT_ENROLL_”your initials” inserting your initials at the end of the
Query.

8. Navigate to Schedule Query and schedule your Query to run immediately.


Write down your Process Instance number here:
View your Query results in Report Manager.

Page | 38
PS QUERY 101

 Section 2 Exercises Human Capital


1. Navigate to PeopleSoft Query Viewer and search for the Query
QHC_HR_EMPLOYEES_BY_BUS_UNIT. Select to run the output to HTML using the following
prompts:
 Business Unit – HR170
List the number of results returned

2. Practice changing the prompts in the HTML output. Change the following:
 Business Unit – HR220
List the number of results returned

3. Returning to Query Viewer, select Advanced Search and using the % Wildcard search for all
Queries in folders that begin with: Pay%
How many Queries were returned:

4. Still in Advanced Search look for all Queries which use the Field Name VENDOR_CLASS. You
may practice using Wildcards in this search as well.
How many Queries were returned:

5. Go back to Basic Search and look for and select any Query that begins with QH_ then add the
selected Query to your “Favorites”.
List the name of the Query here:

6. Navigate to Query Manager and search for QHC_PAULA_EMPL_BY_CO. Run the Query to
Excel. Use the following for the prompts:
 Business Unit – HR220
Open the file in Excel. How many results were returned?

7. Return to Query Manager and this time select to edit the Query QHC_PAULA_EMPL_BY_CO.
Save as a New Query and insert your name in for Paula. Now Search for your Query in Query
Manager and click the checkbox to the left to select it and from the Action Tab choose to
change the name of your Query. Change the name to: QHC_HR_EMPL_BY_CO_”your
initials” inserting your initials at the end of the Query.

8. Navigate to Schedule Query and schedule your Query to run immediately.


Write down your Process Instance number here:
View your Query results in Report Manager.

Page | 39
PS QUERY 101

 Section 2 Exercises Financials


1. Navigate to PeopleSoft Query Viewer and search for the Query
QFS_PO_VENDOR_ITEM_DETAIL. Select to run the output to HTML using the following
prompts:
 Unit – WA220
List the number of results returned

2. Practice changing the prompts in the HTML output. Change the following:
 Institution – WA170
List the number of results returned

3. Returning to Query Viewer, select Advanced Search and using the % Wildcard search for all
Queries in folders that begin with: Expen%
How many Queries were returned:

4. Still in Advanced Search look for all Queries which use the Field Name EXPENSE_TYPE. You
may practice using Wildcards in this search as well.
How many Queries were returned:

5. Go back to Basic Search and look for and select any Query that begins with QF_ then add the
selected Query to your “Favorites”.
List the name of the Query here:

6. Navigate to Query Manager and search for QFS_PAULA_VENDOR_LOC. Run the Query to
Excel. Use the following for the prompts:
 SetID: WACTC
 Location: 220
Open the file in Excel. How many results were returned?

7. Return to Query Manager and this time select to edit the Query QFS_PAULA_VENDOR_LOC.
Save as a New Query and insert your name in for Paula. Now Search for your Query in Query
Manager and click the checkbox to the left to select it and from the Action Tab choose to
change the name of your Query. Change the name to: QFS_AP_VENDOR_LOC_”your initials”
inserting your initials at the end of the Query.

8. Navigate to Schedule Query and schedule your Query to run immediately.


Write down your Process Instance number here:
View your Query results in Report Manager.

Page | 40
PS QUERY 101

 Section 3 Introduction
Section 3 will teach you the steps to use in simple query creation and provide an overview of the
Query Manager Tabs. You will then learn about joins in PS Query and how they work to link records
together. We will begin the discussion on criteria in PS Query and what they mean to queries as
well as how to improve query efficiency and use prompts instead of hard coded data. The exercises
at the end of the section will be pillar specific to give users the chance to use records from the pillar
they actually work in. This will re-enforce finding and using records which contain good information
- one of the key components in successful query development.

At the end of this section you will be able to:

 Look up common Records to use in query development per pillar.


 Create simple queries.
 Join multiple records together to create more complex queries.
 Use criteria to refine query results.
 Make queries more efficient by using prompts.

 Creating Queries

Finding Records to Use


Finding records which have good, accessible data is one of the most challenging aspects of
query creation. It is vital that each Query Developer understand that the data records used in
query creation should be as consistent as possible. This means most of us using the same
records for our queries. The SBCTC Data Services website has some helpful documents about
what core tables are helpful in query creation as well as what prompt tables to use with certain
fields, etc. Follow this link to check out some of the great resources found there. SBCTC Data
Services. Particularly helpful are the documents on common tables for query creation.

Page | 41
PS QUERY 101

Tab Overview and Creating a Simple Query - Detailed Instructions


A simple query uses only a single record to create the query. To create a simple query, navigate
to Query Manager. The initial page will display search functionality that will allow users to find
existing queries. It is required to always first search for an existing query that will meet users’
needs before developing new Queries. Please see the QDLC course for further information. If,
after searching, a suitable query is not found then click on "Create New Query".

This will take users to the main query development page. There are 11 tabs available for use in
creating queries – for the purpose of this course we will discuss only the following tabs:

 Records
 Query
 Prompts
 Fields
 Criteria
 View SQL
 Run

The other tabs are for more advanced developing in PS Query and will be discussed in other
trainings.

Page | 42
PS QUERY 101

The Records Tab

Keeping in mind that a query is a compilation of fields, the first thing to do is to find the data
that is to be queried. Fields live in records so it follows that in order to query the correct fields
we must find the records they live in.

To do this we go to the Records tab (note that when "Create New Query" is clicked the system
will automatically take users to the Records tab). ***The purpose of the Records tab is to
provide a location where users are able to search for and select one or more records to use in
their queries. ***

SEARCHING RECORDS

There are two search options in the Records tab: Basic and Advanced. The basic search allows
the Operator “Begins With” and the options of:

Page | 43
PS QUERY 101

The advanced search allows multiple operators with the same options as the basic
search. Wildcards are available for use in both search types.

Click on “Search” to display the list of records.

USING THE LIST OF RE CORDS

The Title Bar has some options available for how users would like to view the list.

Personalize – allows options on viewing the results

Find – will go to the next available record with the search string

View – will give option to view all, 100 records or 20 records

Zoom – creates a pop out window where the results display

Download - allows results to be downloaded to xls file


Navigation – give options to navigate the pages of results

Page | 44
PS QUERY 101

From the list of records users are able to either "Add Record" or "Show Fields".

"Show Fields" will display the record and all the fields that comprise the record. Note that the
Key Fields are indicated with a Y in the Key column.

Click on "Return" to go back to the list of records.

"Add Record" will take the user to the Query tab and allow the user to select which fields to use
in the query.

Note: Clicking “Return to Search” found at the very bottom of the record will discard the
current record selection and bring the user back to the search screen with no records
displaying. A pop up window will appear where users can confirm this action.

The Query Tab

The Query tab is where all records being used in the query are displayed and fields to be used in
the query are selected. As this is a simple query only a single record is displayed in the image
below. However, if multiple records are selected they will all display in the Query tab. Expand
or collapse the record to view the fields within it by clicking on the folder icon to the left of the
record name. ***The purpose of the Query tab is to provide a location where all of the records
used in the query can be displayed and where fields can be selected to use in the query . ***

Page | 45
PS QUERY 101

SELECTING FIELDS TO DISPLAY IN THE QUERY RESULTS

Select the fields to use in the query by clicking in the checkbox to the left of the Field Name.

Tip! Click the A/Z icon in the upper right section of the screen to view the results
alphabetically!
Tip! Users are able to select or deselect all fields quickly and easily by clicking the "Check All" or
"Uncheck All" buttons.

REMOVING A RECORD FROM A QUERY

Sometimes, there may be a need to remove a record from a query. In order to remove a record
from a query simply click on the minus sign to the right of the record name (to the right of the
Hierarch Join hyperlink).

Page | 46
PS QUERY 101

The Prompts Tab

If a prompt has been created to be used in the query the Prompts tab will display the prompts
along with the option to edit the prompt. Users are also able to create prompts in the Prompts
tab. ***The purpose of the Prompts tab is to create and display prompts***

Please note that new prompts must be re-created for each new query. It is not possible to
create and save a prompt for use across multiple queries.

The Fields Tab

Once the fields to be used in the query have been selected we can then determine how those
fields should be displayed. ***The purpose of the Fields tab is to show a list of all of the fields
selected for the query and to determine how those fields should be displayed in the query
results***

Here we are able to reorder the display, determine sort order, change heading text and choose
translate values, where applicable. In addition, as developers continue their PS Query training
and learn about more advanced options they will find the Fields tab is where many advanced
functions are started.

Page | 47
PS QUERY 101

REORDER/SORT

Click on the "Reorder/Sort" button to select these options.

Each field is numbered in the Column section and this number determines where the field will be
displayed in the list. To change the order, simply enter in the New Column section the number of
the column where to display the field.
Users are also able to select sort order from this screen. In the example to the left a “New
Order By” was selected to sort the results by Class Number in Descending Order and by Course
Career in the default Ascending Order

Had a previous sort order been determined it would be displayed in the Order
By column. Multiple sorts are possible simply by selecting 1 in the field for the first sort, 2 for
the second sort and so on. When finished, click "OK" to return to the Fields tab.

Next, let’s select a field that has an XLAT or Translate Value to edit. In the CS Pillar the record
STDNT_ENRL has fields with a Translate Value. In HCM the record HR_ACCTG_LINE has fields
with a Translate Value while is FS the CUSTOMER table is a good record to use for this
exercise. Click the “Edit” button next to the selected field.

Page | 48
PS QUERY 101

TRANSLATE VALUES
Translate Values are used for fields that are able to read their display values from a translate
table. The default is None which tells the system not use the translate table and to display the
non-translated value. For example, the Student Enrollment Status field default values are E and
D as shown here.

As this may not make sense to the final end user of the query it is possible to look up
the Translate Value and select a different option to display. In this example we will select Long.

Now when we run the query we will see the display values from the translate table which are
much more user friendly.

The Effective Date for Short/Long is more advanced functionality and will be covered in other training.

Page | 49
PS QUERY 101

EDITING DISPLAY OPTIONS

There are three options to modify if the field has a Translate Value and only two options if there
is not a Translate Value.

Translate Value  Heading


Options
 Aggregate
 Translate Value

No Translate  Heading
Value Options
 Aggregate

Page | 50
PS QUERY 101

The Heading box allows the user to select “No Heading”, “Short Heading” and “Long Heading”
or to type in a “Text Heading”. The default heading text will display in the Heading
Text field. This display will change based on the selection. For example, if “No Heading” is
selected then nothing will display in the Heading Text field.

In the example above “Text” was selected and “Student Enrollment Status” was manually
entered in the Heading Text field.

Aggregate is a more advanced functionality and will be covered, in other training classes and
manuals. It is used to apply aggregates to the data.

REMOVING FIELDS FROM A QUERY

To remove a field from the query users can go back to the query tab and de-select the checkbox
next to the field to be removed or from the Fields tab click the "Minus Sign" icon next to the
selected field.

Page | 51
PS QUERY 101

The Criteria Tab

***The purpose of the Criteria tab is to allow users a place to create and/or view criteria that
will refine the results of their Queries***

It is important to note that users are able to create criteria in the Query tab and the Fields tab.
The criteria used in the query however MUST display in the Criteria tab. For example, if a
prompt has been created but does not display in the criteria tab then the prompt will not
function in the query as expected. The prompt must be tied as criteria to the query.

In this tab, criteria may be re-ordered and/or grouped for more logical execution. For the
purpose of this class we will be using the criteria tab to create simple Filters and
prompts. More in depth training on the Criteria tab will be provided in other trainings.

Page | 52
PS QUERY 101

View SQL Tab

Now that the display options have been selected it is time to review the SQL coding. To do this,
simply click on the View SQL tab. ***The purpose of the View SQL tab is to allow users to
review the SQL statements being used in the query***

Run Tab

***The purpose of the Run tab is to allow users to view the results of the query***

Users are now ready to run the query and check how the results will display as well as how long
it takes to run. Make sure to save any changes to the query before running. Queries should not
take over 1 minute to run and most should run much quicker than that. In order to run the
query, simply click on the Run tab. This will automatically start the process. Users may receive
a pop up message stating that the query is returning too many results. Note though the
message implies that there are more than 50,546 rows it is actually a combination of rows and
columns that is assessed so it is possible to have only 30,000 rows of data returned and still
have this message appear. If this message displays the query will need to be scheduled in order
to retrieve the full result set.

Click "OK" to view the results however consider adding a prompt or other criteria to narrow
down the number of results.

Page | 53
PS QUERY 101

VIEWING QUERY RESULTS

The results of the query will display. Each row is numbered and each column is labeled in the
way that was designated in the Fields tab. In addition any Translate Values will display as
indicated in the Fields tab.

From here users are able to:


 View All - see all the results in a single page
 Rerun Query
 Download to Excel

Saving the Query and Hyperlink Options


It is generally wise to save the query as soon as possible and as often as possible. At the
bottom of the screen in all tabs there will display some options for the query via hyperlinks as
well as the "Save" button.

Page | 54
PS QUERY 101

Save Button: Will bring up a pop up window where users enter details regarding the query the
first time it is clicked. Afterwards it will save any changes made to the query.
Save As: Will save the query as a new query. Brings up pop up window where details regarding
the query are entered.
New Query: Will take the user to the first screen of creating a new query.
Preferences: Allows the user to select to display the name and description of the fields used in
query or only the description wherever the fields are displayed. Also allows users to select or
deselect the functionality of PS Query that will auto-join on fields of the same name. The
default is to allow auto-join.
Properties: Displays the properties of the query. The Properties Page will also display the last
update time and user.
Publish as Feed: Allows for the query results to be published as a feed.
New Union: Allows for the user to create a union between two records. This functionality will
be discussed in the ctcLink PS Query 301 course.

For new queries simply click "Save". Please note: if the query is a modification of an existing
query select “Save As”. For more information on modifying existing queries please see
the QDLC course.

Users will be prompted to enter information regarding the query. Systematically required fields
are denoted with an *, however again, please see the QDLC course for additional details on
what fields are required per SBCTC Data Services policy.

Fields to fill out are:

Query Name - follow the QDLC convention for naming the query. Queries that do not follow
this convention could be deleted during environment refreshes or system upgrades.
Query Description - 30 character description of the query.
Folder - Folder the query should be assigned to.
Query Type - Leave the default type of "User".
Owner - Select private or public. Only public queries will be migrated.
Query Definition - detailed description of the query including developer's institution cod, email
address, creation date among other details. Please see the QDLCcourse for more information.

Click "OK" to save.

The Query Name and Description will now display at the top of every tab.

Page | 55
PS QUERY 101

NOTE: The Query Properties Page also found in the hyperlinked options at the bottom of the
screen looks almost exactly like the Save screen but it DOES NOT save the query. The "Save"
button must always be clicked in order to save any changes.

Query Creation Stages Review

To review, the stages of query creation are:

 Find a record (Records tab)


 Add fields (Query tab)
 Save query according to the correct conventions and protocol (This can be done at any
point in the query)
 Determine how the query will display results. (Fields tab)
 Add criteria (Criteria tab)
 Add prompts (Prompts/Field or Query tab)

Not all of the stages must be completed and the order they are done in is completely up to the
Query Developer with the exception of adding a record and selecting fields.

Page | 56
PS QUERY 101

 Create Your Own Simple Query

The exercises below are pillar specific. Select the pillar most worked in and complete the
exercise for that pillar.

Create a Query Simplified Instructions


The purpose of this exercise is to give users the chance to practice creating a simple
query. Though the video below shows all of the steps in creating a query, including adding
criteria and creating joins, etc. For this exercise we will ONLY find a record to use in the query,
select fields to display in the query results, update how the query results will display and save
the query.

Criteria to Use in the Query


Use the following criteria when completing this hands on exercise.

RECORDS TO USE:
 CS – Search for and use the record: STDNT_ENRL
 HC – Search for and use the record: BENEF_PLAN_TBL
 FS – Search for and use the record: CUSTOMER

FIELDS TO USE:
(Select as many other fields as you like but be sure to include the following fields):
 CS: Select the fields: INSTITUTION and STRM as well as any other fields desired.
 HC: Select the fields: SETID and PLAN_TYPE as well as any other fields desired.
 FS: Select the fields: SETID and CUST_ID as well as any other fields desired.

NAME YOUR QUERY:


 QCS_SR_TRAIN_FNAME where FNAME is your first name.
 QHC_BA_TRAIN_FNAME where FNAME is your first name.
 QFS_PR_TRAIN_FNAME where FNAME is your first name.

SIMPLIFIED INSTRUCTIONS
 Navigate to Query Manager.
 Click on “Create New Query”.
 This will take you to the Records tab where you will search for and select the record to
use in the query.
 Go to the Query tab, select the fields from the selected record to use in the query.
Remember to expand the record if necessary.
 Go to the Fields tab, make any edits to the display of the heading text, translate values,
field order or sort order.
 Save Changes

Page | 57
PS QUERY 101

 Creating Joins in PS Query


Joins are used to create queries based on multiple records. Users manually link the records to
retrieve the output

Join Types
There are two types of Joins used by PS Query:
 Standard or Equivalent Joins
 Left Outer Joins
Joins normally MUST have a Key Field in common to be effective. This means that if the base
record has a Key Field of Institution for example, the second record joined must also have the
Institution field if the user is joining the query based on institution.

Cartesian Joins

There is one other join type that will rarely, if ever be used. If there are no common Key Fields
between records then PS Query will join the records but the result is what is called a Cartesian
Join or a Cross Join. Each row of the first record is paired with ALL of the rows of the second
record. This will produce an overwhelming number of results and data that makes no
sense. Cartesian Joins are useful for load testing but should generally never be used outside of
that. A message box will appear letting the user know that there are no common fields on
which to join the two records.

In this case, the only thing allowed is to click "OK" to add the record to the query. Once it's
been added, simply go to the Query tab and remove the record by clicking the minus sign to the
right of the record name (found to the right of the Hierarchy Join hyperlink).

Page | 58
PS QUERY 101

Note: There are instances where records that do not have common Key Fields but do have
common fields are able to be joined. This is a more advanced process and will be covered in
other trainings/manuals.

Standard Join

Standard Joins link data only when a match occurs between the Key Fields. What this means is
that if record A has 10 rows of data when record B is joined to it, only rows that have data in
both Key Fields will be joined resulting in the possibility of not all rows in the record A being
displayed. Let’s take a look at what that means in real life query development. Our original
query returned 21,695 results.

Page | 59
PS QUERY 101

After performing a Standard Join to add the City and State to the query there are now 16,411
results as not all of the rows had matching City/State information.

The different Join types all have a purpose it is just important to understand exactly how they
work and what the data will reflect.

Outer Join

This Join type will always return all of the rows in record A. If there are non-matching fields in
record B then a value of NULL will be returned. In the example below 12,967 rows are returned
with our simple query.

After doing a Left Outer Join to add the Name the query results still display all 12,967 rows.

Page | 60
PS QUERY 101

Creating a Join - Detailed Instructions


Join Methods

There are three methods to create a Join:


 Pre-Defined Join Method
 Hierarchy Join Method
 Any Join Method
Note: Best practice is to use the Any Join method to create a join in PS Query as this is the only
method that will automatically add the join criteria. This means that whenever the records
have key fields in common, PS Query will create the criteria for the user. This ensures that ALL
key fields are always linked.

PRE-DEFINED JOIN METHOD

Once a record has been added to the query users are able to see if there are any pre-defined
joins by navigating to the Query tab. To the right of the fields in the record users will see any
possible predefined joins.

Click on the name of the record to be joined.

A pop up window will appear with the option to select either Standard or Left Outer Join. Make
the selection and click "OK".

Page | 61
PS QUERY 101

Select the fields to add to the query from the new record. Note: Though PS Query will add join
criteria to the SQL code, it is not automatically added to the Criteria tab leaving the Query
Developer unable to modify this criteria.

HIERARCHY JOIN METHOD

Once a record has been added to the query users are able to see if there are any Hierarchy
Joins by navigating to the Query tab. In the upper right corner of the Chosen Records box users
will see a hyperlink for "Hierarchy Join". Click on the link to see the Hierarchy.

Select the record from the Hierarchy list to join.

Page | 62
PS QUERY 101

Note that there is not an option to choose which type of join is being performed. All Hierarchy
Joins are Standard Joins. Select the fields to add to the query from the new record.
Also Note: Though PS Query will add join criteria to the SQL code, it is not automatically added
to the Criteria tab leaving the Query Developer unable to modify this criteria.

ANY JOIN METHOD (PREFERRED JOIN METHOD)

To complete an Any Join, once the first record has been added to the query simply return to the
Records tab where users can search for a different record to add. The list of results will now say
"Join Record" instead of "Add Record".

Click on the record to be joined

A pop up window will appear with the option to select either Standard or Outer Join Type.

Select the correct hyperlinked record to tell the system which base record to join the new
record to.

Page | 63
PS QUERY 101

In the example below we are joining PERSONAL_PHONE (record B) to the first record
STNDT_CAR_TERM (record A). Select the join type and click on the hyperlinked name of the first
record to complete the join.

Another pop up window will appear asking users to confirm the Auto Join Criteria. Click on
"Add Criteria".

Select the fields to add to the query from the new record (record B).

Note: Any Join will allow users to create a Cartesian Join. If a pop up window appears stating
that no join conditions were found then the two records do not share any common Key Fields
and should usually not be joined.

Also Note: The Any Join method will add the join criteria to both the SQL code and to the
Criteria tab allowing Query Developers to modify it.

 Create Your Own Join


The exercises below are pillar specific. Select the pillar most worked in and complete the
exercise for that pillar.

Creating a Join - Simplified Instructions

Page | 64
PS QUERY 101

The purpose of this exercise is to give users the chance to practice creating a join. The video
below shows the steps for creating a join using the Any Join method. For this exercise we will
also use the Any Join method, which is the preferred method to use when creating joins.

Use the following criteria when completing this hands on exercise.

RECORD ALREADY IN USE IN THE QUERY:


CS – Search for and use the record: STDNT_ENRL
HC – Search for and use the record: BENEF_PLAN_TBL
FS – Search for and use the record: CUSTOMER

NEW RECORD TO JOIN TO THE QUERY:


CS – Search for and use the record: PERSON_NAME
HC – Search for and use the record: VENDOR_PROV_VIEW
FS – Search for and use the record: CUST_ADDRESS

FIELDS TO USE FROM THE NEW RECORD:

CS: Select the fields: NAME


HC: Select the fields: VENDOR_NAME_SHORT
FS: Select the fields: ADDRESS1, ADDRESS2, CITY, STATE

INSTRUCTIONS
 Create the join by navigating to the Records tab.
 Search for the record to join to your query.
 Select the hyperlink 'Join Record'.
 Select to use either a Standard Join or a Left Outer Join Type.
 Click on the hyperlinked name of the record which the new record will be joined to.
 Select/confirm the Auto Join Criteria by clicking on "Add Criteria" button.
 Save changes.

 Using Criteria in PS Query


Criteria allows users to determine filters for their data. For example, instead of returning results
for all institutions, users can specify a specific institution. For the scope of this training we are
looking at simple criteria and how to use them though criteria can be quite complex.

Joins should actually create criteria by stating that two records selected share common
fields. A typical join criteria would be that A.EMPLID = B.EMPLID. Meaning that the employee
ID from record A, must equal the employee ID from record B. Other criteria could be specific
institutions, terms, accounts, vendors, employees, etc. The criteria can be “hard coded”, which

Page | 65
PS QUERY 101

means that there is no choice available. For example, the query can be hard coded to only pull
results for institution WA220. Or prompts can be used as criteria to give the end user the option
to select which institution for which they would like to see results.

There are two ways to add criteria to a query.

1. Navigate directly to the Criteria tab and click on the “Add Criteria” button.

2. Use the “Add Criteria” icon in either the Fields Tab or the Query tab.

Adding Criteria Using the Criteria Tab – Detailed Instructions


Click on the “Add Criteria” button.

Page | 66
PS QUERY 101

Criteria Properties
Here we see the options available for creating criteria.
 Expression 1 Type
 Expression 1
 Condition Type (Operators)
 Expression 2 Type
 Expression 2
 Criteria Belongs to (Only displays when a Left Outer Join has been selected)

 WHAT - Expression 1 is WHAT you want to filter on; institution, term, state, etc.
 HOW - The Condition Type is HOW you want to filter; equal to, greater than, less than, etc.
 VALUE - Expression 2 is the comparison VALUE; institution WA171, term 2163, etc.
 WHERE - "This Criteria Belongs To” tells the system WHERE to place the criteria in the SQL
code.

Page | 67
PS QUERY 101

EXPRESSION 1

Expression 1 can be either a Field or an Expression. Here we will choose Field.

To select WHICH field will be used for Expression 1 click on the "Magnifying Glass" icon in the
Choose Record and Field box.

If there is more than one record being used in the query, the user will have the option to "Show
Fields" from record A or from record B. Click on the hyperlink of the Field to use in the
Expression 1 box.

The selected Field will appear in the Expression 1 box.

Page | 68
PS QUERY 101

CONDITION TYPE

The Condition Type determines how Query Manager compares the Expression 1 to the value in
Expression 2.

The various condition types are listed on the following page.

Page | 69
PS QUERY 101

The value in the selected record field falls between two comparison
Between
values. The range is inclusive.
The value in the selected record field exactly matches the comparison
Equal to
value.
This operator is different from the others, in that it does not compare a
Exists record field to the comparison value. The comparison value is a subquery.
If the subquery returns any data, the corresponding row is returned.
Greater Than The value in the record field is greater than the comparison value.
The value in the selected record field matches one of the comparison
In List
values in a list.
The value in the selected record field appears as a node in a tree created
with PeopleSoft Tree Manager. The comparison value for this operator is
a tree or branch of a tree that PeopleSoft Query should search.
In Tree
Note: PeopleSoft Query should not use trees that contain a combination
of dynamic details and range details. The results returned from trees with
this combination of details may be inaccurate.
The selected record field does not have a value in it. Users do not specify
Is Null a comparison value for this operator. Key fields, required fields, character
fields, and numeric fields do not allow null values.
Less Than The value in the record field is less than the comparison value.
The value in the selected field matches a specified string pattern. The
comparison value may be a string that contains wildcard characters.
Like
PeopleSoft Query also recognizes any wild-card characters that the
database software supports.

Also available are:


 Not Between
 Not Equal To
 Not Greater Than (equal to or less than logic)
 Not in List
 Not in Tree
 Not Less Than (equal to or greater than logic)
 Not Like

Select the preferred Condition Type.

Page | 70
PS QUERY 101

EXPRESSION 2

Expression 2 can be a:
 Field
 Expression
 Constant
 Prompt
 Subquery

For the purpose of this training we will discuss Field, Constant and Prompts. Expressions and
Subqueries will be discussed in subsequent trainings.

 Field - Using Expression 2 as a field uses the data in the selected field as the comparison
Value. This is how Joins are able to relate two or more records. For example, the criteria
A.EMPLID = B.EMPLID is expressing as criteria that the field Employee ID from record A
must be the same as the field Employee ID in record B.
 Constant - Using Expression 2 as a Constant allows the user to enter a specific value, for
example, a specific institution. This means the query will be developed for this
institution only.
 Prompt - Using Expression 2 as a prompts allows the end user to select the value, for
example, from a list of institutions. This allows multiple users to use the same query as
they are each able to select different institutions.

Select Expression 2 as a Constant and enter in WA171 in the Constant Field.

THIS CRITERIA BELONG TO

The default for This Criteria Belongs To will be to add the criteria to the WHERE clause of the
SQL Statement. The field will only display in queries that have used a Left Outer Join. We will
go into further detail on this in the PS Query 201 course.

Page | 71
PS QUERY 101

Click "OK".

The new criteria have now been added to the query and only results for institution WA171 will
display when the query is ran.

Logical Operators for Criteria

Logical Operators tell PeopleSoft Query how to coordinate different criteria. When users link
two criteria with AND, a row must meet the first and the second criterion for PeopleSoft Query
to return it. When users link two criteria with OR, a row must meet the first or the second
criterion, but not necessarily both.

Grouping Criteria with Parentheses

When the query includes multiple criteria, PeopleSoft Query checks the criteria according to the
rules of logic: it evaluates criteria that are linked by ANDs before those that are linked by ORs.
When all the criteria are linked by ANDs, this order always returns the correct results. When
users include one or more ORs, however, this is not always what is desired. See the example
below for clarification.

Page | 72
PS QUERY 101

EXAMPLE OF CRITERIA THAT RETURNS AN INCORRECT RESULT.

This example shows the criteria settings for a list of customers who have an active status and
reside in Washington DC (DC) or customers who reside in Maryland (MD).

The set of criteria that was entered in the previous example returns a list of customers in
Washington DC (except those who are inactive) and ALL customers in Maryland (including those
who are inactive). This list results because PeopleSoft Query evaluates based on the order of
operations:
 Parenthesis
 AND
 OR
It looks first for rows where the customer is active AND where the state is Washington
DC. Next it looks for results where the state is Maryland regardless of any other criteria.

What users really want PeopleSoft Query to search for are rows where the state is Washington
DC or Maryland AND where the customer type is inactive. That is, users want PeopleSoft Query
to evaluate the OR before the AND. To accomplish this task, add parentheses to the list of
criteria. When a list of criteria includes parentheses, PeopleSoft Query evaluates the criteria
inside the parentheses before the criteria outside the parentheses.

Using the Group Criteria button on the criteria page, insert the opening parenthesis just before
the field name and the closing parenthesis just after the comparison value.

Page | 73
PS QUERY 101

EXAMPLE OF CRITERIA THAT RETURNS A CORRE CT RESULT BY ADDING


PARENTHESES TO GROUP CRITERIA.

This record shows the Edit Criteria Grouping page with open and close parentheses in the Edit
Criteria Grouping section.

Match the order of operations number with the correct logical operator.

Adding Criteria Using the Add Criteria Icon - Detailed Instructions

To use the “Add Criteria” icon navigate to the Fields tab or the Query tab. The icon appears to
the right of the Field name in the Query tab and in the column Add Criteria in the Fields tab.

Click on the “Add Criteria” icon next to the Field to be used for the criteria selection.

Page | 74
PS QUERY 101

The first thing users will notice is that there is no need to choose the Expression 1 Field as it will
already be automatically filled in by the system using the Field you just selected for the criteria
selection.

From this point on, the way to set up criteria follows exactly the same steps as the Criteria Tab
instructions. Users will select the Condition Type, Expression 2 and This Criteria Belongs to as
explained earlier in this section.

 Create Your Own Criteria


The exercises below are pillar specific. Select the pillar most worked in and complete the
exercise for that pillar.

Adding Criteria Using the Criteria Tab - Simplified Instructions


The purpose of this exercise is to give users a chance to create criteria through both the Criteria
tab and the Add Criteria icon. The exercise is broken down into two parts. The first part will
guide the user through the steps to add criteria using the Criteria tab while the second part will
walk users through the process of adding criteria using the Add Criteria icon.

Criteria to Use in the Query


Use the following criteria when completing this hands on exercise.

RECORD CONTAINING THE FIELDS THE CRITERIA WILL BE ADDED TO:


CS – STDNT_ENRL
HC – BENEF_PLAN_TBL
FS – CUSTOMER

Page | 75
PS QUERY 101

FIELD TO ADD CRITERIA TO:


CS – INSTITUTION
HC – SETID
FS – SETID

VALUE TO USE FOR EXPRESSION 2


CS – WA220
HC – WACTC
FS – WACTC

INSTRUCTIONS
 From the Criteria tab click on “Add Criteria” button.
 Select Expression 1 Type of "Field"
 Select the Field to use as criteria for Expression 1 by clicking on the magnifying glass icon
to search for the correct field.
 All records used in the query will display with the record A fields defaulting in the
display. To select a field from another record simply click on the "Show Fields" button
to the right of the desired record.
 Select the Condition Type.
 Select the Expression 2 Type of "Constant".
 Enter the Expression 2 value to use as the comparison value.
 If using a Left Outer Join, select where the criteria belongs, either the WHERE clause or
on the clause of the Left Outer Join.
 If the Expression 1 field is from record A use the WHERE clause.
 If the Expression 1 field is from another record use the ON clause from the same record.
 Click OK.
 Select the Logical Operator for each criteria.
 Group or Reorder the criteria as necessary.

Adding Criteria Using the Add Criteria Icon - Simplified Instructions


Criteria to Use in the Query
Use the following criteria when completing this hands on exercise.

RECORD CONTAINING THE FIELDS THE CRITERIA WILL BE ADDED TO:


CS – STDNT_ENRL
HC – BENEF_PLAN_TBL
FS – CUSTOMER

FIELD TO ADD CRITERIA TO:


CS – STRM
HC – VENDOR_ID
FS – CUST_ID

Page | 76
PS QUERY 101

VALUE TO USE FOR EXP RESSION 2


CS – 2161
HC – V000000015
FS – 001000004

INSTRUCTIONS
 From the Query tab or the Fields tab, click on the “Add Criteria” icon next to the desired
field.
 The Expression 1 Type will default automatically to "Field".
 The field used as the Expression 1 will be automatically populated.
 Select the Condition Type.
 Select the Expression 2 Type of "Constant".
 Enter the Expression 2 value to use as the comparison value.
 If using a Left Outer Join, select where the criteria belongs, either the WHERE clause or
on the clause of the Left Outer Join.
 If the Expression 1 field is from record A use the WHERE clause.
 If the Expression 1 field is from another record use the ON clause from the same record.
 Click OK.
 Select the Logical Operator for each criteria.
 Group or Reorder the criteria as necessary.
 The video below shows adding "hard coded" criteria to a query through both the Criteria
Tab and the Add Criteria Icon.

 Using Prompts to Extend the Life of a Query


Run time prompts or prompts are the most useful functionality to extend the life of your query
and to increase its value. In the section on criteria we learned how to select a specific or hard
coded value to filter our query output. In this section we will learn how to do the same thing,
with the caveat, that users will be able to select a different value each time the query is ran.
What this means is that a single query can be developed that would be valuable for all colleges
or business units. Each college would simply run the query, inputting the code for their own
Institution in the prompt. Keep in mind that it is possible to prompt on a field that is not
displayed in the query results. For example, the prompt could be designed to filter by a specific
institution but the INSTITUTION field need not be one of the selected fields to show in the
query results.

Query Prompt Table Security


Though query security is determined based on the roles assigned to each developer, it is
required to add an additional layer of security though prompts. All queries in all pillars should
include an Institution, Business Unit or SETID prompt. Any exceptions to this rule must first be
approved by Data Services.

Page | 77
PS QUERY 101

Fields with required security prompt tables are:

CS
 INSTITUTION - INSTITUTN_SCRTY
 BUSINESS_UNIT - SP_BU_SF_OPRVW
FS
 BUSINESS_UNIT - SP_BU_GL_CLSVW
 SETID - SP_SETID_CLSVW
HC
 COMPANY - VHC_CMPNY_SCRTY
 BUSINESS_UNIT_GL - VHC_BU_GL_SCRTY
 BUSINESS_UNIT_HR - -VHC_BU_HR_SCRTY

Required and Recommended Prompt Tables to Use


To see the list of required and recommended prompt tables to use by pillar please click: HERE

Creating Prompts
Prompts are a type of criteria. It can be somewhat confusing when first starting with prompts
because the flexibility of PeopleSoft allows for two ways of achieving the same goal. Let’s go
over the “big picture” of adding prompts.

Creating Prompts Using the Prompts Tab


Using the Prompts Tab method to create prompts has more steps but clearly defines the
difference between creating the prompt and adding the prompt as criteria. When adding the
prompt through the Prompts Tab the user click on "Add Prompt" and then defines the prompt
properties. Click "OK". The prompt will NOT display or be used as criteria until the user adds
the prompt as criteria. To do this go to the Criteria tab and click on "Add Criteria" button.
Select the field to add the prompt to in Expression 1 and select the Expression 2 type as a
prompt and then click on the magnifying glass to search for the prompt just created. Click on
the hyperlink for the corresponding prompt. This will add the prompt as criteria.

Creating Prompts Using the Add Criteria Icon


Adding prompts through the add criteria icon basically combines the steps of creating the
criteria AND the prompt. The user starts the process of adding the criteria and then selects that
the Expression 2 type will be a prompt. THEN the user click on "Edit Prompt" to edit an existing
prompt or click on “New Prompt” to create one from scratch. That takes the user to the “Edit
Prompt Properties” page where the prompt is defined. When finished click "OK" to go back to
the Edit Criteria Properties page to finish out the process of creating the criteria. When done
the prompt will be defined on the Prompts tab AND listed as criteria in the Criteria tab.

Page | 78
PS QUERY 101

To summarize, there are two ways to add prompts to a query. Either navigate directly to the
Prompts Tab or, as prompts really are a just a specialized type of criteria, use the “Add Criteria”

icon in either the Fields Tab or the Query Tab.

Creating Prompts through the Prompts Tab – Detailed Instructions


Creating a prompt through the prompts tab is a two-step process where the first step is to create the
prompt and the second step is to tie the prompt as criteria for the query.

Create the Prompt

From the Prompts tab click on the “Add Prompt” button. The Edit Prompt Properties page will
appear.

Page | 79
PS QUERY 101

On this page you are able to add/modify the:


 Field Name – select the field to use for the prompt
 Heading Type – select the Long or Short Version of the Field Name or input Text.
 Type- Select the type of table.
 Heading Text – Enter the text for the Header.
 Format – choose the format for the prompt table, the system selects the default format for
the field selected.
 Unique Prompt Name – filled in automatically by the system and shouldn’t be changed.
 Length – determine the prompt field’s length
 Decimals – select how many decimals are allowed for numeric prompts
 Edit Type – define the prompt type of field edit
o No Table Edit – Provides a lookup list to the end user with no data validation. Allows for
a prompt to be optional.
o Prompt Table – Provides a lookup list to the end user where the data entered must be
validated against the data stored in the record which has been added to the Prompt
Table field. If some other value is entered the system gives an error saying, "Invalid
Value".
o Translate Table – Provides a dropdown that users can select from. The length of the
field should not exceed 4 char. Only used with fields which have a translate (XLAT)
value.
o Yes/No Table - This is will produce a prompt checkbox. By Default it will be checked
(Y). Only used with fields where a yes/no is applicable. For example; veteran, married,
etc.
 Prompt Table – provide users with a lists of values pulled from a different Record. For a list
of Prompt Tables to Use please see ctcLink PS Prompt Tables. (Links to an external
site.)Links to an external site.
o Select the Prompt Table to use for the prompt by clicking on the "Magnifying Glass"
icon next to Field Name.
 Select an Operator of either "Begins With" or "Contains" and search for the correct
Field Name.
 Optional Checkbox - this checkbox will allow for the prompt to be optional for the end
user. The Query Developer must indicate the prompt is optional if checked. Otherwise,
users will not know it is optional and must not always be filled in.
 Default Value - Allows the Query Developer to insert a default value into the prompt. For
example, if the developer is from Tacoma then WA220 could be entered for the institution
prompt. Query Developers must indicate that the prompt has a default value if one is
selected. Otherwise, it will appear to the end user that the value is hard coded and they will
not know that they can update it.

A list of hyperlinked results will appear. The interesting bit here is that the list will be
comprised of matching fields from ALL records, regardless of whether the record was selected

Page | 80
PS QUERY 101

for the query or not. For the prompt to work the field selected MUST be a field from one of the
records used in the query, however the field does NOT have to be displayed in the results.
Click on the correct Field Name to select the field on which to place the prompt.

Next make any desired changes to the Heading or other options.

Now select the Edit Type via the dropdown menu.

Page | 81
PS QUERY 101

Next, search for the correct record to add to the Prompt Table field to be used to provide a
lookup list to the end user. Search by clicking the "Magnifying Glass" icon under the Prompt
Table field. In this example, "Prompt Table" was selected as the Edit Type and the
INSTITUTN_SCRTY was selected as the record for the Prompt Table field.

Adding the Prompt as Criteria


Now that the prompt has been created it will need to be associated as criteria to the query.
 Go to the Criteria Tab and click “Add criteria”.
 Select the field to be used as the criteria and then select the Operator to use.
 Select Prompt as the "Expression 2 Type" and then click on the "Magnifying Glass" icon in
the Expression 2 Define Prompt box and search for the prompt just created.

Page | 82
PS QUERY 101

As there is already a prompt created you can select it from here by simply clicking on the
hyperlinked result.

Click OK.

Review the Criteria Tab to see that the prompt is now being used as part of the criteria for the
query. Note the prompt displays as a colon and the prompt number (:1). Prompts increase
incrementally. A second prompt would display as :2 in the Expression 2 column.

Page | 83
PS QUERY 101

Run the query.

A pop up window will appear displaying the prompt. Either enter the information in the Field
or click on the "Magnifying Glass" icon to see a list of options.

The query will run based on the information specified in the prompt.

Page | 84
PS QUERY 101

Creating Prompts with the “Add criteria” icon - Detailed Instructions


Creating prompts through the “Add criteria” icon in the Fields Tab or the Query Tab allows the
system to do some of the work for you, simplifying the process just a bit. Using this method has
the following benefits:
 The prompt will also be automatically be added as criteria for the query
 The Expression 1 Type and Value will be added to the prompt based on the field selection
 The Prompt Table field may automatically populate, however it may not always populate
with the correct record

To use the “Add criteria” icon, navigate to the Fields tab or the query tab. The icon appears to
the right of the field name in the query tab and in the column Add criteria in the Fields tab.

Click on the “Add criteria” icon next to the Field you want to use for the prompt
selection. Expression 1 will already be automatically filled in by the system using the field just
selected. Select Prompt as the Expression 2 Type and choose the Condition Type. Now users are
able to either use a prompt already created by searching using the magnifying glass or create a
new prompt. Click on “New Prompt”.

Page | 85
PS QUERY 101

Note that the Field Name and Prompt Table have been automatically populated (however in
the example above the incorrect record has been automatically added to the "Prompt Table"
field.
 It is very important to note that the selection for the Prompt Table made by the system is
NOT always accurate. In this example the TERM_TBL was selected automatically by the
system however the correct Prompt Table to use for the prompt to work is TERM_VAL_TBL.
If the prompt does not work correctly check the document: ctcLink PS Prompt Tables.

Make any changes and click "OK". This will take you back out to the Edit criteria Properties
page. Click "OK "again and then run the query.

A pop up window will appear with the first prompt of Academic Institution and the second
prompt of Term. This query has now been increased in value and longevity as users are able to
select which Institution and which term to display.

Users are able to start typing in the value for the prompt and the system will provide a list
based on the value typed in as shown below.

Page | 86
PS QUERY 101

Or users can click the magnifying glass to the right of the prompt to pull up the complete list of
values to select from as shown in the example below.

Note the maximum amount of values to select from is 300.

 Create Your Own Prompt


The exercises below are pillar specific. Select the pillar most worked in and complete the
exercise for that pillar.

Required Prompt with Lookup List through the Prompts Tab – Simplified
Instructions
To create a prompt through the Prompts/Criteria tabs that must be filled in and can be selected
from a list of validated lookup values (2 Step Process):
Page | 87
PS QUERY 101

The purpose of this exercise is to give users a chance to create a prompt through the
Prompts/Criteria tabs. The exercise is broken down into two parts. The first part will guide the
user through the steps to add a prompt using the Prompts tab and then the second part will
walk users through adding the prompt at criteria.

Criteria to Use in the Query


Use the following criteria when completing this hands on exercise.

RECORD CONTAINING THE FIELD TO WHICH TO ADD THE PROMPT:


CS – STDNT_ENRL
HC – BENEF_PLAN_TBL
FS – CUSTOMER

FIELD TO ADD PROMPT TO:


CS – INSTITUTION
HC – SETID
FS – SETID

PROMPT TABLE TO USE FOR THE PROMPT TABLE FIELD


CS – INSTITUTN_SCRTY
HC – DEPT_SETID_VW
FS – SP_SETID_CLSVW

Create the Prompt


 From the Prompts tab click on the “Add Prompt” button.
 Search for the field on which to place the prompt by clicking on the magnifying glass next to
"Field Name".
o Be careful which field is selected. A list of all fields that meet the search criteria will
display, regardless of the record the field lives in. Only fields that are in records used in
the query will work as a prompt for the query.
 Once the field has been selected some data will fill in automatically based on the field
selection. In this case we will not make any changes to the:
o Heading Type
o Type
o Heading Text
o Format
o Unique Prompt Name
o Length
o Decimals
 Select the “Prompt Table” edit type.
 Look up the correct record for the "Prompt Table" field.
 Leave the "Optional" checkbox unchecked and leave the "Default Value" box empty.
 Click “OK”.
Page | 88
PS QUERY 101

Add the Prompt as Criteria to the Query


 Navigate to the Criteria tab
 Click on the “Add Criteria” button.
 Select "Field" as the Expression 1 type
 Select the field on which to place the prompt by selecting the magnifying glass in the
Expression 1 box.
o The default display will be to show the fields from the A record however this can be
changed by clicking on the "Show Fields" button next to any other records in the query.
 Select the "Condition Type" of "Equal to"
 Select “Prompt” for the Expression 2 Type.
 Click on the magnifying glass in the Expression 2 box to search for the prompt that you just
created in the step above.
 Click on the hyperlinked name of the prompt created above.
 Click OK to finish creating the criteria.
 Save changes.
Run the query to verify the prompts are working correctly.

Optional Prompt with Lookup List Through the Add Criteria Icon –
Simplified Instructions
This exercise will give users the opportunity to practice using the add criteria icon for prompts creation.

Criteria to Use in the Query


Use the following criteria when completing this hands on exercise.

RECORD CONTAINING THE FIELD TO WHICH THE P ROMPT WILL BE


ADDED:
CS – STDNT_ENRL
HC – BENEF_PLAN_TBL
FS – CUSTOMER

FIELD TO ADD PROMPT TO:


CS – STRM
HC – VENDOR_ID
FS – CUST_ID

PROMPT TABLE TO USE FOR THE PROMPT TABLE FIELD


CS –TERM_VAL_TBL
HC – VENDOR_PROV_VW
FS – ID_CUST_VW
To create a prompt that can be left blank or selected from a list of lookup values through the
Add Criteria icon.

Page | 89
PS QUERY 101

INSTRUCTIONS
 From the Fields or Query tab click on the “Add Criteria” icon next to the field on which to
add the prompt.
o The Expression 1 type will be updated to "Field" and value in the Expression 1 box will
be automatically populated with the name of the field selected in the first part of this
step.
 Select the "Condition Type" of "Equal to"
 Select “Prompt” for the Expression 2 Type.
 Click on “New Prompt” hyperlink in the Expression 2 box.
 For this exercise we will not make any changes to the:
o Type
o Format
o Unique Prompt Name
o Length
o Decimals
 Change the "Heading Type" to Text
 Add (optional) to the end of text in the "Heading Text" field to let the users know that the
prompt will be optional.
 Select “No Table Edit” for the Edit Type.
 Search for the correct record to use as a lookup list for the selected field by clicking on the
magnifying glass next to the "Prompt Table" field.
 Click on the hyperlinked name of the correct record to use as the prompt table to select it.
o Use the "Prompt Tables to Use" document for a starting point in searching for the
correct record to use as a prompt table.
 Check the "Optional" checkbox
 Click “OK” to finish creating the prompt portion.
 Click "OK" again to finish adding the prompt as criteria.

 Course Review
The goal of this course was to empower Query Developers with the tools and skills needed to create
and manage basic queries.

The Objectives for this course were to give attendees the tools and necessary information to:
 Be able to explain how Relational Databases work for storing data.
 Effectively employ Query creation and management protocol and conventions.
 Achieve familiarity with Query Terms and Definitions.
 Access PS Query
o Viewer
o Manager
o Schedule Query
 Search for existing Queries using Wildcards.

Page | 90
PS QUERY 101

 Run Queries to multiple outputs.


 Look up common Records to use in Query development per Pillar.
 Create simple Queries.
 Join multiple records together to create more complex Queries.
 Effectively use Criteria to filter Query results.
 Make Queries more efficient by using Prompts.

To meet the Goal and Objectives we learned in Section 1 about Relational Databases and how they
work in efficiently storing data for easy retrieval for reporting. We discussed important Query
protocol and conventions ensuring effective Query migrations, development and maintenance. We
learned some helpful Query terminology ensuring all Query Developers are “on the same page” and
can “speak the same language”.

In Section 2 we learned how to access the three areas of PS Query:


 PS Query Viewer
 PS Query Manager
 Schedule Query

We also learned how to efficiently search for existing Queries using Wildcards; how to output
Query results into different formats such as XLS, HTML or XML and some of the benefits of
viewing Query results in various formats. We saw how to take actions on Queries such as
adding to a “Favorites” list and how to schedule a Query through Schedule Query as well as
view the Query results through this tool.

In Section 3 we learned how to find and utilize Records to create a simple Query and how to create
more complex Queries by utilizing Standard and Outer Joins. Finally, we saw how to use simple
Criteria to hard code filters in a Query and also how to make Queries more valuable by incorporating
Prompts.

Now get out there and have fun developing top notch Queries! 

Page | 91
PS QUERY 101

 Simplified Instructions
Find below all of the step by step instructions provided in this manual.

Scheduling through Query Viewer/Manager – Simplified Instructions for a


New Run Control ID
 Go to Query Manager or Query Viewer and search for the desired Query and click on the
"Schedule" hyperlink to the right of the query you would like to run.
 The Query name will automatically populate based on the Query selected from Query
Viewer or Query Manager.
 Click on the Add New Value tab and enter a Run Control ID.
 Click on the “Add” button.
 If there are prompts (parameters) in the query a pop up box will appear where they can
be filled in.
 Enter a description for the Query Run Control ID in the Description Field. This will be the
Report Name.
 Click Apply
 On the Process Scheduler page select the Time Zone, Date and Time to run the Query, if
desired. Also change the default output Type and Format, if desired
 Click OK
 Note the Process Instance Number
 View the status of the run via Process Monitor by clicking on the hyperlink.
o When done viewing click "Go back to Scheduled Query" hyperlink.
o Note this will take you ALL the way back to the very beginning page where your
new Run Control ID will be already filled in for you. Click on Search again to go to
the Schedule Query page with the Report Manager and Process Monitor
hyperlinks.
o If you hit the back button it is possible for the "Go back to Schedule Query"
hyperlink from the process monitor page to disappear.
 Alternately view the Process Monitor by navigating to Main Menu >
PeopleTools > Process Scheduler > Process Monitor
 View the results of the report via Report Manager by clicking on the hyperlink. You may
need to click on the "Administration Tab" in order to view the results of the scheduled
query
o Click on the hyperlinked name of the report (the description entered earlier) in
the Report column.

Page | 92
PS QUERY 101

o Click on the hyperlinked name of the query to download the results of the
scheduled query.
 Alternately view the Report Manager by navigating to Main Menu >
Reporting Tools > Report Manager

Scheduling through Query Viewer/Manager – Simplified Instructions for an


Existing Run Control ID
 Go to Query Manager or Query Viewer and search for the desired Query and click on the
"Schedule" hyperlink to the right of the query you would like to run.
 The Query name will automatically populate based on the Query selected from Query
Viewer or Query Manager.
 Click on Find an Existing Value and search for the Run Control ID.
 Click on the hyperlink for the Report Name or Run Control ID in the search results.
 If there are prompts (parameters) in the Query a pop up box will appear where they can
be filled in. To update existing parameters click on Update Parameters.
 Click Apply
 On the Process Scheduler page select the Time Zone, Date and Time to run the Query, if
desired. Also change the default output Type and Format, if desired
 Click OK
 Note the Process Instance Number
 View the status of the run via Process Monitor by clicking on the hyperlink.
o When done viewing click "Go back to Scheduled Query" hyperlink.
o Note this will take you ALL the way back to the very beginning page where your
new Run Control ID will be already filled in for you. Click on Search again to go to
the Schedule Query page with the Report Manager and Process Monitor
hyperlinks.
o If you hit the back button it is possible for the "Go back to Schedule Query"
hyperlink from the process monitor page to disappear.
 Alternately view the Process Monitor by navigating to Main Menu >
PeopleTools > Process Scheduler > Process Monitor
 View the results of the report via Report Manager by clicking on the hyperlink. You may
need to click on the "Administration Tab" in order to view the results of the scheduled
query
o Click on the hyperlinked name of the report (the description entered earlier) in
the Report column.
o Click on the hyperlinked name of the query to download the results of the
scheduled query.
 Alternately view the Report Manager by navigating to Main Menu >
Reporting Tools > Report Manager
 View the results of the report via Report Manager

Page | 93
PS QUERY 101

Scheduling through Schedule Query Menu Path – Simplified Instructions for a


New Run Control ID
 Navigate to Schedule Query: Main Menu > Reporting Tools > query > Schedule Query.
 Click on Add a New Value to create a new Run Control ID. Enter a Run Control ID.
 Click on the “Add” button.
 Enter the query name or search for the query.
 Enter a description for the query Run Control ID in the Description Field. This will be the
Report Name.
 If there are prompts (parameters) in the query a pop up box will appear where they can
be filled in. To update existing parameters click on Update Parameters.
 Click Run.
 On the Process Scheduler page select the Time Zone, Date and Time to run the query, if
desired.
 Also change the default output Type and Format, if desired.
 Click OK.
 Note the Process Instance Number.
 View the status of the run via Process Monitor by clicking on the hyperlink.
o When done viewing click "Go back to Scheduled query" hyperlink.
o Note this will take you ALL the way back to the very beginning page where your
new run control ID will be already filled in for you. Click on Search again to go to
the Schedule Query page with the Report Manager and Process Monitor
hyperlinks.
o If you hit the back button it is possible for the "Go back to Schedule Query"
hyperlink from the process monitor page to disappear.
 Alternately view the Process Monitor by navigating to Main Menu >
PeopleTools > Process Scheduler > Process Monitor
 View the results of the report via Report Manager by clicking on the hyperlink. You may
need to click on the "Administration Tab" in order to view the results of the scheduled
query
o Click on the hyperlinked name of the report (the description entered earlier) in
the Report column.
o Click on the hyperlinked name of the query to download the results of the
scheduled query.
 Alternately view the Report Manager by navigating to Main Menu >
Reporting Tools > Report Manager

 Scheduling through Schedule Query Menu Path – Simplified Instructions for Navigate to
Schedule Query: Main Menu > Reporting Tools > query > Schedule Query.
 Click on Find an Existing Value and select the correct Run Control ID
 If there are prompts (parameters) in the query a pop up box will appear where they can
be filled in. To update existing parameters click on Update Parameters.

Page | 94
PS QUERY 101

 Click Run.
 On the Process Scheduler page select the Time Zone, Date and Time to run the query, if
desired. Also change the default output Type and Format, if desired.
 Click OK.
 Note the Process Instance Number.
 View the status of the run via Process Monitor by clicking on the hyperlink.
o When done viewing click "Go back to Scheduled query" hyperlink.
o Note this will take you ALL the way back to the very beginning page where your
new run control ID will be already filled in for you. Click on Search again to go to
the Schedule Query page with the Report Manager and Process Monitor
hyperlinks.
o If you hit the back button it is possible for the "Go back to Schedule Query"
hyperlink from the process monitor page to disappear.
 Alternately view the Process Monitor by navigating to Main Menu >
PeopleTools > Process Scheduler > Process Monitor
 View the results of the report via Report Manager by clicking on the hyperlink. You may
need to click on the "Administration Tab" in order to view the results of the scheduled
query
o Click on the hyperlinked name of the report (the description entered earlier) in
the Report column.
o Click on the hyperlinked name of the query to download the results of the
scheduled query.
 Alternately view the Report Manager by navigating to Main Menu >
Reporting Tools > Report Manager

Creating a Simple Query - Simplified Instructions


 Navigate to Query Manager.
 Click on “Create New Query”.
 This will take you to the Records tab where you will search for and select the record to
use in the query.
 Go to the Query tab, select the fields from the selected record to use in the query.
Remember to expand the record if necessary.
 Go to the Fields tab, make any edits to the display of the heading text, translate values,
field order or sort order.
 Save Changes

Creating a Join - Simplified Instructions


 Create the join by navigating to the Records tab.
 Search for the record to join to your query.
 Select the hyperlink 'Join Record'.
 Select to use either a Standard Join or a Left Outer Join Type.

Page | 95
PS QUERY 101

 Click on the hyperlinked name of the record which the new record will be joined to.
 Select/confirm the Auto Join Criteria by clicking on "Add Criteria" button.
 Save changes.

Adding Criteria Using the Criteria Tab - Simplified Instructions


 From the Criteria tab click on “Add Criteria” button.
 Select Expression 1 Type of "Field"
 Select the Field to use as criteria for Expression 1 by clicking on the magnifying glass icon
to search for the correct field.
 All records used in the query will display with the record A fields defaulting in the
display. To select a field from another record simply click on the "Show Fields" button
to the right of the desired record.
 Select the Condition Type.
 Select the Expression 2 Type of "Constant".
 Enter the Expression 2 value to use as the comparison value.
 If using a Left Outer Join, select where the criteria belongs, either the WHERE clause or
on the clause of the Left Outer Join.
 If the Expression 1 field is from record A use the WHERE clause.
 If the Expression 1 field is from another record use the ON clause from the same record.
 Click OK.
 Select the Logical Operator for each criteria.
 Group or Reorder the criteria as necessary.

Adding Criteria Using the Add Criteria Icon - Simplified Instructions


 From the Query tab or the Fields tab, click on the “Add Criteria” icon next to the desired
field.
 The Expression 1 Type will default automatically to "Field".
 The field used as the Expression 1 will be automatically populated.
 Select the Condition Type.
 Select the Expression 2 Type of "Constant".
 Enter the Expression 2 value to use as the comparison value.
 If using a Left Outer Join, select where the criteria belongs, either the WHERE clause or
on the clause of the Left Outer Join.
 If the Expression 1 field is from record A use the WHERE clause.
 If the Expression 1 field is from another record use the ON clause from the same record.
 Click OK.
 Select the Logical Operator for each criteria.
 Group or Reorder the criteria as necessary.
 The video below shows adding "hard coded" criteria to a query through both the Criteria
Tab and the Add Criteria Icon.

Page | 96
PS QUERY 101

Required Prompt with Lookup List through the Prompts Tab – Simplified
Instructions
Create the Prompt
 From the Prompts tab click on the “Add Prompt” button.
 Search for the field on which to place the prompt by clicking on the magnifying glass
next to "Field Name".
o Be careful which field is selected. A list of all fields that meet the search criteria
will display, regardless of the record the field lives in. Only fields that are in
records used in the query will work as a prompt for the query.
 Once the field has been selected some data will fill in automatically based on the field
selection. In this case we will not make any changes to the:
o Heading Type
o Type
o Heading Text
o Format
o Unique Prompt Name
o Length
o Decimals
 Select the “Prompt Table” edit type.
 Look up the correct record for the "Prompt Table" field.
 Leave the "Optional" checkbox unchecked and leave the "Default Value" box empty.
 Click “OK”.

Add the Prompt as Criteria to the Query


 Navigate to the Criteria tab
 Click on the “Add Criteria” button.
 Select "Field" as the Expression 1 type
 Select the field on which to place the prompt by selecting the magnifying glass in the
Expression 1 box.
o The default display will be to show the fields from the A record however this can
be changed by clicking on the "Show Fields" button next to any other records in
the query.
 Select the "Condition Type" of "Equal to"
 Select “Prompt” for the Expression 2 Type.
 Click on the magnifying glass in the Expression 2 box to search for the prompt that you
just created in the step above.
 Click on the hyperlinked name of the prompt created above.
 Click OK to finish creating the criteria.
 Save changes.
 Run the query to verify the prompts are working correctly.

Page | 97
PS QUERY 101

Optional Prompt with Lookup List through the Add Criteria Icon –
Simplified Instructions
 From the Fields or Query tab click on the “Add Criteria” icon next to the field on which
to add the prompt.
o The Expression 1 type will be updated to "Field" and value in the Expression 1
box will be automatically populated with the name of the field selected in the
first part of this step.
 Select the "Condition Type" of "Equal to"
 Select “Prompt” for the Expression 2 Type.
 Click on “New Prompt” hyperlink in the Expression 2 box.
 For this exercise we will not make any changes to the:
o Type
o Format
o Unique Prompt Name
o Length
o Decimals
 Change the "Heading Type" to Text
 Add (optional) to the end of text in the "Heading Text" field to let the users know that
the prompt will be optional.
 Select “No Table Edit” for the Edit Type.
 Search for the correct record to use as a lookup list for the selected field by clicking on
the magnifying glass next to the "Prompt Table" field.
 Click on the hyperlinked name of the correct record to use as the prompt table to select
it.
o Use the "Prompt Tables to Use" document for a starting point in searching for
the correct record to use as a prompt table.
 Check the "Optional" checkbox
 Click “OK” to finish creating the prompt portion.
 Click "OK" again to finish adding the prompt as criteria.

Date Prompt – Simplified Instructions


 Create the Date Prompt
o Go to Prompts tab and click on “Add Prompt”.
o Leave the Field Name blank.
o On Type drop down select Date.
o Optional: Type the name of the Prompt in the Heading Text Field.
o On Format drop down select None.
o On Edit Type select No Table Edit.
o Click the "Magnifying Glass" on the Prompt Table and click on the “No Value” button.
o Click the “Ok” button.

Page | 98
PS QUERY 101

 Link the Date Prompt to the Selected Field as Query Criteria


o From the Criteria Tab click on “Add Criteria”.
o Select Field for Choose Expression 1 Type.
o In Expression 1 select the Date Field where to tie the Prompt by using the “Magnifying
Glass” icon.
o Select the Operator.
o In "Choose Expression 2 Type select Expression
o In Expression 2 click on “Add Prompt”.
o Select the Date Prompt previously created.
o Click “Ok”.
o Click “Save”

Date Range Prompt – Simplified Instructions


To create a Date Range prompt where random date range can be select it is necessary to create
2 Date prompts then link them through a criteria added to the date field.

 Create the First Date Prompt


o Go to the Prompts tab and click on “Add Prompt”.
o Heading Text should be Text.
o Type “From Date” in the Heading Text Field.
o Select Date on the Type drop down list.
o On the Format drop down list, select None.
o On Edit Type select No Table Edit.
o For the Prompt Table click on the "Magnifying Glass" icon and click on the “No Value”
button.
o Click “Ok”.
 Create the Second Date Prompt
o Go to the Prompts tab and click on “Add Prompt”.
o Heading Text should be Text.
o Type “To Date” in the Heading Text Field.
o Select Date on the Type drop down list.
o On the Format drop down list, select None.
o On Edit Type select No Table Edit.
o For the Prompt Table click on the "Magnifying Glass" icon and click on the “No Value”
button.
o Click “Ok”.
 Match your Prompts to the Selected Date Field and Add as Query Criteria
o Go to the Fields tab and identify the Date Field to tie to your Prompts.
o Click on the “Add Criteria” icon.
o As this was done from the Fields tab Choose Expression 1 and Expression 1 – Choose
Record and Field will be already filled in with the information from the selected Field.

Page | 99
PS QUERY 101

o For Condition Type select Between from the drop down list.
o For Choose Expression 2 Type select the Expr – Expr radio button.
o On Expression 2 – Define Expression click “Add Prompt”.
o Select and link the “From Date” Prompt.
o On Expression2 – Define Expression 2 click “Add Prompt”
o Select and link the “To Date” Prompt.
o "Save".

Page | 100
PS QUERY 101

Optional Numeric Prompt with No Lookup List – Simplified Instructions


This is a special case since the Field used is numeric and the user wants to have the option to
enter a numeric value without having a list to choose from or leave the field blank. This
combination doesn’t work with a regular “Prompt-Expression” combination. It is necessary to
convert the “Numeric” field to a “TO-CHAR” format to make this Prompt work.
 Create a new Expression in the Expression tab.
o For Expression Type select Character from the drop down list.
o Match the original numeric length in the Length Field.
o Enter TO_CHAR(X.FIELD_NAME) where X.FIELD_NAME is the name of the Field.
o Click “OK” button to save the new Expression.
o Back on the Expression tab click “Use as Field” link, to add the Expression as a Field.
Make sure to test it.
 Run your Query to test the results.
o If it runs correctly, re-name the Expression Field and remove the original numeric Field.
 Create the Optional Numeric Prompt
• Back at the Fields tab click the “Add Criteria” icon next to the TO_CHAR Field.
• Choose Expression 1 Type and Expression 1 will be already filled in with the information
from the selected Field.
• On Choose Expression 2 Type select the Prompt radio button.
• Click “New Prompt” button to create a new Prompt.
• Leave Field Name blank.
• Optional: Name the Prompt in the Heading Text Field.
• Match the original numeric length in the Length field.
• Make sure Edit Type is No Table Edit.
• Leave Prompt Table blank.
• Select the “Optional” checkbox
• Click the “OK” button.

Page | 101
PS QUERY 101

Prompt with wildcard (%)– Simplified Instructions


This prompt allows users to select either one value or multiple values. For example, if using
Union Codes the user could type in W% to search all codes beginning with W or the partial code
17% to find all codes starting with 17 or simply % to search all possible codes.

Create a new Expression in the Expression tab.


o In Expression Text enter: ‘ ‘ (apostrophe-space-apostrophe).
o Click “OK”.
 Add your Expression as an Optional Prompt to the Query Criteria
o Go to the Criteria tab click the “Add Criteria” button.
o Select Expression in Expression1 Type.
o Click on the "Magnifying Glass" icon to search for the desired Expression in Expression 1
– and click to select.
o Leave “equal to” as the Condition Type
o Select Prompt in Choose Expression 2 Type.
o Select “New Prompt” in Expression 2 – Define Prompt to create the Optional Prompt.
o Leave the Field Name blank.
o Select Text from the Heading Text drop down list.
o Type the Prompt Name in the Heading Text Field. Be sure to include instructions
regarding Wildcard.
o The Edit Type Field should be No Table Edit.
o Click on the “Magnifying Glass” icon to select a Prompt table. Click on “No Value”.
o Select the “Optional” checkbox
o Click Ok
o Click Ok again
 Match the Selected Field to the Optional Prompt
o Go to the Fields tab and click on the “Add Criteria” icon next to the Field to be used for
the Prompt.
o Select the Condition Type of Like.
o Select Prompt for the Choose Expression 2 Type.
o Click on the "Magnifying Glass" icon to search for the Optional Prompt and click to select
it.
o Click "OK".

 Make the final Criteria modifications


o Navigate to the Criteria Tab.
o Click the “Group Criteria” button.
o Add left and right parenthesis to group both criteria:
o Click “OK”.
o Change the operator in the Logical column to Or and click "Save".

Page | 102
PS QUERY 101

Page | 103
PS QUERY 101

 PS Query 101 Training Evaluation


Please take a moment to answer the following questions. Your comments are an important
contribution as we design learning experiences to meet your professional needs.

What will you do differently as a result of this training?

What do you feel were the strengths of this course?

What do you feel were the weaknesses of this course?

How can we improve this course?

What additional training-development in PS Query do you require?

Page | 104
PS QUERY 101

Please rate the following statements using a 1 through 5 scale where:

1 = Agree Strongly 5 = Disagree Strongly

Question 1 (Agree 2 (Agree) 3 (Neutral) 4 (Disagree) 5 (Strongly


Strongly) Disagree)
The course difficulty level was
about right.
I can apply the information I
learned in this course to my job.
The course met my professional
educational needs.
The trainer actively involved me
in the learning process.
As a result of this training, I feel
more confident in my capacity to
develop Queries.

Page | 105

You might also like