Fix edit_page sql problem