clockworklabs / clockworklabs/SpacetimeDB
Multi-table subscription
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 25.2k
- Forks
- 1.1k
- Avg merge
- 2d 7h
- Merged PRs (30d)
- 46
Description
it would be nice to be able to write subscriptions that subscribe to multiple tables at once with conditions that link them. something like:
"SELECT * FROM auction_listing as AL, user_name as UN, item_lookup as IL WHERE AL.cathegory = 'Weapon' LINK AL.entity_id = UN.entity_id, AL.item_id = IL.item_id"
and it is like writing 3+ separate subscriptions and returns the rows of the 3 tables where the link and where condition matches.
the problem currently is that it is a pain to get related data from multiple tables without opening potentially hundreds to thousands of subcriptions per client.
Requested by @xDovos via the SpacetimeDB site.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
The issue provides a proposed SQL-like syntax but names no files, entry points, or tests. Start by locating the subscription and query-processing implementation, then determine how existing single-table subscriptions are represented and tested. Done would require an agreed multi-table subscription design, implementation, and coverage for linked-table and filtering behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust, sql
- Domain
- databases
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Quiet
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100