I have a CSV file ( usvd.csv ) that contains 41 columns, my bash script processes the header row to train which columns are printed, as a result I need to print 26 out of 41 columns. They may vary - The number of columns in the CSV and the number of columns to print.
An array containing the number of columns to be printed is as follows:
${UNIQUE[@]} = 1 2 3 5 6 7 8 9 10 11 12 13 14 15 16 17 18 20 21 26 30 35 37 39 40 41
So, out of 41 columns, I only want to print the columns listed above, and they may differ from file to file.
Thanks!!
Gregg source share