Problem Note 1101: MISSING function in WHERE clause generates error message
Beginning in Version 7 when using the MISSING function in a WHERE
clause, you may receive the following error message:
ERROR: Function MISSING requires a numeric expression as argument 1.
This message may be produced using either a WHERE statement or WHERE=
data set option. The DATA step below illustrates the problem:
data one;
x=.;
run;
data two;
set one;
where missing(x);
run;
A circumvention is to use an IF condition in place of the WHERE clause,
or the IS NULL/IS MISSING operator in place of the MISSING function.
Beginning in Release 8.1 you will no longer receive an ERROR message.
However, you will receive incorrect results when using the MISSING
function in a WHERE clause. The DATA step below illustrates the
incorrect results:
data one;
x=1; output;
x=.; output;
x=2; output;
run;
data two;
set one;
where missing(x);
run;
The incorrect results would be returning all observations in Data set
TWO on MVS and 2 observations on WIN/NT.
The above circumvention is still applicable in Release 8.1.
The problem has been corrected in Release 8.2.
Operating System and Release Information
| Product Family | Product | System | Reported Release | Fixed Release* |
| SAS System | Base SAS | Microsoft Windows NT Workstation | 8 TS M0 | 8.2 TS2M0 |
| Microsoft Windows 2000 Professional | 8.1 TS1M0 | 8.2 TS2M0 |
| Microsoft Windows 95/98 | 8 TS M0 | 8.2 TS2M0 |
| Microsoft Windows 2000 Server | 8.1 TS1M0 | 8.2 TS2M0 |
| Microsoft Windows 2000 Advanced Server | 8.1 TS1M0 | 8.2 TS2M0 |
| Microsoft Windows 2000 Datacenter Server | 8.1 TS1M0 | 8.2 TS2M0 |
| OpenVMS VAX | 8 TS M0 | 8.2 TS2M0 |
| 64-bit Enabled Solaris | 8 TS M0 | 8.2 TS2M0 |
| Solaris | 8 TS M0 | 8.2 TS2M0 |
| OS/2 | 8 TS M0 | 8.2 TS2M0 |
| IRIX | 8.1 TS1M0 | 8.2 TS2M0 |
| z/OS | 8 TS M0 | 8.2 TS2M0 |
| HP-UX | 8 TS M0 | 8.2 TS2M0 |
| CMS | 8 TS M0 | 8.2 TS2M0 |
| 64-bit Enabled HP-UX | 8 TS M0 | 8.2 TS2M0 |
| 64-bit Enabled AIX | 8 TS M0 | 8.2 TS2M0 |
| OpenVMS Alpha | 8 TS M0 | 8.2 TS2M0 |
| Tru64 UNIX | 8 TS M0 | 8.2 TS2M0 |
| AIX | 8 TS M0 | 8.2 TS2M0 |
*
For software releases that are not yet generally available, the Fixed
Release is the software release in which the problem is planned to be
fixed.
| Type: | Problem Note |
| Priority: | high |
| Date Modified: | 2001-05-24 12:41:04 |
| Date Created: | 1999-09-07 00:00:00 |