TODO: Put in a comment to say that this will extend QueryExecutionException after the reorg