if we create a file, in that 10 rows(means 1,2,....9,10
like). i want 7 row exactly, which command use in unix?
plz send this question.

Answer Posted / soumendra

ans- cut -d " " -f 1-7 <file name>

by this u can get all the 7 rows of ur file.
here i give 'space" as the delimeter.
u give the delimeter as u give in the file.

by -f option u can exactly get the 1 to 7 field/rows

Is This Answer Correct ?    0 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the use of finger command?

601


Write a command that will display files in the current directory, in a colored, long format.

687


What are grep patterns?

579


What is the functionality of a top command?

628


What are the unix commands?

560






why metadb requires a seperate slice to create Solaris volume manager

2556


What is the nmap command?

585


What does touch command do in unix?

731


Is there any method to erase all files in the current directory, along with its all sub-directories, by using only one command?

592


Describe the usage and functionality of the command rm –r * in unix?

827


How do you grep a case insensitive?

541


What is grep short for?

558


Why is awk called awk?

581


What is in grep command?

650


Explain the steps that a shell follows while processing a command.

683