CDE#1881 IntegerArrays not working on sql queries

Integer Arrays are being interpreted as String Arrays and query gets
rejected with type dismatch.
Check how Integer Params are being built and sent to the query