Changes to the article, adding the title of the same name, caused a lot of link confusion

Once you’ve done the above, delete everything above this line.

Steps to reproduce

4
Discovery process
I clicked on a link, but it went to the wrong place
That’s not what I remember
It turns out that when I modified the file, I added a header with the same name as the link to the top of the source linked file
As a result, the title link is incorrectly linked to the title at the top

Did you follow the troubleshooting guide? [Y/N]

Y

Expected result

Discovery process
I clicked on a link, but it went to the wrong place
That’s not what I remember
It turns out that when I modified the file, I added a header with the same name as the link to the top of the source linked file
The title link at the top should be solid, and just because I added something new to the source file shouldn’t cause some links to this file to fail

Actual result

Environment

The code for a link to a section is [[11#aaa]]. As you see, this does not discriminate between heading levels. Clicking the link will instruct Obsidian to go to the target page and find the first matching header.

Workarounds

  • Make sure the header names in a single note are unique
  • Instead use a block reference, i.e., when creating the link, add ^ instead if # and select the second header in the suggestions.

If the structure is like something like this, you can use [[#b#aaa]] to link to the ## aaa sub-heading. e.g.

# aaa

# b

## aaa

# LINK

[[#b#aaa]]

Obsidian_Mai4uKKGjw


I think this is the main feature request here for more precise linking if there are headings of the same name:

1 Like

Yeah, that would solve part of the problem

But the point is, when I was revising this document,
I added some content, as well as the title #aaa
I didn’t know there was a title with the same name at the bottom of the document, #aaa
And I have no way of knowing that the #aaa at the bottom is linked in another document
Without knowing it, my normal writing broke all the links to the bottom #aaa

So I call it a BUG

At the time I made the link, I could not predict that one day in the future, I would add a #aaa title to the front part of the article. It is unrealistic to let users predict the future writing
Once this happens, the link is broken and links to inexplicable places

Bugs are annoying
Finally, thanks for providing this method

We don’t support this. Please, open a FR.