Showing posts with label Export DynamoDB tables in csv. Show all posts
Showing posts with label Export DynamoDB tables in csv. Show all posts

Wednesday, March 4, 2020

Export DynamoDB as csv

You must have dynamodb with lots of data and you want o see this in excel file. Dynamodb is a concept without columns but still it can exported in csv. You may have number of tables in dynamodb. Here is a way to export it.
1. Clone following repo from github.
git clone https://github.com/edasque/DynamoDBtoCSV.git
2. Install node based dependencies.
npm install
3. Fill the access key, secret key and region in the file DynamoDBtoCSV/config.json
{
    "accessKeyId": "QWERTNVEXAMPLEMUJMKI",
    "secretAccessKey": "+WSXCD/SdEfExAmPlEJkjKL/KlOiK45Iu",
    "region": "us-east-1"
}
4. Now export tables using following commands.
node dynamoDBtoCSV.js -t tableOne > tableOne.csv
node dynamoDBtoCSV.js -t tableTwo > tableTwo.csv