Search
Star
Feedback
Setup for Free
© 2026 Hedgehog Software, LLC
Twitter
GitHub
Discord
System
Light
Dark
More
Communities
Docs
About
Terms
Privacy
Select item collection together with item count - Drizzle Team
DT
Drizzle Team
•
3y ago
•
14 replies
Venyl
Select item collection together with item count
Heads
-up
: I
'm an SQL
& Drizzle newbie
I have 3 tables
:
users
users
,
flashcard_collection
flashcard_collection
and
flashcards
flashcards
flashcard_collection
flashcard_collection
has a
creatorId
creatorId
foreign key which indicates what user a collection belongs to
flashcards
flashcards
has a
collectionId
collectionId
foreign key which indicates what collection a flashcard belongs to
I want to select all flashcard collections that belong to a user together with each collection
's flashcard count
Drizzle Team
Join
The official Discord for all Drizzle related projects, such as Drizzle ORM, Drizzle Kit, Drizzle Studio and more!
11,879
Members
View on Discord
Resources
ModelContextProtocol
ModelContextProtocol
MCP Server
Recent Announcements
Similar Threads
Was this page helpful?
Yes
No
Similar Threads
Astro DB: using count() and countDistinct()?
DT
Drizzle Team / help
2y ago
Get total row count in select
DT
Drizzle Team / help
3y ago
help with count()
DT
Drizzle Team / help
2y ago
Count with Limit
DT
Drizzle Team / help
3y ago