Compare Fields Between Two Records
By Chris Malek | Thu, Aug 7, 2025
This SQL snippet allows you to compare the fields of two records in PeopleSoft. You can use this to identify common fields between two records, which is useful for researching data structures.
I often need to find common fields between two records, especially when working with customizations or module I am not super familiar with. This SQL query will help you identify fields that are present in both records.
-- Compare Common Fields Across two records
SELECT
BASEREC.RECNAME,
BASEREC.FIELDNAME,
COMPAREREC.RECNAME,
COMPAREREC.FIELDNAME
FROM
PSRECFIELDDB BASEREC,
PSRECFIELDDB COMPAREREC
WHERE
-- Input 1: This is your base table
COMPAREREC.RECNAME = 'PAYMENT_TBL'
-- Input 2: This is the record you are comparing to.
AND BASEREC.RECNAME = 'QUICK_POST_TBL'
and BASEREC.FIELDNAME = COMPAREREC.FIELDNAME;
Article Categories
Chris Malek
Chris Malek is a PeopleTools® Technical Consultant with two decades of experience working on PeopleSoft enterprise software projects. He is available for consulting engagements.
About Chris Work with ChrisPeopleSoft Simple Web Services (SWS)
Introducing a small but powerful PeopleSoft bolt-on that makes web services very easy. If you have a SQL statement, you can turn that into a web service in PeopleSoft in a few minutes.
Integration Broker - The Missing Manual
I am in the process of writing a book called "Integration Broker - The Missing Manual" that you can read online.