A 54-year-old male student shoved the young woman against a wall at the Mathematics and Social Sciences Building near 16th and C streets, according to a statement issued by the San Diego Community College District.
The woman, whose name was not released, was taken to UCSD Medical Center for treatment. Her injuries were not life-threatening, the statement said.
San Diego police originally reported that the woman had been stabbed in a parking structure on campus.
Students who saw the attack tackled the man and held him until police arrived.