J
Jean-Paul
Hi,
I have a table with 3 "time" fields:
1 starttime
1 stoptime
1 "worked time"
I created a querry to calculate the "worked time" (simple:
stoptime-starttime)
Finally I have to sum all "worked time"s together
I do this with following SQL:
sql = "SELECT Sum(Uren.gewerkt) AS SomVanUur FROM Uren WHERE
Uren.Datum > #" & Format(Forms![Uur_overzicht]!Start_dat, "DD/MM/YYYY")
& "# And Uren.Datum < #" & Format(Forms![Uur_overzicht]!Stop_dat,
"DD/MM/YYYY") & "# ;"
Set kost = db.OpenRecordset(sql)
Then I enter the value in an entryfield:
Me!rek = Format(kost!somvanUur, "hh:mm")
the somvanUur is 1,229166
Me!rek shows 05:30 while it should be 28:30
What am I doing wrong?
Thanks
JP
I have a table with 3 "time" fields:
1 starttime
1 stoptime
1 "worked time"
I created a querry to calculate the "worked time" (simple:
stoptime-starttime)
Finally I have to sum all "worked time"s together
I do this with following SQL:
sql = "SELECT Sum(Uren.gewerkt) AS SomVanUur FROM Uren WHERE
Uren.Datum > #" & Format(Forms![Uur_overzicht]!Start_dat, "DD/MM/YYYY")
& "# And Uren.Datum < #" & Format(Forms![Uur_overzicht]!Stop_dat,
"DD/MM/YYYY") & "# ;"
Set kost = db.OpenRecordset(sql)
Then I enter the value in an entryfield:
Me!rek = Format(kost!somvanUur, "hh:mm")
the somvanUur is 1,229166
Me!rek shows 05:30 while it should be 28:30
What am I doing wrong?
Thanks
JP