consider a table employee with fields empid, ename and department.
records are
consider another table salary with fields empid,month,yea r,and amount received every month.
records are
now i have to display the total amount recieved by the employee 1 during the period may2007-jan2008 in the format
records are
Code:
(1,Ram,sales),(2,Abi,Purchase)
records are
Code:
(1,january,2007,2500),(1,february,2007,2300), (1,march,2007,2800),(1,april,2007,2300), (1,may,2007,2300),(1,june,2007,3300), (1,july,2007,2300),(1,august,2007,2300), (1,september,2007,4300),(1,october,2007,2300), (1,november,2007,4300),(1,december,2007,4300), (1,january,2008,4300),(1,february,2008,2300), (1,march,2008,4300),(1,april,2008,2300), (1,may,2008,2300),(1,june,2007,2300)
Code:
empname |may2007|june2007|july2007|...........|jan2008|total|
| | | | | | |
Ram |2300 |2300 |2300 |...........|4300 | |
Comment