Skip to content

Comments

Merge to master for v0.7#158

Merged
oblivioncth merged 57 commits intomasterfrom
dev
Oct 13, 2025
Merged

Merge to master for v0.7#158
oblivioncth merged 57 commits intomasterfrom
dev

Conversation

@oblivioncth
Copy link
Owner

No description provided.

Provides:
- Semi-declarative SQL struct-to-row mapping, similar to Qx JSON
- Idiomatic query building using C++ syntax
- Easier to use database class that automatically handles connections
and
thread management
- Miscellaneous convenience utilities pertaining to SQL

Does not cover all database functions, primarily for use in the most
common or more simple use cases. More complex database manipulation
should continue use of existing Qt SQL types directly.
Should probably split this into separate, module specific private
namespaces.
Unwraps containing templates into their (primary, if mulitple) inner
type, or simply returns T if it is not a template.
Allows easily wrapping existing QStrings in single or double quotes in
SQL statements.
Due to unspecified initialization order, the static variables in the
stream classes were being initialized before the ones used in IoOpReport
to create a proper report. The types are not compatible with constinit,
so instead we just moved their initialization to the cpp.
There are now 3 distinct overloads, regardless of the actual type
requested:
- Get all rows immediately as a list
- Get the first (or only) row only
- Get an iterable object that can walk all rows

If the actual type (i.e. T or T within a container) is not an sql-tied
struct, then only the first field in a row/record is checked/retrieved.

Also makes the type checking implementation more intuitive.
This allows it to work easily with while() loops, even if empty, just
lke QSqlResult, instead of having to use do while().
@github-actions github-actions bot added the release Pull requests into default branch for release (ignored for change log) label Oct 13, 2025
@oblivioncth oblivioncth merged commit 1d15649 into master Oct 13, 2025
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

release Pull requests into default branch for release (ignored for change log)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant