An aromatic nitrogen-containing 6-membered cyclic compound of the formula (I): <;CHEM>; wherein Ring A is a substituted or unsubstituted nitrogen-containing heterocyclic group; R<;1>; is a substituted or unsubstituted lower alkyl group, -NH-Q-R<;3>; (R<;3>; is a substituted or unsubstituted nitrogen containing heterocyclic group, and Q is a lower alkylene group or a single bond), or -NH-R<;4>; (R<;4>; is a substituted or unsubstituted cycloalkyl group); R<;2>; is a substituted or unsubstituted aryl group; one of Y and Z is =CH-, and the other is =N-, or a pharmaceutically acceptable salt thereof, these compounds exhibiting excellent selective PDE V inhibitory activities, and hence, being useful in the prophylaxis or treatment of penile erectile dysfunction, etc.