MeAnd23W_FamilyTree Table
The MeAnd23W_FamilyTree table stores the nodes of a 23andMe family tree. Each row is one person in the tree for a given profile — this includes relatives 23andMe has placed automatically as well as people the account owner has added or edited. A node may represent a DNA-tested relative (in which case it carries a profile_id) or an inferred ancestor with no test of their own.
The table is filled from two different 23andMe responses that are merged together by node_id: the tree structure itself (parents, partners, generations) and a separate set of annotations (names, married name, deceased and twin/adopted flags). Because of this, a single row is often built up from both sources.
Column Reference
Identifiers
| Column | Type | Description |
| Id | int (PK) | Auto-incrementing primary key |
| psid | string | The 23andMe profile ID being gathered (the logged-in user’s profile whose tree this node belongs to) |
| node_id | string | Tree node ID — the unique identifier of this person within the tree. Combined with psid it uniquely identifies the row. |
| annotation_id | string | Optional annotation ID linking the node to its annotation record (names and personal flags) |
| profile_id | string | 23andMe profile ID for DNA-tested relatives. Null for inferred relatives who have not tested. |
| created_date | string | When this record was created |
Person
| Column | Type | Description |
| sex | string | Sex of the person (nullable). Used to correct gender-specific relationship labels. |
| first_name | string | First name. Null for inferred relatives whose name is unknown. |
| last_name | string | Last name. Null for inferred relatives whose name is unknown. |
| married_name | string | Married name (from annotations) |
Relationships & generations
| Column | Type | Description |
| parent_ids | string | Comma-separated list of parent node IDs |
| partner_ids | string | Comma-separated list of partner node IDs |
| relationship_id | string | Relationship of this person to the logged-in user (e.g. a relationship label such as “grandfather”) |
| up | int | Number of generations up from the user (nullable) |
| down | int | Number of generations down from the user (nullable) |
| num_shared | int | Number of shared connections (nullable) |
Flags
| Column | Type | Description |
| verified | bool | Verified flag (nullable) |
| edited | bool | Edited flag (nullable) |
| added_by_user | bool | True if the node was added by the account owner rather than inferred by 23andMe (nullable) |
| deceased | bool | Deceased flag, from annotations (nullable) |
| is_identical_twin | bool | Identical twin flag, from annotations (nullable) |
| is_adopted | bool | Adopted flag, from annotations (nullable) |
How It’s Populated
Family-tree data is gathered for a profile and written one node at a time. Two responses feed this table:
- Tree structure — each tree node supplies
node_id, annotation_id, sex, first_name, last_name, relationship_id, profile_id, the verified / edited / added_by_user flags, the up / down / num_shared generation counts, and the parent_ids / partner_ids arrays (joined into comma-separated strings). When a female relative is returned with a male-form relationship label, the label is corrected before saving.
- Annotations — a second response provides names,
married_name, and the deceased, is_identical_twin, and is_adopted flags. Annotation rows do not carry a profile_id.
Each node is upserted on node_id + psid. When a node already exists, only non-null incoming fields are written (using COALESCE), so the tree-structure pass and the annotations pass merge into a single complete row without one overwriting the other’s data.
Related Tables
- MeAnd23W_Relatives — DNA-tested relatives; a tree node with a
profile_id corresponds to a relative here.
- MeAnd23W_Profiles — profiles gathered under the account, keyed by profile ID.
- MeAnd23W_Kit — the kits associated with the account.