S simon4amiee Registered User. Local time Today, 15:23 Joined Jan 3, 2007 Messages 109 Mar 20, 2015 #1 Is it possible to easily convert 02/02/2015 15:30:00 to 201502021530 in a query?
C CJ_London Super Moderator Staff member Local time Today, 15:23 Joined Feb 19, 2013 Messages 17,398 Mar 20, 2015 #2 use the format command format(mydate,"yyyymmddhhnn") which is text and to convert this to a number surround with clng clng(format(mydate,"yyyymmddhhnn"))
use the format command format(mydate,"yyyymmddhhnn") which is text and to convert this to a number surround with clng clng(format(mydate,"yyyymmddhhnn"))
spikepl Eledittingent Beliped Local time Today, 16:23 Joined Nov 3, 2010 Messages 6,142 Mar 20, 2015 #3 Errr that number is beyond the range of Long.
C CJ_London Super Moderator Staff member Local time Today, 15:23 Joined Feb 19, 2013 Messages 17,398 Mar 20, 2015 #4 OK - cdbl then. my bad Although for all intents and purposes it will sort the same way as text as a number and I can't see you wanting to add or divide it so the conversion to number is probably academic anyway
OK - cdbl then. my bad Although for all intents and purposes it will sort the same way as text as a number and I can't see you wanting to add or divide it so the conversion to number is probably academic anyway
spikepl Eledittingent Beliped Local time Today, 16:23 Joined Nov 3, 2010 Messages 6,142 Mar 20, 2015 #5 The date already is a number - one of type Double. What is the purpose of this suggested conversion?