我有一个要求,我的 dynamodb 表有很多属性,我需要在投影表达式中的所有属性,除了一两列我不需要响应。 (我正在扫描 table )。
有没有办法如何在 ProjectionExpression 中定义它(除了这一列之外的所有内容)。
我见过一些例子,其中 ProjectionExpression 只采用所有“必需的”而不是其他方式。
最佳答案
根据文档,这是不可能的:
ProjectionExpression - A string that identifies one or more attributes to retrieve from the table. These attributes can include scalars, sets, or elements of a JSON document. The attributes in the expression must be separated by commas. If no attribute names are specified, then all attributes will be returned.
这是一个链接,可帮助您更好地理解 ProjectionExpression 下的内容:https://medium.com/pageup-tech/dynamodb-and-projection-expressions-why-c08c40243195
关于amazon-web-services - DynamoDB ProjectionExpression 排除属性(除一个字段外的所有字段),我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/55473393/