mission2java
Programmer
Im having a difficult time trying to approach this. Basically I have a form which allows the user to enter rates of pay for mon-fri, for sat., and for sun, also one for the holidays. Now basically I have a query which queries out job numbers in our workplace which are place in a table where all jobs have been worked on. Along with the job number there is a date and the number of hours worked on the job for that date. Now I query this information out but I need a way to get on a report the total # of hours along with the total cost. What im having trouble with is how do I, once I get the query figure out the cost for each day? Do I do this code in a report basically i need to do the following:
query the table of jobs, which will return to me all the records with the job number, hours, and date
then I need to be able to do something like this
for each record in the query
Select case 'find out what day it is
case monday
total=total + theRateOnMonday 'rate on mon from the form
case tuesday
total= total + theRateOnTuesday
....
case holiday
total = total + theRateForAHoliday
Finally I have to show this total on the report...but where do I do all this coding. Can anyone offer help or samples. Thanks
query the table of jobs, which will return to me all the records with the job number, hours, and date
then I need to be able to do something like this
for each record in the query
Select case 'find out what day it is
case monday
total=total + theRateOnMonday 'rate on mon from the form
case tuesday
total= total + theRateOnTuesday
....
case holiday
total = total + theRateForAHoliday
Finally I have to show this total on the report...but where do I do all this coding. Can anyone offer help or samples. Thanks