matrixone icon indicating copy to clipboard operation
matrixone copied to clipboard

[Feature Request]: json_extract_string and json_extract_float64

Open fengttt opened this issue 1 year ago • 3 comments

Is there an existing issue for the same feature request?

  • [X] I have checked the existing issues.

Is your feature request related to a problem?

json_extract returns json type.  For comparing with sql value, we need to cast 
data to json.  A much better (both semantically clearer and more efficient) way 
to handle value is just extract them.

Describe the feature you'd like

Adding two functions (maybe 3), json_extract_string -- same as json_extract, but with exactly one path. return string value, or null if json_extract of the path is not a string node. json_extract_float64 -- return float64 or null if node is not a number json_extract_int64 -- maybe this one

Describe implementation you've considered

No response

Documentation, Adoption, Use Case, Migration Strategy

No response

Additional information

No response

fengttt avatar Aug 05 '24 15:08 fengttt

@aronchanisme 麻烦测试一下

YANGGMM avatar Aug 20 '24 07:08 YANGGMM

already tested in another thread: https://github.com/matrixorigin/MO-Cloud/issues/3779

aronchanisme avatar Oct 23 '24 09:10 aronchanisme

forward to product team

aronchanisme avatar Oct 23 '24 10:10 aronchanisme

TEST DONE

aressu1985 avatar Nov 04 '24 07:11 aressu1985