rahulme81 has asked for the wisdom of the Perl Monks concerning the following question:
I made a grep
grep -w BG file.txton my configuration file which produces me an output as below
DATABASE_NAME DB_ABB DB_ID DB_D +IR ============================================================ DATA_ARCHIVE BDAT - - BG - sas DATA_CORP BDAC - Y BG bg sas DAATA_ARCHIVE BDAA - - BG - hado +op DATA_CONS BDAC - - BG - hado +op DATA_APPS BDAP - - BG ba misc + DATA_HISTORY BDAH - - BG - hado +op
What I need to achieve now is, based on DB_ID column value "BG" (which i grep earlier) I need to print the DB_DIR unique values
output should be unique DB_DIR values as below
sas
hadoop
misc
Please advice
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: OT: Find unique values in a column
by choroba (Cardinal) on Nov 30, 2015 at 15:26 UTC | |
by rahulme81 (Sexton) on Nov 30, 2015 at 15:32 UTC | |
by choroba (Cardinal) on Nov 30, 2015 at 15:42 UTC | |
by Laurent_R (Canon) on Nov 30, 2015 at 20:42 UTC |