Confluence Search Problem

I want to search a confluence page which name contains API, but found no results.

image2015-6-26 15:20:47.png

image2015-6-26 15:21:0.png

What's the matter?

And one more question, how to set the page tree opend as a default value? Just like the pagetree macro.

image2015-6-26 15:22:43.png

Thanks very much!

3 answers

1 vote
Stephen Deutsch Community Champion Jun 26, 2015

Using the search syntax, you should be able to search for something like *API* and find all words with API in the middle.  Except that this is a longstanding bug in Confluence: https://jira.atlassian.com/browse/CONF-37153

 

As far as expanding the page tree view, that is possible using the documentation theme (which it looks like you are using from the screenshots).  Just go to "Space Admin", "Themes", "Configure Theme" and then uncheck the "Page Tree" checkbox, and in the navigation box put something like:

{pagetree:root=Home|startDepth=2|searchBox=true}

Choose the right home page and whether you want the searchbox there.  It seems you are already familiar with the pagetree macro so you shouldn't have any problem.

Davin Studer Community Champion Jun 26, 2015

You can do a front wildcard search if you do a regex search like this. The first pat gets the wildcard front and back match. The second part for some reason I have found to be needed as well to get instances where API is at the beginning. /.*API.*/ OR API

Stephen Deutsch Community Champion Jun 26, 2015

That's awesome! I wasn't aware you could use that syntax. I will have to keep that in mind from now on. Thanks a ton, Davin!

0 votes

I think the search stemming means that it needs API to be a separate "word" in the title of the document. The indexing is seeing the API as part of a bigger "word" because it is embedded in a string with other characters.

To the indexing functions, I think your page title looks something like xxxxxxAPIxxxxxxxx, so it's seen as one word.  To test this, try (temporarily) changing the title to xxxxx API xxxxxxx.  I suspect it will find it then.

My guess is that this down to the way native English speakers think - we use spaces between words and code our indexing systems to use it as a break, but most of us don't instinctively see that you don't need spaces in hanzi/kanji etc

I don't think you can default the page tree view

0 votes

Hi Xinan, 

Try to look for the whole title of the page, like xxxxxxAPIxxxxxxxx. Also, this documentation might be useful for you: https://confluence.atlassian.com/display/JIRA/Performing+Text+Searches

 

Regards, 

Renato Rudnicki

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Oct 24, 2018 in Confluence

Atlassian Research opportunity with Confluence templates

Do you use templates with Confluence? Take part in a remote 1-hr workshop. You'll receive USD $100 for your time!   We're looking for people to participate in a   remote 1-hr workshop...

1,077 views 17 14
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you