compare columns

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Jollywg
    New Member
    • Mar 2008
    • 158

    compare columns

    I have 1 file that I need to compare two columns and count how many account names (column1 ie jollywg) do not have a /home directory with that name (column 6 ie /home/jollywg). The file name is /etc/passwd...how can I do this!!...i've been scouring the internet for hours and have come up with nothing.

    Thanks in advance!
    Jollywg
  • numberwhun
    Recognized Expert Moderator Specialist
    • May 2007
    • 3467

    #2
    Originally posted by Jollywg
    I have 1 file that I need to compare two columns and count how many account names (column1 ie jollywg) do not have a /home directory with that name (column 6 ie /home/jollywg). The file name is /etc/passwd...how can I do this!!...i've been scouring the internet for hours and have come up with nothing.

    Thanks in advance!
    Jollywg
    This should be easy enough in shell or another language, what have you tried? I ask this because this sounds like a question asked for homework.

    Regards,

    Jeff

    Comment

    Working...