Thanks, indeed the issue is the location where I've put the prepared statement, don't know why I didn't seen it. I even checked on some older code where I had begin/commit and even though there I've used it correctly I didn't seen differences beetween that and the way I set up my prepared query here.