The conversion of a char data type to a datetime data type resulted in an out-of-range datetime value.
When I run the SQL query on my desktop machine, its fine. No errors or anything. However, when I execute the same code on the server that will be running it, it fails.
I've determined this is the section of SQL causing the issue. DateOfRun is a DateTime field.
,(SELECT intField
FROM tableA
WHERE RowIdentifier= ParentTable.RowIdentifier
AND DateOfRun = Convert(Varchar(10),ParentTable.OfferOutcomeDateTime,120)) AS Days
Why would this work on one machine, but not the other?