Assigned
Status Update
Comments
al...@gojek.com <al...@gojek.com> #2
Forgot to add screenshots.
va...@google.com <va...@google.com>
ku...@google.com <ku...@google.com> #3
Hello,
Thank you for reaching out to us with your request.
We have duly noted your feedback and will thoroughly validate it. While we cannot provide an estimated time of implementation or guarantee the fulfillment of the issue, please be assured that your input is highly valued. Your feedback enables us to enhance our products and services.
We appreciate your continued trust and support in improving our Google Cloud Platform products. In case you want to report a new issue, please do not hesitate to create a new issue on the
Once again, we sincerely appreciate your valuable feedback; Thank you for your understanding and collaboration.
Description
This will create a feature request which anybody can view and comment on.
Please describe your requested enhancement. Good feature requests will solve common problems or enable new use cases.
What you would like to accomplish
I would like to use InsertStruct and Apply with floating values and have the inserted values be those of modified floating values, instead of having the insertion fail with the floating insertion error. Can we allow this somewhere inside the methods?
Use case
inserting coordinates inside JSON values
Language where this is observed
Go
How this might work
Inside Spanner instance, have the option of having floating values inside JSON be converted without roundtripping it ( context ), allowing lossy conversion of floating values. We can use something from wide_number_mode=>'round' to skipping roundtrip inside Cloud Spanner itself.
Anything would work, as long as it's a lossy conversion and floating values are inserted to DB. If this conflicts with existing feature, we can make it as an optional parameter.
If applicable, reasons why alternative solutions are not sufficient:
So far I'm not seeing intuitive options to prevent this than to query
JSON_PARSE('json_number', wide_number_mode=>'round')
, which would result in adding a repository method that otherwise wouldn't be needed in e.g., PostgreSQL or MySQL.Other information (workarounds you have tried, documentation consulted, etc)