Actually, this problem went away once ASK was rewritten as parser function and you can use it all as with any other parser function. Basically, that was the main reason for parser function development.

          Sergey


On Fri, May 30, 2008 at 4:50 AM, Rolf Lampa <rolf.lampa@rilnet.com> wrote:
The documentation says that parameters can NOT be used in queries,
not in "any case.  See this page
http://semantic-mediawiki.org/wiki/Help:Semantic_search#Using_templates_and_variables

The text doesn't seem to reveal the whole truth, though. The text says:

 >> == Using templates and variables ==
 >>
 >> Within a query, arbitrary templates and variables can be used.
 >> This can be used to create a standard query that displays all
 >> future events (where "future" gets its meaning from the current date):

<snip>  It goes on to say:

 >> Many other uses are possible, especially when using queries inline.
 >> However, it is in *no case possible* to use template parameters (the
 >> things in {{{ }}}) within a query. *Sorry*.

But, parameters /can/ be used in a query, although not directly. I suggest
assigning parameter values to temporary variables, and then use the
variables in the query  instead, like so:

// 1. Assign {{{param values}}}  to temp variables :

{{#vardefine: tmp_pageclass | {{{1|}}} }}
{{#vardefine: tmp_property | {{{2|}}} }}

// 2. In this way the variables (params) actually /can/ be used in the
query:

{{#ask: [[Category:{{#var:tmp_pageclass}}]]
 | [[{{#var:tmp_property}}::+]] [[{{#var:tmp_property}}::*]]
}}

Tested, and it works. Perhaps a hint to use "param-variables" like this
should be  added to the documentation as well.

Regards,

// Rolf Lampa

-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Semediawiki-user mailing list
Semediawiki-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/semediawiki-user



--
Sergey Chernyshev
http://www.sergeychernyshev.com/