catheter question

My 1st was an emergency c-section and they put in the catheter very rushed like before I was given any pain meds and it hurt. When is it done during a planned csection? After the block or early on?