in reply to insert null in missing places of csv
what have you tried so far? I'm not a csv expert but you can do for sure something similar to:
@current_row = map { $_ ? $_ : qq(NULL) } @current_row
you can also do the job in a oneliner
perl -lanF',' -e "print join',',map {$_ ? $_ : 'NULL'} @F " testcsvnul +l.txt A,NULL,D,E,F L,T,NULL,G,Q C,D,E,NULL,L
L*
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: insert null in missing places of csv
by ukhare (Novice) on Feb 19, 2016 at 16:42 UTC | |
by AnomalousMonk (Archbishop) on Feb 19, 2016 at 17:23 UTC | |
by Discipulus (Canon) on Feb 19, 2016 at 17:41 UTC | |
by ukhare (Novice) on Feb 19, 2016 at 18:41 UTC |