rQuery Builder is a lightweight, modular SQL query builder designed to generate SQL statements dynamically and programmatically. It aims to simplify common query construction across various databases—without the heavy abstraction of traditional ORMs.
Unlike most ORMs, rQuery Builder respects the syntax and features unique to each supported database. It provides isolated modules and methods per database, ensuring full flexibility and alignment with native SQL dialects.
- Modular design with adapters for each database.
- Initial support for:
- PostgreSQL
- MySQL
- SurrealDB
-
=Equal -
!=Not Equal -
LIKE -
>Greater Than -
>=Greater Than or Equal -
<Less Than -
<=Less Than or Equal -
IN -
NOT IN -
IS NULL -
IS NOT NULL -
BETWEEN
-
DISTINCT -
ORDER BY -
GROUP BY -
WHERE - Select specific columns
-
JOIN(inner, left, etc.) - Table aliasing
- Retrieve columns of a table
- JSONB filtering(where), columns(select fields), group by and order by
- Placeholder Kinds/Types: (
?,$N)
- Single row insert
- Bulk insert
- Placeholder Kinds/Types: (
?,$N)
- Single row update
- Bulk update
- Placeholder Kinds/Types: (
?,$N)
-
DELETEqueries - Placeholder Kinds/Types: (
?,$N)
-
SELECTqueries -
INSERTqueries -
UPDATEqueries -
DELETEqueries
Targeting full feature parity with PostgreSQL support.
Exploring support for SurrealDB's document-style query language and unique features.
Coming soon: Installation, setup instructions, and usage examples.
To speed up builds, it's recommended to use sccache for caching compiled dependencies.
cargo install sccachebrew install sccachechoco install sccacheAdd the following to your .cargo/config.toml:
[build]
rustc-wrapper = "sccache"Verify it's working:
sccache --show-statsAll contributions are welcome—feature suggestions, bug reports, documentation updates, or pull requests. Feel free to open an issue or contribute directly.
MIT License