• You should change dbcc inputbuffer something like that:

    SELECT t.[text]

    FROM sys.dm_exec_requests As r

    cross apply sys.dm_exec_sql_text(Sql_handle) As t

    WHERE session_id = @@spid

    More better if you search in text the line of error using ERROR_LINE () function

    Cheers,Safi