jorain has asked for the wisdom of the Perl Monks concerning the following question:
<Readme> Output from array 1(username) is as follows: smithj jonesa johnsonw Output from array 2(smartcard id) is as follows: 1234567 8901234 5678901 Output from both arrays are in same order, so i just need a one for one association (eg, output1 from first array will always = output2 from array2, and so forth), that is output like: smithj = 1234567 jonesa = 8901234 johnsonw = 5678901 Not sure how to associate this - would appreciate any assists</readme>@getuser = `dsquery user –name * -o samid –limit 1000`; foreach (@getuser) { $a = $_; chomp $a; $b = (split (/”/, $a))[1]; } @getcert = `dsquery usern –name * -o upn –limit 1000`; foreach (@getcert) { $c = $_; chomp $c; $d = (split (/”/, $c))[1]; $e = (split (/@/, $d))[0]; }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Newbie Needs Help with Hash
by kyle (Abbot) on Sep 13, 2007 at 03:04 UTC | |
|
Re: Newbie Needs Help with Hash
by almut (Canon) on Sep 13, 2007 at 03:37 UTC | |
|
Re: Newbie Needs Help with Hash
by mayaTheCat (Scribe) on Sep 13, 2007 at 06:44 UTC | |
|
Re: Newbie Needs Help with Hash
by hangon (Deacon) on Sep 13, 2007 at 14:34 UTC |