问题描述
我正在使用 dynamodb Local。我正在尝试为一个人分配两个地址,但出现“重复密钥”错误。 我想为一个人添加更多国家/地区和更多地址。但是每当我尝试为该人添加另一个国家/地区和地址时,它都会出现重复密钥错误
有人可以帮我吗?帮助表示赞赏。 The image of my localhost code
{
"AttributeDeFinitions": [
{
"AttributeName": "AddressID","AttributeType": "S"
},{
"AttributeName": "CustomerID",{
"AttributeName": "Country","AttributeType": "S"
}
],"TableName": "Addresses","KeySchema": [
{
"AttributeName": "AddressID","KeyType": "HASH"
},"KeyType": "RANGE"
}
],"TableStatus": "ACTIVE","CreationDateTime": "2021-04-06T09:06:29.622Z","ProvisionedThroughput": {
"LastIncreaseDateTime": "1970-01-01T00:00:00.000Z","LastDecreaseDateTime": "1970-01-01T00:00:00.000Z","NumberOfDecreasesToday": 0,"ReadCapacityUnits": 5,"WriteCapacityUnits": 5
},"TableSizeBytes": 732,"ItemCount": 6,"TableArn": "arn:aws:dynamodb:ddblocal:000000000000:table/Addresses","GlobalSecondaryIndexes": [
{
"IndexName": "UserIndex","KeySchema": [
{
"AttributeName": "AddressID","KeyType": "HASH"
},{
"AttributeName": "Country","KeyType": "RANGE"
}
],"Projection": {
"ProjectionType": "ALL"
},"IndexStatus": "ACTIVE","ProvisionedThroughput": {
"ReadCapacityUnits": 5,"WriteCapacityUnits": 5
},"IndexSizeBytes": 732,"IndexArn": "arn:aws:dynamodb:ddblocal:000000000000:table/Addresses/index/UserIndex"
}
]
}
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)