Link to home
Start Free TrialLog in
Avatar of dsoderstrom
dsoderstrom

asked on

Question regarding SQL Query Editor

I am designing a query using the Query Editor in SQL server.
I am querying a table and putting a filter on a nvarchar column.
If I type a value into the filter column, for example '12', the editor changes it to N'12'.  
why is it doing this?  What does the "N" signify?
Avatar of Jim Horn
Jim Horn
Flag of United States of America image

N (nchar, nvarchar, ntext) signifies Unicode, meaning it handles a larger number of characters then non-unicode, and each character takes two bytes in memory instead of one.

Typically this is needed when dealing with foreign language collations.

>If I type a value into the filter column, for example '12', the editor changes it to N'12'.  
Curiosity overwhelms me ... if you have a column that you'd want to filter on '12', then why is it a character data type as opposed to numeric?
Avatar of dsoderstrom
dsoderstrom

ASKER

So, can I strip out this N and get the same results?
ASKER CERTIFIED SOLUTION
Avatar of Jim Horn
Jim Horn
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Okay, thanks for the info Jim