class Aws::DynamoDB::Types::DeleteItemInput
@see docs.aws.amazon.com/goto/WebAPI/dynamodb-2012-08-10/DeleteItemInput AWS API Documentation
@return [Hash<String,Types::AttributeValue>]<br>: docs.aws.amazon.com/amazondynamodb/latest/developerguide/Expressions.SpecifyingConditions.html<br><br><br><br>Expressions][1] in the *Amazon DynamoDB Developer Guide*.
For more information on expression attribute values, see [Condition
`ProductStatus IN (:avail, :back, :disc)‘
You could then use these values in an expression, such as this:
“:disc”:{“S”:“Discontinued”} }`
`{ “:avail”:{“S”:“Available”}, “:back”:{“S”:“Backordered”},
follows:
You would first need to specify `ExpressionAttributeValues` as
`Available | Backordered | Discontinued`
following:
whether the value of the ProductStatus attribute was one of the
attribute value. For example, suppose that you wanted to check
Use the : (colon) character in an expression to dereference an
One or more values that can be substituted in an expression.
@!attribute [rw] expression_attribute_values
@return [Hash<String,String>]<br>: docs.aws.amazon.com/amazondynamodb/latest/developerguide/Expressions.AccessingItemAttributes.html<br>[1]: docs.aws.amazon.com/amazondynamodb/latest/developerguide/ReservedWords.html<br><br><br><br>Item Attributes] in the *Amazon DynamoDB Developer Guide*.
For more information on expression attribute names, see [Specifying
</note>
runtime.
attribute values*, which are placeholders for the actual value at
<note markdown=“1”> Tokens that begin with the : character are *expression
^
* `#P = :val`
example:
You could then use this substitution in an expression, as in this
^
* `{“#P”:“Percentile”}`
following for `ExpressionAttributeNames`:
Developer Guide*). To work around this, you could specify the
reserved words, see [Reserved Words] in the *Amazon DynamoDB
cannot be used directly in an expression. (For the complete list of
The name of this attribute conflicts with a reserved word, so it
^
* `Percentile`
name. For example, consider the following attribute name:
Use the **#** character in an expression to dereference an attribute
misinterpreted in an expression.
* To prevent special characters in an attribute name from being
name in an expression.
* To create a placeholder for repeating occurrences of an attribute
reserved word.
* To access an attribute whose name conflicts with a DynamoDB
`ExpressionAttributeNames`:
expression. The following are some use cases for using
One or more substitution tokens for attribute names in an
@!attribute [rw] expression_attribute_names
@return [String]<br>: docs.aws.amazon.com/amazondynamodb/latest/developerguide/Expressions.SpecifyingConditions.html<br><br><br><br>Expressions][1] in the *Amazon DynamoDB Developer Guide*.
For more information about condition expressions, see [Condition
* Logical operators: `AND | OR | NOT`
* Comparison operators: `= | <> | < | > | <= | >= | BETWEEN | IN `
These function names are case-sensitive.
attribute_type | contains | begins_with | size`
* Functions: `attribute_exists | attribute_not_exists |
An expression can contain any of the following:
`DeleteItem` to succeed.
A condition that must be satisfied in order for a conditional
@!attribute [rw] condition_expression
@return [String]
returned.
response. If set to `NONE` (the default), no statistics are
any, that were modified during the operation are returned in the
`SIZE`, the response includes statistics about item collections, if
Determines whether item collection metrics are returned. If set to
@!attribute [rw] return_item_collection_metrics
@return [String]
response.
* `NONE` - No `ConsumedCapacity` details are included in the
`ConsumedCapacity` for the operation.
* `TOTAL` - The response includes only the aggregate
table(s).
`INDEXES` will only return `ConsumedCapacity` information for
do not access any indexes at all. In these cases, specifying
Note that some operations, such as `GetItem` and `BatchGetItem`,
and secondary index that was accessed.
for the operation, together with `ConsumedCapacity` for each table
* `INDEXES` - The response includes the aggregate `ConsumedCapacity`
throughput consumption that is returned in the response:
Determines the level of detail about either provisioned or on-demand
@!attribute [rw] return_consumed_capacity
@return [String]
</note>
`NONE` or `ALL_OLD`.
however, `DeleteItem` does not recognize any values other than
<note markdown=“1”> The `ReturnValues` parameter is used by several DynamoDB operations;
receiving a larger response. No read capacity units are consumed.
value aside from the small network and processing overhead of
There is no additional cost associated with requesting a return
* `ALL_OLD` - The content of the old item is returned.
`ReturnValues`.)
`NONE`, then nothing is returned. (This setting is the default for
* `NONE` - If `ReturnValues` is not specified, or if its value is
values are:
appeared before they were deleted. For `DeleteItem`, the valid
Use `ReturnValues` if you want to get the item attributes as they
@!attribute [rw] return_values
@return [String]<br>: docs.aws.amazon.com/amazondynamodb/latest/developerguide/LegacyConditionalParameters.ConditionalOperator.html<br><br><br><br>DynamoDB Developer Guide*.
more information, see [ConditionalOperator] in the *Amazon
This is a legacy parameter. Use `ConditionExpression` instead. For
@!attribute [rw] conditional_operator
@return [Hash<String,Types::ExpectedAttributeValue>]<br>: docs.aws.amazon.com/amazondynamodb/latest/developerguide/LegacyConditionalParameters.Expected.html<br><br><br><br>Developer Guide*.
more information, see [Expected] in the *Amazon DynamoDB
This is a legacy parameter. Use `ConditionExpression` instead. For
@!attribute [rw] expected
@return [Hash<String,Types::AttributeValue>]
values for both the partition key and the sort key.
for the partition key. For a composite primary key, you must provide
example, with a simple primary key, you only need to provide a value
For the primary key, you must provide all of the attributes. For
the primary key of the item to delete.
A map of attribute names to `AttributeValue` objects, representing
@!attribute [rw] key
@return [String]
The name of the table from which to delete the item.
@!attribute [rw] table_name
}
},
“ExpressionAttributeValueVariable” => “value”, # value <Hash,Array,String,Numeric,Boolean,IO,Set,nil>
expression_attribute_values: {
},
“ExpressionAttributeNameVariable” => “AttributeName”,
expression_attribute_names: {
condition_expression: “ConditionExpression”,
return_item_collection_metrics: “SIZE”, # accepts SIZE, NONE
return_consumed_capacity: “INDEXES”, # accepts INDEXES, TOTAL, NONE
return_values: “NONE”, # accepts NONE, ALL_OLD, UPDATED_OLD, ALL_NEW, UPDATED_NEW
conditional_operator: “AND”, # accepts AND, OR
},
},
attribute_value_list: [“value”], # value <Hash,Array,String,Numeric,Boolean,IO,Set,nil>
comparison_operator: “EQ”, # accepts EQ, NE, IN, LE, LT, GE, GT, BETWEEN, NOT_NULL, NULL, CONTAINS, NOT_CONTAINS, BEGINS_WITH
exists: false,
value: “value”, # value <Hash,Array,String,Numeric,Boolean,IO,Set,nil>
“AttributeName” => {
expected: {
},
“AttributeName” => “value”, # value <Hash,Array,String,Numeric,Boolean,IO,Set,nil>
key: { # required
table_name: “TableName”, # required
{
data as a hash:
@note When making an API call, you may pass DeleteItemInput
Represents the input of a `DeleteItem` operation.