----- Original Message -----
From: "Tony Weeg" <[EMAIL PROTECTED]>
To: "CF-Talk" <[EMAIL PROTECTED]>
Sent: Wednesday, March 24, 2004 1:48 PM
Subject: RE: Quick Question, RE: Datatype and future date/time calculation

> ok...
>
> I would have these tables.
>
> tasks
> ----------
> id
> allottedTime  (int) [keep as seconds]
> status (int) (complete/not complete) (1 or 0)
> actualTimeSpent (int) [seconds]
> (you could write total seconds here once status is changed, or update
> this with new value plus old value to keep accruing)
> taskName (varchar)
>
> taskTimeSpent
> --------------------
> id
> beginTime (int) [seconds since jan 1 1970]
> EndTime (int) [seconds since jan 1 1970]
> taskId
> userId
>
> then you can do myriad calculations on this...using this, its very simple,
> and probably a lot could be added, but that's how id do it off the top of
my
> head.

Okay, I'm almost exactly with you, except for the "beginTime" and "EndTime".
I recommended that very way of storing time, and was told "our people only
enter in the amount of time, not start and stop". Also, if multiple people
could be assigned to a task, and perform multiple times against it, wouldn't
it be easier to just "summarize the total of taskTimeSpent.usedTime where
taskTimeSpent.taskID = tasks.id" than to keep tasks.actualTimeSpent...or at
the very least, wouldn't this calculation be how I arrived at
"actualTimeSpent"?

Jeff,
just making sure I'm keeping up.
[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]

Reply via email to