As already suggested you could use the appropriate informat to convert the date strings to SAS Date values (count of days since 1/1/1960 stored in a numerical variable).
For your date and partial date strings informat b8601da. appears to do the job. Partial dates will get aligned to the beginning of what's available (=beginning of month or beginning of year).
data demo;
infile datalines truncover dlm=' ';
input dt_string_1:$8. dt_string_2:$8.;
sas_dt_1=input(dt_string_1,b8601da.);
sas_dt_2=input(dt_string_2,b8601da.);
min_date=min(sas_dt_1,sas_dt_2);
format sas_dt_1 sas_dt_2 min_date yymmdd10.;
datalines;
202108 20211201
202112 20210824
2021 20210824
;
proc print data=demo;
run;
... View more