An open API service indexing awesome lists of open source software.

https://github.com/onramper/server-db-scan-util

DynamoDB Scan and CSV Export Utility
https://github.com/onramper/server-db-scan-util

aws csv dynamodb export scan tool utility

Last synced: 8 months ago
JSON representation

DynamoDB Scan and CSV Export Utility

Awesome Lists containing this project

README

          




DynamoDB Scan and CSV Export Utility




A simple utility that allows for synchronous filtered scans on DynamoDB



Introduction
Purpose
Instructions
Troubleshooting
License

## Introduction
A simple utility that allows for synchronous filtered scans of DynamoDB tables. The scan parameters can be configured (in `index.ts`) to filter the results as desired.

## Purpose
There are scenarios in which you'd like to export a filtered set of records from DynamoDB. There can be use cases in which your DynamoDB schema doesn't support direct querying of the desired records (because the full PK is unknown), thus either a GSI has to be added or a scan should be performed. The AWS web console allows these scans to be performed but doesn't allow for easy exporting of a large number of records. This utility aims to fill this gap.

## Instructions
1. `yarn install` to install the dependencies. (Use Node v16)
2. Adjust the configuration in `index.ts` as you see fit.
3. `yarn start` to retrieve the items from DynamoDB and to then save the items to a csv file in the `out` folder.

## Troubleshooting
* If you run into `SyntaxError: Unexpected reserved word` when running the utility, then make sure you have Node v16 set up, some versions of Node v14 can cause this error.

## License
This utility is licensed under the [MIT license](LICENSE.md).