sql stop working after updating from V5.76 to V5.92
Posted: 2020-12-11 16:24
Hello everybody,
I have an app working fine developed with Appgini Version 5.76. After upgrading to Appgini V5.92, a couple of weeks ago, the systems is not working.
As an example, I have this code in a hook working perfecty fine:
$id_itemsorden=$data['selectedID'];
sql("update itemsorden left join menu on itemsorden.nombre_itemorden = menu.id_menu set itemsorden.precio_itemorden = menu.precio_menu where id_itemsorden ='$id_itemsorden'", $eo);
$pitemorden = sqlValue("SELECT precio_itemorden FROM itemsorden WHERE id_itemsorden = '$id_itemsorden' ");
$total_itemorden=money_format('%.2n',$pitemorden*$data['cant_itemorden']*(1+$data['iva_itemorden']/100));
sql("update itemsorden set total_itemorden='$total_itemorden' where id_itemsorden='$id_itemsorden'", $eo);
updatecfTotals($data['orden_item']);
After upgrading, that code stopped working. Has something changed in the sql sintax to be used in the new Appgini Version?
This is just a piece of code, I have worked a lot on this app in order to achieve what it is needed and it is taking me a lot of time trying to figure out how to replicate all the features of the app using the new calculated field tab in Version5.92, so I would like to keep the hooks approach, until I manage to learn how to do it withing the calculated tab in AppGini.
Thanks in advance for all the help.
I have an app working fine developed with Appgini Version 5.76. After upgrading to Appgini V5.92, a couple of weeks ago, the systems is not working.
As an example, I have this code in a hook working perfecty fine:
$id_itemsorden=$data['selectedID'];
sql("update itemsorden left join menu on itemsorden.nombre_itemorden = menu.id_menu set itemsorden.precio_itemorden = menu.precio_menu where id_itemsorden ='$id_itemsorden'", $eo);
$pitemorden = sqlValue("SELECT precio_itemorden FROM itemsorden WHERE id_itemsorden = '$id_itemsorden' ");
$total_itemorden=money_format('%.2n',$pitemorden*$data['cant_itemorden']*(1+$data['iva_itemorden']/100));
sql("update itemsorden set total_itemorden='$total_itemorden' where id_itemsorden='$id_itemsorden'", $eo);
updatecfTotals($data['orden_item']);
After upgrading, that code stopped working. Has something changed in the sql sintax to be used in the new Appgini Version?
This is just a piece of code, I have worked a lot on this app in order to achieve what it is needed and it is taking me a lot of time trying to figure out how to replicate all the features of the app using the new calculated field tab in Version5.92, so I would like to keep the hooks approach, until I manage to learn how to do it withing the calculated tab in AppGini.
Thanks in advance for all the help.