05-11-2011
while i appreciate your response agama im afraid im ust not that knowledgable enough to figure out how to achieve what your suggesting, most specifically how to read the last date\time, tuck it away, and then use that for the next run of the script. Would reallly appreicate if if you educate me a little
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi ,
I am trying a script which takes user input userid . I am stuck how to check whether that is a valid user id or not in the audit log files. My code is :
cd $CCP_AUDIT
cat * > /export/home/$USR/l***/files
echo "UserId:\c"
read UserId
#Date Function
echo "DATE : \c"
read xxx
I... (7 Replies)
Discussion started by: gundu
7 Replies
2. UNIX for Dummies Questions & Answers
alist contain:
a
b
c
d
e
blist contain:
a
b
c
the code:
#!/usr/bin/ksh
cat blist | while read line
do
grep -V "$line" alist > data
done (8 Replies)
Discussion started by: bobo
8 Replies
3. Shell Programming and Scripting
I have a huge file and want to separate it into several subsets.
The file looks like:
C1 C2 C3 C4 ... (variable names)
1 ....
2 ....
3 ....
:
22 ....
23 ....
I want to separate the huge file using the column 1, which has numbers from 1 to 23 (but there are different amount of... (8 Replies)
Discussion started by: AMBER
8 Replies
4. Shell Programming and Scripting
I have a key file
$ cat klist
5 N:8855 CASA VERDE ROAD :32827 :ORLAND
5 N:585 MOLLY LANE :30189 :WOODST
5 N:320 NINA ROAD :32304 :TALLAH
and a data file, see example of the line below:
N:RT 15 & N 7TH STREET :17837 :U SAVE
I need to search by key (2nd field) from klist... (6 Replies)
Discussion started by: migurus
6 Replies
5. Shell Programming and Scripting
Hi all,
I have the below script to get input but i cannot get grep to work.
input1.txt
AAAAAAAAG
input2.txt
>gi|184009.1| LEAFY-like |AAAAAAAAGSGGGDHLPY
However, when i use grep -f input1.txt input2.txt
i cannot get any output matches (note that the match is underlined).
Is it... (8 Replies)
Discussion started by: turkishvan
8 Replies
6. Shell Programming and Scripting
So this is what I'm trying to do:
I have a file called registry.txt which has a list of registry entries I want to search for.
I have another file called inctrl.txt on which I want to perform the search on.
Here's the example contents of registry.txt
SOFTWARE\Microsoft\Security... (3 Replies)
Discussion started by: r4v3n
3 Replies
7. Red Hat
Hello everybody,
I have been searching it, but it seems I am unable to find the correct information, that s why I am asking you guys, hoping somebody get an idea.
Here is my problem :
I want a script to loop until a string is identified in a log file.
Here is the script :
#!/bin/sh... (5 Replies)
Discussion started by: guyiom
5 Replies
8. Homework & Coursework Questions
Use and complete the template provided. The entire template must be completed. If you don't, your post may be deleted!
1. The problem statement, all variables and given/known data:
I need to search through the users home directories for keywords, display them. The code listed below will show... (7 Replies)
Discussion started by: jcllns1
7 Replies
9. UNIX for Beginners Questions & Answers
Hello -
I am running a script that is outputting to a log. Let call it output.log
I would like to monitor that log until the line "Build Successful" is found.
I think I would need to use the grep command.
How would I do that in a loop?
Thanks
Marty (1 Reply)
Discussion started by: MSpeare
1 Replies
10. Shell Programming and Scripting
Hello,
I have built the following script to check if processes supplied by the argument are running or not.
#!/bin/bash
PROCLIST=$1
PROCESS="0"
ERROR_PROCS=""
IFS='+'
read -ra ADDR <<< "$PROCLIST"
for PROC in "${ADDR}"; do
if ; then
PROCESS=1
... (9 Replies)
Discussion started by: nms
9 Replies
LEARN ABOUT DEBIAN
datetime::format::w3cdtf
DateTime::Format::W3CDTF(3pm) User Contributed Perl Documentation DateTime::Format::W3CDTF(3pm)
NAME
DateTime::Format::W3CDTF - Parse and format W3CDTF datetime strings
SYNOPSIS
use DateTime::Format::W3CDTF;
my $w3c = DateTime::Format::W3CDTF->new;
my $dt = $w3c->parse_datetime( '2003-02-15T13:50:05-05:00' );
# 2003-02-15T13:50:05-05:00
$w3c->format_datetime($dt);
DESCRIPTION
This module understands the W3CDTF date/time format, an ISO 8601 profile, defined at http://www.w3.org/TR/NOTE-datetime. This format as
the native date format of RSS 1.0.
It can be used to parse these formats in order to create the appropriate objects.
METHODS
This API is currently experimental and may change in the future.
o new()
Returns a new W3CDTF parser object.
o parse_datetime($string)
Given a W3CDTF datetime string, this method will return a new "DateTime" object.
If given an improperly formatted string, this method may die.
o format_datetime($datetime)
Given a "DateTime" object, this methods returns a W3CDTF datetime string.
NOTE: As of version 0.4, format_datetime no longer attempts to truncate datetimes without a time component. This is due to the fact
that "DateTime" doesn't distinguish between a date with no time component, and midnight.
o format_date($datetime)
Given a "DateTime" object, return a W3CDTF datetime string without the time component.
SUPPORT
Support for this module is provided via the datetime@perl.org email list. See http://datetime.perl.org/?MailingList for details.
Please submit bugs to the CPAN RT system at http://rt.cpan.org/NoAuth/ReportBug.html?Queue=datetime-format-w3cdtf or via email at
bug-datetime-format-w3cdtf@rt.cpan.org.
AUTHOR
Dave Rolsky <autarch@urth.org>
CREDITS
This module is maintained by Gregory Todd Williams <gwilliams@cpan.org>. It was originally created by Kellan Elliott-McCrea
<kellan@protest.net>.
This module was inspired by DateTime::Format::ICal
COPYRIGHT
Copyright (c) 2009 David Rolsky. All rights reserved. This program is free software; you can redistribute it and/or modify it under the
same terms as Perl itself.
Copyright (c) 2003 Kellan Elliott-McCrea
Portions of the code in this distribution are derived from other works. Please see the CREDITS file for more details.
The full text of the license can be found in the LICENSE file included with this module.
SEE ALSO
datetime@perl.org mailing list
http://datetime.perl.org/
perl v5.10.1 2011-02-06 DateTime::Format::W3CDTF(3pm)