Reply
comparing dates
Old 03-26-2006, 03:15 PM comparing dates
numbenator's Avatar
Ultra Talker

Posts: 413
Location: London
hi

I have a date in a access table that is in the format 26/03/2006 20:11:54

I wish to compare this date but not the time against now() without the time. so just dd/mm/yyyy

how do id o this.

cheers
__________________
www.mastech-solutions.com
numbenator is offline
Reply With Quote
View Public Profile Visit numbenator's homepage!
 
When You Register, These Ads Go Away!
Old 03-27-2006, 06:27 AM Re: comparing dates
chrishirst's Avatar
Super Moderator

Posts: 15,291
Location: Blackpool. UK
all dates are stored as Floating Point numbers,

date before the decimal point, time after

so cast the date as a long type to remove the time portion

Code:
clng(now())
__________________
Chris. ->> Links are advertising NOT optimising!! <<-
Indifference will be the downfall of mankind, but who cares?
Code Samples | People Counting System | Bits & Bobs
chrishirst is offline
Reply With Quote
View Public Profile Visit chrishirst's homepage!
 
Reply     « Reply to comparing dates
 

Thread Tools

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
Trackbacks are Off
Pingbacks are Off
Refbacks are Off


Webmaster Resources Marketplace:
Software Development Company | Webhosting.UK.com | Text Link Brokers 


   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML

 


Page generated in 0.12136 seconds with 12 queries