Preparing for last_id