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

Allow to override field type #263

Open
efirs opened this issue Apr 13, 2023 · 0 comments
Open

Allow to override field type #263

efirs opened this issue Apr 13, 2023 · 0 comments
Labels
enhancement New feature or request

Comments

@efirs
Copy link
Collaborator

efirs commented Apr 13, 2023

For the structured fields with custom marshaler, it may be needed to override underlying JSON type the field marshals to.

For example:

Name sql.NullString `tigris:"string"`

This would instruct Tigris to treat Name as string in the schema and in the JSON.
It's responsibility of the user type to properly marshal and unmarshal into the JSON.

@efirs efirs added this to Tigris Apr 13, 2023
@efirs efirs added the enhancement New feature or request label Apr 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant