use try catch
temporarly fix feature types link problem
advanced search with pgQuery