Attribute Value

On This Page

Description

A JSON object that represents the value of a NoSQL item attribute:

Syntax

{"<attribute data type>": "<attribute data value>"}
Elements
<attribute data type>

The name of the Attribute Value object, which signifies the type of the attribute's data value.

  • Type: String

The following attribute-value names (attribute data-type strings) are supported. See the Attribute Data Types Reference for documentation of the related attribute data types.

<attribute data value>

The attribute's data value ("attribute value"). This value must match the data type signified by the Attribute Value object name (<attribute data type>).

  • Type: String

Examples

Define a string attribute value. The name of the attribute-value object is "S", which signifies that the type of the attribute data is a string, and the value of the object (the attribute's data value) is "johnd":

{"S": "johnd"}

Define a numeric attribute value. The name of the attribute-value object is "N", which signifies that the type of the attribute data is a number, and the value of the object (the attribute's data value) is "34"; note the numeric data value is represented as a string:

{"N": "34"}

Define a Boolean attribute value. The name of the attribute-value object is "BOOL", which signifies that the type of the attribute data is Boolean, and the value of the object (the attribute's data value) is false:

{"BOOL": false}

Define a blob attribute value. The name of the attribute-value object is "B", which signifies that the type of the attribute data is a blob, and the value of the object (the attribute's data value) is "iguazio:$apr1$YgrCYAYo$6v6iumigwirH4Jsdt4MWr0"; note the blob data value is represented as a string:

{"B": "iguazio:$apr1$YgrCYAYo$6v6iumigwirH4Jsdt4MWr0"}

See Also