Wanted to print csv data in single line.
CSVFile.txt:
abc|xyz|111
def|uvw|222
Python 3.x code:
with open(csvfile, "r") as csvdata:
    for line in csvdata:
        fields = line.split("|")
        for data in fields:
            # do some processing and then
            print(data)
This prints the data as
abc
xyz
111
def
uvw
222
Want to print data in straight line as
abc, xyz, 111
def, uvw, 222
    
fields? Is it a single row or the whole file?