• RichB (1/3/2013)


    How about using Quotename...?

    SELECT QUOTENAME('o''neil', '''')

    Yes, QUOTENAME is my preferred method of dealing with dynamic SQL. Especially since it can also handle brackets.