troubleshooting Question

sort this file using out-of-the-box Redhat Linux tools

Avatar of MarkLoveExEx
MarkLoveExEx asked on
Scripting LanguagesLinuxShell Scripting
2 Comments1 Solution181 ViewsLast Modified:
Dear script writers,

Is there a way to sort the data in the attached file (using a script) where the oldest data is on the top, and the latest data is at the bottom? It would have to processed, keeping the "blocks" of data together and using the date info from the ".ER" lines.

A ".ER" line is the begining of a block of data. The spacing and format of the data can't be changed. Just need to blocks sorted. The date information is in the "ER" lines, as as follows:
.ER LAWV2    0224 E DC201602241659/DH19/HGIFF/DIH6

Tools must be out of the box Redhad Linux. I know I have python, awk, shell script stuff. Whatever works the best...

Thanks for your help!
Maciej S

Our community of experts have been thoroughly vetted for their expertise and industry experience.

Join our community to see this answer!
Unlock 1 Answer and 2 Comments.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 2 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros