Python Forum
How to copy a .csv worksheet into a .xlsx file without the number values turning into
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How to copy a .csv worksheet into a .xlsx file without the number values turning into
#2
There must be something in your csv file that is confusing the reader. Do you have multi-row column headers in the csv file? Do you have ragged columns (not all the same length). Do you have column footers?

After reading the csv file print some of the data. Start with first row/first column and last row/last column. Is there any text where you expect to see a number? If so you might have to give the reader some extra help, tell it to skip some rows, or tell it what the data type is for a column
Reply


Messages In This Thread
RE: How to copy a .csv worksheet into a .xlsx file without the number values turning into - by deanhystad - Mar-28-2020, 05:44 AM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Errors if an xlsx file has blank rows in the beginning…. tester_V 1 886 Aug-28-2023, 06:22 PM
Last Post: deanhystad
  Export dataframe to xlsx - Error "zipfile.BadZipFile: File is not a zip file" Baggio 10 62,994 Mar-12-2021, 01:02 PM
Last Post: buran
  XLSX file with multiple sheets to josn file ovidius 2 2,289 Apr-05-2020, 09:22 AM
Last Post: ovidius
  spread values of dataset equally over fixed number of bins moose_man 3 2,579 Oct-30-2019, 07:41 PM
Last Post: ichabod801
  Import Excel File that Starts with Number kiki1113 1 3,364 Dec-20-2018, 07:13 PM
Last Post: Larz60+
  copy one column from csv file and paste into xls file kprogrammer 0 4,420 Nov-03-2018, 04:03 PM
Last Post: kprogrammer
  Copy raw data in excel to another new excel file keerthiprashanth 5 3,968 Oct-20-2018, 10:13 AM
Last Post: volcano63
  Searching a .txt file for a specific number and extracting the corresponding data nrozman 3 3,290 Jul-27-2018, 02:07 PM
Last Post: nrozman
  Updating the Pandas dataframe to existing excel workbook in existing worksheet. sanmaya 1 9,815 Jul-01-2018, 06:23 PM
Last Post: volcano63
  Write data into existing Excel (xlsx) file with multiple sheets BNB 1 15,415 Jun-01-2017, 04:22 PM
Last Post: Larz60+

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020