Find (clsCollection)

ms133286.note(zh-cn,SQL.90).gif注意:
  下一版本的 Microsoft SQL Server 将删除该功能。请不要在新的开发工作中使用该功能,并尽快修改当前还在使用该功能的应用程序。

The Find method of a Decision Support Objects (DSO) collection locates an item in a collection. This method does not apply to CustomProperties collections.

语法

bPresent = object.Find(vKey)

参数

  • bPresent
    A Boolean variable that receives the returned value: True if the item was found, False otherwise.
  • object
    An instance of a DSO collection object.
  • vKey
    The key or index of the item to be found.

示例

Use the following code to check for the existence of a partition named EastCoast in the MDStores collection of partitions for a cube:

' Assume the existence of an object cubCube
' of ClassType clsCube.
Dim bPresent As Boolean 
bPresent = cubCube.MDStores.Find("EastCoast") 
 

请参阅

其他资源

Collections

帮助和信息

获取 SQL Server 2005 帮助