Randomly? Is this to anonymize data? To have a placeholder ID for any name, that isn't the real personid, userid or employeeid?
You could easily [tt]SELECT Name, Cast(0 as integer) as id from employees INTO CURSOR crsRandomized READWRITE[/tt] then populate id with random numbers. As you showed IDs are not even necessarily 1-400, but even higher, you could use something like RAND()*10000. Use a candidate index to enforce any ID to be unique, if an UPDATE triggers an index error simply repeat it, creating another random number.
Bye, Olaf.