To improve the performance of current solder joint inspection method, an efficient method based on statistical learning is proposed in this paper. In the method, the solder was divided into several sub-regions to determine the defect type. To resolve imbalance problem, an improved over-sampling algorithm was proposed in which the synthetics samples are generated between the boundary samples and their neighbors. AdaBoost was used for feature selection and classification for every sub-region. Experiments results showed that the defects of solder joints can be identified properly using the proposed algorithm.