• VegasL - Saturday, November 11, 2017 10:44 PM

    Hi,

    I have in a data row:  column [date]   2017-11-06 01:17:34.000

    I only want to search for values if the year is 2015.  How do I do this?

    where [date] like '%2015"          ?

    This is a datetime value, neither a string nor date value, constrain the search accordingly, i.e. 
    WHERE [date] > CONVERT(DATEDIME,'2014-12-31 23:59',126)
    AND [date] < CONVERT(DATEDIME,'2016-01-01 00:00',126)

    😎