Created
June 1, 2018 12:53
-
-
Save notionquest/ca4ed8bd638bdbad5d7432f4b04f8a12 to your computer and use it in GitHub Desktop.
dynamodb scan table local in shell
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var dynamodb = new AWS.DynamoDB({ | |
region: 'us-east-1', | |
endpoint: "http://localhost:8000" | |
}); | |
var params = { | |
TableName: "Movies", | |
}; | |
function doPrint(response) { | |
if (response.error) ppJson(response.error); // an error occurred | |
else { | |
ppJson(response.data); // successful response | |
} | |
} | |
console.log("List of tables"); | |
dynamodb.scan(params) | |
.on('complete', doPrint) | |
.send(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment