Hi Guys
i have a file with hundreds of lines like this
alerts.log2011-29:08/29/2011 12:47:56 XYZ_1234 ABSCTT One Failed File Push To Remote Server Failed ABC.DEF.1234
alerts.log2011-29:08/29/2011 12:47:56 XYZ_1234 ABSCTT One Failed File Push To Remote Server Failed WXYZ_ABC001
i want to take date and last column of file (till first special character) at a time.
expected output of command is:
08/29/2011 12:47:56 ABC
08/29/2011 12:47:56 WXYZ
Here i m facing 2 problems
1) when i cat this file and grep any one of these 2 i cant grep other in same command
2) In last column i want to pull the information only till first special character found which is not consistent in the file, its flooded with all kind of them. :wall:
Any help is greatly appreciated folks
Regards