added last_insert_id snippet