Dec-10-2018, 11:38 AM
(This post was last modified: Dec-10-2018, 12:38 PM by Gribouillis.)
Hello,
I am creating CSV file in unix with help of sed command.
File is getting created correctly as below:
I am creating CSV file in unix with help of sed command.
File is getting created correctly as below:
Output:Column_1 Nunber(10,1)
Column_1 Decimal(8,2)
Column_1 Varchar
I am trying to read this file row by row in python as below with open (datafile) as csvfile: reader = csv.reader(csvfile,dialect='excel') row = next(reader) for row in reader: sql = sql + (" ".join(row)) + (",") + "\n" sql= sql[:-2]when i am trying to put this row in sql file the comma in datatype is missing like below
Output:Column_1 Nunber(10 1)
Column_1 Decimal(8 2)
Is there any reason for this ?