Software Design
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me

The Shed is going Social! Join us on FaceBook and Twitter and chime in on the conversation.

Go Back   Dev Shed ForumsProgramming Languages - MoreSoftware Design

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old August 7th, 2003, 10:55 AM
epp_b's Avatar
epp_b epp_b is offline
PHPer
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Oct 2002
Location: La La Land
Posts: 145 epp_b User rank is Corporal (100 - 500 Reputation Level)epp_b User rank is Corporal (100 - 500 Reputation Level)epp_b User rank is Corporal (100 - 500 Reputation Level)epp_b User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: 6 h 14 m 23 sec
Reputation Power: 12
24 hour time

Does it make more sense to set 12 AM to 24:00 or to 00:00? Which will cause less trouble for inserting and reading from a database?
__________________
if (!$broke) {
dontFixIt();
}

Reply With Quote
  #2  
Old August 7th, 2003, 01:15 PM
Pasiphae1213's Avatar
Pasiphae1213 Pasiphae1213 is offline
Web Developer
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Oct 2001
Location: Pennsylvania
Posts: 171 Pasiphae1213 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Send a message via AIM to Pasiphae1213 Send a message via Yahoo to Pasiphae1213
To me, it seems more logical to set midnight to 00:00 because it is the switch from PM to AM, thus starting a new day. All digital wrist-watches and clocks that I have ever seen also go from 23:59 to 00:00.

As far as more efficiency in databases, I really don't know.

Reply With Quote
  #3  
Old August 7th, 2003, 08:02 PM
epp_b's Avatar
epp_b epp_b is offline
PHPer
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Oct 2002
Location: La La Land
Posts: 145 epp_b User rank is Corporal (100 - 500 Reputation Level)epp_b User rank is Corporal (100 - 500 Reputation Level)epp_b User rank is Corporal (100 - 500 Reputation Level)epp_b User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: 6 h 14 m 23 sec
Reputation Power: 12
Hmm. It seems that the database will accept 24:00:00, but will not properly use comparison operaters in the SQL queries (eg.: "SELECT * FROM TableName WHERE Time < '24:00:00'" will not work)

I've seem to come up with a bit of a work around though. Thanks for the suggestion

Reply With Quote
  #4  
Old August 8th, 2003, 12:22 PM
dog135's Avatar
dog135 dog135 is offline
Doggie
Dev Shed Novice (500 - 999 posts)
 
Join Date: Jul 2003
Location: Seattle, WA
Posts: 751 dog135 User rank is Corporal (100 - 500 Reputation Level)dog135 User rank is Corporal (100 - 500 Reputation Level)dog135 User rank is Corporal (100 - 500 Reputation Level)dog135 User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: 10 h 38 m 25 sec
Reputation Power: 11
Proper military time has 00:00 as midnight, so if you're using SQL tools to do the comparison, that's how you should store it.

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming Languages - MoreSoftware Design > 24 hour time

Developer Shed Advertisers and Affiliates



Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 


Powered by: vBulletin Version 3.0.5
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.

© 2003-2013 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap