Hallo Zusammen,
vielleicht hat jemand von euch eine Lösung!
Ich habe ein Array aus folgender Function!
$aObjects = _AD_GetObjectsInOU("OU=User,OU="&$aOUs[$x]&",DC=Domäne,DC=int", "(&(objectcategory=person)(objectclass=user)(mail=*)(userAccountControl=512))", 2, "sAMAccountName,mail,company")
im array stehen jetzt die werte "sAMAccountName,mail,company"
unter Company steht jetzt für jeden User ein eintrag Beispiel wie folgt:
user1 Firma1
user2 Firma1
user3 Firma1
user4 Firma2
user5 Firma2
user6 Firma1
user7 Firma3
user8 Firma3
user9 Firma2
wie kann ich jetzt die company einträge zählen?
als ergebnis sollte herauskommen:
Firma1 = 4
Firma2 = 3
Firma3 = 2
Gruß gmmg