Files
Trilium/docs/Developer Guide/Developer Guide/Development and architecture/Database/notes.md
2025-04-12 01:36:03 +03:00

2 lines
2.4 KiB
Markdown

# notes
<figure class="table"><table><thead><tr><th>Column Name</th><th>Data Type</th><th>Nullity</th><th>Default value</th><th>Description</th></tr></thead><tbody><tr><th><code>noteId</code></th><td>Text</td><td>Non-null</td><td>&nbsp;</td><td>The unique ID of the note (e.g. <code>2LJrKqIhr0Pe</code>).</td></tr><tr><th><code>title</code></th><td>Text</td><td>Non-null</td><td><code>"note"</code></td><td>The title of the note, as defined by the user.</td></tr><tr><th><code>isProtected</code></th><td>Integer</td><td>Non-null</td><td>0</td><td><code>1</code> if the entity is <a href="../Protected%20entities.md">protected</a>, <code>0</code> otherwise.</td></tr><tr><th><code>type</code></th><td>Text</td><td>Non-null</td><td><code>"text"</code></td><td>The type of note (i.e. <code>text</code>, <code>file</code>, <code>code</code>, <code>relationMap</code>, <code>mermaid</code>, <code>canvas</code>).</td></tr><tr><th><code>mime</code></th><td>Text</td><td>Non-null</td><td><code>"text/html"</code></td><td>The MIME type of the note (e.g. <code>text/html</code>).. Note that it can be an empty string in some circumstances, but not null.</td></tr><tr><th><code>isDeleted</code></th><td>Integer</td><td>Nullable</td><td>0</td><td><code>1</code> if the entity is <a href="../Deleted%20notes.md">deleted</a>, <code>0</code> otherwise.</td></tr><tr><th><code>deleteId</code></th><td>Text</td><td>Non-null</td><td><code>null</code></td><td>&nbsp;</td></tr><tr><th><code>dateCreated</code></th><td>Text</td><td>Non-null</td><td>&nbsp;</td><td>Localized creation date (e.g. <code>2023-11-08 18:43:44.204+0200</code>)</td></tr><tr><th><code>dateModified</code></th><td>Text</td><td>Non-null</td><td>&nbsp;</td><td>Localized modification date (e.g. <code>2023-11-08 18:43:44.204+0200</code>)</td></tr><tr><th><code>utcDateCreated</code></th><td>Text</td><td>Non-null</td><td>&nbsp;</td><td>Creation date in UTC format (e.g. <code>2023-11-08 16:43:44.204Z</code>)</td></tr><tr><th><code>utcDateModified</code></th><td>Text</td><td>Non-null</td><td>&nbsp;</td><td>Modification date in UTC format (e.g. <code>2023-11-08 16:43:44.204Z</code>)</td></tr><tr><th><code>blobId</code></th><td>Text</td><td>Nullable</td><td><code>null</code></td><td>The corresponding ID from&nbsp;<a class="reference-link" href="blobs.md">blobs</a>. Although it can theoretically be <code>NULL</code>, haven't found any such note yet.</td></tr></tbody></table></figure>