How to directly execute SQL query in C#? Stack ...
IMPORTANT NOTE: You should not concatenate SQL queries unless you trust the user completely. Query concatenation involves risk of SQL Injection being used to take over the world, ...khem, your database. If you don't want to go into details how to execute query using SqlCommand then you could call the same command line like this: