No description
Find a file
Kacper Kula 939c6dfe2d feat: add TAGS() macro and auto-detection for multi-tag AND queries
Introduces two complementary solutions for the common mistake of filtering
by multiple tags with AND (which always returns zero results):

1. TAGS() macro: explicit opt-in syntax
   WHERE TAGS('#project', '#active')
   → path IN (SELECT path FROM tags WHERE tag = '#project'
              INTERSECT SELECT path FROM tags WHERE tag = '#active')

2. Auto-detection: transparently rewrites the broken pattern
   WHERE tag = '#a' AND tag = '#b'
   → path IN (...INTERSECT...)
   Mixed conditions (AND name = 'test') are preserved correctly.

Both use INTERSECT subqueries which are more flexible than an EXISTS
approach (no hardcoded table reference required).

Adds disableTagAutoDetection setting so advanced users can opt out of
the transparent rewrite and handle the SQL themselves.

Docs updated in query-vault-content.md and faq/understanding-tags.md.
2026-03-22 22:42:30 +00:00
.changeset release: Release Next (#192) 2025-09-18 11:21:12 +01:00
.github docs: added documentation for charts (#165) 2025-06-04 16:16:56 +01:00
docs feat: add TAGS() macro and auto-detection for multi-tag AND queries 2026-03-22 22:42:30 +00:00
scripts chore: adding checks to skip when version exists 2025-05-22 14:23:55 +01:00
src feat: add TAGS() macro and auto-detection for multi-tag AND queries 2026-03-22 22:42:30 +00:00
types-package Refactoring Project to use proper Inversion of Control (#171) 2025-08-10 09:34:54 +01:00
.editorconfig chore: initial version 2024-04-19 15:53:50 +01:00
.eslintignore chore: initial version 2024-04-19 15:53:50 +01:00
.eslintrc chore: initial version 2024-04-19 15:53:50 +01:00
.gitignore chore: splitting styles into separate SCSS files 2025-05-17 19:24:49 +01:00
.npmrc chore: initial version 2024-04-19 15:53:50 +01:00
.prettierrc mvp 2024-04-30 22:52:52 +01:00
CHANGELOG.md release: Release Next (#192) 2025-09-18 11:21:12 +01:00
CONTRIBUTING.md chore: added contributing guide and missing package 2025-05-22 11:30:19 +01:00
esbuild.config.mjs Feat/global tables new (#173) 2025-08-10 10:01:08 +01:00
jest.config.js feat: reworking communication to signals and fixing issues with some keys 2024-11-03 00:28:09 +00:00
LICENSE Create LICENSE 2024-05-06 17:43:49 +01:00
manifest.json release: Release Next (#192) 2025-09-18 11:21:12 +01:00
package.json release: Release Next (#192) 2025-09-18 11:21:12 +01:00
pnpm-lock.yaml feat: updating how modules are being defined (using new version of DITY) (#191) 2025-09-18 11:18:22 +01:00
README.md Variable editor in SQLSeal Explorer (#185) 2025-08-15 14:57:27 +01:00
tsconfig.json Refactoring Project to use proper Inversion of Control (#171) 2025-08-10 09:34:54 +01:00
version-bump.mjs chore: initial version 2024-04-19 15:53:50 +01:00
versions.json release: Release Next (#192) 2025-09-18 11:21:12 +01:00

Obsidian SQLSeal

SQLSeal allow you to query for files, tags and tasks in your vault using familar SQL syntax. It also enables you to preview any CSV file in your vault as a database. It brings fully featured database into your vault!

Installation

You can install plugin from the Community Plugins directly from Obsidian, just look for SQLSeal in the marketplace.

Manual Instalation

To manually install the package, open Releases and download .zip of the last one. Unzip it in your vault under .obsidian/Plugins/sqlseal.

Usage

Once you install the plugin, you can use it by creating sqlseal codeblocks in your notes. To create table base on the existing CSV file in your vault simply address it using the following command:

TABLE transactions = file(transactions.csv)

SELECT * FROM transactions LIMIT 10

The code above will create table called transactions based on the transactions.csv file from your vault. Further you can refer to it using regular SELECT statements. You can define multiple tables in a single snippet. You can also point to the tables defined in different snippets within the same note (for now tables stay local to the file).

For more comprehensive documentation head to hypersphere.blog/sql-seal.

Disclaimer

The plugin authors do not take any responsibility for any potential data loss. Always backup your files before usage. This plugin may modify files in your vault in the following situations (the list might not be exhaustive):

  • .sql and .sqlseal files: Variable values are saved as comments at the end of these files
  • Markdown files: When interacting with task using tasks table, the plugin will update source markdown files.

Please ensure you have proper backups before using this plugin.

Stay in Touch!

If you have any questions about the project, ideas or want to share your use-cases, join our Discord Channel!