update sets and query fix