Link to home
Start Free TrialLog in
Avatar of syhctl
syhctl

asked on

SQL/PL Oracle/PeopleSoft -What experession to use retrieve specific data IF FIELD(prompt) = value then return specific data

I am using PeopleSoft/Oracle database

My question:
I am tryng to retrieve data :
example
If  userID (this value would come from a prompt :1) = 'aaaaa'
then return
only data for DeptID 12345, 34567

If userID = 'bbbbb'
then return only data for
DeptID  67891 54341

I tried this using a CASE expression, but did not work not sure if a DECODE would work.   Any suggestions would be much appreciated.
Thanks,
Syhctl
ASKER CERTIFIED SOLUTION
Avatar of Jinesh Kamdar
Jinesh Kamdar
Flag of India image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial