Click or drag to resize

DiscoveryQuery Method

Query the discovery instance.

Namespace:  IBM.Watson.DeveloperCloud.Services.Discovery.v1
Assembly:  unity-documentation (in unity-documentation.exe) Version: 1.0.0.0 (1.0.0.0)
Syntax
C#
public bool Query(
	DiscoverySuccessCallback<QueryResponse> successCallback,
	DiscoveryFailCallback failCallback,
	string environmentID,
	string collectionID,
	string filter,
	string query,
	string aggregation,
	int count,
	string _return,
	int offset,
	Dictionary<string, Object> customData = null
)

Parameters

successCallback
Type: IBM.Watson.DeveloperCloud.Services.Discovery.v1DiscoverySuccessCallbackQueryResponse
The success callback.
failCallback
Type: IBM.Watson.DeveloperCloud.Services.Discovery.v1DiscoveryFailCallback
The fail callback.
environmentID
Type: SystemString
The environment identifier.
collectionID
Type: SystemString
The collection identifier.
filter
Type: SystemString
A cacheable query that limits the documents returned to exclude any documents that don't mention the query content. Filter searches are better for metadata type searches and when you are trying to get a sense of concepts in the data set.
query
Type: SystemString
A query search returns all documents in your data set with full enrichments and full text, but with the most relevant documents listed first. Use a query search when you want to find the most relevant search results.
aggregation
Type: SystemString
An aggregation search uses combinations of filters and query search to return an exact answer. Aggregations are useful for building applications, because you can use them to build lists, tables, and time series. For a full list of possible aggregrations, see the Query reference.
count
Type: SystemInt32
Number of documents to return.
_return
Type: SystemString
A comma separated list of the portion of the document hierarchy to return.
offset
Type: SystemInt32
The number of query results to skip at the beginning. For example, if the total number of results that are returned is 10, and the offset is 8, it returns the last two results.
customData (Optional)
Type: System.Collections.GenericDictionaryString, Object
Optional custom data.

Return Value

Type: Boolean
True if the call succeeds, false if the call is unsuccessful.
See Also