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

bug(expr): format of float of Jsonb #13224

Open
KeXiangWang opened this issue Nov 2, 2023 · 2 comments
Open

bug(expr): format of float of Jsonb #13224

KeXiangWang opened this issue Nov 2, 2023 · 2 comments
Assignees
Labels
no-issue-activity type/bug Something isn't working
Milestone

Comments

@KeXiangWang
Copy link
Contributor

KeXiangWang commented Nov 2, 2023

Describe the bug

Currenly, we print a float keeping at least one digit after the decimal point.

One example of to_jsonb:

select to_jsonb(1.0000::float);

# PG:
 to_jsonb
----------
 1

# RW:
 to_jsonb 
----------
 1.0

We need to fix the formating function of the float of Jsonb. It may require some modification in the jsonbb repo.

@KeXiangWang KeXiangWang added the type/bug Something isn't working label Nov 2, 2023
@github-actions github-actions bot added this to the release-1.5 milestone Nov 2, 2023
@KeXiangWang
Copy link
Contributor Author

After a quick investigation here's reason:
Our dependency chain on this is: risingwave -> jsonbb -> serde_json -> ryn.
Here's the line of the code adding the ".0". Based on the developer's answer, it's intentional.

As jsonbb is under control, so to solve this problem, we can either fork serde_json and ryn and modify the corresponding codes or switch to another repo providing similar json serialization function. As currently this misalignment has not become a big problem, let's table this issue temporarily.

@fuyufjh fuyufjh removed this from the release-1.5 milestone Dec 6, 2023
@KeXiangWang KeXiangWang added this to the release-1.9 milestone Apr 8, 2024
Copy link
Contributor

github-actions bot commented Aug 1, 2024

This issue has been open for 60 days with no activity.

If you think it is still relevant today, and needs to be done in the near future, you can comment to update the status, or just manually remove the no-issue-activity label.

You can also confidently close this issue as not planned to keep our backlog clean.
Don't worry if you think the issue is still valuable to continue in the future.
It's searchable and can be reopened when it's time. 😄

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
no-issue-activity type/bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants