Library Item Function

The library is a set of predefined tables. Each table contains well-known data like cities, names or countries.
$Lib or $Library function can be used to add these data sets to generated data.

The function has the following parameters:

  1. Data set name. String.
  2. (optional) Column Name. String, default is 'Name'.
  3. (optional) Maximum acceptable length. Integer. Default value is 0 that means 'do not check'.
  4. (optional) Use data sequentially. Integer. Default value is 0 that means 'random'.
  5. (optional) Where clause. String, default value is empty that means 'all rows'.

Examples

$Lib(Cities) - use all cities.
$Lib(Cities,Name,10,1) - use cities with name shorter 11 symbols sequentially (A to Z).
$Lib(Cities,Name,0,0,State='Ohio') - use cities where "State" is 'Ohio'.

Note: you can use @'column name' in you 'where' parameter if referred column is located before this.
For example, if you have 'State' and 'City' columns the following call is acceptable:
$Lib(Cities,Name,0,0,State='@'State' ')

See also: library.