how to obtain the number of row affected by an INSERT query ?