sql-js / sql-js/sql.js

Getting "bad parameter or other API misuse" for a prepared statement with correct data

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

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
13.7k
Forks
1.1k
PR merge metrics
No merged PRs in 30d

Description

I'm running some queries that produce the error "bad parameter or other API misuse", while the query and the params are all correct. I'm running the DB in a worker, is there any chance to have more info on what is actually going on? Since the query looks good, and it actually runs fine in tests, I'm wondering what else could be wrong.

Contributor guide

Open the contributing guide

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 prepared-statement path used by the worker and compare it with the tests where the same query and parameters succeed. Determine what causes the API-misuse error and make the resulting failure provide more useful information or document the cause, then verify the worker case and existing tests.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, sqlite
Domain
database
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.