Link to home
Start Free TrialLog in
Avatar of Loganathan Natarajan
Loganathan NatarajanFlag for India

asked on

How do I find next day date by end time ?

I have db with these details

Title (text)
Date Start Time (Timestamp)
Date End Time  (Timestamp)

Open in new window


I will get input as

"This is title"
09/29/2014
11:55 PM
03:35 AM

Open in new window


Now I need to calculate based on end time "03:35 AM".. the next day as "09/30/2014"?

How can I do this?

attached are my sample input screen.
SOLUTION
Avatar of Ray Paseur
Ray Paseur
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Now I need to calculate based on end time "03:35 AM".. the next day as "09/30/2014"?
How do you figure out that the next day is 09/30/2014?  Is this value always the current date + 1 day?  Give us a little more to go on, and I'll be glad to show you the calculations (or just read the article and you'll find many examples of date/time arithmetic).
Avatar of Loganathan Natarajan

ASKER

Thanks Ray, let me go through your article first.
OK.  Once we know the rules for interpreting the times, it should be pretty easy to get the code together.
I read the tutorial , it is useful and more details to work further. Thanks Ray.

but in my case different, just check the attachment screen. the input comes always one DATE and FROM, TO time ...

So, what is the best way to validate in my case?
doubt.png
ASKER CERTIFIED SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Thanks ray. It is very helpful and fixed it.
Great!  Thanks for the points, ~Ray