I've tried using the below, and various 'csv import' machinations, and no matter what I do the double quotes are present when I open the file in notepad++, notepad, etc. And when I bulk insert to sql serve there are coming over as an 'o' with an umlaut at the beginning and end of every column. I'm oviously missing something with my lack of Python knowledge, but I'm at wits end as to why they just won't go away. (They are hex value 94 if it makes a difference). Originally opened as a csv file with excel, then format was changed to quote all but integers, and now I'm where I am. If anybody can offer a take on that or a link, or anything, I would appreciate it, thanks.
import os mypath = r'C:\\csv\\' myoutputpath = r'C:\\csv\\output\\' for file in os.listdir(mypath): # This will loop through every file in the folder if '.csv' in file: # Check if it's a csv file fpath = os.path.join(mypath, file) fpath_out = os.path.join(myoutputpath, file) #+ '_output' # Create an output file with a similar name to the input file with open(fpath) as infile: lines = infile.readlines() # Read all lines with open(fpath_out, 'w') as outfile: for line in lines: # One line at a time outfile.write(line.replace('"', '')) # Remove each " and write the line