Sponsored Content
Top Forums Shell Programming and Scripting need to delete lines that start with letters Post 302322751 by Franklin52 on Thursday 4th of June 2009 01:41:16 PM
Old 06-04-2009
Is this a homework question?
Assuming that it's not, what is the practical business problem you are solving?
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

awk - delete last two letters

Hello! How do I remove the last two letters "GB" off each line, using awk? What I need to remove is the "GB" in following input: ..... 30GB 2504GB 3GB 40GB ...... The OS used is Solaris9 Regards, Fredrik (1 Reply)
Discussion started by: sap4ever
1 Replies

2. Shell Programming and Scripting

Delete all lines that start with a bigger number of a specific one.

E.g. the file is like this: I want to delete all lines that begin with a number larger than 2, ignoring the lines that doesn't begin with a number! PS:'2' is actually a variable that can have a lot of values:b:i bet you got it (10 Replies)
Discussion started by: hakermania
10 Replies

3. Shell Programming and Scripting

Start from the prefixes, delete script

My folder is/app2/istech/scratch, which contain all the below files. I need to delete the files which start from the prefixes. dup_events_*.* Event_*.* New_time_*.* New_Loc_*.* New_Uptime_*.* Detailed_Reason*.* cmt_dup_*.* Uptime_*.* Can anyone please let me know how to write a... (3 Replies)
Discussion started by: dsnaveen
3 Replies

4. UNIX for Dummies Questions & Answers

How to delete all columns that start with a specific value

I have this space delimited large text file with more than 1,000,000+ columns and about 100 rows. I want to delete all the columns that start with NA such that: File before modification aa bb cc NA100 dd aa b1 c2 NA101 de File after modification aa bb cc dd aa b1 c2 de How would I... (3 Replies)
Discussion started by: evelibertine
3 Replies

5. UNIX for Dummies Questions & Answers

Grep.Need help with finding the words which start at [A-K] letters in thesecond column of the table

Hi buddies ! I need some help with one grep command :) I have this table: 1 Petras Pavardenis 1980 5 08 Linas Bajoriunas 1970 10 3 Saulius Matikaitis 1982 2 5 Mindaugas Stulgis 1990... (1 Reply)
Discussion started by: vaidastf
1 Replies

6. UNIX for Dummies Questions & Answers

How can I replace the lines that start with a star and replace it with numbers start from 1?

I need to replace the (*) in the fist of a list with numbers using sed for example > this file contain a list * linux * computers * labs * questions to >>>> this file contain a list 1. linux 2. computers 3. labs 4. questions (7 Replies)
Discussion started by: aalbazie
7 Replies

7. Shell Programming and Scripting

awk to remove lines that do not start with digit and combine line or lines

I have been searching and trying to come up with an awk that will perform the following on a converted text file (original is a pdf). 1. Since the first two lines are (begin with) text they are removed 2. if $1 is a number then all text is merged (combined) into one line until the next... (3 Replies)
Discussion started by: cmccabe
3 Replies

8. Shell Programming and Scripting

Get the average of lines with the same first 4 letters

How to sum up and print into the next line the total SUM. ]$ cat hhhh aaa1a 1 aaa1g 2 aaa1f 3 baa4f 3 baa4d 4 baa4s 4 cddg1 3 cddg3 4 cddfg 1 $ cat hhhh|awk ' {sum+=$2} END {print sum}' 25 Desire output: aaa1a 1 (13 Replies)
Discussion started by: kenshinhimura
13 Replies

9. UNIX for Beginners Questions & Answers

How do delete certain lines alone which are matching with start and end string values in file?

Hi, In my previous post ( How to print lines from a files with specific start and end patterns and pick only the last lines? ), i have got a help to get the last select statement from a file, now i need to remove/exclude the output from main file: Input File format: SELECT ABCD, DEFGH,... (2 Replies)
Discussion started by: nani2019
2 Replies

10. UNIX for Beginners Questions & Answers

How to print lines from a files with specific start and end patterns and pick only the last lines?

Hi, I need to print lines which are matching with start pattern "SELECT" and END PATTERN ";" and only select the last "select" statement including the ";" . I have attached sample input file and the desired input should be as: INPUT FORMAT: SELECT ABCD, DEFGH, DFGHJ, JKLMN, AXCVB,... (5 Replies)
Discussion started by: nani2019
5 Replies
PAGESJAUNES(1p) 					User Contributed Perl Documentation					   PAGESJAUNES(1p)

NAME
pagesjaunes - Lookup phones numbers from www.pagesjaunes.fr SYNOPSIS
pagesjaunes [options ...] Options: -activite -business : Business type -nom -name : Name -prenom -firstname : First name -localite -town : Town -departement -district : Dept district or Region -useragent : String to be passed as User-Agent header (this may be needed to bypass user-agent detection) -fast : Submit the request directly without querying the form -separator : Character used to separate the fields (default ' ') -limit : Maximum number of results returned -english : Use the pagesjaunes.fr english interface -quiet : Turn off error messages display -help : Brief help message -man : Full documentation -version : Display version number You must provide the localite/town option, and either activite/business or nom/name option. The prenom/firstname option is ignored if the localite/town option is set. OPTIONS
-activite or -business Activity or business type you're looking for. This is a mandatory switch if you don't specify the -name or -nom switches. -nom or -name Name of the person or company you're looking for. Note that the search is done with a fuzzy match. -prenom or -firstname First name of the person you're looking for. This option is ignored if the -activite or -business are set. -adresse or -address Address of the person you're searching for. -localite or -town Name of the town. -department or -district Department district or Region you're searching in. -separator Character used to separate fields in the result set. Default is a tabulation character. -useragent The default user-agent string passed to the www.pagesjaunes.fr site is ""WWW::Search::Pagesjaunes/x.xx" where x.xx is the version of the module. Sometimes, it is needed to change it to other user-agent strings. -limit Maximum number of entries returned. Default is 50. If you set it to 0 or a negative number, it will return all the entries found. -english Use the english interface of pagesjaunes.fr. This means that you can enter business types in english (i.e. 'plumber' instead of 'plombier'), and error messages will be displayed in english. -quiet No error messages are printed when this switch is on -help Print a brief help message and exits. -man Prints the manual page and exits. -version Prints the version of the script and exits. DESCRIPTION
This script provides name, phone number and addresses of French telephone subscribers by using the http://www.pagesjaunes.fr directory and the WWW::Search::Pagesjaunes module. COPYRIGHT
Please read the Publisher information of <http://www.pagesjaunes.fr> available at the following URL: http://www.pagesjaunes.fr/pj.cgi?html-=commun/avertissement.html&lang=en <http://www.pagesjaunes.fr/pj.cgi?html-=commun/avertissement.html&lang=en> This script is Copyright (C) 2002, Briac Pilpre This script is free software; you can redistribute it or modify it under the same terms as Perl itself. AUTHOR
Briac Pilpre <briac@cpan.org> perl v5.12.4 2011-11-02 PAGESJAUNES(1p)
All times are GMT -4. The time now is 12:43 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy