perf: offer array-shaped query results
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 5/5
- Estimated time
- Over a week
- Newbie friendliness
- 48/100
- Issue type
- Feature
- Clarity
- Mostly clear
- Activity status
- Active
- Tech stack
- cpp, javascript, react-native, sqlite
- Domain
- database, mobile, performance
Research direction
Begin with PR #389's converter and the existing synchronous, asynchronous, and prepared-statement query entry points. Add coverage for both result modes, including duplicate aliases, NULL, text, numbers, BLOBs, and empty results, then compare narrow and wide full-row consumption on iOS and Android Release builds for conversion time and peak memory.
Written by the indexing model from the issue text.
Description
Object-shaped results create a JavaScript object and set a property for every returned column. PR #389 removes the native row maps and an intermediate copy, but its converter still builds those JavaScript objects. For callers that consume wide results by column position, an array-shaped result may reduce conversion time and memory.
Add an opt-in result mode that returns each row as an array alongside column names in SQL order. Keep the existing object-shaped result as the default. The API should work for ordinary synchronous and asynchronous queries and prepared statements without creating a second SQL execution path. An ordered column list matters because duplicate aliases cannot be represented faithfully by the current metadata map.
Measure this against the object converter after #389 on the same Release builds. Include both narrow and wide queries, full row consumption, conversion time, and peak memory on iOS and Android. Preserve the old behavior for duplicate aliases in object mode and test NULL, text, numbers, BLOBs, and empty results in both modes.
Related: #30, #62, #389. The timings in #30 came from the old QuickSQLite implementation and are not an expected v10 speedup.
- Dominant language
- C
- Stars
- 567
- Forks
- 53
- Avg merge
- 2d 5h
- Merged PRs (30d)
- 67
Getting set up
- No Dockerfile or Docker Compose file
- No pull request template
- Read the contributing guide
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.
More from margelo/react-native-nitro-sqlite
-
area:api area:runtime enhancement
Difficulty 5/5 Over a week Newbie friendliness 35/100
margelo/react-native-nitro-sqlite#402 ·
Maintainers usually reply within 1 day
-
area:api area:runtime enhancement
Difficulty 5/5 Over a week Newbie friendliness 28/100
margelo/react-native-nitro-sqlite#401 ·
Maintainers usually reply within 1 day
-
area:api area:runtime enhancement
Difficulty 5/5 Over a week Newbie friendliness 35/100
margelo/react-native-nitro-sqlite#400 ·
Maintainers usually reply within 1 day
-
area:api area:runtime enhancement
Difficulty 5/5 Over a week Newbie friendliness 28/100
margelo/react-native-nitro-sqlite#399 ·
Maintainers usually reply within 1 day
-
area:api area:runtime enhancement
Difficulty 5/5 Over a week Newbie friendliness 35/100
margelo/react-native-nitro-sqlite#398 ·
Maintainers usually reply within 1 day
All issues in margelo/react-native-nitro-sqlite
Similar issues
-
Difficulty 1/5 Under an hour Newbie friendliness 88/100
containers/bubblewrap#813 · 1 reaction ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 86/100
kubernetes-sigs/security-profiles-operator#3537 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
darktable-org/darktable#22502 · 2 comments ·
Maintainers usually reply within 1 day
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
Maintainers usually reply within 1 day
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 86/100
Maintainers usually reply within 1 day