[FEATURE]: Async Custom Types
Describe what you want
I was looking for a way to amend my database results with some additional data. Specifically I am storing a key in a database column and a corresponding value in a different service. I'd like to read the corresponding value from the other service and replace the key with the value in the query result. Currently this has to be done explicitly on every query, for every resulting row, which has really awkward ergonomics, is tedious and error prone.
It would be cool if custom data types could support async fromDriver and maybe even toDriver functions that would get awaited by Drizzle before returning the resulting rows. That would allow for transparent implementation of custom data types to handle functionality like outlined above. E.g. a column containing a cache key could transparently convert the key into the cached value upon read.