Adding in location variable in encounter search.
Making sql statement slightly cleaner.