crystal-pg
crystal-pg copied to clipboard
Add to_json method
Please add a to_json method to resultset/Query result object to provide automatic json conversion.
A db can hold more values than then json format can represent. And there are not always a clear winner on how to encode it.
Meanwhile https://manas.tech/blog/2017/01/16/from-a-db-to-json-with-crystal.html might offer some alternatives to handle within the scope of the app you are working on.
Please check this project https://github.com/akwiatkowski/crystal_api for Postgresql type conversion.