Modified dynamic soql to look for namespaced values