A primary key is a variable in a dataset that has a unique value for every row. A variable must be either numeric or text type and have no duplicate or missing values. A primary key on a dataset causes updates to that dataset that have the rows with the same primary key value(s) as the first dataset to update the existing rows rather than inserting new ones.
# S4 method for CrunchDataset
pk(x)# S4 method for CrunchDataset
pk(x) <- value
a Dataset
For the setter, a single Variable to use as the primary key or NULL
to remove the primary key.
Getter returns the Variable object that is used as the primary key (NULL
if there is no primary key); setter
returns x
duly modified.