Rand Functions

I would like to ask if it is safe to use the random function with the callerid function?I’m trying to manipulate the CLID and using both SET adn the random functions. I was able to make a sucessful callerid manipulation on CLID random selection of DID.But there is one problem that I had. I wanted that manipulate the CLID using the random but I wanted the when the CLID was already in use the it should not have duplicate CLID instead reassigned new CLID.

Is this possible.


Best regards.