![]() |
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !! |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| parsing data file picking out certain fields | timj123 | Shell Programming and Scripting | 8 | 03-05-2008 06:57 PM |
| Listing out three fields of data | damion | UNIX for Dummies Questions & Answers | 3 | 11-08-2007 08:32 PM |
| How can i remove spaces in between the fields in a file | dsravan | Shell Programming and Scripting | 3 | 09-26-2006 04:11 PM |
| How to change Raw data to Coloumn data fields | Nayanajith | Shell Programming and Scripting | 1 | 08-29-2006 01:23 AM |
| Identifying new fields of data | davels | SUN Solaris | 0 | 01-10-2005 11:06 PM |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
||||
|
Remove Data from Fields
I would like some sugestions on how to solve the following problem with removing selected data from fields. Each day I receive a file containing 22,000 records that I use a combination of awk and the cut command to remove unwanted fields. This is a work in process as I learn more about awk, sed and other tools.
The problem I am struggling with is how can i remove only the time stamp, days, day from the last field? I only want the number days in the last field. For days less than 1 if I can place a "0" in field great, I think a blank will work for now. Below is a sample of the file output. Thanks |1|8|0|0|10 days, 5:35:33 |1|8|0|0|0:00:00 |1|8|0|0|18 days, 12:08:44 |1|8|0|0|0:09:25 |1|8|0|0|23:59:25 |1|8|0|0|1 day, 1:16:25 |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|