2012-04-27

PeopleSoft Time and Labor Tips: tracing TRC and migrating rules

HOWTO: trace TL_TIMEADMIN

By following the Application Engine program convention, either we can override or append a Parameter List, say “-TRACE 135 -TOOLSTRACESQL 31”:

Main Menu > PeopleTools  > Process Scheduler > Processes

Process Name: TL_TIMEADMIN

When debugging PeopleSoft T&L rules, the SQL below can be used to trace a specified TRC (take “SH125” as my example):

select * from PS_TL_RULE_PGM_DTL A, PS_TL_RULE_STEPS B, PS_TL_SQL_EXPRESSN C where A.RULE_PGM_ID='AGEP' and A.TL_RULE_ID=B.TL_RULE_ID and B.SQL_ID = C.SQL_ID
and C.EXPRESSIONTEXT like '%SH125%' /*<<<<< the TRC focused*/
order by A.PRIORITY, B.TL_RULE_STEP;

Time and Labor rules can be copied across from one environment to the other by running DMS scripts. Oracle support site has a complete DMS script listed for the same purpose. For quick reference I just list my script here. Do remember to put on 'WHERE' clauses for each statement, if necessary.

EXPORT TL_RULE_DEFN  [WHERE…]
EXPORT TL_RULE_STEPS
EXPORT TL_RULE_CONDS
EXPORT TL_TMPLT_RULE
EXPORT TL_TMPLT_RULE2
EXPORT TL_SQL_BINDS
EXPORT TL_SQL_INSERT
EXPORT TL_SQL_JOIN
EXPORT TL_SQL_JOINFLDS
EXPORT TL_SQL_OBJECT
EXPORT TL_SQL_SEL_FLDS
EXPORT TL_SQL_TABLES
EXPORT TL_SQL_UPDATE
EXPORT TL_SQL_UPDBINDS
EXPORT TL_SQL_WHERE
EXPORT TL_SQL_WHRBINDS
EXPORT TL_SQL_EXPRESSN
EXPORT TL_RULE_PGM
EXPORT TL_RULE_PGM_DTL

This can be done by non-rule package as well.

Note: In version 9.1 PeopleSoft has come up with a utility to export and import rules between environments. Using that will eliminate to either memorise or execute the DMS scripts manually and riskily.

No comments: