errors in structured queries