Property Graphs vs RDF Triples
What you'll learn: How the two main graph data models—property graphs and RDF triples—differ in structure and usage.
Two Ways to Model Connected Data
Graph databases use two primary models to represent relationships: property graphs and RDF triple stores. While both excel at connected data, they structure information differently.
Property Graph Model
A property graph consists of:
- Nodes (entities) with labels and key-value properties
- Edges (relationships) that are also first-class citizens with types and properties
- Multiple properties attached directly to both nodes and edges
Think of a social network: a Person node might have properties like name: "Alice" and age: 30, connected by a FRIENDS_WITH edge that has a since: 2020 property.
RDF Triple Model
RDF (Resource Description Framework) structures data as triples:
- Subject (the thing)
- Predicate (the relationship)
- Object (the value or another thing)
Each statement is atomic: (Alice, friendsWith, Bob) or (Alice, hasAge, 30). Properties become separate triples rather than being embedded in entities.
Key Differences
| Aspect | Property Graph | RDF Triples |
|---|---|---|
| Structure | Rich nodes/edges with properties | Simple subject-predicate-object |
| Edge properties | Native support | Requires reification (extra nodes) |
| Standards | Implementation-specific | W3C standards (RDF, SPARQL) |
| Typical use | Application graphs, recommendations | Knowledge graphs, semantic web |
Property graphs feel more intuitive for application development—you can directly attach metadata to relationships. RDF excels at data integration and formal semantics, where standardized vocabularies matter.
Key Takeaway: Property graphs store rich properties on nodes and edges directly, while RDF triple stores decompose all data into atomic subject-predicate-object statements—choose based on whether you need application flexibility or semantic web standards.