-
April 26th, 2016, 03:12 AM
#1
Junior Member
How do I write a SQL query involving a time stamp?
How do I write a SQL query involving a time stamp?
QUOTE_ID is a character string
CREATE_DTG is a date time type
RETENTION_LEAD_TRACK is a table
This sql statement cmf.CommandText = "SELECT QUOTE_ID FROM RETENTION_LEAD_TRACK where CREATE_DTG > '2016 - 04 - 25 18:18:15.2891'"
throws this error {"Conversion failed when converting date and/or time from character string."}
-
April 27th, 2016, 09:35 AM
#2
DATE - format YYYY-MM-DD
DATETIME - format: YYYY-MM-DD HH:MI:SS
SMALLDATETIME - format: YYYY-MM-DD HH:MI:SS
Looks like you have spaces in the date that shouldn't be there.
Similar Threads
-
By JAsoN74185 in forum Wireless Security
Replies: 22
Last Post: September 6th, 2004, 03:49 PM
-
By groovicus in forum Computer Forensics
Replies: 10
Last Post: November 23rd, 2003, 11:12 PM
-
By bpiedlow in forum *nix Security Discussions
Replies: 0
Last Post: September 19th, 2003, 06:11 PM
-
By E5C4P3 in forum AntiOnline's General Chit Chat
Replies: 6
Last Post: March 3rd, 2002, 10:43 AM
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
|