I am making an installer, which needs to send a query at the end of the installation and after mounting the sMySQL service. I have no idea how this is done, this would be in the CODE section in PascalScript.
Once the installation is finished, an XML is accessed to load them to a couple of ListBox
, having them selected we send the data (which includes Country, Currency and some others). Previously it was done using JAVA with IzPack , with the following code.
String insert = "INSERT INTO `simarin`.`moneda` (`mon_id`, `moneda`, `abr`, `tipoCambio`, `singPlur`, `caracter`,`mn` ,`img16`, `img24`, `img32`, `status`) "
+ "VALUES (" + ((isPrincipal) ? "1" : "null") + ", '" + de.getName() + "', '" + de.getWSMoneda().getAbr() + "', " + convert(a.getWSMoneda(), de.getWSMoneda()) + " "
+ ", '" + de.getWSMoneda().getSingPlur() + "', '" + de.getWSMoneda().getCaracter()
+ "'," + (isPrincipal ? 1 : 0) + " ,?, ?, ?, 1);";
PreparedStatement pse = conn.prepareStatement(insert);
pse.setBlob(1, b16);
pse.setBlob(2, b24);
pse.setBlob(3, b32);
pse.execute();
It is the code that was passed to me to translate it to Inno Setup but I have no idea how to do it. Does anyone know what it would be like?
The solution I found was to create a script
SQL
:Then create a bat to run the script:
We call all of this
NextButtonClick