I want to import many items to DynamoDB from a ion file, there is an example of importing only one item in official document. But how to import many items at once ? I have tried:
$ion_1_0{
Item: [
{
pk:1d0,
sk:1d0,
c1: "sql",
},
{
pk:1d0,
sk:2d0,
c1: "mono",
}
]
}
$ion_1_0{
Item: {
pk:1d0,
sk:1d0,
c1: "sql",
},
Item: {
pk:1d0,
sk:2d0,
c1: "mono",
}
}
All failed.
The document give an multi-items example in json format, but it is even not a valid json.
And i don not want to use BatchWriteItem api, because it's much more expensive than import from S3.
Please give me a correct example of importing many items to DynamoDB from one ion/json file.
From AWS doc:-
Here is the working example:-
In case of import failure, you can always check in Cloudwatch logs for the exact error message.
Hope this helps.