I'm trying to run a SQL-query in Excel 2010 to MS SQL-Server 2008 with one parameter in DATETIME format:
SELECT * FROM mytable WHERE myCreateDate > ?
The column myCreateDate is DATETIME in MS SQL-Server. The parameter comes from a cell in Excel.
What do I have to enter in the Excel-cell? If I create the query in msquery directly, it writes
myCreateDate > {ts '2013-03-19 10:01:36'}
and it works. But I cannot get it work with a parameter.
Thanks for help.