I have created a dummy variable in SAS, that in any given year takes the value 1 if both countries are members of the EMU and 0 otherwise in that year.
emu1=0;
if country1 in ("AUT","BEL","FIN","FRA","DEU","IRL","ITA","NLD","PRT","ESP") and year>1998 then emu1=1;
if country1 in ("GRC") and...