More explicitly, the UK's regulator says: "You should however note that if this ‘inferred’ or ‘derived’ data is personal data, you still need to provide it to an individual if they make a subject access request."
if (dob.month == december) $birthstone = quartz
select advert from adverts where stone = $birthstone
Or whatever