Salary Breakup:
Denomination:
Use the following Query to find the Denomination:
You can change values in order to get your desired results.
SELECT
TRUNC(SAL/1000) THOUSAND_NOTES,
MOD(SAL,1000) REMANING_AFTER_THOUSAND,
TRUNC(MOD(SAL,1000)/500) FIVE_HUNDRED_NOTES,
MOD(MOD(SAL,1000),500) REMANING_AFTER_FIVE,
TRUNC(MOD(MOD(SAL,1000),500)/100) HUNDRED_NOTES,
MOD(MOD(MOD(SAL,1000),500),100) REMANING_AFTER_HUNDRED,
TRUNC(MOD(MOD(MOD(SAL,1000),500),100)/50) FIFTY_NOTES,
MOD(MOD(MOD(MOD(SAL,1000),500),100),50) REMANING_AFTER_50
FROM
(
SELECT
95780 SAL
FROM
DUAL
UNION ALL
SELECT
95000 SAL
FROM
DUAL
UNION ALL
SELECT
90080 SAL
FROM
DUAL
)
No comments:
Post a Comment
Thanks for making a comment.