Check if query fails in post proc.