Public Methods

  Name Description
Public method Equals Determines whether the specified Object is equal to the current Object. (inherited from Object)
Public method GetHashCode Serves as a hash function for a particular type. GetHashCode is suitable for use in hashing algorithms and data structures like a hash table. (inherited from Object)
Public method GetType Gets the Type of the current instance. (inherited from Object)
Public method SetAll Specifies that duplicate rows can be returned in the result set.
Public method SetContainsRestriction Restricts the query to return only items where the text in the content element or elements matches the specified String. This method uses the CONTAINS function for CBR (Content-Based Retrieval) queries.

The CONTAINS function can perform the search on CBR-enabled properties for the supported content elements in any of the following ways:

  • Search a single property.
  • Search all properties within a specified zone.
  • Search all properties.
Public method SetDistinct Restricts the query to return only distinct rows. This setting is valid only when all properties in the select list are orderable (as specified in the ORDER BY clause).
Public method SetFolderRestriction Restricts the query to return only items from the specified class within the specified folder.
Public method SetFreetextRestriction Restricts the query to return only items where the text in the content elements matches the specified String. This method uses the FREETEXT function for CBR (Content-Based Retrieval) queries.

The FREETEXT function searches all content on all CBR-enabled properties on the supported content elements. To search content on a single CBR-enabled property, use SetContainsRestriction.

Public method SetFromClauseAdditionalJoin Adds another class to the FROM clause used in the SQL statement.
Public method SetFromClauseInitialValue Sets the first class to be used in the FROM clause for the statement.
Public method SetMaxRecords Sets the maximum number of rows that can be returned in the result set. When unspecified, all records that satisfy the query will be returned, subject to the limit of the IServerCacheConfiguration property NonPagedQueryMaxSize.
Public method SetOrderByClause Sets the ORDER BY clause to be used for the SQL statement to the specified String.
Public method SetQueryString Specifies the entire SQL statement. This method cannot be used in conjunction with any of the other Set methods on this class. Doing so will have the following effect:
  • Any values set by calling another SearchSQL Set method (such as, SetMaxRecords), then calling this method, will overwrite or nullify the value initially set.
  • Calling this method, then calling any other SearchSQL Set method will overwrite or nullify the SQL statement specified here.

No SQL validation is performed on the specified string.

Public method SetSelectList Sets the SELECT list for SQL statement to the specified String. This must be called prior to calling SetFromClauseAdditionalJoin.
Public method SetTimeLimit Sets the maximum duration the query runs on the server, in seconds. When unspecified, the value of the ObjectStore property DefaultQueryTimeLimit is used.

Warning: Date/Time values in queries are evaluated with respect to the Content Engine server clock. If the client and server clocks are not in sync, be careful when translating relative time concepts into absolute times. For example, specifying a value that means "within the last 5 minutes" on the client will translate to a comparison to an absolute time in the SQL query, which may not mean "within the last 5 minutes" relative to the server clock.

Public method SetWhereClause Sets the WHERE clause to be used for SQL statement to the specified String.
Public method ToString Overridden. Returns either the SQL statement constructed using the helper methods (in this case, SetFromClauseInitialValue must have been called prior to this method), or the SQL statement specified in its entirety using either SetQueryString or the SearchSQL(String) constructor.
Top

Protected Methods

  Name Description
Family method Finalize Allows an Object to attempt to free resources and perform other cleanup operations before the Object is reclaimed by garbage collection. (inherited from Object)
Family method MemberwiseClone Creates a shallow copy of the current Object. (inherited from Object)
Top

See Also