how oracle bi publisher serves your peoplesoft …...2015/02/04  · –rtf file containing...

52
Prepared by: Session ID: How Oracle BI Publisher Serves Your PeopleSoft Reporting Needs John Beretz Senior Developer and Instructor SpearMC Consulting @SpearMC 101790

Upload: others

Post on 13-Apr-2020

5 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

Prepared by:

Session ID:

How Oracle BI Publisher Serves

Your PeopleSoft Reporting Needs

John Beretz

Senior Developer and Instructor

SpearMC Consulting

@SpearMC

101790

Page 2: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

Agenda

• Introduction

• Reporting Tools Overview

• BI Publisher Overview

• Connected Query for Complex Reports

• Programming BI Publisher

• Questions and Answers

2

Page 3: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

Your Presenter

• PeopleTools Technical Consultant – 12 Years

• PeopleTools Instructor – BI Publisher, Web Services, PeopleTools/PeopleCode

• Formerly a Developer at PeopleSoft – 8 Years

John Beretz Senior Developer and Instructor

[email protected]

866-SPEARMC x816

www.SpearMC.com

3

Page 4: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

About SpearMC

Page 5: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

About SpearMC Founded in 2004, SpearMC is a technology and professional services firm specializing in

PeopleSoft FSCM, HCM, ESA

PeopleTools Development and System Administration

PeopleSoft Test Framework

Oracle Cloud ERP and HCM

PeopleSoft Training

Project Management

Oracle Public Cloud

QA & Test Automation

Host Analytics EPM

Page 6: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

Presenters:

Our History

Page 7: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

Reporting Tools

Overview

Page 8: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

The PeopleTools Reporting Family

Crystal Reports (supported pre 8.55 only)

SQR

nVision

Query

BI Publisher

PS/nVision

Crystal Reports

PS Query

Page 9: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

Crystal Reports

• GUI Report Designer

– Drag-and-drop

– Preview look and feel

• Query used as the data source

• Support has been discontinued as of PeopleTools 8.55

• No delivered Crystal Reports as of application version 9.2

Page 10: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

Crystal Reports

When to use it

Presentation matters

A PS Query can generate the data

But…

External migration

Non-Oracle solution

Support has ended

Page 11: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

SQR

• Old-school procedural programming language similar to COBOL

• Data extracted using embedded SQL statements

• Character-based report formatting

• Powerful! Full database access within a "report"

• Lots of knowledge in the PeopleSoft community

• Logic can be organized into

reusable building-blocks

• Part of the Oracle family

• Built-in support for debugging

• Programmer-centric

– Quick to build and run

– Requires a technical resource

Page 12: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

SQR

When to use it

You have lots of SQR talent

Data more important than

presentation

Report output requires complex

preprocessing

High performance requirements

But…

Buried business logic

External migration

Report layouts are hard to

create/maintain

Page 13: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

nVision

• Power of Excel

• Excel add-in

• Allows users to leverage power of Excel

• Tightly connected to PeopleSoft data

– Ledgers

– Trees

• Matrix layout plus nPlosion provides quick access to details

• Drill-down into additional reports

Page 14: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

nVision

When to use it

Financial/ledger data

Power users; want interactive

analysis

But…

Steep learning curve; nVision talent

is essential

Challenging setup and

maintenance

Page 15: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

Query

• Browser-based tool for creating and executing SQL SELECTs

• Empowers business users – Solve their own problems

– Explore data

• Built-in features include – Table and row level security

– Translate descriptions

– Output to Excel

– Effective Date handling

– “In Tree” WHERE clause operator

– Embedded URLs

• Several other tools leverage Query – E.g. BI Publisher (like Crystal before it) uses Queries as data source

Page 16: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

Query

When to use

Need tabular output

Limited IT involvement

Users want spreadsheet output

No need for fancy formatting

Query authors know the data model

But…

Ever-growing collection of

redundant and obsolete Queries

Poorly designed Queries can have

serious performance consequences

Page 17: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

BI Publisher

• Data comes from Query, Application

Engine, or anything else that can

generate XML

• Any pre-processing done in AE

• Report layout is created using special

Microsoft Word plug-in

• Supports complex, multi-level data and

nested sections

• Leverages PeopleSoft metadata

• All pieces live in PeopleSoft

• Built on industry-standard technologies

(e.g. XSL, XML)

• Modular: built from re-usable building

blocks

Page 18: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

BI Publisher

When to use it

Presentation matters

Simple data/output

Complex data/output

Limited IT involvement (for simple

reports)

But…

Performance issues for high

volume output

Complex formatting requires

mastery of Word

Complex reports require

programming

Report templates are easy to break

and hard to troubleshoot

Page 19: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

BI Publisher

Overview

Page 20: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

BI Publisher Background

• Reporting tool introduced as “XML Publisher” in PeopleTools 8.48

• Renamed to “BI Publisher” in PeopleTools 8.52

o “BI” as in “Business Intelligence”, aka “Reporting and Analytics”

• Positioned as a reporting tool that:

o Replaces Crystal

o Alternative to SQR

o Better integrated with PeopleSoft

o Architected for better maintenance and extensibility

Page 21: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

What does a BI Publisher Report look like?

• Demo: Delivered Report List of Valid Currency Codes

1. Reporting Tools > BI Publisher > Query Report Viewer

2. Report Name: FSX0035 (List of Valid Currency Codes)

3. Click View Report link.

– Popup appears with prompts

4. Enter As Of Date: current date

5. Click OK

6. Review output

Page 22: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

How does it work?

• In broad strokes, a lot like Crystal

1. The report’s data comes from a PS Query

– Prompts presented at run time

2. The report’s layout comes from a Report

Template

– RTF file containing formatting, data

placeholders, and special syntax

3. The BI Publisher Engine combines the

data from the Query with the Report

Template to build a PDF

– "Data Source" column in Query Report

Viewer is the name of the Query

• Query and Template are tied together by

the Report Definition

Page 23: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

Introducing the Report Definition

• Each BI Publisher Report has a Report Definition

• Reporting Tools > BI Publisher > Report Definition

• Most important properties

o Data Source

– This is how it knows about the Query

o Template tab > Template File

– Open in Word

• Have a Query but not sure what reports use it?

o Find References link (new in 8.54)

• Demo: Delivered Report List of Valid Currency Codes

o Report Definition FSX0035

o Query FSX0035_CURRENCY_CODES

o Template FSX0035.rtf

Page 24: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

Introducing Template Builder

• Microsoft Word is the BI Publisher design-time environment

o Instead of having Crystal installed on your machine, you need

– Microsoft Word

– Java Runtime

– Oracle’s BI Publisher Template Builder Add-In for Microsoft Word (aka “Design Helper”)

–Windows only (no Mac support)

• BI Publisher Word Add-In

o Download installer from any PeopleSoft environment!

o Reporting Tools > BI Publisher > Setup > Design Helper

o Now there's a new "BI Publisher" ribbon in Word

• Completed report templates consist of

o Standard Word Formatting (tables, text, etc.)

o Special placeholders to indicate where data should go, and more

Page 25: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

1. Open the BI Publisher Template file

2. Import XML file containing appropriate sample data (Load Data > Sample XML) o Typically generated from Query using Download to XML link on results page

3. Test Template using Preview tool o Allows for rapid, iterative, trial-and-error report building

• Demo: Currency Codes Report Template o Run Query FSX0035_CURRENCY_CODES to XML

o Import sample XML into FSX0035.rtf

o Preview to PDF

Running Report in Template Builder

Page 26: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

Creating a Tabular Report

• Demo: Asset Costs

1. Create a Query that returns a list of Asset Costs

– Record COST

– Include any Fields that we want to include on the report

– Criteria: ACCOUNTING_DT >= prompt value

– Save it as Public Query named Z_ASSET_COST

2. Create a sample data file

– Run the Query to XML

3. Create the template in Word

• BUSINESS_UNIT • CATEGORY

• ASSET_ID • TRANS_TYPE

• BOOK • ACCOUNTING_DT

• DEPTID • COST

Page 27: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

• Best way to start a new report!

• Choose which fields get added to the table

• Choose Grouping options

o Grouping sorts your rows that have same value in the group field

o Grouping displays the grouping field value only once for each group

o “Group above” adds a “table break” when the value in that field changes

o “Group left” adds the group field as left-most column

• Choose Sorting options

• Demo: Creating the Asset Costs Template

Template Builder – Table Wizard

Page 28: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

Basic Tabular Report Formatting

• Works just like Microsoft Word…because it IS Microsoft Word!

• Examples

o Add report title by typing text at top of page

o Add report date: Ribbon Insert > Text > Date & Time

o Add page numbers: Ribbon Insert > Header & Footer > Page Number

o Change column titles by directly editing text

o Change column alignment

– Select cell (hover over lower-left corner until mouse cursor is up-right arrow

– Ribbon Layout > Alignment

o Remove unwanted columns

– Select the column to delete by hovering near the top of the column until the mouse cursor

becomes a down arrow, then click

– Right-click the column and select Delete Columns

– E.g. Remove the row number column from the report

Page 29: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

Template Builder is not dummy proof!

• Report broken?

o Deleting the Row Number column inadvertently deleted an essential BI Publisher tag

• Making changes in Word can break your report!

o The structure of the report is controlled by the tags on it

o Deleting or rearranging the report tags can have unexpected consequences

o Template Builder is not at all dummy proof!

• Recommendation:

o When editing a report template, only change one thing at a time

o Test each change before saving the template

o Periodically make sure Validate Template finds no errors

o When in doubt, undo!

Page 30: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

Repeating Groups

• Parts of the report template that should be repeated at runtime based on data

(typically once per row of data)

• Everything between For-Each and End-for-each tags gets repeated

• Most commonly used with Word tables

o A for-each tag must be the first thing in the left-most column

o An end-for-each tag should be the last thing in the right-most column

• The Table Wizard tool automatically sets row 2 as a Repeating Group

• Adding a Repeating Group manually

1. Select the area of document to repeat (e.g. table body row)

2. Choose Insert > Repeating Group from the BI Publisher ribbon

3. Select For Each row (for more complex data sets, pick the element that represents

the “rows” to loop through)

4. Click OK

Page 31: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

Multi-Level

Data and Reports

Page 32: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

Tabular vs. Hierarchical Reports

• The simplest reports are tabular

o Look like simple extracts of data from a database table

o Maybe include grand totals

o Example: FSX0035 – Currency Code Report

o Queries are perfect for generating tabular data

• Most real-world reports are hierarchical

o Organized like a data model diagram

– e.g. Assets, Asset Costs, and Asset Locations

o Parent-child relationships

o Queries can’t generate this type of data

o But multiple Queries could…

Asset

(ASSET)

Asset Cost

(COST)

Asset Location

(ASSET_LOC_VW)

Page 33: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

Connected Query and BI Publisher

• Connected Query gives you a way to “join” PS Queries that have a logical parent-child relationship

• Allows you to create XML with hierarchical data

• Can be used as a BI Publisher Data Source

• Introduced in PeopleTools 8.50

• Reporting Tools > Connected Query > Connected Query Manager

• First create PS Queries, then connect them in Connected Query

• Include key fields in each Query

Page 34: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

Connected Query and BI Publisher

• Demo: Create an Asset Connected Query

o Name: Z_ASSETS_BY_UNIT

o Parent Query: Z_ASSET (over Record.ASSET)

o Child Query 1: Z_ASSET_LOC (over Record.ASSET_LOC_VW)

o Child Query 2: Z_ASSET_COST (over Record.COST)

Query Z_ASSET

Record ASSET • BUSINESS_UNIT • ASSET_ID • ASSET_TYPE • DESCR • ACQUISITION_DT • ASSET_CLASS • MANUFACTURER • MODEL • SERIAL_ID

Query Z_ASSET_LOC

Record ASSET_LOC_VW • BUSINESS_UNIT • ASSET_ID • LOCATION • AREA_ID

Record LOCATION_TBL • DESCR • COUNTRY • CITY • STATE

Asset

(ASSET)

Asset Cost

(COST)

Asset Location

(ASSET_LOC_VW)

Page 35: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

Creating a Connected Query

1. Create PS Queries that will be part of Connected Query

o Include key fields in each Query

2. Go to Connected Query Manager: Reporting Tools > Connected Query > Connected Query Manager > Add a New Value

3. Name the new Connected Query

4. Add Top-Level “Parent Query” to new Connected Query definition

5. Add descendent Queries

a. Click name of a Query to display tool icons

b. Use Child and Sibling icons

6. “Join” each child Query to parent

o Click Select Related Fields, check fields, click Map Fields

7. Set Status to “Active”

8. Click Save button to save the Connected Query

9. Use Preview to test

Page 36: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

Connected Query and BI Publisher

• Query Prompts

o Supported for all Queries in a Connected Query

o User prompted at run/schedule time

o Recommendation: When possible, only use with top-level Query

o Queries with In-Tree prompt cannot be used in Connected Query

• Advantages

o Leverage existing Queries (Query reuse)

o Easier to develop and maintain

– Multiple bite size Queries instead of one, big, complex one

– Alternative to outer joins

o Very different data sets can be included in same report

o Alternative to creating an App Engine to generate XML for BI Publisher

• Disadvantages

o Performance not great with large amounts of data

Page 37: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

Connected Query and BI Publisher

• Generating Sample XML for Template Builder

o Option 1: Use Preview in Connected Query Viewer or Connected Query Manager

– Must specify upper limit on number of rows

– Do save-as on XML file that gets opened in browser

o Option 2: Schedule Connected Query

– Reporting Tools > Connected Query > Schedule Connected Query

– Also available from Connected Query Viewer / Manager search results

– Create run control specifying Connected Query name and parameter values

– Exports complete results to XML file

– Retrieve XML file from Process Monitor View Log/Trace

• Demo: Connected Query Sample XML

o Create an XML File containing a large data sample from your Connected Query using

Preview in Connected Query Viewer/Manager

Page 38: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

Building Templates with Multi-Level XML

• Typically end up with one Repeating Group for each Query in a Connected Query

• Word Tables can be nested

o Put cursor in a cell (a cell big enough to hold a table; use Word’s cell merge)

o Use Table Wizard > Table

o Adds complexity, so use with caution! Overuse can become confusing to maintain, ugly

for end users, and can even break BI Publisher. Simple is best!

• The repeating portion of a Word table can be more than one row

o For-Each tag in upper left cell of region

o End-For-Each tag in lower right cell of region

o Useful for form-style appearing beneath each row of parent data

• Repeating data is NOT limited to Word tables

Page 39: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

Building Templates with Multi-Level XML

• Demo: Connected Query Based Report

o Build a new BI Publisher report

o Template Name: Z_ASSETS_BY_UNIT.rtf

o Use Connected Query (and sample XML file) from previous example

Page 40: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

Building Templates – Tips

• Use the Word Table Tools ribbons o Only visible if cursor is in a table

o Central location for all table formatting tools

• Explore Word Table Properties o Available on right-click when cursor in

a table

o Advanced, precise control over table/row/column/cell sizing

o Example: Allows you to control padding at cell level

• Not getting formatting you expected? o Try Previewing to RTF

o Sometimes is easier to troubleshoot than a PDF because you can see the table borders and special characters

Page 41: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

Programming

BI Publisher

Page 42: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

• BI Publisher templates are computer programs in disguise!

• Form Field Tags inserted by the BI Publisher ribbon tools contain code

o Code is on BI Publisher Properties > Advanced tab

o This is the code that actually runs when the report gets generated

o BI Publisher ribbon tools are “code generators”

• This code can be edited!

o Once code is edited, “Properties” tab may become read-only

• See XDOUserGuide.pdf (Chapter 17) installed with the Word plug-in

o Note: Most of this document is not applicable to PeopleSoft!

BI Publisher Template Syntax

Page 43: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

BI Publisher Template Syntax

• Command syntax

o <?command: expression?> …

<?end command?>

o Functionality depends on the

command

• Display expression syntax

o <?expression?>

o Displays the result of the expression

• Comments o Standard XML style (<!-- and -->)

• Data Types

o String, Number, Logical, Node Set

• Logical operators

o and, or, =, !=, etc.

• Looping (“Repeating Groups”)

o <?for-each:nodeSetExpression?>…

<?end for-each?>

• Conditional (“Conditional Regions”)

o <?if:logicalExpression?>…<?end if?>

• Choose command

<?choose:?>

<?when:logicalExpression1?> …

<?end when?>

<?when:logicalExpression2?> …

<?end when?>

<?otherwise:?>…<?end otherwise?>

<?end choose?>

Page 44: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

BI Publisher Template Syntax

• Most of the supported BI Publisher functionality is not even available through the

BI Publisher ribbon!

o The appropriate syntax must be coded manually

• Demo

o Modify report so that asset costs meeting the following criteria appear in red

1. Have cost > $50,000

2. Belong to Business Unit BLG01

• What happened?

o BIP ribbon Conditional Format tool only supports logic on a single field

• Solution

<?if:number(A.COST)>50000 and A.BUSINESS_UNIT='BLG01'?> <?attribute@incontext:color;'red'?> <?end if?>

Page 45: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

BI Publisher Template Syntax

• Demo

o Modify report so that asset costs meeting the following criteria appear in red

1. Have cost > $50,000

2. Belong to Business Unit BLG01

3. Belong to an asset with an Asset Type of 020

• What happened?

✓ ✓

Page 46: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

BI Publisher Expressions: XPath

• BI Publisher ribbon only supports references to data at same or lower level

• Example: Conditional expression cannot reference field in parent Query

• BI Publisher expressions use XPath syntax

• Industry standard language for precisely specifying subset of data in XML file

• Like file system paths but use XML element/node names instead of folder names

• Expressions are relative to “current node”, i.e. the XML element the for-each is on

• XPath expression syntax includes:

• Use Insert > Field tool to see structure of your data

target Elements tagged as target that are descendants of current node (BIP default)

.//target Same as above

./target Values of elements tagged as target that are children of the current node

../target Siblings of the current node tagged as target

//target Elements tagged as target anywhere in XML

Page 47: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

BI Publisher Template Syntax

• Demo

o Modify report so that asset costs meeting the following criteria appear in red

1. Have cost > $50,000

2. Belong to Business Unit BLG01

3. Belong to an asset with an Asset Type of 020

• What happened?

o Plain field references in XPath assume field is at or below current level

o A.ASSET_TYPE is at parent level

• Solution

o Use XPath expression ../A.ASSET_TYPE

✓ ✓

Page 48: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

XPath Node Set Predicates

• Predicates

o Syntax for adding data filtering to an XPath node set expression

o Enclosed in square brackets

o Consist of a logical expression

o Only elements passing that test are included in final XPath result

o Similar to a SQL WHERE clause

• Examples, from this business unit level

o All the asset cost field values

./Z_ASSET/Z_ASSET_COST/A.COST

o All the asset cost field values associated with department 50000

./Z_ASSET/ZZZ_ASSET_COST[./A.DEPTID="50000"]/A.COST

o All the type 010 asset cost amounts associated with department 50000

./Z_ASSET[./A.ASSET_TYPE="010"]/ZZZ_ASSET_COST[./A.DEPTID="50000"]/A.COST

Page 49: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

XPath Node Set Predicates

• Demo: Totals and XPath Predicates

o Add a subtotal to the business unit level that shows the total asset cost for assets of

type 020.

o Example:

BLG01 Total for 020 Assets: $1,025,954.50

Page 50: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

Tuesday, July 18 @ 10:15 – 11:15 am

• PeopleSoft on Oracle Public Cloud

• Session ID: 101690

• Presented by David Pigman

• Location: Paris

Wednesday, July 19 @ 8:00 – 9:00 am

• PeopleSoft Clear Benefits (eBenefits)

• Session ID: 101810

• Presented by John Beretz

• Location: Tegal

Wednesday, July 19@ 9:15 – 10:45 am

• How Oracle BI Publisher Serves Your

PeopleSoft Reporting Needs

• Session ID: 101790

• Presented by John Beretz

• Location: International Ballroom F

Wednesday, July 19 @ 11:15 am – 12:15 pm

• Powerful PeopleSoft Composite & Connected Query

• Session ID: 101710

• Presented by Randy Johnson

• Location: Narita AB

Wednesday, July 19 @ 1:30 – 2:30 pm

• Extending PeopleSoft WorkCenters

• Session ID: 101730

• Presented by Randy Johnson

• Location: International Ballroom E

Wednesday, July 19 @ 4:30 – 5:30 pm

• PeopleSoft Mobile Expenses – your modern, fluid

expense management and reporting tool

• Session ID: 101700

• Presented by Randy Johnson

• Location: International Ballroom F

SpearMC Presentations at Reconnect

Page 51: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the

Session ID:

Please complete the session evaluation 101790

Page 52: How Oracle BI Publisher Serves Your PeopleSoft …...2015/02/04  · –RTF file containing formatting, data placeholders, and special syntax 3. The BI Publisher Engine combines the