Home > Software design >  Update data in csv table which is stored in AWS S3 bucket
Update data in csv table which is stored in AWS S3 bucket

Time:03-12

I need a solution for entering new data in csv that is stored in S3 bucket in AWS.

At this point we are downloading the file, editing and then uploading it again in s3 and we would like to automatize this process.

We need to add one row in a three column.

Thank you in advance!

CodePudding user response:

I think you will be able to do that using Lambda Functions. You will need to programmatically make the modifications you need over the CSV but there are multiple programming languages that allow you to do that. One quick example is using python and the csv library

Then you can invoke that lambda or add more logic to the operations you want to do using an AWS API Gateway.

You can access the CSV file (object) inside the S3 Bucket from the lambda code using the AWS SDK and append the new rows with data you pass as parameters to the function

CodePudding user response:

There is no way to directly modify the csv stored in S3 (if that is what you're asking). The process will always entail some version of download, modify, upload. There are many examples of how you can do this, for example here

  • Related