From the course: SAS® 9.4 Cert Prep: Part 03 Exploring and Validating Data

Unlock this course with a free trial

Join today to access over 22,600 courses taught by industry experts.

Using special WHERE operators

Using special WHERE operators

- [Instructor] Let's talk about some special where operators that you can use in expressions. Suppose you want to filter your data by missing values. You could write an expression where a column is equal to a period for a numeric missing value or a space enclosed in quotation marks for a character missing value, but a simpler option is to use the is missing or is not missing special operator. This code can be used for either numeric or character missing values. If you happen to be working with data coming from a DBMS environment that distinguishes between missing and null values, there's also an is null operator. The between and operator is handy for numeric and character ranges. The endpoints of the range are inclusive. Finally, the like operator enables us to do pattern matching. The percent symbol is a wildcard for any number of characters and the underscore is a wildcard for a single character. In this example…

Contents