hi guys
i am getting this error incorrect syntax near ‘,’ when i try to insert row in sql database through vb.net. the same command works for all tables but i get error in this. please help. its urgent.
Dim cmd1 As New SqlCommand
cmd1 = New SqlCommand("insert into finstock(finstkcode,orderno,linenb,productcode,description,totmakcharge,stockdate,stkfor,designcode,diacolor,diashape,diapurity,stoneshapecode,karatcode,stonepcs,stonecode,gramwtgld,gramwtslvr,karattype,diapcs) values('" & fin & "'," & dsor.Tables(0).Rows(0).Item(0) & "," & dsor.Tables(0).Rows(0).Item(1).ToString & ",'" & dsor.Tables(0).Rows(0).Item(14) & "','" & txtdec.Text & "','" & txtmak.Text & "','" & stkdate.Text & "','" & str & "','" & dsor.Tables(0).Rows(0).Item(2) & "','" & dsor.Tables(0).Rows(0).Item(6) & "','" & dsor.Tables(0).Rows(0).Item(8) & "','" & dsor.Tables(0).Rows(0).Item(7) & "','" & dsor.Tables(0).Rows(0).Item(9) & "','" & dsor.Tables(0).Rows(0).Item(11) & "'," & dsor.Tables(0).Rows(0).Item(12) & ",'" & dsor.Tables(0).Rows(0).Item(10) & "'," & dsor.Tables(0).Rows(0).Item(4) & "," & dsor.Tables(0).Rows(0).Item(5) & "," & dsor.Tables(0).Rows(0).Item(3) & "," & dsor.Tables(0).Rows(0).Item(13) & "')", con)