An N,N-bis(p-methoxybenzyl)-protected a a a-acetyl-a a a-diazomethane sulfonamide proved to be a useful building block for accessing new 5-methyl-1,2,3-thiadiazole-4-sulfonamide as well as methyl 3-sulfamoyl-1H-pyrazole-5-carboxylate. The latter was further subjected to N-alkylation and N-arylation reactions. All resulting compounds showed potent inhibition of I, II and particularly of cancer-related IX and XII isoforms of human carbonic anhydrase.