Operating System - Linux
1753554 Members
4302 Online
108795 Solutions
New Discussion юеВ

Re: awk operand !~ not working?

 
SOLVED
Go to solution
lawrenzo_1
Super Advisor

Re: awk operand !~ not working?

I did add a colon but didnt use -F for the delimiter.

:-
hello
James R. Ferguson
Acclaimed Contributor

Re: awk operand !~ not working?

Hi (again) Chris:

> I did add a colon but didnt use -F for the delimiter.

Well, if you are going to manually edit '/etc/passwd', you should use 'vipw' [on HP-UX, but if this is AIX there isn't one].

Too, its a good thing to run 'pwck' (or maybe 'pwdck' on AIX) if you have kludged '/etc/passwd'.

Regards!

...JRF...
lawrenzo_1
Super Advisor

Re: awk operand !~ not working?

James ...

>> You are saying that you want to match the character sequence "GIO-ES-UAM:" *anywhere* in a record, *and* then using the matched record, if the *beginning* character sequence is *not* "+@GIO", then print. <<

yes this is correct james but have worked out that by doing the it prints every line that is not matched - I think I have chosen the wrong tool for my problem so will use shell ksh syntax.

:-)

Thanks all.
hello