Search Results

Search: Posts Made By: zenkarthi
3,604
Posted By Aia
I went back and read your first post and this...
I went back and read your first post and this will not do what you said your requirements are. Nevertheless, just so you believe me I will convert it to what you asked.

perl -ne '
...
3,604
Posted By MadeInGermany
The problem is that the string comparison is not...
The problem is that the string comparison is not precise enough.
So before the comparisons one needs to ensure that there is a time stamp.
awk '/^[0-9][0-9][0-9][0-9][0-9][0-9]...
2,889
Posted By RudiC
ad-lib and untested: you could save any (last)...
ad-lib and untested: you could save any (last) line - the next run would resume from there.
Or, replace the END section with /# Time:/ {timeline=$0} END {print timeline > "lasttime"}
2,889
Posted By RudiC
Given your sample is representative, i.e. the...
Given your sample is representative, i.e. the last line has a time stamp entry, and you can have a file somewhere holding the last time stamp, tryawk 'FNR==NR {START=$0; next} END {print >...
3,606
Posted By Scrutinizer
You could something like this to get entries of...
You could something like this to get entries of the last 15 minutes:
perl -MPOSIX -lane '
BEGIN{
$c=strftime("%Y%m%d%H%M%S",localtime(time-15*60))
}
if(/^....-..-/) {
...
3,606
Posted By Akshay Hegde
This would be fine, uses current row date $ cat...
This would be fine, uses current row date
$ cat log
2014-01-18 16:00:49,624 DEBUG [testhandler] XMLObjectType: S=xyz@http://www.xyz.org/2000/XMLDSchema
2014-01-18 16:10:49,624 DEBUG [testhandler]...
12,706
Posted By Corona688
$ cat dconv3.awk BEGIN { FS="[#<>...
$ cat dconv3.awk

BEGIN {
FS="[#<> ,:]+"
# Build tables so MON["Jan"] becomes 1, etc.
split("Jan Feb Mar Apr May Jun Jul Aug Sep Oct Nov Dec", M);
for(X in M)...
12,706
Posted By Corona688
Hmmm. You might try changing this line: { ...
Hmmm. You might try changing this line:

{
YYMMDD=sprintf("%04d %02d %02d %02d %02d %02d",
$4, MON[$2], $3, T[$5 $8], $6, $7);
if((S >= from) && (S <= to))...
12,706
Posted By Corona688
BEGIN { FS="[#<> ,:]+" #...
BEGIN {
FS="[#<> ,:]+"
# Build tables so MON["Jan"] becomes 1, etc.
split("Jan Feb Mar Apr May Jun Jul Aug Sep Oct Nov Dec", M);
for(X in M) MON[M[X]]=X
...
12,706
Posted By Corona688
This program can hopefully deal with both: ...
This program can hopefully deal with both:

BEGIN {
FS="[#<> ,:]+"
# Build tables so MON["Jan"] becomes 1, etc.
split("Jan Feb Mar Apr May Jun Jul Aug Sep Oct Nov Dec",...
Showing results 1 to 10 of 10

 
All times are GMT -4. The time now is 04:56 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy