04-09-2013
I want to match on pattern, print subsequent lines, then do NOT print from blahblah to EOF.
Pattern data data data
data data data
data data data
...
blabla <-- do not print to EOF. If first blabla must be printed, that's okay.
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
HiCan someone show me how to print all lines from a file after a line matching a pattern using sed?Thanks (13 Replies)
Discussion started by: steadyonabix
13 Replies
2. Shell Programming and Scripting
Hi folks,
I have a text file that I need to parse, and I cant figure it out. The source is a report breaking down softwares from various companies with some basic info about them (see source snippet below). Ultimately what I want is an excel sheet with only Adobe and Microsoft software name and... (5 Replies)
Discussion started by: rowie718
5 Replies
3. Shell Programming and Scripting
Hi All,
Please find the sample file below:
NAME ID NUMBER
-------------------------------------------------------------------------------------------------- ---------
abcdefgheija;lksdf ... (13 Replies)
Discussion started by: niel.verty
13 Replies
4. Shell Programming and Scripting
I have in a file
domain.com. 1909 IN A 1.22.33.44
domain.com. 1909 IN A 22.33.44.55
ns1.domain.com. 1699 IN A 33.44.55.66
ns2.domain.com. 1806 IN A 77.77.66.66
I need to "grep" or "awk" out the lines starting with domain.com. as follows.
domain.com. 1909 IN A 1.22.33.44
domain.com.... (3 Replies)
Discussion started by: anilcliff
3 Replies
5. Shell Programming and Scripting
I am using Solaris, I want to print
3 lines before pattern match
pattern
5 lines after pattern match
Pattern is abcd to be searched in a.txt. Looking for the solution in sed/awk/perl. Thanks ..
Input File a.txt:
=================
1
2
3
abcd
4
5
6
7
8 (7 Replies)
Discussion started by: manuswami
7 Replies
6. Shell Programming and Scripting
i need to search for a pattern from a big file and print everything expect the next 6 lines from where the pattern match was made. (8 Replies)
Discussion started by: chidori
8 Replies
7. Shell Programming and Scripting
I need to print the lines that do not match a pattern. I tried using grep -v and sed -n '/pattern/!p', but both of them are not working as I am passing the pattern as variable and it can be null some times.
Example
........ abcd......
.........abcd......
.........abcd......... (4 Replies)
Discussion started by: sunny1234
4 Replies
8. Shell Programming and Scripting
Hi,
I have a simple problem but i guess stupid enough to figure it out. i have thousands rows of data. and i need to find match patterns of two columns and print the number of rows. for example:
inputfile
abd abp 123
abc abc 325
ndc ndc 451
mjk lkj... (3 Replies)
Discussion started by: redse171
3 Replies
9. Shell Programming and Scripting
Hello Experts , require help . See below output:
File inputs
------------------------------------------
Server Host = mike
id rl images allocated last updated density
vimages expiration last read <------- STATUS ------->... (4 Replies)
Discussion started by: tigerhills
4 Replies
10. Shell Programming and Scripting
I am trying to combine lines with these conditions:
1. First line starts with text of "libname VALUE db2 datasrc" where VALUE can be any text.
2. If condition1 is met then continue to combine lines through a line that ends with a semicolon.
3. Ignore case when matching patterns and remove any... (5 Replies)
Discussion started by: Wes Kem
5 Replies
LEARN ABOUT DEBIAN
uri::data
URI::data(3pm) User Contributed Perl Documentation URI::data(3pm)
NAME
URI::data - URI that contains immediate data
SYNOPSIS
use URI;
$u = URI->new("data:");
$u->media_type("image/gif");
$u->data(scalar(`cat camel.gif`));
print "$u
";
open(XV, "|xv -") and print XV $u->data;
DESCRIPTION
The "URI::data" class supports "URI" objects belonging to the data URI scheme. The data URI scheme is specified in RFC 2397. It allows
inclusion of small data items as "immediate" data, as if it had been included externally. Examples:
data:,Perl%20is%20good
data:image/gif;base64,R0lGODdhIAAgAIAAAAAAAPj8+CwAAAAAI
AAgAAAClYyPqcu9AJyCjtIKc5w5xP14xgeO2tlY3nWcajmZZdeJcG
Kxrmimms1KMTa1Wg8UROx4MNUq1HrycMjHT9b6xKxaFLM6VRKzI+p
KS9XtXpcbdun6uWVxJXA8pNPkdkkxhxc21LZHFOgD2KMoQXa2KMWI
JtnE2KizVUkYJVZZ1nczBxXlFopZBtoJ2diXGdNUymmJdFMAADs=
"URI" objects belonging to the data scheme support the common methods (described in URI) and the following two scheme-specific methods:
$uri->media_type( [$new_media_type] )
Can be used to get or set the media type specified in the URI. If no media type is specified, then the default
"text/plain;charset=US-ASCII" is returned.
$uri->data( [$new_data] )
Can be used to get or set the data contained in the URI. The data is passed unescaped (in binary form). The decision about whether to
base64 encode the data in the URI is taken automatically, based on the encoding that produces the shorter URI string.
SEE ALSO
URI
COPYRIGHT
Copyright 1995-1998 Gisle Aas.
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
perl v5.14.2 2012-02-11 URI::data(3pm)