Fix closing quote for 'N' strings
When typing a string preceded with 'N' (like N'string value'), when you type the closing quote it gets doubled. Hard to explain, but easy to reproduce. Just type these two statements into SSMS to see the difference:
SELECT 'Bill' As FirstName
SELECT N'Bill' As FirstName
Jim Nguyen commented
I don't get that issue when I type those two SELECT statements. The feature to automatically add the closing character and remove a duplicate closing character works correctly.
However, I was able to recreate the scenario that you are describing. The removal of a duplicate closing character does not work after I applied a style and tried to add a new literal as part of the existing SELECT statement. I was able to consistently recreate this problem following the steps below.
Type: SELECT 'Bill' AS FirstName
Edit Existing Statement by attempting to add a new literal column: ,'Bill' AS NewColumn
When you add the new column, the ending quote is added when you add the opening quote. If you add a closing quote after adding the literal value, the feature to remove a duplicate closing quote is not applied, so you end up with two closing quotes. This occurred using version 10.3.5.
This only occurs with existing statements where the style was applied. For new statements, the features work correctly before or after the style was applied.