Worried parents can breathe a little easier today, after results of a study were released that suggest that not all teens who have sex have lower grades as a result.

Presented on Sunday at the American Sociological Association conference in Atlanta, the results found that if students have sex within a committed relationship, there is no resulting effect on grades. However, if students simply “hook up” and have casual sex, their grades do tend to be lower, according to the Associated Press. Researchers say the type of relationship matters, since a close relationship also provides emotional support, while having casual partners may increase stress.

These findings challenge conventional notions that having sex at a younger age affects academic performance. The study may cast a new light on sex education in schools, which some experts now say ought to emphasize the importance of relationships and warn students about casual sex.