SearchShortName Property
Syntax
FindQuery.SearchShortName
Applies To
Discussion
Use a FindQuery object to locate categories within a cube that match the search string specified by the SearchText property. Normally, the operation searches the category label text used in the short names for cube data. Set this property to False to search for long names.
The result is dependent on how the user views data. If the user specifies long names, searching returns a list of matching category labels with the long name format; similarly, using short names returns the short name format.
To search for a description, set this property to false and the SearchDescription property to True.
The order of the components in the subset definition is important. First, set the Dimension property, followed by the SearchShortName, SearchDescription, SearchText, and Pattern properties, and then the Execute and AddToReport methods. Set the Name property anywhere within the subset definition.
Default: False
Type
Boolean
Access
Read/Write
Example
This example creates a FindQuery (type 1) subset definition that searches for all products that begin with the name Star.
Sub Main()
Dim strCubePath As String
Dim objPPRep As Object
Dim objFind As Object
strCubePath = "C:\Cubes and Reports\Great Outdoors.mdc"
Set objPPRep = CreateObject("CognosPowerPlay.Report")
objPPRep.New strCubePath, 1
objPPRep.ExplorerMode = False
objPPRep.Visible = True
Set objFind = objPPRep.ReportQueries.Add(1)
With objFind
.Name = "Find Star"
.Dimension = "Products"
.SearchShortName = False
.SearchText = "Star"
.Pattern = 2
End With
Set objFind = Nothing
Set objPPRep = Nothing
End Sub