• Post Reply Bookmark Topic Watch Topic
  • New Topic

How to select time stamp data as date

 
M Wilson
Ranch Hand
Posts: 41
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I would like to know how in my sql to select the date part of a time stamp date?
For example:
select REF_NO, STAT_CD, DATE_TS
FROM TABLE

The result of this returns DATE_TS = 2011-01-24 08:45:19.977
How can my sql return just the 2011-01-24 part of it?

Thank you very much.
 
Tom Reilly
Rancher
Posts: 618
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Try Googling mysql Date(). Please respond if you need more information.
 
my overalls have superpowers - they repel people who think fashion is important. Tiny ad:
the new thread boost feature brings a LOT of attention to your favorite threads
https://coderanch.com/t/674455/Thread-Boost-feature
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!