jackrabbit-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Adeel Shahzad <Adeel.Shah...@cto247.com>
Subject RE: Jackrabbit search does not find node with backslash in its name
Date Fri, 17 Apr 2015 15:57:37 GMT
This might seem strange, but you will have to escape the '\' in your node's jcr:title property
and not in query.

I am trying to find what the specification says for property name convention.

Thanks,
Adeel

-----Original Message-----
From: dinesh.babu@pb.com [mailto:dinesh.babu@pb.com] 
Sent: Friday, April 17, 2015 8:01 PM
To: users@jackrabbit.apache.org
Subject: RE: Jackrabbit search does not find node with backslash in its name

Thanks Adeel.

1) I can't use Like clause, because I am looking for exact match

2) I escaped "\" by making it "\\" in the exact match query AND ( LOWER([jcr:title]) = 'back\\slash1'
). That did not bring any result.

Regards,
Dinesh Babu

Ph: +441923 279123
dinesh.babu@pb.com
www.pb.com<http://www.pb.com/>

Pitney Bowes Software
6 Hercules Way, Leavesden Park, Watford, Herts WD25 7GS

From: Adeel Shahzad [via Jackrabbit] [mailto:ml-node+s510166n4662322h48@n4.nabble.com]
Sent: 17 April 2015 15:56
To: Dinesh Babu
Subject: RE: Jackrabbit search does not find node with backslash in its name

Ok got you. I have done something to check this...

I added 2 properties in my node. These props are:

- test:abc\tre
- test123:abc\\tre

And I used following 3 queries to access the node (might help you):

select * from [nt:base] AS s where ISDESCENDANTNODE(s, '/content') and test123 like '%\\%'
above query showed desired node

select * from [nt:base] AS s where ISDESCENDANTNODE(s, '/content') and test like '%\%'
above query didn't come up with any result

select * from [nt:base] AS s where ISDESCENDANTNODE(s, '/content') and test123 like '%\%'
above query also showed nothing

I think you might have to change the value of jcr:title i.e. escape the value there

Thanks,
Adeel

-----Original Message-----
From: [hidden email]</user/SendEmail.jtp?type=node&node=4662322&i=0> [mailto:[hidden
email]</user/SendEmail.jtp?type=node&node=4662322&i=1>]
Sent: Friday, April 17, 2015 7:18 PM
To: [hidden email]</user/SendEmail.jtp?type=node&node=4662322&i=2>
Subject: RE: Jackrabbit search does not find node with backslash in its name

Thanks for your reply.

It did not work. The problem part in the query is here "AND ( LOWER([jcr:title]) = 'back\slash1'
) " where title name has got a backslash in its name

Regards,
Dinesh Babu


From: Adeel Shahzad [via Jackrabbit] [mailto:[hidden email]</user/SendEmail.jtp?type=node&node=4662322&i=3>]
Sent: 17 April 2015 15:07
To: Dinesh Babu
Subject: RE: Jackrabbit search does not find node with backslash in its name

This is part doesn't look good

 SELECT * FROM [pb:community] WHERE ISDESCENDANTNODE('/community')

This should be

SELECT * FROM [pb:community] AS s WHERE ISDESCENDANTNODE(s, '/community')

-----Original Message-----
From: Dinesh Babu [mailto:[hidden email]</user/SendEmail.jtp?type=node&node=4662320&i=0>]
Sent: Friday, April 17, 2015 3:45 PM
To: [hidden email]</user/SendEmail.jtp?type=node&node=4662320&i=1>; [hidden
email]</user/SendEmail.jtp?type=node&node=4662320&i=2>
Subject: Jackrabbit search does not find node with backslash in its name

Hi,

Jackrabbit search for a node with backslash ("\")  does not work.

This is the following query that we fire which does not work SELECT * FROM [pb:community]
WHERE ISDESCENDANTNODE('/community') AND ( LOWER([jcr:title]) = 'back\slash1' )

Does anyone know how to escape a backslash to get this query working? Commonly used methods
in Text or  ISO9075 does not do the trick.

Regards,
Dinesh Babu

Pitney Bowes Software
6 Hercules Way, Leavesden Park, Watford, Herts WD25 7GS


________________________________



________________________________
If you reply to this email, your message will be added to the discussion below:
http://jackrabbit.510166.n4.nabble.com/Jackrabbit-search-does-not-find-node-with-backslash-in-its-name-tp4662318p4662320.html
To start a new topic under Jackrabbit - Users, email [hidden email]</user/SendEmail.jtp?type=node&node=4662322&i=4><mailto:[hidden
email]</user/SendEmail.jtp?type=node&node=4662322&i=5>>
To unsubscribe from Jackrabbit, click here< NAML<http://jackrabbit.510166.n4.nabble.com/template/NamlServlet.jtp?macro=macro_viewer&id=instant_html%21nabble%3Aemail.naml&base=nabble.naml.namespaces.BasicNamespace-nabble.view.web.template.NabbleNamespace-nabble.view.web.template.NodeNamespace&breadcrumbs=notify_subscribers%21nabble%3Aemail.naml-instant_emails%21nabble%3Aemail.naml-send_instant_email%21nabble%3Aemail.naml>

________________________________





--
View this message in context: http://jackrabbit.510166.n4.nabble.com/Jackrabbit-search-does-not-find-node-with-backslash-in-its-name-tp4662318p4662321.html
Sent from the Jackrabbit - Users mailing list archive at Nabble.com.


________________________________
If you reply to this email, your message will be added to the discussion below:
http://jackrabbit.510166.n4.nabble.com/Jackrabbit-search-does-not-find-node-with-backslash-in-its-name-tp4662318p4662322.html
To start a new topic under Jackrabbit - Users, email ml-node+s510166n510167h43@n4.nabble.com<mailto:ml-node+s510166n510167h43@n4.nabble.com>
To unsubscribe from Jackrabbit, click here<http://jackrabbit.510166.n4.nabble.com/template/NamlServlet.jtp?macro=unsubscribe_by_code&node=510166&code=ZGluZXNoLmJhYnVAcGIuY29tfDUxMDE2NnwtMTUwMTI4NTUzMA==>.
NAML<http://jackrabbit.510166.n4.nabble.com/template/NamlServlet.jtp?macro=macro_viewer&id=instant_html%21nabble%3Aemail.naml&base=nabble.naml.namespaces.BasicNamespace-nabble.view.web.template.NabbleNamespace-nabble.view.web.template.NodeNamespace&breadcrumbs=notify_subscribers%21nabble%3Aemail.naml-instant_emails%21nabble%3Aemail.naml-send_instant_email%21nabble%3Aemail.naml>

________________________________





--
View this message in context: http://jackrabbit.510166.n4.nabble.com/Jackrabbit-search-does-not-find-node-with-backslash-in-its-name-tp4662318p4662323.html
Sent from the Jackrabbit - Users mailing list archive at Nabble.com.


Mime
View raw message