how to cut a particular field

hi all

i am need to cut the name of the file which i am entering in the comand line. say abc.txt is the name of the file i need to cut only the "abc" part. when i try doing this(using cut -f1) i am getting the data that s present inside the file and the file name. pls help....

Try:

read filename
echo ${filename%%.*}

If you insist on using cut

echo "$filename" | cut -d. -f1

see man pages of cut for better understanding.
you should tell cut the field separator.

cut -d. -f1

there are many others ways also like sed,awk and with string operation within shell itself.

probably you might have tried

cut -d. -f1 abc.txt

what you need to do is

echo abc.txt | cut -d. -f1