If I'm using CSV.dictReader to read in an CSV, how would I go about having it ignore certain columns in the CSV?
For example,
"id","name","address","number","created"
"123456","someName","someAddress","someNumber","2003-5-0294"
And I want to just get the id and name using the reader, discarding and ignoring the rest. I tried using fieldnames but it still reads it in and sets it as "None". I noticed that the csv.DictWriter has an 'ignore' function but it seems the DictReader does not. Was hoping there was a more elegant way to do this versus just reading and then writing only the columns I want to another CSV and then reading that CSV using DictReader to do further processing.
Thanks guys!