Sometimes a data step should only be executed if one or more variables are present in the input dataset. The same is true of statements within data steps. This paper provides several macros to detect the presence of variables and counts of the present variables. Examples show how these macros can be used to accomplish conditional execution for many scenarios. These macros have the advantage of only using macro statements, thus avoiding the costs of opening datasets.