Baika
Technical User
- Dec 19, 2013
- 1
Hi All:
I have a table that has more than 30,000 columns. Below is a small snapshot of the table. I am looking for a script to delete columns that contain only the number "1" from top to bottom.
ST L1 L2 L3 L4 L5
ST2 1 1 1 1 1
ST2 1 0 1 0 1
ST3 1 0 1 0 1
ST3 0 0 1 1 1
ST4 1 0 1 0 1
ST5 1 0 1 0 1
ST6 1 0 1 0 1
ST7 0 0 1 1 1
ST8 0 0 1 0 1
ST9 1 0 1 0 1
Basically, I am looking for an output like this:
ST L1 L2 L4
ST2 1 1 1
ST2 1 0 0
ST3 1 0 0
ST3 0 0 1
ST4 1 0 0
ST5 1 0 0
ST6 1 0 0
ST7 0 0 1
ST8 0 0 0
ST9 1 0 0
Any help would be greatly appreciated.
Thanks in advance,
baika
I have a table that has more than 30,000 columns. Below is a small snapshot of the table. I am looking for a script to delete columns that contain only the number "1" from top to bottom.
ST L1 L2 L3 L4 L5
ST2 1 1 1 1 1
ST2 1 0 1 0 1
ST3 1 0 1 0 1
ST3 0 0 1 1 1
ST4 1 0 1 0 1
ST5 1 0 1 0 1
ST6 1 0 1 0 1
ST7 0 0 1 1 1
ST8 0 0 1 0 1
ST9 1 0 1 0 1
Basically, I am looking for an output like this:
ST L1 L2 L4
ST2 1 1 1
ST2 1 0 0
ST3 1 0 0
ST3 0 0 1
ST4 1 0 0
ST5 1 0 0
ST6 1 0 0
ST7 0 0 1
ST8 0 0 0
ST9 1 0 0
Any help would be greatly appreciated.
Thanks in advance,
baika