The code you show only updates a single row. When are you calling it?