Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Can you find a record lenght of a file using MORE?

Status
Not open for further replies.

wolves

Programmer
Jan 26, 2001
130
US
Using more to look at a file, is there a way to find what the record lenght is. I need to try and find out how many entries in my file, I do that by using
"awk ' END { print NR }' filename", but now I need to know the record lenght of each entry. Anyway of doing this.
 
Something like this ?
awk '{print NR, length($0)}' filename

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ222-2244
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top