Link to home
Start Free TrialLog in
Avatar of akatz66
akatz66

asked on

teradata - pulling time information from datetime field

Hello,
   I am trying to pull out the time from a datetime field and I'm having some trouble.  It's fairly easy to do with the date and I'm not sure what I'm doing wrong.  An example of the field is :

2008-08-29 13:05:00

To pull a date, I use the following code:
WHERE
(CAST(tablename.fieldname AS DATE) BETWEEN {(alias) '2010-06-01'} AND {(alias) '2011-04-30'})
ASKER CERTIFIED SOLUTION
Avatar of Jim P.
Jim P.
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