Query data is now stored in .sqlx/{query_hash}.json directly by the macro
invocations, rather than first writing to target/sqlx/{input_span_hash}.json
and then collecting those into sqlx-data.json separately.
* Make PgLTree::push infallible and take PgLTreeLabel directly.
Previously the function took strings and parsed them into
PgLTreeLabel internally, now it's possible to directlry push
PgLTreeLabels onto a PgLTree.
* Push PgLTree String conversion to label.
* rebase and fix compile error
Co-authored-by: Austin Bonander <austin@launchbadge.com>
* postgres: use Oid type instead of u32
* Make serde happy
* Expose the inner u32
* docs
* Try to fix tests
* Fix unit tests
* Fix order
* Not sure what happened here
git2-rs recently updated major versions due to libgit2 doing the same.
Bump the version used in sqlx accordingly, to allow users of the new
git2 to use git2::Oid with sqlx.
* Add Query builder
* Make query_builder.rs in sqlx-core
* Add QueryBuilder::new()
* Add QueryBuilder::push()
* Define questions for documentation
* Get new, push, push_bind working with types
* Handle postgres' numbered bind varaibles
* Add a test for QueryBuilder#build
* Move arguments into Option
* Refactor query builder
* Finish testing QueryBuilder#build
* Remove design doc
* Add a test for pushing strings with push_bind
* Integration test green
* Adjust some tests
* Make query builder generic about placeholder segmenent ('$N' or '?')
* Run fmt
* Redesign Arguments#format_placeholder in line with code review
* Use write! to push sql to QueryBuilder
* Add QueryBuilder::reset to allow for QueryBuilder reuse
* Run cargo fmt
Right now, there is only a `run` function to programatically run the
migrations, which is great, but nothing to run the migrations down.
This function adds the possibility to undo the migrations until a
specific version (could say -1 or 0 to remove them all).
With this feature, it's now possible, in the end to end or integration
tests to run the migrations and undo them between each test set and
therefore test the migrations themselves.
This is the kind of feature that some ORM have like sequelize in nodejs
that allow you to undo migrations programatically.
Reference to the doc:
https://sequelize.org/v7/manual/migrations.html#undoing-migrations
Signed-off-by: Jérémie Drouet <jeremie.drouet@gmail.com>
* Reproduce github issue#1249: Left joins in sqlite can break the query macros
* Fix panic caused by unknown cursor columns when executing NullRow command. Fixes#1249
* Implement PgHasArrayType for JSON types in the serde_json crate
* Remove redundant Type impls for arrays and Vecs of JsonValue
* Relax an implicit Sized bound to support JsonRawValue