You could create keys in a hash table on startup for each group of the ini. Add the relevant item as value of the key. Then you can loop through all the keys and for every key that matches the value you could spawn a dummy sprite with a PV that equals the keyname. Now you can pick a random dummy sprite and will therefore have selected a random group that matches.
EDIT: Or instead of creating those sprites just add the keyname to a string with a divider attached. And then pick one by random with Gettoken(Random(Numtokens)+1) or something of the sort.
It doesn't seem very clever to me right now, but that's the only thing I could think of on top of my head . And seeing that you haven't got any replies yet I thought I'd share.
Oh, and if you already found a better solution please post!