![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
Hi, I have a large table with a 'datetime' column that has date and time values in it. The data is in this format: 2007-10-02 09:54:00.000 The table is called 'profile' and the column 'msgdate' I want to return only rows that match a specific date. So far I have the following query working: select * from profile where msgdate like '%2007%' This returns all rows that start with '2007'. However I cannot seem to ge the syntax that will allow me to return a specific date, e.g. 2007-10-02 I have researched this, trying all sorts of queries with escape characters/sequences because of the dash character, but I cannot get it to return anything. Most of my queries have ran without error, its just that no data is returned. James |
#3
| |||
| |||
|
|
Hi, I have a large table with a 'datetime' column that has date and time values in it. The data is in this format: 2007-10-02 09:54:00.000 The table is called 'profile' and the column 'msgdate' I want to return only rows that match a specific date. So far I have the following query working: select * from profile where msgdate like '%2007%' This returns all rows that start with '2007'. However I cannot seem to ge the syntax that will allow me to return a specific date, e.g. 2007-10-02 I have researched this, trying all sorts of queries with escape characters/sequences because of the dash character, but I cannot get it to return anything. Most of my queries have ran without error, its just that no data is returned. James |
#4
| |||
| |||
|
|
Hi, I have a large table with a 'datetime' column that has date and time values in it. The data is in this format: 2007-10-02 09:54:00.000 The table is called 'profile' and the column 'msgdate' I want to return only rows that match a specific date. So far I have the following query working: select * from profile where msgdate like '%2007%' This returns all rows that start with '2007'. However I cannot seem to ge the syntax that will allow me to return a specific date, e.g. 2007-10-02 I have researched this, trying all sorts of queries with escape characters/sequences because of the dash character, but I cannot get it to return anything. Most of my queries have ran without error, its just that no data is returned. James |
![]() |
| Thread Tools | |
| Display Modes | |
| |