background image
<< Rational Test uses to compute random values | Example of Datapool Value Generation >>
<< Rational Test uses to compute random values | Example of Datapool Value Generation >>

Example of Datapool Column Definition

314
Chapter 11 - Working with Datapools
Example of Datapool Column Definition
Suppose you want to record a transaction in which a customer purchase is entered
into a database. During recording, you supply the client application with the
following information about the customer:
s
Customer name
s
Customer ID
s
Credit card number
s
Credit card type
s
Credit card expiration date
After you record the test script, create the datapool. Define the datapool's columns in
the Datapool Specification dialog box, as illustrated in the following figure:
The following are some highlights of the datapool column you have chosen:
s
fName
column. The standard data type Names
­
First supplies this datapool
column with masculine and feminine first names.
s
lName
column. The standard data type Names
­
Last supplies this datapool
column with surnames.
s
custID
column. The standard data type Integer
­
Signed supplies ID numbers to
this datapool column. Because all customer IDs in this example consist of seven
digits, the
Minimum
and
Maximum
range is set from 1000000 through 9999999. Also,
because all IDs must be unique,
Sequence
is set to Unique.
Note: Sequence
can only be set to Unique for Integer
­
Signed data types.
Generate 1000
datapool rows
The only user-defined data
type needed
Date range
Float data type with 0
decimals is used for
credit card numbers
Customer ID is unique
Datapool
column 1