$smwgQConceptFeatures

From semantic-mediawiki.org


Configuration parameter details:
Name $smwgQConceptFeatures
Description Defines which query features should be available by default within concept definitions
Default setting See below
Software Semantic MediaWiki
Since version
Until version still available
Configuration Concept settings
Keyword concept queries · concept features · query features · query performance


$smwgQConceptFeatures is a configuration parameter that defines which query features should be available by default within concept definitions. It is the concept counterpart of configuration parameter $smwgQFeaturesDefines which query features should be available by default..

Starting with Semantic MediaWiki 7.0.0Released on 4 June 2026 and compatible with MW 1.43.x - 1.46.x. this parameter accepts an array of plain string keys instead of the SMW_*_QUERY constants. The constant form still works but is deprecated and will be removed in Semantic MediaWiki 8.0.0Released on an unknown date and compatible with unknown versions of MediaWiki.. The SMW_ANY_QUERY "all features" shortcut has been removed; list every permitted feature explicitly in the array.1

Default setting[edit]

$smwgQConceptFeatures = [ 'property', 'category', 'concept', 'namespace', 'conjunction', 'disjunction' ];

The default setting allows all basic features within concept definitions.

Available options[edit]

  • 'property' (formerly SMW_PROPERTY_QUERY) for conditions of the form [[Property::...]],
  • 'category' (formerly SMW_CATEGORY_QUERY) for conditions of the form [[Category:...]],
  • 'concept' (formerly SMW_CONCEPT_QUERY) for conditions of the form [[Concept:...]],
  • 'namespace' (formerly SMW_NAMESPACE_QUERY) for conditions of the form [[Namespace:+]],
  • 'conjunction' (formerly SMW_CONJUNCTION_QUERY) for combinations of multiple conditions in one query,
  • 'disjunction' (formerly SMW_DISJUNCTION_QUERY) for queries using OR or ||.

Changing the default setting[edit]

The available features are listed as strings in an array. To modify the setting, add a line to your "LocalSettings.php" file, e.g. to allow only category intersections within concepts:

$smwgQConceptFeatures = [ 'category', 'conjunction' ];

Legacy constant form (deprecated since 7.0.0)[edit]

The constant form below is deprecated since Semantic MediaWiki 7.0.0Released on 4 June 2026 and compatible with MW 1.43.x - 1.46.x. and will be removed in Semantic MediaWiki 8.0.0Released on an unknown date and compatible with unknown versions of MediaWiki.. Use the string-array form shown above instead. It is documented here for wikis still running the constant form. The SMW_ANY_QUERY shortcut has been removed and no longer works.
$smwgQConceptFeatures = SMW_PROPERTY_QUERY | SMW_CATEGORY_QUERY | SMW_CONCEPT_QUERY | SMW_NAMESPACE_QUERY | SMW_CONJUNCTION_QUERY | SMW_DISJUNCTION_QUERY;

See also[edit]

References

  1. ^  | | | | | | | | |  Semantic MediaWiki: GitHub pull request gh:smw:6793