Adam, let me address the SQL statement first. I'll have to take a look at your project later. I might suggest you find some tutorials on SQL. Once you know the syntax of SQL statements, then you just need to be able to apply them inside MVD's SQLExecute command. Here is an online site which provides tutorials and examples of basic SQL statements: https://www.w3schools.com/sql/
The SqlExecute command is simply one big string of an SQL statement inside the parentheses. SQLExecute('Insert.....'); The entire SqlExecute line can actually be on one line, but then it would stretch way past the screen edge. I put line breaks in for readability purposes. It also makes it a little easier for debugging as well.
Since the entire Sql statement is a string, then if you have text string values inside the single quotes, then the strings are placed inside double quotes (quotation marks). Text fields should be inside quotation marks while numeric values typically do not need the quotes.
The Sql Insert command defines the fields you are inserting separated by commas. The actual values being inserted are also separated by commas. That's why you see commas between the field values. If you manually inserted a row, an example might look like this:
Insert into Invoice (Counter1,Counter2,Counter3,Counter4,DBCRvalue,product,PIprice,PIRprice,SIprice,SIRprice) Values ("00001","00002","00003","00004","Purchase","ABC Product",100,40,150,10)
I rewrote the SqlExecute statement to maybe make it a little more understandable and readable to you. It does exactly the same as the one you presented except I formatted it for better understanding of the position of the quotation marks around text fields. Hope this makes sense.
SqlExecute('Insert into Invoice (Counter1,Counter2,Counter3,Counter4,DBCRvalue,product,PIprice,PIRprice,'
+ 'SIprice,SIRprice) Values ('
+ '"' + frmRefund.EdCounter1.Text + '",'
+ '"' + frmRefund.edCounter2.Text + '",'
+ '"' + frmRefund.edCounter3.Text + '",'
+ '"' + frmRefund.edCounter4.Text + '",'
+ '"' + frmRefund.edDBCR.Text + '",'
+ '"' + frmRefund.edInvProduct.Text + '",'
+ frmRefund.edPIRpricePI.sqlValue + ','
+ frmRefund.edPIRprice.sqlValue + ','
+ frmRefund.edSIRpriceSI.sqlValue + ','
+ frmRefund.SIRprice.sqlValue + ')' );
Sorry that I didn't annotate with pictures. Just didn't have time. I'll try to look at your project tomorrow.