-
Notifications
You must be signed in to change notification settings - Fork 130
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
Add JSON type compiler support #1130
base: main
Are you sure you want to change the base?
Conversation
55464ec
to
26ab924
Compare
Would it be possible for you to provide an example output based on having this new code? i.e. being able to write sqlalchemy-based Python code with this new capability would allow us to generate SQL that looks like what? A simple example would suffice so that I can quickly picture what we are trying to achieve that isn't currently possible? I am in the middle of a couple of hot tasks, so I won't be able to come back to this for a day or two, but I am interested in getting this pushed through. |
Here's an example. I created a
I created a simple sqlalchemy engine and inspector. Then I got columns using
Ideally it should be Also, if we try to use
This is required as we might need to store column type as a string. Thanks. |
Thank you very much for your interest in this project and for your suggested change. Before we can approve and merge this PR, we will need to add tests. Is that something you are comfortable doing? If not that is fine, we have several options. If you want to add the tests but are not sure what that entails, we can provide guidance along the way. If you really don't feel comfortable, then let us know and we can put this into our backlog of tasks. |
This is failing this test:
|
Fixes #399 🦕
This commit handles JSON as column type. Currently it throws error for that and we can't use str() method on that column like column.type.