As the first barrier of flood control, the integrity and continuity of dams are of the utmost importance. However, with the influence of natural weathering, running water erosion, and humanistic factors, various degrees of damage are prone to occur inside and outside dams. Therefore, it is necessary to detect the integrity of dams and evaluate their flood control capacity. Different from the previous detection of water-filled imperfect areas, we used numerical simulation and measured data analysis and considered the influence of actual noise to conduct DC resistivity detection and 2D inversion research on the high-resistivity imperfect areas existing in dams. The research results show that both the calculated apparent resistivity and the resistivity obtained by 2D inversion deviate from the real resistivity of the dam. A dam with a height less than 5 m has a relatively small influence on the 2D inversion results of the DC resistivity method, and the inversion results can accurately show the spatial information of the high-resistivity imperfect areas. The distance between the river and dam has a major influence on the inversion results, but the influence on the inversion results can be ignored when the distance is greater than 20 m in the model of this paper. The 2D inversion of the DC resistivity method can be used to detect high-resistivity imperfect areas of dams, and the 2D spatial information of the 3D geological bodies can be accurately obtained.