if I am correct you are using two queries for fetching data from db.
use this nested query, it will save the database connection effort and nested while loop
SELECT * FROM snomed_descriptiondata WHERE conceptid in (SELECT id FROM snomed_conceptdata WHERE active=1) AND active=1