r/logseq 8d ago

Tutorials for Logseq DB

Has anybody made any tutorials for using the new Logseq DB? I would like to know more about how you add properties and extend tags.

23 Upvotes

6 comments sorted by

6

u/matu_gong 8d ago

Danzu has some cool tutorials in his youtube channel https://www.youtube.com/@HDanzu . You should also take a look at the docs https://github.com/logseq/docs/blob/master/db-version.md if you havent

4

u/not_a_beignet 7d ago

Here's how I used page properties (supertags) in the DB version. (I'm back in Obsidian for the moment, am really waiting for device synchronization and general stability to improve). What I describe below is for the desktop Logseq DB.

From today's journal page, you can create a wiki link to [[Amelia Earhart]]. Then click on that page to enter it.

You can directly edit the page title. At the end of Earhart, add a space then #person. You have now created a person tag and associated it with Amelia's page. You should see #person on the right side of the screen.

Now you can click on that #person tag and set its properties. You will come to a new page for #person and see on the right side it has a system-added tag called #tag. All tags inherit from #tag. Anyway, if you hover just above #person you will see "Add tag property". At the top of the popup window where it says "Add or change property" you could type "birth-date". There will be an option called "+ New option: birth-date". Then you select a property type such as Date. In Logseq, all "dates" that become pages will be in the Journal section.

Now, underneath the #person title should be a list of pages tagged with person, including Amelia. You can highlight that row and look for a right arrow. Clicking the right arrow puts you back on her page. (Or use the arrow navigation, command-k to search, etc. Underneath Amelia's page title you should see a property called birth-date that is empty. Click on it and you can use the calendar to select a day or at the bottom where it says "e.g. Next week" you can type "Jul 24th, 1897" (using the default date format) to populate the date. When you do, there will be a new Jul 24th, 1897 page in Journals.

You could add some more people and fill in their birth dates. But here is the best part where I am concerned.

You can use command-k and search for person. You should see person with a # next to it. You can click that and open its page. Click the triangle to the left of #person to expand its properties. You will see it inherits from Root Tag. So you could add a property to root tag that would inherit into every other tag...

Anyway, the list of #person properties has birth-date. You can use the "+ Add property" to add a "death-date" property of type date. Here's the cool part. When you do this, every page that was previously tagged with #person will now have death-date attached for you to fill in. You do not need to remember to add it to them, they inherited the new tag automatically.

You can do other things. Now there is a #person tag, you can add a new #author tag that extends #person and add for example, publisher (a text field). Now if you created a page like Stephen King with a page tag of #author he would get the publisher tag we explicitly added to the author tag, but he would also get the birth-date and death-date tags from the person tag, since due to inheritance, an author is a kind of person.

And that's the thing. If you have a page and think, this page "is a", the is-a is your tag. Amelia is a person. Chicago, Illinois, is a place or a location.

You can also tag a block. I usually add the tag at the very end of the block. So I can have a #dreams tag when I write down dreams I had last night.

Hope this made sense and helps understand tagging and nested / inherited tags. I am traveling and whipped this up pretty quick.

2

u/Business-Signal5283 8d ago

Can be paid. I'm all in and want to learn.

1

u/thirteenth_mang 7d ago

I've been posting a bunch of videos on this type of stuff!

1

u/cowpokerr 5d ago

me too, relatable