3.1 KiB
3.1 KiB
title, category, type, source, date, tags
| title | category | type | source | date | tags | |||||
|---|---|---|---|---|---|---|---|---|---|---|
| Obsidian Dataview | Summary | Tool/Plugin | https://github.com/blacksmithgu/obsidian-dataview | 2026-02-23 |
|
Obsidian Dataview
URL: https://github.com/blacksmithgu/obsidian-dataview
Description: A data index and query language over Markdown files for Obsidian
Date Summarized: 2026-02-24
tl;dr
Treat your Obsidian Vault as a database that you can query. Query, filter, sort, and extract data from Markdown pages using YAML frontmatter and inline fields.
What It Does
Dataview generates data from your vault by pulling information from:
- Markdown Frontmatter — YAML at the top of documents:
---
alias: "document"
last-reviewed: 2021-08-17
rating: 8
status: active
---
- Inline Fields — Key:: Value syntax in documents:
Basic Field:: Value
**Bold Field**:: Nice!
You can also write [field:: inline fields]
(field2:: hidden field)
Query Modes
1. Dataview Query Language (DQL)
Pipeline-based, SQL-like expressions:
TABLE file.name AS "File", rating AS "Rating"
FROM #book
SORT rating DESC
2. Inline Expressions
Embed directly in markdown:
= this.file.name → shows filename
3. DataviewJS
JavaScript for complex logic:
for (let group of dv.pages("#book")
.where(p => p["time-read"].year == 2021)
.groupBy(p => p.genre)) {
dv.header(3, group.key);
dv.table(["Name", "Rating"], group.rows
.sort(k => k.rating, 'desc')
.map(k => [k.file.link, k.rating]))
}
Example Use Cases
Table of games with metadata:
TABLE time-played, length, rating
FROM "games"
SORT rating DESC
List by tags:
LIST FROM #game/moba or #game/crpg
Tasks from active projects:
TASK FROM #projects/active
Books read in 2021, grouped by genre:
for (let group of dv.pages("#book")
.where(p => p["time-read"].year == 2021)
.groupBy(p => p.genre)) {
dv.header(3, group.key);
dv.table(["Name", "Time Read", "Rating"],
group.rows.sort(k => k.rating, 'desc')
.map(k => [k.file.link, k["time-read"], k.rating]))
}
Key Features
- ✅ Query any Markdown files in your vault
- ✅ Filter by tags, folders, metadata
- ✅ Sort by any field
- ✅ Group results
- ✅ Render as tables, lists, or tasks
- ✅ JavaScript API for complex logic
- ✅ Inline fields for hidden metadata
- ✅ Automatic data index updates
Potential Uses for Corey's Vault
- Home Assistant Automations Table — Query all automations by status
- Projects Dashboard — Active vs completed projects
- Daily Notes Query — Recent entries, completed tasks
- Research Summaries — All
/summarizeoutputs by date - Cron Jobs Status — Active vs disabled jobs
Installation
Available in Obsidian Community Plugins:
- Settings → Community Plugins → Browse
- Search "Dataview"
- Install & Enable
Full Docs: https://blacksmithgu.github.io/obsidian-dataview/