Retrieve value from csv file and replace it in database in C#
问题 I am creating an application which reads a csv file into a data grid view in C#. The file consists of data such as item number and stock. If item number is same then its stock should be added and then replace the present stock in the database with same item number. I am able to add stock from the csv file to the database with same item numbers in the database but I am not able to replace stock. Here is my code: string sql_select = "select count(*) from PRODUCTS where item_no= '" + itemNo + "'