hello
have a file1
H87I
Y788O
T347U
J23U
and
file2 J23U U887Y I99U T556U
file3 I99O J99T F557J
file4 N99I T666U R55Y
file5 H87I T347U
file6 H77U R556Y E44T
file7 Y788O K98U H8I
May be using script we can use file1 to search for all the files
and have the output
H87I file5... (3 Replies)
Hello,
I have a file which has user information. Each user has 2 variables with the same name like
Email: testuser1
Email: testuser1@test.com
Email: testuser2
Email: testuser2@test.com
My intention is to delete the ones without the '@' symbol. When I run this statement awk '/^Email:/&&!/@/'... (6 Replies)
Hi,
Is there anyway to print contents of any file ( say log files that grow automatically) within some timeframe ( comparing with current time), say
print contents of the added in:
1) last 2 hr
2) last 45 min
3) last 3 hrs 47 min (3 Replies)
i am trying to search a few hundred release note text files for a certain word. however when i use the below command i can find a file that contains it but i dont know the file name. how can i change this command to output the name of the file that grep was successful in?
find builds -name... (4 Replies)
Hi,
Need help in writing a script to read the contents of this file test
Test
00a
00b
00c
00d
00e
00f
where it need to read each line to give a display such as
form meta from dev 00a , config=Striped; add dev 00b:00f to meta 00a
Can any one help me in writing this script (2 Replies)
Solaris 10
When running grep from within find command (don't know the technical term for 'running from within' ) , find command returns only the line which contains the pattern. Is there any way to get the file name printed as well ?
$ pwd
/opt/testdir/anotherDir
$
$
$ cat findme.txt... (3 Replies)
Hi Friends,
This is the only solution to my task. So, any help is highly appreciated.
I have a file
cat input1.bed
chr1 100 200 abc
chr1 120 300 def
chr1 145 226 ghi
chr2 567 600 unix
Now, I have another file by name
input2.bed (This file is a binary file not readable by the... (7 Replies)
Hello,
I know that gnu grep has option of -A and -B to extra previous and next lines.
But I'm using HP UX and its grep does not support these options.
BID="0/0/6/1/1.145.17.255.0.0.0"
I need to search a file using $BID and get next 5 lines and previous 5 lines separately.
Please... (1 Reply)
I need to find a file and print its contents
I am trying but it is not working
find -path /opt/app-root/src/.npm/_logs -type f -name "*.log" -print
Version
$ bash -version
GNU bash, version 4.4.12(1)-release (x86_64-pc-msys) (1 Reply)
Discussion started by: SVRao19056
1 Replies
LEARN ABOUT DEBIAN
anydata::format::weblog
AnyData::Format::Weblog(3pm) User Contributed Perl Documentation AnyData::Format::Weblog(3pm)NAME
AnyData::Format::Weblog - tiedhash & DBI/SQL access to HTTPD Logs
SYNOPSIS
use AnyData;
my $weblog = adTie( 'Weblog', $filename );
while (my $hit = each %$weblog) {
print $hit->{remotehost},"
" if $hit->{request} =~ /mypage.html/;
}
# ... other tied hash operations
OR
use DBI
my $dbh = DBI->connect('dbi:AnyData:');
$dbh->func('hits','Weblog','access_log','ad_catalog');
my $hits = $dbh->selectall_arrayref( qq{
SELECT remotehost FROM hits WHERE request LIKE '%mypage.html%'
});
# ... other DBI/SQL read operations
DESCRIPTION
This is a plug-in format parser for the AnyData and DBD::AnyData modules. You can gain read access to Common Log Format files web server
log files (e.g. NCSA or Apache) either through tied hashes or arrays or through SQL database queries.
Fieldnames are taken from the W3 definitions found at
http://www.w3.org/Daemon/User/Config/Logging.html#common-logfile-format
remotehost
usernname
authuser
date
request
status
bytes
In addition, two extra fields that may be present in extended format logfiles are:
referer
client
This module does not currently support writing to weblog files.
Please refer to the documentation for AnyData.pm and DBD::AnyData.pm for further details.
AUTHOR & COPYRIGHT
copyright 2000, Jeff Zucker <jeff@vpservices.com> all rights reserved
perl v5.10.1 2004-08-17 AnyData::Format::Weblog(3pm)