NOVELTY - Nitrogen-containing heterocyclic compound (I) or its salt is new.    USE - The nitrogen-containing heterocyclic compound or its salt is useful as germicide in agriculture and horticulture (claimed) for preventing fungal infection in crops such as apple, sugar beet, peanut, cucumber, rice, wheat, citrus and grape, where the fungus include Venturia inaequalis, Cercospora beticola, Mycosphaerella arachidis, Cladosporium cucumerinum, Botrytis cinerea, Corynespora cassicola, Pyricularia oryzae, Puccinia recondita, Penicillium italicum and Plasmopara viticola.    ADVANTAGE - The nitrogen-containing heterocyclic compound does not produce drug-induced damage in plants, and exhibit less toxic effects with respect to animals and environment.    DETAILED DESCRIPTION - Nitrogen-containing heterocyclic compound of formula (I) or its salt is new.    R1,R2,R8,R9=H, halo, 1-20C alkyl, 1-20C haloalkyl, 2-20C alkenyl, 2-20C haloalkenyl, 2-20C alkynyl, 2-20C haloalkynyl, 1-20C alkoxy, 1-20C haloalkoxy, 3-20C cycloalkyl, 4-20C cycloalkenyl, 8-20C cyclo alkynyl, 1-20C acyl, or 1-20C alkoxycarbonyl, and R1 and R2, and R8 and R9 optionally form 5-8 membered ring having (un)substituted group;    R3-R6=H, halo, 1-20C alkyl, 1-20C haloalkyl, 2-20C alkenyl, 2-20C haloalkenyl, 2-20C alkynyl, 2-20C haloalkynyl, 1-20C alkoxy, 1-20C haloalkoxy, 3-20C cycloalkyl, 3-20C cyclo alkoxy, 2-20C alkenyloxy, 2-20C alkynyloxy, 1-20C alkylthio, cyano, nitro, amino having (un)substituted group, aryl having (un)substituted group, aralkyl having (un)substituted group, aryloxy having (un)substituted group, or heterocyclyl having (un)substituted group, and R4 and R5, and R5 and R6 optionally form 5-8 membered ring having (un)substituted group;    R7=H, halo, hydroxyl, 1-20C alkyl, 1-20C haloalkyl, 2-20C alkenyl, 2-20C haloalkenyl, 2-20C alkynyl, 2-20C haloalkynyl, 1-20C alkoxy, 1-20C haloalkoxy, 3-20C cycloalkyl, 3-20C cycloalkoxy, 2-20C alkenyloxy, 2-20C alkynyloxy, 1-20C alkylthio, or cyano group;    X=hydroxyl, organic group, halo, nitro, or amino having (un)substituted group;    n=0-4;    Z=oxygen atom, sulfur atom and group of formula: CR8R9 or NR10;and    R10=H, 1-20C alkyl, 2-20C alkenyl, 2-20C alkynyl, 1-20C acyl, 1-20C alkoxycarbonyl, 1-20C alkylsulfonyl, 1-20C alkoxy 1-20C alkyl, 2-20C acyloxy 1-20C alkyl, aminocarbonyl group having (un)substituted group, arylsulfonyl having (un)substituted group, or amino sulfonyl having (un)substituted group.