raycast / raycast/utils

Merging multiple SQL queries (useMultiSQL)

Open
#18 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
TypeScript
Stars
84
Forks
18
Avg merge
3m
Merged PRs (30d)
1

Description

I'd like to support calling multiple SQL databases and return the results together with one hook (see https://github.com/raycast/extensions/issues/7665).

Can we create a useMultiSQL hook that accepts an array of paths to local SQL files and return the data, loading state and

  const { data, isLoading, permissionView } = useMultiSQL<HistoryEntry>([defaultHistory, profile1History, profile2History], getHistoryQuery(searchText));

Is this a good idea? I know there is a consideration on performance here and error handling if one of the DBs fails or returns data in an inconsistent format.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the proposed useMultiSQL API and the linked Raycast issue 7665. Define how multiple local SQL paths, loading state, permissionView, performance, and partial failures should be handled before identifying implementation entry points and tests; the payload names no files or existing tests.

Written by the indexing model from the issue text.

Assessment

Tech stack
sql, typescript
Domain
database
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.