I have this code so far:
string userInput = Textbox1.text;
string query = "SELECT * FROM Books WHERE BookName = @Title";
SqlConnection con = new SqlConnection(connectionString);
SqlCommand cmd = new SqlCommand(query, con);
cmd.Parameters.AddWithValue("@Title", userInput);
and I need this query to support Cyrillic characters, and use N” for Cyrillic support:
SELECT * FROM Books Where BookName = N'UserInput%'
i need ‘%’ too because i want to find all books that match the UserInput.
This is not tested since I don’t use .NET but I would probably do it like this.
Change
=tolikein the query, add the%to the user input and make sure that the data type for BookName in table Books is ofnvarchar.