variable
variable

Reputation: 9724

What is the implication of not specifying N prior to the nvarchar text

I have been reading SQL best practice examples and notice that when filtering a nvarchar column using the where clause, it is best practise to specify the keyword N prior to the text being searched.

Example: where column1=N'text'

In above example I am filtering column1 (nvarchar column) on the string 'text'.

I want to understand what is the implication of not following this method (that is - not specifying the N keyword while filtering nvarchar coloumns)

Upvotes: 0

Views: 70

Answers (1)

Kapil
Kapil

Reputation: 987

On using N if there is any foreign language character available like French æ , it will be considered as æ and not as an English language character 'ae'. This will not produce any mismatch while data comparison of an incoming text with the existing text.

Upvotes: 1

Related Questions