Get the right dict for where clause complete
ideas mostly