>>334
なら
update person set sex='男' where sex='女' and...
update person set sex='女' where sex='男' and...
みたいに2つSQL文を発行すれば?
他に読み出してから行う処理がなくて済むなら速いと思う