Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- var AWS = require("aws-sdk");
- var dynamoDB = new AWS.DynamoDB.DocumentClient();
- let params = {
- RequestItems: {
- "db-test": [
- {
- PutRequest: {
- Item: {
- R_TIMESTAMP: 'STRING_VALUE1' ,
- R_ID: 'STRING_VALUE1'
- }
- }
- },
- {
- PutRequest: {
- Item: {
- R_TIMESTAMP: 'STRING_VALUE2' ,
- R_ID: 'STRING_VALUE2'
- }
- }
- }
- ]
- }
- };
- dynamoDB.batchWrite(params, function(err, data) {
- if (err) {
- console.log("Error", err);
- } else {
- console.log("Success", data);
- }
- })
- Error { ValidationException: The provided key element does not match the schema
- at Request.extractError (/var/runtime/node_modules/aws-sdk/lib/protocol/json.js:51:27)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement