The transgenic wheat line N12-1 containing the WYMV-Nib8 gene was obtained previously through particle bombardment, and it can effectively control the wheat yellow mosaic virus (WYMV) disease transmitted by Polymyxa graminis at turngreen stage. Due to insertion of an exogenous gene, the transcriptome of wheat may be altered and affect root exudates. Thus, it is important to investigate the potential environmental risk of transgenic wheat before commercial release because of potential undesirable ecological side effects. Our 2-year study at two different experimental locations was performed to analyze the impact of transgenic wheat N12-1 on bacterial and fungal community diversity in rhizosphere soil using polymerase chain reaction-denaturing gel gradient electrophoresis (PCR-DGGE) at four growth stages (seeding stage, turngreen stage, grain-filling stage, and maturing stage). We also explored the activities of urease, sucrase and dehydrogenase in rhizosphere soil. The results showed that there was little difference in bacterial and fungal community diversity in rhizosphere soil between N12-1 and its recipient Y158 by comparing Shannon's, Simpson's diversity index and evenness (except at one or two growth stages). Regarding enzyme activity, only one significant difference was found during the maturing stage at Xinxiang in 2011 for dehydrogenase. Significant growth stage variation was observed during 2 years at two experimental locations for both soil microbial community diversity and enzyme activity. Analysis of bands from the gel for fungal community diversity showed that the majority of fungi were uncultured. The results of this study suggested that virus-resistant transgenic wheat had no adverse impact on microbial community diversity and enzyme activity in rhizosphere soil during 2 continuous years at two different experimental locations. This study provides a theoretical basis for environmental impact monitoring of transgenic wheat when the introduced gene is derived from a virus.