cancel
Showing results for 
Search instead for 
Did you mean: 

Lucene Search: Path Queries

emmy
Champ in-the-making
Champ in-the-making
Hi,
I have created a space with name '123' and I have noticed that the name of the node created is {http://www.alfresco.org/model/content/1.0}123,
but if I search this node using Lucene I have this error
Search failed due to: org.alfresco.repo.search.SearcherException: Failed to parse query: PATH:"//app:company_home/cm:Clienti/cm:123"

The name given to the node by Lucene is {http://www.alfresco.org/model/content/1.0}_x0031_23.
If I search the node in this way: PATH:"//app:company_home/cm:Clienti/cm:_x0031_23"
the node comes found

There is the same problem if I create a space with name 'Hello world'.

Is there a function to resolve the problem?

Regards,
Emanuela
1 REPLY 1

andy
Champ on-the-rise
Champ on-the-rise
Hi

This is expected. PATH is treated as a subset of XPATH. Numbers are not valid at the start of xml element names.
The ISO9075 encoding classs should be used to encode local names.

Regards

Andy