Specifies the number
of threads to be used for WHERE clause evaluations.
Default: THREADNUM= is set equal to the value of the MAXWHTHREADS server parameter.
Used in
Conjunction with SPD Server Parameter
Corresponding
Macro Variable
Arguments
is the number of threads.
THREADNUM= allows you
to specify the thread count the SPD Server should use when performing
a parallel WHERE clause evaluation.
Use this option to explore
scalability for WHERE clause and GROUP_BY evaluations in non-production
jobs. If you use this option for production jobs, you are likely
to lower the level of parallelism that is applied to those clause
evaluations.
THREADNUM= works in
conjunction with MAXWHTHREADS, a configurable system parameter. MAXWHTHREADS
imposes an upper limit on the consumption of system resources. The
default value of MAXWHTHREADS is dependent on your operating system.
Your SPD Server administrator can change the default value for MAXWHTHREADS.
If you do not use THREADNUM=,
the software provides a default thread number, up to the value of
MAXWHTHREADS as required. If you use THREADNUM=, the value that you
specify is also constrained by the MAXWHTHREADS value.
The THREADNUM= value
applies both to parallel table scans (EVAL2 strategy), parallel indexed
evaluations (EVAL1 strategy), parallel BY-clause processing, and parallel
GROUP_BY evaluations. See the
SAS Scalable Performance
Data (SPD) Server 4.5: User's Guide for more information
about
Optimizing WHERE Clauses.
The SPD Server administrator
set MAXWHTHREADS=128 in the SAS Scalable Performance Data (SPD) Server's
parameter file. Explore the effects of parallelism on a given query
by using the following SAS macro:
%macro dotest(maxthr);
%do nthr=1 %to &maxthr
data _null_;
set SPDSCEN.PRECS(threadnum=&nthr);
WHERE
occup='022'
and state in('37','03','06','36');
run;
%mend dotest;