Weekday funtion, group dates, not showing correct amount...

pablavo

Registered User.
Local time
Yesterday, 23:51
Joined
Jun 28, 2007
Messages
189
Hi there,

I would greatly appreciate if someone could help me with this.


I’m working on a query that has a daily hours and daily date field.

I’ve used the weekday function to group daily dates to weekly dates and subsequently, use the totals to show the sum of hours for each week.
I've been comparing the query that has the sum of hours for each week and the table with the daily hours for each employee and have found discrepancies.

I really am not sure why this might be. I thought at first it might have been to do with the date field repeated on the next row (which is because one or more rows can be made on the same day on the hour field for different expenses). but it seems to add these fields in other instances.

The hours can vary, for example, on the 28 aug, there can be two records, one with 7.5 hours, and one with .5 hours.
The data discrepancy is usually out by .5 or .25. The confusing thing is that sometimes there’s a higher amount on the query with the function and sometimes a lower amount.

I just want to ask anyone if they've had this problem as well. I'm not sure if it's because of the decimals or the dates.

Just to note, the function I used was.

Code:
[COLOR=black][FONT=Verdana]DateFriday: [TimeLineDate]-Weekday([TimeLineDate],6)+8[/FONT][/COLOR]

The only other fields in this table are the Employee name and the sum of hours for the week.
 
You need to give us a little more to go on. Ideally a cut down version of your DB and a clear description related to that of what is going wrong. Otherwise we would need the SQL of your query and some sample data so we can recreate the problem
 

Users who are viewing this thread

Back
Top Bottom