Month: February 2014

Ben Admin Snapshot Error

I ran into this error with the Ben Admin Snapshot process. It was the second time I ran into it, so I thought that I had better make sure that I got this in my notes so I would remember it.

Here’s the error…

Costs Not Found For Pgm/Plan/Optn: <benefit program>/<plan type>/<option code>.
 
Application Program Failed
 In Pgm Section  : MOVE-TO-PDEFN                                                                                                                                               

Application Program Failed
 In Pgm Section  : TABLE-ACCESS(PSPBATBL)                                                                                                                                      
 
 
Application Program Failed
 In Pgm Section  : MAIN(PSPBASCH)                                                                                                                                              

Read More

Changing Records in Queries

This isn’t best practice, but I found a way to switch out a record in a query without redoing the criteria. Here’s the situation: I have a query in which the row-level security is causing problems. It is slowing down the query and also eliminating future-dated rows from the results. So, I created a view of the table which would select all of the rows from the original table. It was basically a copy with the query security view removed. The next challenge was to change the query to use that new record. If I remove the old record and add the new, I would have to redo the whole complicated query just about.

So, I found that I could update two records in the database:

UPDATE PSQRYFIELD
SET RECNAME = '<new record name>'
WHERE QRYNAME = '<query name>'
AND RECNAME = '<old record name>';

UPDATE PSQRYRECORD
SET RECNAME = '<new record name>'
WHERE QRYNAME = '<query name>'
AND RECNAME = '<old record name>';

After that, I found that I needed to open the query online in query manager, make a small change, and save it. After that, it worked fine with no problems.

Warning: use at your own risk. This isn’t the intended way to edit queries.

Null Date in PeopleCode

Just the other day, I needed to set a Date to null or blank, and I couldn’t remember how to do it.  Here’s my notes so that I can remember next time.  Javier’s blog came to the rescue:

Javier’s PeopleSoft blog: Setting Date Variables to Null in PeopleCode

The short version is: use the Date(0) function:

     Local Date &hireDate;

     &hireDate = Date(0);

Here’s some more information to explore a little more in depth…

Read More