categories-posts relationship and search