Skip to content

Commit

Permalink
Add index for pinnedAt in Feed and FeedGroup table
Browse files Browse the repository at this point in the history
  • Loading branch information
msasikanth committed Apr 17, 2024
1 parent 5a90a1e commit df7300b
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 0 deletions.
Binary file added shared/src/commonMain/sqldelight/databases/17.db
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ CREATE TABLE feed(
);

CREATE INDEX feed_link_index ON feed(link);
CREATE INDEX feed_pinned_at ON feed(pinnedAt);

upsert:
INSERT INTO feed(id, name, icon, description, homepageLink, createdAt, link)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ CREATE TABLE IF NOT EXISTS feedGroup(
pinnedAt INTEGER AS Instant
);

CREATE INDEX feed_group_pinned_at ON feedGroup(pinnedAt);

count:
SELECT COUNT(*) FROM feedGroup;

Expand Down
2 changes: 2 additions & 0 deletions shared/src/commonMain/sqldelight/migrations/16.sqm
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
CREATE INDEX feed_pinned_at ON feed(pinnedAt);
CREATE INDEX feed_group_pinned_at ON feedGroup(pinnedAt);

0 comments on commit df7300b

Please sign in to comment.