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

the trait sqlx::Decode<'_, sqlx::Any> is not implemented for u64 #2144

Closed
victorteokw opened this issue Oct 11, 2022 · 2 comments
Closed

the trait sqlx::Decode<'_, sqlx::Any> is not implemented for u64 #2144

victorteokw opened this issue Oct 11, 2022 · 2 comments
Labels

Comments

@victorteokw
Copy link

Hi,

Thanks for this great library. 👍

Bug Description

The error message prevents compiling which is:

the trait `sqlx::Decode<'_, sqlx::Any>` is not implemented for `u64`

Info

  • SQLx version: 0.6.2
  • SQLx features enabled: ["sqlx/mysql", "sqlx/any", "sqlx/chrono", "sqlx/runtime-tokio-native-tls"]
  • Database server and version: MySQL 8.0.28
  • Operating system: macOS 13.0
  • rustc --version: 1.64.0
@abonander
Copy link
Collaborator

Not a bug. Most SQL databases either don't support unsigned integers, or require an extension.

@abonander abonander closed this as not planned Won't fix, can't repro, duplicate, stale Oct 11, 2022
@victorteokw
Copy link
Author

Thanks @abonander,

I just searched the google and understand that PostgreSQL and SQLite don't support unsigned integers.

But in my MySQL database, these columns are defined as UNSIGNED BIGINT or UNSIGNED TINYINT, how can I decode it with sqlx?

Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants