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 gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to find if 3rd position in a record is space or not?? 1

Status
Not open for further replies.

longs

Programmer
Jul 27, 2007
31
US
Hi All

How can we find out if the 3rd position and/or 4th in all the records of a flat file is space or not?

e.g

AB8798723498 20071201 ca94567
TC A9398js sfkji390809 20060108
JJ897987987 897897 2154863


How can we check if there is spaces or there is a character on 3rd and 4th position in a record.

Thanks for your help
 
What about this ?
Code:
grep -e '^.. ' -e '^... ' /path/to/fltafile

Hope This Helps, PH.
FAQ219-2884
FAQ181-2886
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top