Hi,
I got an error in this script and i don’t know how to fix it. The idea that i have is automatically send to one database the backups:
if system.file.fileExists("/home/antonio/Ignition-backup-20160327-0530.gwbk"):
bytes = system.file.readFileAsBytes('/home/antonio/Ignition-backup-20160327-0530.gwbk')
system.db.runPrepUpdate("INSERT INTO db.gw_backups (file) VALUES (?)", (bytes))
It should work but i got always an error
[color=#FF0000]Caused by: java.lang.Exception: Error executing system.db.runPrepUpdate(INSERT INTO gw_backups (fc,file) VALUES (?,?), [MAD4, [B@5c8e9657], MAD4_SID, , false, false)
… 24 more
Caused by: com.mysql.jdbc.PacketTooBigException: Packet for query is too large (24039952 > 16777216). You can change this value on the server by setting the max_allowed_packet’ variable.[/color]
I have tried to find this setting in the gateway but i couldn’t find it. Can you please help me?
Thanks,
Antonio