fix deletion of partitioned tables

* when the WHERE clause queries a non existent column
* when the WHERE clause queries a non existent partition value