Quantcast
Channel: UNIX and Linux Forums
Viewing all articles
Browse latest Browse all 16232

how to keep tab from being converted to space

$
0
0
Hi, I want to read lines from a file, and I'm using two methods
1 use
Code:

while read line
do
done<filename

2 use
Code:

line=`sed -n '3p' filename`
however, in both of them, I notice that the tab between fields are automatically converted to space

because I want to use awk over the lines, I hope the 'tab' can be kept
are there any ways? thanks

Viewing all articles
Browse latest Browse all 16232

Trending Articles