Questions tagged [csvtojson]

101 questions
4
votes
3 answers

How to upload a CSV file in FastAPI and convert it into JSON?

I am trying to upload my .csv file to my FastAPI server, then convert it into JSON and return it to the client. However, when I try to process it directly (without storing it somewhere), I get this error: Error : FileNotFoundError: [Error 2] No such…
sourabh
  • 41
  • 1
  • 1
  • 3
4
votes
4 answers

How to convert csv file data to json object in reactjs?

I want to get csv file from input tag and convert data of csv file into json object. Is there any plugin in react js or any custom code ?
3
votes
0 answers

Python panda (dataframe) .to_jason escaping forward slash

I'm trying to print out a dataframe in json format. it's pretty cool so far because I can import a directory load of CSV files into a large dataframe, filter for the different criteria and create json outputs with select output from different…
elcuartomago
  • 31
  • 1
  • 5
3
votes
3 answers

How to parse CSVs from s3 bucket to use in a javascript AWS Lambda function

I'm trying to read in a CSV from an s3 bucket using the csvtojson library in AWS Lambda, but it's not working properly. Locally, my code works. But when I upload it to Lambda, it doesn't return anything. There are no errors in the Lambda console, so…
2
votes
0 answers

Puppeteer React/NodeJS form submissions automation with a database

So I'm trying to test a recaptcha implementation by writing my own spambot using React and Puppeteer. I got the script ready to do a single form submission after executing the script, but what I'm actually hoping for is to have my script loop…
2
votes
2 answers

Azure Logic App calculate Total Sum of a column from a CSV file

I'm using an Azure Logic App to get the blob contents from my storage account. The Blob-file is in .CSV file. The CSV file consists of a few columns and multiple rows. The file is basically an Invoice file which consists of a column named…
SD4
  • 439
  • 10
  • 27
2
votes
1 answer

Creating a nested key/value pair in R from data frame

I'm attempting to convert a csv into JSON format for the first time. When the csv is read into R, it's in the following data frame format: col1 col2 col3 1 a def1 1 b def2 2 c def3 2 a def1 Ideally,…
2
votes
1 answer

Convert CSV to a nested JSON while formatting values for specific keys to numeric/int/float

I am trying to convert a CSV file to nested JSON, here's my CSV with first row as columns. CLID,District, attribute,value C001,Tebuslik, Name,Philip C001,Tebuslik,Age,34 C002,Hontenlo,Name,Jane C002,Hontenlo,Age,23 My desired output is a nested…
Aleu
  • 73
  • 6
1
vote
1 answer

How to remove a entire record conditionally using npm "csv" or "csvtojson" package?

I wanted to store CSV values to an object variable using npm "csv" sync API by parsing it. // Read the CSV file synchronously const csvData = fs.readFileSync(csvFilePath, "utf-8"); // Parse the CSV data synchronously const parsedData =…
vishnu p s
  • 51
  • 6
1
vote
1 answer

Converting CSV files Into JSON while Changing the Key Names in Javascript?

I have 2 CSV files and I want to grab specific data (while ignoring some columns) from the CSVs and turn them into a JSON format with nested arrays and specific key names. I also want to order the JSON by a specific value (orderID). Here's an…
1
vote
1 answer

Convert CSV to nested JSON objects with NodeJS

I am trying to convert a csv text file into a JSON object with a specific structure. I have been using the csvtojson nodejs module and I have it really close, I just need some help with the fine tuning. This is what my input file looks…
matthh
  • 47
  • 4
1
vote
3 answers

convert a CSV file to JSON file

I am trying to convert CSV file to JSON file based on a column value. The csv file looks somewhat like this. ID Name Age CSE001 John 18 CSE002 Marie 20 ECE001 Josh 22 ECE002 Peter …
QWERTY
  • 11
  • 2
1
vote
1 answer

Convert a data frame in which one column contains array of numbers as string to a json file

I'd like to convert a data frame into a json file. One of the columns of the data frame contains time series as a string. Thus, the final json looks like this: [{"...":"...","Dauer":"24h","Wertereihe":"8619.0,9130.0,8302.0,8140.0"}, {...}, {...}] Is…
SkogensKonung
  • 601
  • 1
  • 9
  • 22
1
vote
1 answer

How to convert a CSV into a nested JSON using Python

So i have read alot of previous questions about this topic but non were really able to help me get to the result I want so here's the CSV file…
1
vote
1 answer

Convert a CSV file to multiple small JSON files in lambda through streams

I am trying to write a lambda function that can convert stream a huge csv file to multiple small json files (say a json file for 2000 rows) from and to a s3 bucket. I though have some restrictions like running in a limited RAM memory of 256 MB. I am…
devil-0-per
  • 173
  • 3
  • 14
1
2 3 4 5 6 7