Search Results

Search: Posts Made By: smarones
860
Posted By smarones
File Editing
Never mind!. Thanks
1,276
Posted By smarones
wow that was quick man thanks, But one more...
wow that was quick man thanks,

But one more question I have 2000+ useLabels does the command gaurantee that the correct swVersion (the one below it) is put in fron of the userLabel?
1,276
Posted By smarones
Awk/Nawk Questions
Hi Guys,

This is the Input:


<xn:MeContext id="XXX012">
<xn:ManagedElement id="1">
<xn:attributes>
<xn:userLabel>XXX012</xn:userLabel>
...
4,305
Posted By smarones
Hey guys thanks all of you. tried all and...
Hey guys thanks all of you.

tried all and the all work.

and I did try to search but did not find the links you provided
4,305
Posted By smarones
Converting a line into a list using awk or sed
Hello,

I am trying to convert a line into a list using awk or sed.


Line:
345 897 567 098 123

output:
345
897
567
098
123


thanks
5,281
Posted By smarones
how to prompt the user to enter an array in tcsh
Hello,

I am writing a script that requires the user to enter a string of numbers:

ex: 134 345 865 903


This command only allows for one variable to be entered:

set "var" = $<

...
1,969
Posted By smarones
file 1 FC1 FC3 FC4 FC2 FC5 ...
file 1
FC1
FC3
FC4
FC2
FC5


actual file2:

Network=ONR,Context=FC6,Element=1
Network=ONR,Context=FC7,Element=1
Network=ONR,Context=FC0,Element=1
Network=ONR,Context=FC1...
1,969
Posted By smarones
hey jayan jay can you explain to me why field $4?...
hey jayan jay can you explain to me why field $4?

---------- Post updated at 04:31 AM ---------- Previous update was at 04:25 AM ----------

jayan jay,

all possible combinations:


>...
1,969
Posted By smarones
I get the same thing ---------- Post...
I get the same thing

---------- Post updated at 04:24 AM ---------- Previous update was at 04:18 AM ----------

if anyone is interested,
a combination of jayan jay's solution and rdcwayx's...
1,969
Posted By smarones
Hi jayan jay, this is the error I get when...
Hi jayan jay,

this is the error I get when running your solutions:


user (v62253@akr1e1cx3)> fgrep -f not_upgraded_sites.txt not_upgraded.sel | nawk -F'[=,]' '!x[$4]++'
x[: Event not found.
1,969
Posted By smarones
Hi rdcwayx, I think your solution is what I...
Hi rdcwayx,
I think your solution is what I need however my lines are a bit more complicated than the example I gave and your solution is based on that which is my fault. But I was looking for...
1,969
Posted By smarones
how to fgrep -f two files and get only one instance of each matched line
Hello,

I have two files:


file1
x
v
r
g

file2

aaaa,x,1111
bbbb,v,2222
bbbb,v,
cccc,r,3333
dddd,s,4444
eeee,q,5555
ffff,p,6666
10,567
Posted By smarones
renaming the default output name of the split command
Hello,

I would like to split a file but I dont what the subfiles to be named the way they are:


ex:
default name: xaa xab xac xad xae
desired name: b01 b02 b03 b04 b05


I know I can...
3,501
Posted By smarones
ok, it makes sence now, I am using Solaris and I...
ok, it makes sence now, I am using Solaris and I had the same problem previously and it was suggested that I use nawk instead of awk.

using nawk your solutions works, thanks alot
3,501
Posted By smarones
Thanks ahamed but the solution does a little bit...
Thanks ahamed but the solution does a little bit more than what I ask for:


awk 'NR==FNR{a[++j]=$0;next}{b=b"=="$0}END{for(i=1;i<j;i++){print a[i]} printf("%s%s\n",a[j],b)}' fil1.txt file2.txt...
11,025
Posted By smarones
Thanks Ahamed, Nice work around, it works. ...
Thanks Ahamed,

Nice work around, it works.
So I guess the answer is you cant use wildcards with a tcsh if statment.:(
11,025
Posted By smarones
well the problem is I started scripting about 5...
well the problem is I started scripting about 5 weeks ago and the script I have been working on thus far I have written in tcsh, its a pretty long one. So far I have not had a problem with tcsh.
...
11,025
Posted By smarones
Wildcard in a tcsh if statment
Hello everyone

I was hoping someone could tell me whether I can use a wildcard inside an tcsh if statement.

I am trying to test the argument the user has fed the script and whether it is a...
3,501
Posted By smarones
Hi CarolM, I am using tcsh to write the...
Hi CarolM,

I am using tcsh to write the script I believe your solution is for Bash, it does not work when I run it.

can you or anyone esle provide a tcsh awk or sed command which would...
3,501
Posted By smarones
Hi CarloM, Already logged out of my solaris...
Hi CarloM,

Already logged out of my solaris account, but it seems like its exactly what I need.
I will try it tomorrow and let you know.

Thanks
2,085
Posted By smarones
Hi CarloM, My files are not sorted so "join"...
Hi CarloM,
My files are not sorted so "join" would not work properly
but I did not know about join, am sure i will use it later on.

Thanks
3,501
Posted By smarones
how to append multiple lines to the last line of a file
Hello,

This is what I am trying to achieve:


file1

a
b
c
d



file2

e
f
g
h
2,085
Posted By smarones
oh sorry about that, my eyes are getting really...
oh sorry about that, my eyes are getting really tired, its really late here :(, will try tomorrow and let you
2,085
Posted By smarones
Works like a charm when using nawk, thanks alot...
Works like a charm when using nawk, thanks alot guys :)
2,085
Posted By smarones
Thanks guys, I will try both methods and let you...
Thanks guys, I will try both methods and let you know.

---------- Post updated at 04:44 AM ---------- Previous update was at 04:12 AM ----------

Hi zaxxon, this is what I got when I tried...
Showing results 1 to 25 of 26

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