Solved

SQL select

Posted on 2014-03-20
3
310 Views
Last Modified: 2014-03-20
Hi Experts,

I have table where one column is timestamp type. I need to get rows comparing date part only of timestamp to mine 'YYYY-MM-DD'

Thanks.
0
Comment
Question by:fpoyavo
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 66

Expert Comment

by:Jim Horn
ID: 39942696
Give us a 'for example..' of what you're trying to pull off here.

SQL expert PortletPaul has an excellent article on SQL Server Date Styles using CONVERT(), where your answer will likely be in there somewhere.
0
 
LVL 1

Author Comment

by:fpoyavo
ID: 39943082
Hi Jim,

I tried this WHERE convert(varchar, my_tmsp ,110) = '03-20-2014'
 
and it does not work ... empty result

Thanks.
0
 
LVL 11

Accepted Solution

by:
John_Vidmar earned 500 total points
ID: 39943252
SQL Server's TIMESTAMP data-type has nothing to do with a date and/or time, it's just a binary representation of a consecutive number - it's only good for making sure a row hasn't change since it's been read.
0

Featured Post

Turn Insights Into Action

You’ve already invested in ITSM tools, chat applications, automation utilities, and more. Fortify these solutions with intelligent communications so you can drive business processes forward.

With xMatters, you'll never miss a beat.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

If you have heard of RFC822 date formats, they can be quite a challenge in SQL Server. RFC822 is an Internet standard format for email message headers, including all dates within those headers. The RFC822 protocols are available in detail at:   ht…
In this article I will describe the Backup & Restore method as one possible migration process and I will add the extra tasks needed for an upgrade when and where is applied so it will cover all.
Monitoring a network: why having a policy is the best policy? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the enormous benefits of having a policy-based approach when monitoring medium and large networks. Software utilized in this v…
Monitoring a network: why having a policy is the best policy? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the enormous benefits of having a policy-based approach when monitoring medium and large networks. Software utilized in this v…

691 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question