Columns of type 'N' having value 0 does not appear in get_item, scan.

Bug #1424770 reported by Ajaya Agrawal
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
MagnetoDB
Incomplete
Undecided
Unassigned

Bug Description

There could be a similar bug in the calls which fetches data from MagnetoDB.

table_schema:
{
    "table_name": "email_data",
    "attribute_definitions": [
        {
            "attribute_name": "a",
            "attribute_type": "S"
        },
        {
            "attribute_name": "b",
            "attribute_type": "N"
        }

    ],
    "key_schema": [
        {
            "attribute_name": "a",
            "key_type": "HASH"
        },
        {
            "attribute_name": "b",
            "key_type": "RANGE"
        }
    ]

}

put_item:
{
    "item": {
        "a": {
            "S": "a"
        },
        "b": {
            "N": 0
        }
    }
}

get_item:
{
   "consistent_read": true,
   "key":
       {

           "a": {
               "S": "a"
            },
            "b": {
            "N": 0
            }
       }
}

result of get_item:
{
    "item": {
        "a": {
            "S": "a"
        }
    }
}
expected result:
{
    "item": {
        "a": {
            "S": "a"
        }
        "b": {
            "N": 0
        }
     }
}

Revision history for this message
Andrii Ostapenko (aostapenko) wrote :

Could you please add more details: expected and actual behavior

Changed in magnetodb:
status: New → Incomplete
Ajaya Agrawal (ajayaa)
description: updated
description: updated
Revision history for this message
Ajaya Agrawal (ajayaa) wrote :

This is also seen in scan request. The row is returned but the column having values 0 is not there at all. If you send a filter in scan on that column then the result is empty.

summary: - Columns of type 'N' having value 0 does not appear in get_item.
+ Columns of type 'N' having value 0 does not appear in get_item, scan.
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.