I guess, I need help with this one
Let’s say we have an EMP table as below
****************
Name* points
ab * 3200
dc * 100
ef * 20
gh * 0
*****************
and you need to generate a report with columns name and commission ( where commission is decided based on the following conversion table)
******************
point_range * commission
0-100 * 0
101-500 * 50
501-1500* 1000
1501-3000 * 2000
3000+ * 2500
*******************
How would one implement the above requirement, using decode function.
If it cannot be, what is the way out ... use pl/sql code?
Thank you,
nk
