Hi,
while defining constraints on dataset columns, like
proc datasets;
modify datasetname;
ic create i_reqd = check(where=(reqd in ('YES','NO'))) message = "Valid values for variable REQD are either 'YES' or 'NO'.";
quit;
The above defined constraint allows only YES & NO (uppercase values). how can I make it case insensitive.??.. that is user shd be able to enter (yes , no, YES, NO,Yes,No yEs,nO)
Can't you just include the upcase function? e.g.,
ic create i_reqd = check(where=(upcase(reqd) in ('YES','NO'))) message = "Valid values for variable REQD are either 'YES' or 'NO'.";
Can't you just include the upcase function? e.g.,
ic create i_reqd = check(where=(upcase(reqd) in ('YES','NO'))) message = "Valid values for variable REQD are either 'YES' or 'NO'.";
Yes , upcase is working... Thanks Arthur , you are Great!!
Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.
Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.
Learn how use the CAT functions in SAS to join values from multiple variables into a single value.
Find more tutorials on the SAS Users YouTube channel.