Thanks @novinosrin . We learn something new every day! I checked out a previous post (https://communities.sas.com/t5/SAS-Programming/sql-count-using-case-when-group-by-inside-count/m-p/624905#M184140) using "id" but got an error. ERROR: The following columns were not found in the contributing tables: id. Could I get a reference on how to use "id" in PROC SQL? Thanks in advance. VR
... View more