![]() |
PING
0.9
Statistical data handling and processing in production environment
|
Create a working copy of a given dataset.
%ds_working(idsn, odsn, mirror=LIKE, where=, groupby=, having=, ilib=);
idsn : a dataset reference;mirror : (option) type of copy operation used for creating the working dataset, i.e. either an actual copy of the table (mirror=COPY) or simply a shaping of its structure (mirror=LIKE); default: mirror=LIKE;groupby, where, having : (option) expressions used to refine the selection when mirror=COPY, like in a SELECT statement of PROC SQL (GROUP BY, WHERE, HAVING clauses); these options are therefore incompatible with mirror=LIKE; note that where and having should be passed with %quote; see also %ds_select; default: empty;ilib : (option) name of the input library; by default: empty, i.e. WORK is used.odsn : name of the output dataset (in WORK library) where a copy of the original dataset or its structure is stored.
For instance, we can run:
%ds_working(idsn, odsn, mirror=COPY, where=%quote(var=1000));
so as to retrieve:
See %_example_ds_working for more examples.
The command ds_working(idsn, odsn, mirror=COPY, ilib=ilib) consists in running:
while the command ds_working(idsn, odsn, mirror=LIKE, ilib=ilib) is equivalent to: