aws / graph-notebook

Library extending Jupyter notebooks to integrate with Apache TinkerPop, openCypher, and RDF SPARQL.
https://github.com/aws/graph-notebook
Apache License 2.0
726 stars 166 forks source link

[BUG] Null value results in conversion of column of integers to float #678

Closed michaelnchin closed 1 month ago

michaelnchin commented 1 month ago

Community Note

Describe the bug

When a query returns a result entry that is either missing or contains null value for a property that would would otherwise be of integer type, all other values in the integer column created in the result table will be displayed as floats instead.

Example query:

Screenshot 2024-08-15 at 5 25 45 PM

Raw result:

{
  "results": [
    {
      "n.iucnCategory": "CR",
      "size(n.iucnCategory)": 2
    },
    {
      "n.iucnCategory": "EN",
      "size(n.iucnCategory)": 2
    },
    {
      "n.iucnCategory": "LC",
      "size(n.iucnCategory)": 2
    },
    {
      "n.iucnCategory": "NT",
      "size(n.iucnCategory)": 2
    },
    {
      "n.iucnCategory": "VU",
      "size(n.iucnCategory)": 2
    },
    {
      "n.iucnCategory": "DD",
      "size(n.iucnCategory)": 2
    },
    {
      "n.iucnCategory": null,
      "size(n.iucnCategory)": null
    }
  ]
}