- 1

How to compute salary in sql

hi i need to compute the salary and have its total displayed. grosspay (rate*hours worked), total deductions and netpay. i just need the formula and the right code thank you.

12th Sep 2017, 5:07 AM
Troy Saludo
Troy Saludo - avatar
1 Respuesta
+ 4
select ( rate * hour_work ) AS payment from your_table; to see payment needed each person. ----------- select SUM( rate * hour_work ) AS payment from your_table; to see single cell contain total cost of payment. --------- and nahh , I dunno your table content or structure , so I just guessing. I dunno what your intend of "total deduction and netpay" either. so , I guess you can manipulate the rest.
12th Sep 2017, 5:18 AM
Mikhael Anthony
Mikhael Anthony - avatar