We are trying to figure out how to pull random names from our data sheet. We have a column of first names and a column of last names. We are trying to be so random the same name should not appear for some time as there are extra warnings in the system to prevent duplicate names.
Here is the code we used;
set myDB to (file:ResourcePath(“Data.xlsx”), type:“excel”, writeable:“Yes”)
set Patientdata to the records of table (“PTData”) of mydb
repeat with each patient of Patientdata
put (item 1 of patient.fname, item 100 of patient.fname) into fnameR
typetext any item of fnameR, return
end repeat
Eggplant would certainly pull random names from the list but would go down in the order on the list and skip some of the name which would come up as a blank. Is there a way to pull a list of random names without the skipping?
I have seen some scripts online to create names but would the names generated be scrambled letters instead of names?