Custom date/time type conversion #3067
Unanswered
lmaotrigine
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I'm the author of a (currently private) datetime library, and I would like to provide
Typeimplementations for each database. The public API ofsqlxdoesn't export enough for me to implement this (column flags and charset for MySQL for example, or PgType constants).since this is still very early stages and I foresee understandable skepticism from my own users given that there already exist well-established crates for handling these, i want to maintain these implementations myself instead of requesting the maintainers to add another feature. Is there a good way to do this?
so far, I've only had success with Postgres, because of
PgType::with_namemagically working; butMySqlTypedoesn't provide any public constructors; so I don't see a way to implementType<MySql>for my own types. Similar woes with SQLite. Is there something I'm missing?Beta Was this translation helpful? Give feedback.
All reactions