Delete queries and procedure now work