Re: Ask again about comparing cast string to date

2004-06-18 Thread Michael Stassen
Cao, Wenhong wrote: I am trying to select the records where the field activationtimestamp is within a certain range. Unfortunately the field activationtimestamp is defined as character(14) in the table. Perhaps you should change the type of activationtimestamp: ALTER TABLE SubscriptionVersion

RE: Ask again about comparing cast string to date

2004-06-17 Thread Victor Pendleton
If the activationtimestamp field is in MMDDHHMMSS format have you tried using unix_timestamp? ... select * from SoutheastDB.SubscriptionVersion where unix_timestamp(activationtimestamp) > unix_timestamp(DATE_ADD('2004061807', INTERVAL 5 HOUR)) and activationtimestamp <= '20040619065959' lim