Help:Query restrictions

From semantic-mediawiki.org
QueryHelp:Query restrictions

This help page provides an overview to query restrictions and how to change them by adapting the respective configuration parameters.

Query size and depth[edit]

In case a query returns with a message like "The following $2 query conditions could not be considered due to this wiki's restrictions on query size or depth: $1." (with $1, $2 being placeholders)1 the following configuration parameters $smwgQMaxSizeSets the maximum number of conditions for inline queries and $smwgQMaxDepthSets the maximum property depth for inline queries define the restrictions applied before a query is executed:

  • $smwgQMaxSize defines the maximum number of conditions in queries
  • $smwgQMaxDepth defines the maximum property depth of queries (e.g. [[Rel1::<q>[[Rel2::Test]]</q>]] has depth 2)

Using result format "Debug" (format=debug) for the respective to output the computed size and depth of query and to analyze the restrictions applied to a query.

Limit query execution[edit]

The $smwgQExpensiveThresholdDefines the expensive threshold (denotes the ceiling) and $smwgQExpensiveExecutionLimitLimit of expensive #ask/#show parser functions (count all classified #ask/#show parser functions and restricts further use on pages that exceed that limit) configuration parameters can be used to limit the execution of expensive #ask and #show queries.

See also[edit]

size and depth
execution


References

  1. ^  Semantic MediaWiki: GitHub issue gh:smw:4003