declare @error nvarchar(4000)
select @error=convert(nvarchar(4000),notes) from app_log_sql where id=1365
print @error