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] Large values (unsigned long type number) do not display correctly in OpenSearch Dashboards #7605

Open
seaneez opened this issue Aug 1, 2024 · 5 comments
Assignees
Labels
bug Something isn't working

Comments

@seaneez
Copy link

seaneez commented Aug 1, 2024

Describe the bug

Thank you for fixing [BUG] Large values do not display correctly in OpenSearch Dashboards #5485 .

However, the problem still occurs with even larger numbers.
We are currently using values that correspond to the unsigned long type, but precision errors still occur with such large numbers.

Could you please fix the bug so that unsigned long type numbers are also displayed accurately?

@seaneez seaneez added bug Something isn't working untriaged labels Aug 1, 2024
@kavilla
Copy link
Member

kavilla commented Aug 6, 2024

@AMoo-Miki do you have some feed back here?

@AMoo-Miki
Copy link
Collaborator

@seaneez can you please give me an example of one such long number with the area that is not showing it correctly? Long numerals support is currently only available on Discover and Dev Tools AFAIK. A screenshot with what you expect to see would help me understand the problem better.

@seaneez
Copy link
Author

seaneez commented Aug 19, 2024

@AMoo-Miki

Sure. Here is the image. This issue occurred in Discover. The "requestId" is not showing correctly.

opensearch_inaccurate_ulong_num

@AMoo-Miki
Copy link
Collaborator

AMoo-Miki commented Oct 16, 2024

Based on the screenshot fields.requestId is not a numeric value. The t beside fields.requestId indicates that the index mapping has its type as text. Lack of numeric formatting reconfirms that since the index pattern doesn't have it as a number.

If the actual value saved with the document was a numeric 1815920796384625582, I would expect to see that as the unformatted 1815920796384625582 (being a text field). I suspect the incorrect value is saved in the field.

You can confirm this by going to the DevTools console of your OSD and running this:

GET <YOUR INDEX NAME>/_search
{
  "query": {
    "wildcard": {
      "message": {
        "value": "*1815920796384625582*"
      }
    }
  },
  "_source": "fields.requestId"
}

If your result looks like this, it confirms that the data is stored as text and has the incorrect value:

{
  ...
  "hits": {
    ...
    "hits": [
      {
        ...
        "_source": {
          "fields": {
            "requestId": "1815920796384625700"
          }
        }
      }
    ]
  }
}

Notice the quotes around the value. If it is saved as a number, the quotes will be missing. What I am hoping to confirm is that you see it ending with 5700.

Also, what version of OSD are you using?

@seaneez
Copy link
Author

seaneez commented Oct 17, 2024

I remember that the number was displayed correctly in the DevTools. (1815920796384625582)
We are now using OpenSearch Dashboards v 2.11.0.

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

No branches or pull requests

3 participants