Search Results

Search: Posts Made By: karthik023
42,736
Posted By radoulov
Yes: awk '!x[$1]++' filename Use...
Yes:

awk '!x[$1]++' filename


Use nawk or /usr/xpg4/bin/awk on Solaris.
4,888
Posted By kalpeer
i done a little modification to my script and...
i done a little modification to my script and display the last two days and today report

#! /bin/bash

#retrieve current date and month
da_date="`date +%d`"
#da_date="2"
da_month=`date "+%m"`...
2,441
Posted By balajesuri
perl -ane 'open O,">>month_$F[2].txt";print O...
perl -ane 'open O,">>month_$F[2].txt";print O "$F[0] $F[1] $F[3]\n;close O' inputfile.txt---------- Post updated at 14:47 ---------- Previous update was at 14:31 ----------

#! /bin/bash
while...
33,663
Posted By Raynon
Hi cbkihong, Is there a perl code with same...
Hi cbkihong,

Is there a perl code with same function as the command lcd in csh ?
And how can i put a wild card in the get command ? $ftp->get("xxx*.txt"). It didn;t seem to work below for me...
2,674
Posted By yazu
% perl -F'/(?<=}),\s/' -alne 'print join ", ",...
% perl -F'/(?<=}),\s/' -alne 'print join ", ", grep {!/\b0\b/} @F' INPUTFILE
{123, 2, 244}, {22, 756, 92}, {211, 645, 22}
2,674
Posted By yazu
Ok, I'll try but my English is not good at all. ...
Ok, I'll try but my English is not good at all.

Perl switches (perldoc perlrun):
"-n" reads lines from @ARGV (that is INPUTFILE) to $_ and "-l" removes and adds (when printing) newline chars....
9,661
Posted By Skrynesaver
Not a pure shell solution, however the following...
Not a pure shell solution, however the following works

export string1="abc|def|hij"
export string2="12|13|14"
string3=$(perl -e '@f=split /\|/, $ENV{string1};@s=split /\|/, $ENV{string2};for...
Showing results 1 to 7 of 7

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