BackupDeviceItem.CompareTo Method

Verifies whether the specified object shares the same name as the referenced BackupDeviceItem object.

命名空间: Microsoft.SqlServer.Management.Smo
程序集: Microsoft.SqlServer.Smo (in microsoft.sqlserver.smo.dll)

语法

声明
Public Function CompareTo ( _
    obj As Object _
) As Integer
public int CompareTo (
    Object obj
)
public:
virtual int CompareTo (
    Object^ obj
) sealed
public final int CompareTo (
    Object obj
)
public final function CompareTo (
    obj : Object
) : int

参数

  • obj
    A Object object value that is used to specify object that is compared with referenced BackupDeviceItem object.

返回值

A Int32 value that specifies the lexical relationship between the two strings.

Value

Description

Less than zero

The referenced object name is less than the object name specified by the parameter.

Zero

The referenced object name is equal to the object name specified by the parameter.

Greater than zero

The referenced object name is greater than the object name specified by the parameter.

备注

已更新的文本:

The comparison of object names is case-insensitive, meaning that "MyTable" is the same as "mytable".

仅 Microsoft .NET Framework 的 2.0 版本支持此命名空间、类或成员。

线程安全

Any public static (Shared in Microsoft Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

平台

开发平台

有关支持的平台列表,请参阅安装 SQL Server 2005 的硬件和软件要求。

目标平台

有关支持的平台列表,请参阅安装 SQL Server 2005 的硬件和软件要求。

请参阅

参考

BackupDeviceItem Class
BackupDeviceItem Members
Microsoft.SqlServer.Management.Smo Namespace

其他资源

How to: Back Up Databases and Transaction Logs in Visual Basic .NET
BACKUP (Transact-SQL)
在 SQL Server 中备份和还原数据库