The UNIX and Linux Forums  
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.

Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
.
google unix.com



Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts and shell scripting languages here.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
assign a command line argument and a unix command to awk variables sweta_doshi Shell Programming and Scripting 0 08-08-2008 06:54 AM
Help Required: Command to find IP address and command executed of a user loggedout Security 2 08-06-2008 08:12 PM
how to? launch command with string of command line options TinCanFury Shell Programming and Scripting 5 04-28-2008 06:06 PM
inconsistent ls command display at the command prompt & running as a cron job rajranibl SuSE 5 07-30-2007 08:26 AM
How to use more than one MPE command STREAM with Unix command in a single shell? bosskr HP-UX 1 10-16-2006 04:16 PM

Closed Thread
English Japanese Spanish French German Portuguese Italian Dutch Swedish Russian Norwegian Hungarian Hebrew Danish
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
  #1 (permalink)  
Old 10-14-2008
nileshjori nileshjori is offline
Registered User
  
 

Join Date: Apr 2008
Posts: 3
cut command

HI,

Bieng new to this forum not know how to start new thread.
hence updating this thread on cut command.

Please suggest delimter character for below scenario.

Here is output of my df -kP command
Filesystem 1024-blocks Used Available Capacity Mounted on
/dev/mapper/VolGroup00-LogVol00 7095808 3404132 3331228 51% /
/dev/sda2 101105 14095 81789 15% /boot
none 248540 0 248540 0% /dev/shm
/dev/mapper/db_dv_hig_01-db_dv_hig_01 24541052 18302040 4992396 79% /db_dv_hig_01
192.100.192.214:/soft/oradb/10202 16356288 10412192 5113216 68% /soft/oracledb

I want output of 5 files
1.txt
Filesystem
/dev/mapper/VolGroup00-LogVol00
/dev/sda2
none
/dev/mapper/db_dv_hig_01-db_dv_hig_01
192.100.192.214:/soft/oradb/10202

2.txt
1024-blocks
7095808
101105
248540
24541052
16356288

3.txt
Used
3403696
14095
0
18302016
10412192

4.txt
Available
3331664
81789
248540
4992420
5113216

5.txt
Capacity
51%
15%
0%
79%
68%

6.txt
Mounted
/
/boot
/dev/shm
/db_dv_hig_01
/soft/oracledb
  #2 (permalink)  
Old 10-14-2008
Franklin52 Franklin52 is offline Forum Staff  
Moderator
  
 

Join Date: Feb 2007
Posts: 4,212
You can use cut, for the first column:

Code:
cut -d" " -f1
Read the manpage of cut.

Regards
Sponsored Links
Closed Thread

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT -4. The time now is 01:11 PM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited. Language translation by Google.
vBCredits v1.4 Copyright ©2007 - 2008, PixelFX Studios
The UNIX and Linux Forums Content Copyright ©1993-2009. All Rights Reserved.Ad Management by RedTyger

Content Relevant URLs by vBSEO 3.2.0