Right now, our advanced search queries join to every table that could possibly queried by default. We should only include the tables that will be needed for the SELECT clause by default and then add on the tables that are actually queried dynamically. This should help performance on the advanced search page.