Skip to main content
Filter by
Sorted by
Tagged with
-1 votes
1 answer
150 views

Last 52 lines are not written in csv file using qt

I have one csv file in which 3 column and 866300 lines. I have try to write this data into other csv file. when i try to write it has write 866248 lines in file after that remaining 52 lines are not ...
coder's user avatar
  • 68
2 votes
1 answer
427 views

How to write a matrix into csv C++

I'm a new learner of C++. I want to get a CSV file like this: | S0001 | S0002 | S0003 | S0004 | ... 0 | 10.289461 | 17.012874 | | 1 | 11.491483 | 13.053712 | | 2 | 10....
Cyan's user avatar
  • 339
0 votes
1 answer
2k views

Using CSVWriter to write a string array - some with quotes and some without

I see some other questions about CSVWriter writing to files and quotes. But nothing as specific as my issue. I want to print something like: abc,def,ghi,"jkl",mno,pqr When I just write: ...
ssn's user avatar
  • 2,711
1 vote
2 answers
3k views

Python writing in a csv-file: io.UnsupportedOperation: not writable

I am trying to read a complete csv file, alter it at one point and write it back. This is my Code: def change_Content(AttributIndex: int, content: str, title: str): with open("Path.csv") as ...
Timuraschka's user avatar
-1 votes
2 answers
64 views

I wrote a program for finding password from hash, and i have some hashes, but it writes just the last row. what is the problem

from hashlib import sha256 import csv with open ('source.csv', 'r' ) as file: reader = csv.reader ( file ) dic = {} for hash in range ( 1000, 10000): hasher = sha256 ( b'%i' % ...
Hamid Nejad's user avatar
1 vote
1 answer
38 views

How to include a dropdown query into a HttpResponse view

I would like to convert to excel contents of a model after passing a filter from the dropdown selection . Here is the view. def ConvertToExcelView(request): response = HttpResponse(content_type='...
fakeMake's user avatar
  • 768
0 votes
1 answer
681 views

APK made by buildozer not making CSV file on android mobile

I made an APK with the help of KivyApp. APK generated successfully and my APK also runs on my mobile. The problem is that I didn't give any specific path for the CSV file, which stored the output ...
Mehul Desai's user avatar
0 votes
1 answer
38 views

Python column groupby and split

Hi I have the following data in a Python dataframe: input_string value Apple 5 Apple 6 Pear 2 Pear 4 Grape 5 Grape 7 I want the ...
CeeB's user avatar
  • 11
0 votes
0 answers
560 views

Append data frame to an existing csv files with different number of columns

How can i append data frame to an existing csv files in python? I am using the following code but this does not check if the columns are matching or not. new_dataframe.to_csv("my_file.csv") ...
user86907's user avatar
  • 837
-1 votes
1 answer
842 views

appending data frame to an existing csv files in python

I have several data frames to append to a csv files in python. I am using the following code to achieve that but not luck yet. import csv as writer import pandas as pd def append_list_as_row(...
user86907's user avatar
  • 837
0 votes
5 answers
2k views

Python : set delimiter as both comma and space ', '

I want to append my CSV file with a new row But the new row must be separated by a comma as well as space between them. I can only separate them with either comma or space. The current file is: data....
Aman Sharma's user avatar
1 vote
2 answers
297 views

Wait for promises to complete before pushing error array of objects to CSV

I am trying to import and delete large numbers of users from Okta while staying within rate limits, and logging any errors to excel. The code below seems to be working, but there is just the issue ...
Jake Durell's user avatar
-2 votes
2 answers
726 views

Reading, editing and writing data from a csv file

import csv with open( "example.csv" , "r") as csv_file: csv_reader = csv.reader(csv_file) with open("edited.csv", "w", newline='') as new_file: csv_writer = csv.writer(new_file) ...
contodore's user avatar
1 vote
1 answer
3k views

How to avoid repeating header when Writing to CSV in loop?

I want to save the values of different variables in a CSV file. But it prints another header every time. I don't want this, I am attaching my CSV file snapshot for your understanding. Output csv ...
Faheem-Ur-Rehman 2305-FETBSEEF's user avatar
0 votes
1 answer
131 views

Python csv data logging doesn't work in while loop

I have been trying to log the data received from the Arduino through USB port and the strange thing is that the code works on my mac just fine but on windows it won't write it. At the start I expected ...
helpme123's user avatar
0 votes
1 answer
2k views

Writing to multiple CSV files from a for-loop

I have a for loop which get the ticker symbol and another for loop inside which gets stock data. Now i am trying to create csv files which will take the data of stock name from the first for loop and ...
Slartibartfast's user avatar
2 votes
2 answers
8k views

How to write, update, and save a CSV in AWS S3 using AWS Lambda

I am in the process of automating an AWS Textract flow where files gets uploaded to S3 using an app (that I have already done), a lambda function gets triggered, extracts the forms as a CSV, and saves ...
Greation's user avatar
2 votes
2 answers
5k views

How to write outputs of spark streaming application to a single file

I'm reading data from Kafka using spark streaming and passing to py file for prediction. It returns predictions as well as the original data. It's saving the original data with its predictions to file ...
Prayas Pagade's user avatar
1 vote
1 answer
529 views

String buffer fails to write data to database table

I am porting a mongo database over to a PostgreSQL one and I came across with an issue. I am using psycopg2's COPY_FROM, which takes as arguments a file object, the table to write to and other ...
GRoutar's user avatar
  • 1,415
0 votes
3 answers
895 views

How to Convert List<String[]> to Comma Separated String without " " in Java

I'm trying to remove fist line from the CSV file after reading it. Code is working properly but it's adding "" to my data when it's rewriting. for an example: before write to csv file: 100,COMRADE,...
SanjX's user avatar
  • 1,107
12 votes
3 answers
56k views

How to Export CSV file from ASP.NET core

I am trying to migrate code from ASP.net to ASP.net core. Where as in ASP.net code was like below, var progresses = db.Progresses.Where(p => p.UserId == id).Include(p => p.User.UserMetaData)....
Rohit Borude's user avatar
0 votes
1 answer
564 views

how to add header to existing csv files using python without rewrite all the existing content

I am trying to add a header to my existing csv file and there are already content in it. I am just wondering if there is any piece of code that could insert a header row at the top (such as ['name','...
Liang Hu's user avatar
0 votes
1 answer
1k views

Export csv file with CsvWriter and merge rows in C#

The default csv export from c# like: RoomName | EquipmentName | EquipmentCode Room1 - Television - E01 Room1 - Microwave - E02 Room2 - Television - E01 Now how can I export csv file. How can I do ...
Nguyen Quan's user avatar
0 votes
0 answers
2k views

Continuously writing terminal output to CSV file from python

I am trying to write the output to my python program onto a csv file. I print these outputs on the terminal as well for me to see, however the csv file only saves the most recent output. Here is my ...
Veejay's user avatar
  • 565
3 votes
0 answers
1k views

zip HUGE csv files in c#

I am working in .Net 4.7.2. We have List of objects say MyObject which is to be converted to csv single file. Currently using below code i use to create HUGE csv file ( 10GB and onwards). using (var ...
knowdotnet's user avatar
1 vote
2 answers
43 views

Convert a dictionary of lists to two-column csv

I have a dictionary of lists as follows: {'banana': [1,2], 'monkey': [5], 'cow': [1,5,0], ...} I want to write a csv that contains one number and word as follows: 1 | banana 2 | banana 5 | ...
quinn's user avatar
  • 31
1 vote
1 answer
2k views

Generate CSV from Java object and move to Azure Storage without intermediate location

Is it possible to create a file like CSV from Java object and move them to Azure Storage without using temporary location?
Vinay Limbare's user avatar
-1 votes
2 answers
86 views

How to write headers to a csv file?

I've wrote this code to write headers to a csv file: with open(os.path.join(directory, 'UserPass.csv'), 'wb') as csvFile: writer = csv.DictWriter(csvFile, fieldnames = ['Username', 'Password']...
Siddharth Chaudhary's user avatar
-1 votes
1 answer
3k views

How to get csvHelper to write csv as text

I have the following code using (StreamWriter streamwriter = new StreamWriter(savetopath)) { using (CsvWriter csv = new CsvWriter(streamwriter)) { List<string> columns = new ...
user avatar
1 vote
1 answer
1k views

Node.js - write CSV file creates empty file in production, while OK in Mocha testing

This gist shows a code snippet that dumps an object into a CSV file. File writing is done using module csv-write-stream and it returns a promise. This code works flawlessly in all the Mocha tests ...
Marco Faustinelli's user avatar
0 votes
1 answer
278 views

python csv write to a new additional file without replace old file

I am trying to write csv file and create a new file every time when a user using it, rather than replace the old file. Moreover, the users will need to enter their name at the beginning, so I need the ...
key's user avatar
  • 63
1 vote
0 answers
927 views

cant't write data in csv file

I am beginner in java and I am try to write data in csv file using apache.poi library. but csvPrinter can't write data in csv file. URL dir = getClass().getClassLoader().getResource("csv/input.csv"); ...
Kamal's user avatar
  • 61
1 vote
3 answers
5k views

CSVWriter don't allow to write to file

I want to save my data into CSV file. I'm using Scanner to read -> CSVWriter to save. I got error: incompatibile types: List[String] can't be converted to String[]. method: private static void ...
4est's user avatar
  • 3,168
1 vote
1 answer
2k views

Error writing to file fs stream NodeJS

Objective Write a very large array to a file using csv-write-stream and fs stream. Background I have a small app that writes a huge array of data (thousands of entries) to a CSV file. To achieve ...
Flame_Phoenix's user avatar
4 votes
1 answer
391 views

fs dump equivalent in NodeJs?

Objective Forcing fs (and the libraries using it) to write everything to files before terminating application. Background I am writing an object to a CSV file using the npm package csv-write-stream....
Flame_Phoenix's user avatar