Hello Jasha, Thanks for your proposed solution. Two step search is an option, I just wanted to try to make it as simple as I could and see if it is possible with just one search.
Can you please tell me is it possible to extract document path as property? Or is there already some property containing path? When moving document, extracting will not happen? Is there a way to change document content when being moved? Kind regards, Daniel On Mon, Sep 20, 2010 at 08:36, Jasha Joachimsthal <[email protected]> wrote: > The wildcard in the beginning of the search will be very inefficient so > don't go for that. > An "eq" search on a property with the name of the office based on some > lookup/dropdown field would be very efficient but you want to be able to > move the documents without changing its contents. > > So what I can think of is splitting up the search into 2 steps: > One SEARCH or PROPFIND that returns all the location folders. > Then a second SEARCH query with multiple scopes based on the returned > locations. > > Jasha Joachimsthal > > [email protected] - [email protected] > > Hippo > Europe • Amsterdam Oosteinde 11 • 1017 WT Amsterdam • +31 (0)20 522 > 4466 > USA • San Fransisco 185 H Street Suite B • Petaluma CA 94952-5100 • +1 > (707) 773 4646 > Canada • Montréal 5369 Boulevard St-Laurent #430 • Montréal QC H2T > 1S5 • +1 (514) 316 8966 > www.onehippo.com • www.onehippo.org • [email protected] > > > > > 2010/9/17 Daniel Stevanović <[email protected]> > >> Hi Paul, >> >> Yes I know about preprocessing/postprocessing/insertcontent, and you >> are right properties could be created that way, but values will be >> written only on document creation. Problem is that when document is >> moved to another folder (employee moved to another location/office) >> properties should be updated too. >> >> Regards, >> Daniel >> >> On Fri, Sep 17, 2010 at 11:10, Paul van der Maden >> <[email protected]> wrote: >> > >> > Hi Daniel, >> > >> > do you know something about preprocessing? I know for sure you'd be able >> to have the path info available at that moment. From there you can insert it >> into a document field. And extract it using a configured extractor. Be sure >> to create a path field in your template otherwise you'll lose the info upon >> saving and before it gets extracted. >> > >> > To bad I can't find the hippo binaries anywhere otherwise I could have >> played around a bit and be of a little more help. >> > >> > greets >> > Paul >> > >> >> Date: Fri, 17 Sep 2010 10:42:20 +0200 >> >> Subject: Re: [HippoCMS-dev] Document path as property >> >> From: [email protected] >> >> To: [email protected] >> >> >> >> Hi Paul, >> >> >> >> I have already checked with webdav client and there is no property >> >> that contains path. >> >> I know how dav:like works, but thanks anyway. Still need a property to >> >> check value. >> >> I mentioned wildcards in scope as maybe another way to solve this (if >> >> property is not available). >> >> >> >> Thanks, >> >> Daniel >> >> >> >> On Fri, Sep 17, 2010 at 10:20, Paul van der Maden >> >> <[email protected]> wrote: >> >> > >> >> > Daniel, >> >> > >> >> > my knowledge is a bit rusty but I am sure the path is already >> available as a property. You can view which properties you have using a >> webdav client. I used webdavpilot from within eclipse most of the times. >> >> > >> >> > I mentioned dav:like because you can query property values with it and >> use wildcards. It checks if the value of the given property matches the >> literal. >> >> > Basically equal to<S:propcontains/>, but you may use the '%' and >> >> > '?' characters like in SQL. % matches any amount of characters, ? >> matches one character. So I guess you'd be having something like this: >> >> > >> >> > <D:where> >> >> > <D:like> >> >> > <D:prop><D:path/></D:prop> >> >> > <D:literal>%office1%</D:literal> >> >> > </D:like> >> >> > </D:where> >> >> > >> >> > take a look at the folowing pages: >> >> > https://wiki.onehippo.com/display/CMS/06.+Using+DASL+Queries >> >> > http://www.webdav.org/dasl/protocol/draft-dasl-protocol-00.html >> >> > >> >> > My example wont work, because I don't have anything to test it with or >> verify I even got the names right, but it should give you some pointers at >> least. I don;t know if you could use wildcards in scope, but does it >> matter? Can't you just use a wide scope and narrow your results filtering on >> path? >> >> > >> >> > cheers, >> >> > Paul >> >> > >> >> >> Date: Fri, 17 Sep 2010 09:47:17 +0200 >> >> >> Subject: Re: [HippoCMS-dev] Document path as property >> >> >> From: [email protected] >> >> >> To: [email protected] >> >> >> >> >> >> Hi Paul, >> >> >> >> >> >> That is my question. If there is a property containing path already I >> >> >> don't know how to use it in dasl, if not how could I configure >> >> >> extractor to add one? >> >> >> I'm not sure I understand your proposal to use dav:like, I need a >> >> >> property to check value with dav:like. Can I use wildcards in scope >> >> >> maybe? >> >> >> >> >> >> Regards, >> >> >> Daniel >> >> >> >> >> >> On Fri, Sep 17, 2010 at 09:26, Paul van der Maden >> >> >> <[email protected]> wrote: >> >> >> > >> >> >> > Hi Daniel, >> >> >> > >> >> >> > I don't have any working hippo install available right now, but >> isnt the path already a property? If not, you can probably use an extractor >> to set the property on the document. And have you looked into wildcard >> searches using dav:like? >> >> >> > >> >> >> > cheers, >> >> >> > Paul >> >> >> > >> >> >> >> Date: Fri, 17 Sep 2010 09:17:06 +0200 >> >> >> >> From: [email protected] >> >> >> >> To: [email protected] >> >> >> >> Subject: [HippoCMS-dev] Document path as property >> >> >> >> >> >> >> >> Hello everyone, >> >> >> >> >> >> >> >> I have some questions that I hope someone could help me with. >> >> >> >> >> >> >> >> 1. Is it possible to extract document path and add it as a >> property ? >> >> >> >> >> >> >> >> 2. Or maybe there is some other solution to my problem. I have >> >> >> >> following folder structure: >> >> >> >> - location1 >> >> >> >> - office1 >> >> >> >> - employee1 >> >> >> >> - employee2 >> >> >> >> ... >> >> >> >> - office2 >> >> >> >> - employee3 >> >> >> >> ... >> >> >> >> - location2 >> >> >> >> - office1 >> >> >> >> - employee4 >> >> >> >> - employee5 >> >> >> >> ... >> >> >> >> - office2 >> >> >> >> ... >> >> >> >> ... >> >> >> >> How could I perform a dasl search to return all employees from >> e.g. >> >> >> >> office1 (regardless of location) ? "office1" has the same name in >> all >> >> >> >> locations. >> >> >> >> My idea was to extract parts of the path, location and office, and >> add >> >> >> >> them as a property to employee document, then the dasl would be >> very >> >> >> >> simple, but I'm not sure that is feasible. >> >> >> >> >> >> >> >> Any help would be appreciated. >> >> >> >> Thanks in advance. >> >> >> >> >> >> >> >> Kind regards, >> >> >> >> Daniel Stevanovic >> >> >> >> ******************************************** >> >> >> >> Hippocms-dev: Hippo CMS 6 development public mailinglist >> >> >> >> >> >> >> >> Searchable archives can be found at: >> >> >> >> MarkMail: http://hippocms-dev.markmail.org >> >> >> >> Nabble: http://www.nabble.com/Hippo-CMS-f26633.html >> >> >> >> >> >> >> > >> ******************************************** >> >> >> > Hippocms-dev: Hippo CMS 6 development public mailinglist >> >> >> > >> >> >> > Searchable archives can be found at: >> >> >> > MarkMail: http://hippocms-dev.markmail.org >> >> >> > Nabble: http://www.nabble.com/Hippo-CMS-f26633.html >> >> >> > >> >> >> > >> >> >> ******************************************** >> >> >> Hippocms-dev: Hippo CMS 6 development public mailinglist >> >> >> >> >> >> Searchable archives can be found at: >> >> >> MarkMail: http://hippocms-dev.markmail.org >> >> >> Nabble: http://www.nabble.com/Hippo-CMS-f26633.html >> >> >> >> >> > >> ******************************************** >> >> > Hippocms-dev: Hippo CMS 6 development public mailinglist >> >> > >> >> > Searchable archives can be found at: >> >> > MarkMail: http://hippocms-dev.markmail.org >> >> > Nabble: http://www.nabble.com/Hippo-CMS-f26633.html >> >> > >> >> > >> >> ******************************************** >> >> Hippocms-dev: Hippo CMS 6 development public mailinglist >> >> >> >> Searchable archives can be found at: >> >> MarkMail: http://hippocms-dev.markmail.org >> >> Nabble: http://www.nabble.com/Hippo-CMS-f26633.html >> >> >> > >> ******************************************** >> > Hippocms-dev: Hippo CMS 6 development public mailinglist >> > >> > Searchable archives can be found at: >> > MarkMail: http://hippocms-dev.markmail.org >> > Nabble: http://www.nabble.com/Hippo-CMS-f26633.html >> > >> > >> ******************************************** >> Hippocms-dev: Hippo CMS 6 development public mailinglist >> >> Searchable archives can be found at: >> MarkMail: http://hippocms-dev.markmail.org >> Nabble: http://www.nabble.com/Hippo-CMS-f26633.html >> >> > ******************************************** > Hippocms-dev: Hippo CMS 6 development public mailinglist > > Searchable archives can be found at: > MarkMail: http://hippocms-dev.markmail.org > Nabble: http://www.nabble.com/Hippo-CMS-f26633.html > > ******************************************** Hippocms-dev: Hippo CMS 6 development public mailinglist Searchable archives can be found at: MarkMail: http://hippocms-dev.markmail.org Nabble: http://www.nabble.com/Hippo-CMS-f26633.html
