0 out of 1 rated this helpful - Rate this topic

MediaPassword Property

SQL Server 2000

MediaPassword Property

The MediaPassword property sets or retrieves the password for a media set.

Applies To

Syntax

object.MediaPassword[= value]

Parts

object

Expression that evaluates to an object in the Applies To list

value

String that contains the password

Data Type

String

Modifiable

Read/write

Prototype (C/C++)

HRESULT GetMediaPassword(SQLDMO_LPBSTR pRetVal);

HRESULT SetMediaPassword(SQLDMO_LPCSTR NewValue);

Remarks

The MediaPassword property provides the password used for a media set. If a media set password exists, it must be supplied to perform any restore operation from the media. If no media set password is passed by the Backup2 object, MediaPassword is set to NULL. An application can set MediaPassword multiple times; however once a backup or restore operation has been performed, MediaPassword cannot be altered.

Note  If an application calls MediaPassword on an instance of SQL Server version 7.0, the operation is ignored.

See Also

Password Property

Did you find this helpful?
(1500 characters remaining)
© 2013 Microsoft. All rights reserved.