Here is a project method that can be used to fill a test table with random string data. In this example, the database contains a table [SourceStrings] with a single string field "FiftySixChars". Every time the method below is executed, $numCreated random text strings will be created. The random characters are selected from ASCII codes 33 (exclamation point) to 126 (tilde) and include upper and lower case characters and punctuation, but no white space. The resulting random strings are not very legible but can be useful for stress-testing or performance benchmarks where a large number of records are needed.
Cut and Paste the following code example into your
own 4D project
CONFIRM("Add "+String($numCreated)+" random strings to [SourceStrings]?")
$message:="Created "+String($numCreated)+" random strings of length "
$message:=$message+String($stringLength)+" in [SourceStrings]."