Skip to content

some performance related index #1225

@alphatownsman

Description

@alphatownsman
CREATE INDEX CONCURRENTLY idx_activities_post_author_published 
ON activities_post (
    author_id, 
    published DESC
) 
WHERE state NOT IN ('deleted', 'deleted_fanned_out');

CREATE INDEX CONCURRENTLY idx_timelineevent_identity_type_created 
ON activities_timelineevent (identity_id, type, created DESC);

CREATE INDEX CONCURRENTLY idx_journal_rating_item_grade 
ON journal_rating (item_id, grade) 
WHERE grade IS NOT NULL;

CREATE INDEX CONCURRENTLY idx_shelf_ctype_group ON journal_shelfmember (owner_id, parent_id) 
INCLUDE (item_id);

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    Status

    Wishlist

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions