1.0.1 • Published 4 years ago

@gorillastack/dynamodb-csv-export-import v1.0.1

Weekly downloads
-
License
Apache-2.0
Repository
github
Last release
4 years ago

dynamodb-csv-export-import

A utility to import CSV files generated by the AWS DynamoDB Console Export to csv feature into a DynamoDB table.

Usage

# Set the region to use
export AWS_DEFAULT_REGION=us-east-1

# Run without installing globally
npx @gorillastack/dynamodb-csv-export-import my-exported-file.csv MySlackTable

# OR

# Install globally

npm i -g @gorillastack/dynamodb-csv-export-import

export AWS_DEFAULT_REGION=us-east-1

dynamodb-csv-export-import my-exported-file.csv MySlackTable

The following environment variables affect its runtime:

  • DYNAMODB_ENDPOINT_URL - change the DynamoDB endpoint (useful when running dynamodb-local)
  • AWS_DEFAULT_REGION - set the region it connects to (defaults to us-east-1)

Limitations

This utility was created specifically to deal with the CSV files generated by the AWS Console which have a particular export format (column names and type in the first row, mixed JSON / values in each record).

It does not have the ability to export from DynamoDB to CSV or import from arbitrary CSV files to DynamoDB.