One of your columns has name DESC
, which is Reserved Keyword
. In order to peoperly execute the INSERT
statement, you need to delimite the column by using brackets
eg
insert into branch(code,[desc]) values ('"+b+"','"+c+"')";
One more thing, your code is prone to SQL Injection
. Please do parameterized the query.