jackrabbit-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Brian Thompson" <elephant...@gmail.com>
Subject Re: Strange behaviour between sql and xpath search
Date Wed, 04 Apr 2007 23:52:21 GMT
Try

SELECT * FROM nt:base WHERE my:name = 'test.txt'

or something like

SELECT * FROM nt:base WHERE contains(my:name, '%.txt')

-Brian


On 4/4/07, KÖLL Claus <C.KOELL@tirol.gv.at> wrote:
>
> yet another information,
>
> the "test.txt" string is in the my:name property .
> the file node name itself is something like "hgugh2374jbbjk.txt"
>
> claus
> -----Ursprüngliche Nachricht-----
> Von: KÖLL Claus [mailto:C.KOELL@TIROL.GV.AT]
> Gesendet: Mittwoch, 04. April 2007 17:29
> An: users@jackrabbit.apache.org
> Betreff: Strange behaviour between sql and xpath search
>
> i have added a text file to my workspace and i would search it by its name
> with the contains function
> With the sql search it will be found
>
> SELECT * FROM nt:base WHERE contains(*, '*.txt')
>
> If i try to search with XPath i didnt find it !
>
> //element(*, nt:base)[jcr:contains(*, '*.txt')]
>
> I think the two statements are the same or not ?
>
> With xpath i do only find strings with contains(*) on the jcr:content node
> !
> Is this a bug ??
>
> My node structure looks like:
>
> /test.txt (nt:file)
> -my:name (Mixin)
> - .. some Mixin properties
> /jcr:content (nt:resource)
>    -jcr:mimetype
>    -jcr:lastModified
>    -jcr:data
>
> thanks for any help
> claus
>
>
Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message