Enables creating databases based on files in Obsidian - like Dataview, but with editing!

Overview

Obsidian Database Plugin

Do you like Dataview plugin for Obsidian? This one is taking Dataview to next level, but not only allowing you to view the data, but also... edit it in place!

Features

  • allows you to generate a table based on files in a directory
  • the table is editable, if you edit a cell the changes will be written to original file!
  • supports multiple types of data, including rating with stars and progress bars
  • supports sorting by multiple columns (including dynamic sorting by clicking on column header)
  • supports creating links between documents (the real ones, shown on graph)

Example

Let's create a database of motorcycles offers you consider buying.

  1. create directory called motorcycles
  2. create a file with a table:
```databaseTable
sources:
- type: directory
  path: motorcycles
fields:
- name: file
  type: fileName
  label: File
  width: 20%
- name: brand
  label: Brand
  type: link
  sources:
  - type: directory
    path: brands
- name: model # field name in frontmatter
  label: Model # display label
- name: year
  label: Year
- name: mileage
  label: Mileage
- name: accessories
  label: Accessories
  type: dropdown
  multiple: true
  options:
  - label: Crash bars
    value: crash-bars
  - label: Bags
    value: bags
  - label: Cruise control
    value: cruise-control
  - name: rate
    label: Rate
    type: rating
    width: 10%
  - name: owned
    label: Owned
    type: checkbox
\```

(replace final line with triple ` )

  1. now, create some files inside directory motorcycles (and if you want autosuggest for Brand field then create some files in brands folder), they can be blank or you can put some sample frontmatter matching name in the list above
  2. after you go back to a file with a table, you should see entries for newly created files
  3. you can put data in the table now and they will be filled inside the files!

Sample view

Sources

There are the following sources available:

directory

Reads all files from specified directory.

Example usage:

sources:
- type: directory
  path: motorcycles

tags

Reads all files with one of the tags specified.

Example usage:

sources:
- type: tags
  tags:
  - motorcycles

Field types

The plugin, at the moment, supports the following field types:

fileName

Generates clickable link with filename.

filePath

Generates clickable link with full file path (relative to vault root).

link

This type generates a block with links in the target documents, you can add multiple: true to link to multiple documents.

To enable autocomplete you need to add source parameter:

- name: brand
  label: Brand
  type: link
  sources:
  - type: directory
    path: brands

This way the plugin searches brands directory and suggest linking to any file within that directory.

rating

Shows 5 stars control for providing a rating.

progress

Shows a slider that you can use to set the progress (0-100%).

checkbox

Simple checkbox with true/false values

dropdown

Generates a dropdown with selectable values. You can use it to select predefined value or values from list:

Multiple values example:

- name: accessories
  label: Accessories
  type: dropdown
  multiple: true
  options:
  - label: Crash bars
    value: crash-bars
  - label: Bags
    value: bags
  - label: Cruise control
    value: cruise-control

Single value example (with colors):

- name: status
  label: Status
  type: dropdown
  width: 10%
  options:
  - label: In progress
    value: inProgress
    color: green
  - label: Next up
    value: nextUp
    color: gray
    dark: true

By default, the font color will be determined automatically, but if you want to adjust it to be white, then mark the item with dark: true to indicate that a provided color is dark.

Other types

number, text, date and other supported by HTML input field (when field type is not any of above, it fallbacks to standard input field with type specified)

Known issues

  • doesn't support inline adding of new files/records yet
  • doesn't support dark mode
  • uses ugly CSS to show context menus

Future plan

  • add filtering
  • add grouping
  • add sorting in both directions in the code
  • add ability to use Dataview queries as a source
  • add ability to set global ignore patterns in settings

Use plugins and other projects

This plugin is powered by Vue and Vuetify!

Comments
  • [Bug]: plugin css affect checkboxes

    [Bug]: plugin css affect checkboxes

    the checkboxes appear flat when enabling the plugin while using custom theme (like shimmering focus).

    https://user-images.githubusercontent.com/38974541/166682489-c57b30a4-c49e-46a1-b778-238fbf022c80.mov

    opened by imeed166 4
  • Ignore subfolder and file extension

    Ignore subfolder and file extension

    If you create a folder to make a database of people or products, it is normal that you have images. I have the images in a subfolder called images.

    When viewing the database, the md notes and images are shown and it is a bit confusing.

    An option to ignore subfolders or some extensions would be nice.

    opened by javiavid 3
  • Create new row directly within the database table

    Create new row directly within the database table

    Not sure if this is planned, but being able to create a new file/row directly within the database table would make this really powerful. Also, the ability to move delete rows/files too.

    planned 
    opened by crazymedguy 2
  • [feature] support for BRAT plugin

    [feature] support for BRAT plugin

    It would be nice if we could use BRAT to install and/or update this plugin, instead of doing it manually.

    For now, this is what I get when I try installing with BRAT :

    image

    opened by imeed166 2
  • [Question] How to select everything in the current folder? Is there a way to specify path from root?

    [Question] How to select everything in the current folder? Is there a way to specify path from root?

    Hello!! I'm starting to experiment and it's looking very good so far! However I cant figure out how to specify the folder the database is in itself. The way I have my vault set up, I make heavy use of folder notes which are placed inside the folder they are assigned to, along with the folder's actual contents, and because of that I would like to have the path to specify the folder the file is currently in! However from the documentation it seems to only support subfolders? I tried leaving path empty, including just a . and ./ but no such luck.

    I also tried selecting from the root of the vault in case by specifying the path as /folder/subfolder/targetfolder but that didn't work either. Am I doing something wrong?

    If neither current or full path options are available, if I had to choose one to eventually be implemented I would choose full path since that's much more flexible with what can be done with it!

    I can provide any logs if any of this is unintended behavior! Thank you so much for this plugin ^^

    opened by wychwitch 1
  • [bug]: doesn't work in reading view

    [bug]: doesn't work in reading view

    It works in live preview, but when I switch to reading view, it shows nothing.

    https://user-images.githubusercontent.com/38974541/166459549-d945ee2b-907d-46a5-86cc-a0f8ba58546b.mov

    opened by imeed166 1
  • docs: Improve backticks for example

    docs: Improve backticks for example

    Instead of having a backslash and the prompt to '(replace final line with triple ` )', this formatting renders the example code in the desired way. Check it out in the 'Preview' on GitHub.

    Also, if one uses the 'Copy' button in the top-right corner, they'll get the desired code with the correct final line.

    opened by Ben-Hampson 0
  • Number fields gets parentheses

    Number fields gets parentheses

    When declaring a number field (type: number), the data get enclosed in quotation marks, making it impossible to proceed them with arithmetical functions (var1+var2 gets simply joint to var1var2).

    Obsidian 0.15.9, Database 1.8.0.

    opened by Pazukulele 0
  • Spaces between lines are trimmed in view mode

    Spaces between lines are trimmed in view mode

    Say I have this text:

    A
    
    B
    

    then if you see the note in view mode the space between the lines should be preserved. However with the plugin being enable, it is trimmed:

    A
    B
    

    Version 1.8.0. I install it via BRAT. The strict line breaks option is turn off.

    opened by ooker777 0
Releases(1.8.0)
Owner
Łukasz Tomaszkiewicz
Łukasz Tomaszkiewicz
Like Obsidian Publish but for self-hosting. Plugin integrations for dataview, admonition, and more.

Obsidian Export Obsidian Publish is great but lacks support for many of the plugins we Obsidian addicts have grown accustomed to — in particular Datav

null 12 Nov 28, 2022
Use better-sqlite3 to give obsidian the ability to manipulate sqlite3 databases

OBSIDIAN-SQLITE3 Use better-sqlite3 to give obisidian the ability to manipulate sqlite3 databases. Intention Currently the linkage between obsidian an

cloud 12 Nov 28, 2022
A plugin for Obsidian (https://obsidian.md) that adds a button to its search view for copying the Obsidian search URL.

Copy Search URL This plugin adds a button to Obsidian's search view. Clicking it will copy the Obsidian URL for the current search to the clipboard. T

Carlo Zottmann 6 Dec 26, 2022
A example vault to collect and showcase various dataview queries. Created on behalf of AB1908

Obsidian Example Vault for Dataview Queries Good day! This example vault showcases different usages of the Dataview plugin for Obsidian.md. You'll fin

s-blu 184 Jan 5, 2023
For data quality enthousiasts (and dataview lovers): manage the metadata of your notes.

Metadata Menu This plugin is made for data quality enthousiasts: access and manage the metadata of your notes in Obsidian. Metadata Menu adds context

mathieu 139 Dec 23, 2022
Vaultacks lets users store files off-chain on Gaia. Files are encrypted by default but also can be made public and shared

Vaultacks Vaultacks is built on the Stacks Chain. It lets users upload files to Gaia, a off-chain data storage system. Vaultacks currently uses the de

Anish De 5 Sep 14, 2022
This plugin for Obsidian enables you to quickly jump to internal and external links

Obsidian Quick Jump Plugin This plugin for Obsidian enables you to quickly jump to internal and external links. This plugin is inspired by Jump to lin

Tadashi Aikawa 9 Sep 24, 2022
Obsidian plugin that allows user to create a glossary of files, an index of files or both.

Obsidian Auto Glossary Auto Glossary is an Obsidian plugin to create a glossary, an index or a glossary with an index from the files you want. Feature

Ennio Italiano 29 Dec 30, 2022
Obsidian plugin to open a note of your choice when creating a new tab, like in the browser.

New Tab Default Page Obsidian plugin to open a note of your choice when creating a new tab, like in the browser. Usage Set the note to open in new tab

pseudometa 20 Dec 27, 2022
Node js package makes creating node jd dependincies files like Controllers,Entities and Repositories easier by executing a few instructions

Nodejs Studio Node js package makes creating node js project dependincies files like Controllers,Entities and Repositories easier by executing a few i

Syrian Open Source 9 Oct 12, 2022
A free, open-source, web-based self-service BI tailor-made for analytical databases.

Rocket BI RocketBI is a self-service, web-based business intelligent product tailor-made for analytical databases. RocketBI is the core product of Dat

Data Insider 19 Jan 3, 2023
enables communication between command-line or desktop applications and browser-based Ethereum wallets such as Metamask.

@securerpc/walletbus @securerpc/walletbus Abstract Quickstart Installation Usage Ethers.js Web3.js Configuration options Logging Development Automated

Manifold Finance 8 Dec 27, 2022
A work-in-progress HTML sanitizer that strives for: performance like window.Sanitizer, readiness like DOMPurify, and ability to run in a WebWorker like neither of those.

Amuchina A work-in-progress HTML sanitizer that strives for: performance like window.Sanitizer, readiness like DOMPurify, and ability to run in a WebW

Fabio Spampinato 9 Sep 17, 2022
Cooperative databases using smart contracts.

Vitra ██╗ ██╗██╗████████╗██████╗ █████╗ ██║ ██║██║╚══██╔══╝██╔══██╗██╔══██╗ ██║ ██║██║ ██║ ██████╔╝███████║ ╚██╗ ██╔╝██║ ██║ ██╔══██╗██

Paul Frazee 177 Dec 30, 2022
A multipurpose transporting app that contains, loads databases, documentation and more.

TransportingApp This project was generated with Angular CLI version 12.0.3. Development server Run ng serve for a dev server. Navigate to http://local

Sebastian Oliveros 1 Jan 21, 2022
E-Commerce solution for security of databases and transactions.

commerce_new_era AMAÇ Amacımız günümüzde E-Ticaret sitelerinde bulunan sahte ürünlerin ve mağduriyetlerin önüne geçmektir. Bunu yapmak için Blockchai

Ayberk ESER 4 May 14, 2022
🍉 Water is a micro-ORM + QueryBuilder designed to facilitate queries and operations on PostgreSQL databases designed to work in Melon

?? Water Water is a micro-ORM + QueryBuilder designed to facilitate queries and operations on PostgreSQL databases designed to work in MelonRuntime In

Melon Runtime 22 Aug 6, 2022
CDK construct to periodically take snapshots of RDS databases, sanitize them, and share with selected accounts.

CDK Construct for RDS Sanitized Snapshots Periodically take snapshots of RDS databases, sanitize them, and share with selected accounts. Use this to a

CloudSnorkel 6 Dec 7, 2022