🔒 This topic is solved and locked.
Need further help from the community? Please
sign in and ask a new question.
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
Posted 03-29-2017 02:28 AM
(1393 views)
Hello,
I have the following code:
proc means data=sasuser.sasfile010916 mean median std min max;
where firmdefi=1 and firmdefi=2;
var equity TAssets Sales;
class firmdefi;
run;
The log indicate NOTE: No observations were selected from data set SASUSER.SASFILE010916.
There is data that relate to firmdefi 1 or 2 and I do not understand what is my mistake?
Thanks for any help!!!
1 ACCEPTED SOLUTION
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
Logically, it is not possible for FIRMDEFI to equal 1 and 2 at the same time. Instead of using AND, your WHERE statement could switch to OR. Alternatively:
where firmdefi in (1, 2);
1 REPLY 1
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
Logically, it is not possible for FIRMDEFI to equal 1 and 2 at the same time. Instead of using AND, your WHERE statement could switch to OR. Alternatively:
where firmdefi in (1, 2);