fix failure on missing keys for where clause