Thanks a lot! That works!!
Janne Jalkanen wrote:
>
>
> Leave out the [ and ]. That is, use "query='name:{$username}'".
> There's already a [ in the sentence, you don't need another one.
>
> /Janne
>
> On 12 Jun 2008, at 18:59, Ramya KGrama wrote:
>
>> Hello:
>> I am looking at creating a "My Page(s)" link along similar lines.
>> I was successful enough to provide the user with a form that
>> creates pages
>> with a structure like:
>> title, submitter, created fields.
>> When the user clicks "My Pages" in the left menu, I want to be able to
>> search the pages that he created, by using the wiki variable
>> [{$username}]
>> in the TaskQuery.
>> This is what I tried - but doesnt return any values:
>> [{TasksQuery select='title,created,owner'
>> from='MyPage'
>> where='submitter=[{$username}]'}]
>> I also tried escaping the'[' and '{' characters with '\' but
>> doesn't work.
>> Is there a way to pass a variable name in the where clause instead
>> of having
>> to hard code it.
>>
>> I also tried using the Search Plugin but got stuck at the very same
>> point:
>> [{Search query='name:[{$username}]' max=10 }] did not work.
>>
>> Any help is highly appreciated.
>> Thanks!!
>>
>>
>>
>> On 6/11/08, Dirk Frederickx <[EMAIL PROTECTED]> wrote:
>>>
>>> You also may want to look at http://www.jspwiki.org/wiki/TasksPlugin
>>>
>>>
>>> dirk
>>>
>>>
>>> On Wed, Jun 11, 2008 at 12:22 AM, Murray Altheim
>>> <[EMAIL PROTECTED]>
>>> wrote:
>>>> Amit Prahesh wrote:
>>>> [...]
>>>>>
>>>>> Now, is it possible, out of the box, or via plugins, to dynamically
>>>>> sift through the pages (like Employee*) and get information from
>>>>> them?
>>>>> Like creating a list of employees grouped by department, or maybe
>>>>> reporting their salaries, etc.
>>>>
>>>> As Janne mentioned, search is likely your best bet, if simplicity
>>>> and not wanting to do additional development work are your
>>>> priorities.
>>>>
>>>> The downside of search is that it is full text and does not take
>>>> into
>>>> account the context of a given word or phrase, i.e., if one searches
>>>> on a term the search engine will find it anywhere on any wiki page.
>>>> There is no current facility for searching on fields.
>>>>
>>>> I don't have any code available for distribution, but it's not
>>>> particularly difficult to modify JSPWiki for fielded searches. The
>>>> way I've approached this is to have a plugin that declares page-
>>>> level
>>>> metadata that is picked up the Lucene search engine as fields, then
>>>> one can search on those fields.
>>>>
>>>> For example, a plugin might declare (via a form) the following
>>>> metadata:
>>>>
>>>> __field name__ __field value__
>>>> title : The Hound of the Baskervilles
>>>> author : Sir Arthur Conan Doyle
>>>> language : English
>>>>
>>>> You'd have your plugin declare these name-value pairs as page-level
>>>> metadata, extend com.ecyrd.jspwiki.search.LuceneSearchProvider to
>>>> read the page metadata and add that as new Document fields, then
>>>> your
>>>> users can search using
>>>>
>>>> title:baskervilles author:doyle
>>>>
>>>> etc.
>>>>
>>>> This isn't a trivial solution but it's not enormously difficult
>>>> either.
>>>> Lucene's indexing functionality is relatively easy to extend. Using
>>>> this method one could use JSPWiki as a bibliographic or employee
>>>> database, etc.. where each page (i.e., those containing fielded
>>>> data)
>>>> can serve as a database record. You could then add an additional
>>>> search JSP to make searching on those fields easier.
>>>>
>>>> Murray
>>>>
>>>>
>>> .....................................................................
>>> ......
>>>> Murray Altheim <murray07 at altheim.com>
>>> === = =
>>>> http://www.altheim.com/murray/ =
>>> = ===
>>>> SGML Grease Monkey, Banjo Player, Wantanabe Zen
>>>> Monk = = =
>>> =
>>>>
>>>> Boundless wind and moon - the eye within eyes,
>>>> Inexhaustible heaven and earth - the light beyond light,
>>>> The willow dark, the flower bright - ten thousand houses,
>>>> Knock at any door - there's one who will respond.
>>>> -- The Blue Cliff Record
>>>>
>>>
>
>
>
--
View this message in context:
http://www.nabble.com/Adding-a-little-structure-tp17764712p17807217.html
Sent from the JspWiki - User mailing list archive at Nabble.com.