So, I'm getting a "Msg 241, Level 16, State 1, Line 1 Conversion failed when converting date and/or time from character string." when I run the following query. What's going on?
select sub.SSNO +REPLICATE (' ',714) +sub.BDFW +sub.BDFWDT +sub.ADM +sub.ADMDT +REPLICATE (' ',1431) from (select e.SSNO as ssno, BDFW='7153', e.[SCH-BD-DT] as BDFWDT, ADM='7154', e.[SCH-ADM-DT] as ADMDT from Manual.dbo.External_Award_Dates_Prep e ) sub order by 1
The dates in the query are "BDFWDT" and "ADMDT" and are in the table as dates.