sa.Index('hive_posts_ix4','parent_id DESC NULLS LAST','id'),#postgresql_where=sql_text("is_deleted = '0'")), # API: fetching children #[JES] We decided we want the full index since posts can be deleted/undeleted
sa.Index('hive_posts_ix5','id',postgresql_where=sql_text("is_pinned = '1' AND is_deleted = '0'")),# API: pinned post status
sa.Index('hive_posts_ix6','community_id','id',postgresql_where=sql_text("community_id IS NOT NULL AND is_pinned = '1' AND is_deleted = '0'")),# API: community pinned