bug fix: post update SQL was wrong