You are on page 1of 78

2010 Oracle Corporation Proprietary and Confidential

<Insert Picture Here>

PeopleTools Tips and Tricks


Stephen Wills
(Stephen.Wills@oracle.com)
PeopleSoft Application Technology Sales Consultant, Oracle

The following is intended to outline our general


product direction. It is intended for information
purposes only, and may not be incorporated into any
contract. It is not a commitment to deliver any
material, code, or functionality, and should not be
relied upon in making purchasing decisions.
The development, release, and timing of any
features or functionality described for Oracles
products remains at the sole discretion of Oracle.

Program Agenda
Communities and resources
Extend the user interface
Browser extensions
iScripts
Ajax: Zero impact customizations almost

PeopleTools the extensible foundation


Extend the app server
Extend the web server
Extend Integration Broker
Web Services-less Real-time Integrations
Custom target connectors

<Insert Picture Here>

<Insert Picture Here>

Communities and
Resources

Forums
http://mix.oracle.com
http://forums.oracle.com/forums/category.jspa?categoryID=152
PeopleSoft General
Business Intelligence
Security
Upgrades
http://peoplesoft.ittoolbox.com/groups/technicalfunctional/peopletools-l
Caveat
Forums dont replace the Global Support Center!
Dont Post Confidential Information

Blogs

http://blogs.oracle.com/peopletools/
http://jjmpsj.blogspot.com/
http://blog.greysparling.com/
IT Toolbox groups ERP > PeopleSoft
http://blogs.ittoolbox.com/peoplesoft/rob
http://xtrahot.chili-mango.net/
http://peoplesofttipster.com/
http://campus-codemonkeys.blogspot.com/
http://gasparotto.blogspot.com/

RSS Feeds
Choose A Feed Reader, And Subscribe

Oracle Customer Support


Trouble Navigating The Flash Site?
Default flash site is:
https://support.oracle.com

But
theres an HTML version of the site at:
https://supporthtml.oracle.com

Oracle Web Site Useful Links


Did You Know About These?
Online PeopleBooks:
http://www.oracle.com/pls/psft/homepage

Downloadable PDF PeopleBooks


http://www.oracle.com/technology/documentation/psftent.html

PeopleTools Viewlets
http://download.oracle.com/peopletools/viewlets.html

PeopleSoft Business Process Maps


and Entity Relationship Diagrams
Available On

Available on My Oracle Support


Business Process Maps
(r9.0 Doc ID 989289.1)
(r9.1 Doc ID 1061003.1)
Entity Relationship Diagrams
(Doc ID 1051533.1)

PeopleSoft Enterprise
Integration Point Diagrams

Available on My Oracle Support Document ID 1157149.1

Available On

PeopleSoft Upgrade Home


Pages on Oracle Support

Available On

One page for each upgrade path per product line,


serves as a homepage for that specific upgrade path

Upgrade Files including the Getting Started Guide


Change Assistant User Guide (link)
Upgrade instructions
Demo to Demo Compare Reports
Upgrade code files.

Install/Upgrade Information Development team posts


installation documentation, hardware/software
requirements documentation, and certification
information on a separate Oracle Support page for
Install & Hardware/Software

Example Upgrade Pages


On My Oracle Support

Available On

Oracle Tweets on Twitter

<Insert Picture Here>

Extend the
User Interface

Site Specific Browsers


No noise
No distractions
More real estate

Fewer browser-related
user errors
No back button
No Favorites/Bookmarks

No plugins
Although you can add plugins

Implementations
Mozilla Prism
Microsoft HTA

Ubiquity
Command your Browser
Delivered scripts
Map location
Vendor, customer, offices, training rooms, etc

PeopleSoft transaction specific


View employee
Open vendor

<Insert Picture Here>

IScripts The Swiss


Army Knife

What is an IScript?
A function that can be called from a URL
http:/EMPLOYEE/EMPL/s/WEBLIB_ADS_FB.ISCRIPT1.Fi
eldFormula.IScript_GetFriends

Takes no parameters and does not return a value


Function IScript_GetFriends()
...
End-Function;

Contained in a record named WEBLIB_XXXXXXXX

Provides access to %Request and %Response

What Can They Do?


Custom user interfaces
Not bound to Page/Component paradigm

Ajax/Flex/Applet request/response handlers


Serve JSON, XML, or HTML in response to Ajax requests

Excellent for testing PeopleCode snippets


Just about anything but choose wisely (see
disadvantages)

Advantages of IScripts
Unstructured Request/Response handling
PeopleCode version of JSP/ASP
Very few rules

Full PeopleCode/Database access


Leverage PeopleSoft security model
Great for non-UI development

Disadvantages of IScripts
No META-DATA
No upgrade
No component processor
Event processing

More difficult to develop and maintain

AJAX Injection
Light-weight User Interface Customizations
Design
Modify PT_COPYURL HTML definition
Use AJAX/IScript to load page specific JavaScript

Advantages
Reduce modification footprint (<20 lines of JavaScript)
Only way to modify search pages
Global or page specific

Disadvantages
Minimal access to component buffer
Only access page (not component) fields
Visible or
Interact with JavaScript

<Insert Picture Here>

PeopleTools Foundation

The Extensible Foundation


The Tech Stack
Relational database
Programmable
Functions, procedures, triggers

App Server
Java VM
Native libraries

J2EE web server


JSP/JSF
Servlets
EJB

Web Browser

<Insert Picture Here>

Extend the App Server

Language Diversity
Best Practices
How many languages are
delivered with PeopleTools?

PeopleCode
SQR
DMS
COBOL
SQL

Others?
Java
XML
XSL
JavaScript
HTML
Stored Procedures
Shell scripting (batch, bash,
etc)
C++
Java interpreted script engines:
JRuby, Groovy, Jython, etc
Unlimited

Extend the PeopleCode Language


Operating system native libraries
DLLs
sos

Java VM
Standard Java API
Custom Java classes

Extend the PeopleCode Language


Why?
Some things are easier to do in Java
Java regular expressions versus PeopleCode String
manipulation

Take advantage of existing libraries


Apache POI for reading binary Microsoft Excel files
(integration)

Extend PeopleCode Language


Using the Java API
Function
Local
Local
Local

ResolveMetaHTML(&html as string) returns string


JavaObject &pattern;
JavaObject &matcher;
String &node_url;

REM ** Resolve %NodePortalURL(NODENAME) tags;


&pattern = GetJavaClass("java.util.regex.Pattern")
.compile("(?i)%NodePortalURL\((\w+)\)");
&matcher = &pattern.matcher(
CreateJavaObject("java.lang.String", &html));
While &matcher.find()
SQLExec("SELECT URI_TEXT FROM PSNODEURITEXT WHERE MSGNODENAME
= :1 AND URI_TYPE = 'PL'", &matcher.group(1), &node_url);
&html = Substitute(&html, &matcher.group(), &node_url);
End-While;
End-Function;

Extend PeopleCode Language


Custom Java Classes
REM ** Generate MD5 checksum;
Function test_md5() Returns string
Local JavaObject &jMD5;
&jMD5 = GetJavaClass("com.oracle.ads.peoplesoft.MD5");
&sig = &jMD5.encodeString("String to encode");
End-Function;

Access PeopleSoft from Java


Within a PeopleSoft session (app or process
scheduler server)
PeopleCode objects
Record, SQL, Field, File, XMLDoc, etc
PeopleCode functions
Func.SQLExec, Func.SendMail, etc
PeopleCode system variables
Sysvar.UserId(), Sysvar.Roles()
TIP: Add peoplecode.jar to your Java IDEs classpath

Java Integration Scenario


Vendor e-mails invoice in Microsoft Excel format
You need to create a voucher from that invoice
Solution
Use Apache POI (http://poi.apache.org/) and PeopleCode
objects/functions to copy spreadsheet to staging table (Java)
Use a component interface based on VCHR_EXPRESS to
create vouchers (PeopleCode)

Java Integration Scenario


Java Component
public static void processSpreadsheet(int processInstance) {
//POI variable initilization, etc
...
// 20 insert bind values
Object[] parms = new Object[20];
parms[0] = row.getCell(0).getStringCellValue();
// column 2 contains an integer
Parms[1] = new
Integer(row.getCell(1).getNumericCellValue().intValue());
...
// use Meta-SQL to simplify retrieving SQL from
// stored SQL object
Func.SQLExec("%SQL(MYSQLOBJECT)", parms);
...
}

Advantages of Using
PeopleCode Data Objects from Java
Avoid JDBC configuration, data access,
authentication, etc
Simplicity of SQLExec
Simplicity of SQL objects/cursors
Meta-SQL expansion
Avoid updating PS database directly

Access PeopleSoft from Java


Additional References
Enterprise PeopleTools 8.50 PeopleBook:
PeopleCode API Reference > Java Class

<Insert Picture Here>

Extend the Web Server

Extensible Options
Standard J2EE web server options

Servlet filters
JSP
JSF
Custom Servlets
CGI

ServletFilters
Allow you to modify the HTTP request or response
Examples
Authentication
Injection
Monkeygrease
Add additional HTML/JavaScript/CSS to pages
Compression
URLRewriting
Encryption
Encoding
Request/Response header modification

Standard Request Response Cycle...


and then ServletFilters
Web Server

App Server
Request

Client/Browser
Response

Web Server
ServletFilter
Request
Response
Modify Response

Modify
Request

Servlet

<Insert Picture Here>

Extend Integration
Broker

The Problem
Real-time Integrations
Integrate with web service challenged applications
Common solution: Batch process
Suffers from:
Latency
Complex logic
Performance and resource utilization (caused by complex
logic)

Solution: Custom Target Connectors


Real-time Integrations
Create connectors to send Integration Broker
messages to targets not covered by delivered
connectors
Databases via JDBC (JDBCTargetConnector)
Other TCP/IP based protocols
Anywhere, in any electronic way

Advantages
Creating Custom Connectors
Reuse delivered integration points
Employees, vendors, transactions

Eliminate complex identification logic


No was transaction modified? logic

<Insert Picture Here>

Want More?

PeopleTools 8.51 Information


Development Deliverables
PeopleTools 8.51

PeopleTools 8.51

PeopleTools Cumulative

Documentation Homepage

Hosted PeopleBooks

Feature Overview Tool

Includes direct links to PeopleBooks,


PeopleBook Updates, Release Notes,
Installation and Upgrade Guides, and
more. All accessible from one
convenient My Oracle Support
location.
https://supporthtml.oracle.com/ep/f
aces/secure/km/DocumentDisplay.j
spx?id=1127534.1&h=Y

Access a searchable HTML


installation of our PeopleTools 8.50
PeopleBook suite. This hosted
solution lets you access PeopleBooks
using the help link in your applications
without having to install PeopleBooks
on your own server.
http://www.oracle.com/pls/psft/hom
epage

Dynamic tool provides concise


descriptions of new and enhanced
solutions and functionality that have
become available between your
starting and target releases.
The CFO tool can be found on My
Oracle Support and on our Doc Home
Pages.

Cumulative Feature Overview Tool


How do I know what changed between releases?
You could read all the release notes
or use the PeopleSoft Enterprise Cumulative
Feature Overview Tool
Excel-based tool
Choose your topics
Choose your from and to releases

Creates a summary of changes, by release, for the


topics chosen between the releases chosen
Available for PeopleTools and PeopleSoft Apps

PeopleTools 8.50
Available Training
PeopleTools 8.50 classes available now:

PeopleSoft PeopleTools 1 Rel 8.50


PeopleTools II Rel 8.50
PeopleTools I/PeopleTools II - Accelerated Rel 8.50
PeopleSoft PeopleCode Rel 8.50
SQR for PeopleSoft Rel 8.50
Application Engine Rel 8.50
PeopleCode/SQR Accelerated Rel 8.50
PeopleCode/Application Engine Accelerated Rel 8.50

To view a schedule of these classes or new upcoming


classes visit the Oracle University booth in Moscone
West (W-144) or go to oracle.com/education

PeopleTools Tips and Techniques


New PeopleTools book available now!
A collection of code, documentation, and best
practices as presented by Jim Marion over the last
few years
600 pages of well written, thought provoking
techniques
Available Now!
Order from major book resellers

PeopleTools Tips and Techniques


New PeopleTools book available now!
Whats inside?
The basics
App Classes, Approval Workflow Engine, File Attachments
The user interface
Mobile, iScripts, Flex, JavaScript, AJAX, Pagelet Wizard
How and when to use Java in PeopleSoft
App server, Web server, and Integration
Best Practices
Fluent interface design, test driven development
http://www.amazon.com/PeopleSoft-PeopleToolsTechniques-Osborne-ORACLE/dp/0071664939

2010 Oracle Corporation Proprietary and Confidential

You might also like