Content Query
- 80%
- 6.0
- Enterprise
- Community
Planned
Overview
One of the main features of Sense/Net is Content Query. Sense/Net Content Repository is a query based system. This means that every content or image you see on the portal is collected by a very sophisticated and fast query engine.
As a user, portal builder or administrator you get a simple but powerful content query language (CQL). You can use this language to find, filter and sort content even in a huge and constantly expanding repository.
As a developer you get an easy-to use Application Programming Interface (API) that is capable of serving any need in your custom code.
User group information
- End users
- If you want details on how to search for content on the portal, create simple or more sophisticated queries to collect content, see the Query syntax page.
- Developers
- If you are a developer and want to extend your code with collecting and presenting content, see the Query API page.
Examples
In this section you will get some overview about where and how can you utilize the power of the Content Query.
Please check out Query syntax before proceeding!
Getting articles
If you want to get the five newest article you can do so by defining the following query.
Type:Article .REVERSESORT:ModificationDate .TOP:5
Getting last modified documents
If you want to list the 10 last modified documents of the current user you can do so with this query:
+Type:Document +ModifiedBy:@@CurrentUser@@ .SORT:Name .TOP:10
All web content in a subtree
+TypeIs:WebContent +InTree:/Root/MyDocuments
Portlet usage examples
You can use query text in the following places:
Search boxes
When you search for a content on the main portal search, you can make a simple search for one word, but using the full query syntax you can create more sophisticated searches.
Smart folders
SmartFolder is a very powerful portal builder feature of Sense/Net. You can define a query to collect content from anywhere in the portal and present them as children in a SmartFolder.
Portlet property windows
In Sense/Net every portlet has a property window that you can use to customize the behavior of the portlet. In some cases you can provide a content query to specify the list of content you want to present or just a filter query that narrows a children list. These portlets are for example the Content collection Portlet and the Content query presenter Portlet.
Content Picker (Search mode)
If you are editing a content that has a Reference Field or you are editing the properties of a portlet you will come across the Content Picker. You can use it to search for content if you switch to Search mode and type a query text to the text box.