Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Documentation Review #1

Closed
tyt2y3 opened this issue Jul 24, 2021 · 8 comments
Closed

Documentation Review #1

tyt2y3 opened this issue Jul 24, 2021 · 8 comments

Comments

@tyt2y3
Copy link
Member

tyt2y3 commented Jul 24, 2021

image

https://www.sea-ql.org/SeaORM/docs/write-test/sqlite

This example is not illustrative enough. We need some asserts.

And perhaps we can copy a more real example from our test suite, like 'create_order'

@billy1624
Copy link
Member

But our updated test suit is targeted to run on MySQL for now. Perhaps I will update the doc after the updates completed?

@tyt2y3
Copy link
Member Author

tyt2y3 commented Jul 27, 2021

There is not too much database specific code right?

@billy1624
Copy link
Member

billy1624 commented Jul 27, 2021

We use UUID & decimal in test suit. These two can map to column type in Sqlite?

@billy1624
Copy link
Member

billy1624 commented Jul 27, 2021

@billy1624
Copy link
Member

billy1624 commented Jul 27, 2021

The special attribute types we used in Model are supported by all three databases (MySQL, Postgres, Sqlite), except for rust_decimal::Decimal

  • uuid::Uuid
  • rust_decimal::Decimal (not supported by sqlx-sqlite)
  • chrono::NaiveDateTime

The supported rust types of each database in Sqlx

@tyt2y3
Copy link
Member Author

tyt2y3 commented Jul 27, 2021

Yes sure lets pick a small example

@tyt2y3
Copy link
Member Author

tyt2y3 commented Jul 30, 2021

https://www.sea-ql.org/SeaORM/docs/basic-crud/raw-sql-and-json
Add also examples for:

  1. the raw query_* API (on DbConn and using QueryResult
  2. the raw execute API
  3. some asserts for the JSON results

@billy1624
Copy link
Member

@tyt2y3 tyt2y3 closed this as completed Sep 20, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants