If your dependent is a qualifying child, then they are not a qualifying relative. Most dependents are defined as a qualifying child. The short definition of a qualifying child is a child who is your relative who is under age 19 (or age 24 if a student).
A qualifying relative is someone who does not meet the definition of a qualifying child and who meets the following criteria:
Is your son, daughter, stepchild, foster child, grandchild, brother, sister, niece, nephew, father, mother, grandmother, grandfather, great-grandparent, aunt, uncle, stepbrother, stepsister, stepfather, stepmother, son-in-law, daughter-in-law, father-in-law, mother-in-law, brother-in-law, sister-in-law, or any other person other than your spouse who lived with you all year as a member of your household. The dependent must have had a gross income of less than $4,150 during 2018. You and one or more other eligible persons together must have paid over half the dependent's support.