1. <legend id='5FFv2'><style id='5FFv2'><dir id='5FFv2'><q id='5FFv2'></q></dir></style></legend>
        <bdo id='5FFv2'></bdo><ul id='5FFv2'></ul>

      <small id='5FFv2'></small><noframes id='5FFv2'>

      <i id='5FFv2'><tr id='5FFv2'><dt id='5FFv2'><q id='5FFv2'><span id='5FFv2'><b id='5FFv2'><form id='5FFv2'><ins id='5FFv2'></ins><ul id='5FFv2'></ul><sub id='5FFv2'></sub></form><legend id='5FFv2'></legend><bdo id='5FFv2'><pre id='5FFv2'><center id='5FFv2'></center></pre></bdo></b><th id='5FFv2'></th></span></q></dt></tr></i><div id='5FFv2'><tfoot id='5FFv2'></tfoot><dl id='5FFv2'><fieldset id='5FFv2'></fieldset></dl></div>
      <tfoot id='5FFv2'></tfoot>

    2. 如何将新的键值对放入 DynamoDB 中的映射中?(爪哇)

      How to put a new key-value pair into a map in DynamoDB? (java)(如何将新的键值对放入 DynamoDB 中的映射中?(爪哇))
        <bdo id='wUi9B'></bdo><ul id='wUi9B'></ul>
          <tbody id='wUi9B'></tbody>

      • <tfoot id='wUi9B'></tfoot>
          <legend id='wUi9B'><style id='wUi9B'><dir id='wUi9B'><q id='wUi9B'></q></dir></style></legend>
          <i id='wUi9B'><tr id='wUi9B'><dt id='wUi9B'><q id='wUi9B'><span id='wUi9B'><b id='wUi9B'><form id='wUi9B'><ins id='wUi9B'></ins><ul id='wUi9B'></ul><sub id='wUi9B'></sub></form><legend id='wUi9B'></legend><bdo id='wUi9B'><pre id='wUi9B'><center id='wUi9B'></center></pre></bdo></b><th id='wUi9B'></th></span></q></dt></tr></i><div id='wUi9B'><tfoot id='wUi9B'></tfoot><dl id='wUi9B'><fieldset id='wUi9B'></fieldset></dl></div>
          1. <small id='wUi9B'></small><noframes id='wUi9B'>

              • 本文介绍了如何将新的键值对放入 DynamoDB 中的映射中?(爪哇)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                问题描述

                我有一个 DynamoDB 属性,其值是从数字到字符串的映射.我正在尝试放入一个新的键值对.根据我的阅读,这似乎是可能的,但我不知道如何.

                I have a DynamoDB attribute whose value is a map from a Number to a String. I am trying to put in a new key-value pair. From what I've read, this seems to be possible, but I don't know how.

                我认为解决方案类似于以下链接中的解决方案:

                I assume the solution is similar to the one in the link below:

                如何在 AWS DynamoDB 文档 API 上更新地图或列表?

                但我不相信这个例子是在地图上添加一个新项目.有人可以告诉我如何将项目放入地图吗?

                But I do not believe the example is on putting in a new item to a map. Could someone show me how to put in an item to a map?

                谢谢.

                我不想获取该项目,在本地进行更改,然后将其放回原处.我正在与可能同时交互的多个客户合作(我假设 dynamo 的更新确保不会出现竞争条件).

                I do not want to get the item, locally make the changes, and put it back. I am working with multiple clients who might interact concurrently (and I assume the update by dynamo ensures there will be no race conditions).

                推荐答案

                使用 UpdateItem 的以下参数,当 map.#number 在地图中不存在时,您可以在 #number 处添加地图条目:

                With the following arguments to UpdateItem, you can condition adding a map entry at #number when map.#number does not exist in the map already:

                UpdateExpression = "SET map.#number = :string"
                ExpressionAttributeNames = { "#number" : "1" }
                ExpressionAttributeValues = { ":string" : "the string to store in the map at key value 1" }
                ConditionExpression = "attribute_not_exists(map.#number)"
                

                这篇关于如何将新的键值对放入 DynamoDB 中的映射中?(爪哇)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

                本站部分内容来源互联网,如果有图片或者内容侵犯了您的权益,请联系我们,我们会在确认后第一时间进行删除!

                相关文档推荐

                Lucene Porter Stemmer not public(Lucene Porter Stemmer 未公开)
                How to index pdf, ppt, xl files in lucene (java based or python or php any of these is fine)?(如何在 lucene 中索引 pdf、ppt、xl 文件(基于 java 或 python 或 php 中的任何一个都可以)?)
                KeywordAnalyzer and LowerCaseFilter/LowerCaseTokenizer(KeywordAnalyzer 和 LowerCaseFilter/LowerCaseTokenizer)
                How to search between dates (Hibernate Search)?(如何在日期之间搜索(休眠搜索)?)
                How to get positions from a document term vector in Lucene?(如何从 Lucene 中的文档术语向量中获取位置?)
                Java Lucene 4.5 how to search by case insensitive(Java Lucene 4.5如何按不区分大小写进行搜索)

                  1. <tfoot id='AdOys'></tfoot>
                    • <small id='AdOys'></small><noframes id='AdOys'>

                        <tbody id='AdOys'></tbody>
                      <legend id='AdOys'><style id='AdOys'><dir id='AdOys'><q id='AdOys'></q></dir></style></legend>
                      <i id='AdOys'><tr id='AdOys'><dt id='AdOys'><q id='AdOys'><span id='AdOys'><b id='AdOys'><form id='AdOys'><ins id='AdOys'></ins><ul id='AdOys'></ul><sub id='AdOys'></sub></form><legend id='AdOys'></legend><bdo id='AdOys'><pre id='AdOys'><center id='AdOys'></center></pre></bdo></b><th id='AdOys'></th></span></q></dt></tr></i><div id='AdOys'><tfoot id='AdOys'></tfoot><dl id='AdOys'><fieldset id='AdOys'></fieldset></dl></div>

                        • <bdo id='AdOys'></bdo><ul id='AdOys'></ul>