I have some data like this in a table:
year           month        day           ID
2013            1             1            x1
2013            1             2            x2
2013            1             3            x3
2013            1             4            x4
2013            1             5            x5
2013            1             6            x6
...
2016            4             10           x1500
This table is a customer table with customerID and customer apply date, but the apply date is split to year & mont & day , data from 2013/1/1 to 2016/4/10 , I want to get the customerID that apply after 2014/4/5.
Here's the code I tried:
SELECT * 
FROM table
WHERE [Year]+'-'+[Month]+'-'+[Day] > '2014-4-5'
But I got this error back:
[Err] 22018 - [SQL Server]Conversion failed when converting the varchar value '2014-4-5' to data type int.
Who can help me?
 
     
     
     
     
     
     
    