BackgroundUnderstanding the mechanisms of drug resistance can facilitate better management of antiretroviral therapy, helping to prevent transmission and decrease the morbidity and mortality of people living with HIV/AIDS. However, there is little data about transmitted drug resistance and acquired drug resistance for HIV/AIDS patients in Shanghai.MethodsA retrospective cohort study of HIV-infected patients who visited the Department of Infectious Disease from June 2008 to June 2015 was conducted in Shanghai, China. Logistic regression analysis was performed to analyze risk factors for drug resistance among HIV-infected people with virological failure. The related collected factors included patient age, gender, marital status, infection route, baseline CD4 count, antiretroviral therapy regimens, time between HIV diagnosis and initiating antiretroviral therapy. Factors with p<0.1 in the univariate logistic regression test were analyzed by multivariate logistic regression test.ResultsThere were 575 subjects selected for this study and 369 participated in this research. For the antiretroviral therapy drugs, the rates of transmitted drug resistance and acquired drug resistance were significantly different. The non-nucleoside reverse transcriptase inhibitor (NNRTI) had the highest drug resistance rate (transmitted drug resistance, 10.9%; acquired drug resistance, 53.3%) and protease inhibitors (PIs) had the lowest drug resistance rate (transmitted drug resistance, 1.7%; acquired drug resistance, 2.7%). Logistic regression analysis found no factors that were related to drug resistance except marital status (married status for tenofovir: odds ratio = 6.345, 95% confidence interval = 1.553–25.921, P = 0.010) and the time span between HIV diagnosis and initiating antiretroviral therapy (≤6M for stavudine: odds ratio = 0.271, 95% confidence interval = 0.086–0.850, P = 0.025; ≤6M for didanosine: odds ratio = 0.284, 95% confidence interval = 0.096–0.842, P = 0.023; ≤6M for tenofovir: odds ratio = 0.079, 95% confidence interval = 0.018–0.350,P<0.001).ConclusionNNRTI had a higher DR rate compared with nucleoside reverse transcriptase inhibitor (NRTI) and PIs, consequently, LPV/r was a reasonable choice for patients with NNRTI drugs resistance in China. Only married status and a time span≤6 month between the HIV confirmed date and the time initiating antiretroviral therapy were risk factors for TDF drug resistance. Both baseline HIV-RNA load and resistance test is crucial for TDR diagnosis, and frequent monitoring of HIV-RNA load is crucial for ADR identification and intervention. Treatment adherence still plays a positive role on the outcome of ART.