Reputation: 91
I have the following insert
statement in a stored procedure:
INSERT INTO Persons (ID, Name, LocationID)
VALUES (@MaxId, @Name, @LocationID)
It works fine until I get a name with Cyrillic characters (i.e дом), which added a record with name = ???
I know I can use something like that:
INSERT INTO Assembly
VALUES(N'Македонски парлиамент број 1', '', '');
But how can I use it with SQL parameters?
Thanks
Upvotes: 0
Views: 497
Reputation: 43636
Basically, you should check the followings:
@Name
variable with NVARCHAR
type? If it is a VARCHAR
type it cannot store properly your Cyrillic values.@Name
value by yourself, check if there is N
before the string value (as in your example)Upvotes: 3