Provides access to pages previously marked suspect by recovery.
sp_forceonline_page dbname, pgid, {"sa_on" | "sa_off" | "all_users"}
sp_forceonline_page pubs2, 312, "sa_on"
sp_forceonline_page pubs2, 312, "sa_off"
sp_forceonline_page pubs2, 312, "all_users"
sp_forceonline_page with all_users cannot be reversed. When pages have been brought online for all users, you cannot take them offline again.
A page that is forced online is not necessarily repaired. Corrupt pages can also be forced online. The SAP ASE server does not perform any consistency checks on pages that are forced online.
You cannot use sp_forceonline_page in a transaction.
sp_forceonline_page works only for databases in which the recovery fault isolation mode is "page." Use sp_setsuspect_granularity to display the recovery fault isolation mode for a database.
To bring all of a database’s offline pages online in a single command, use sp_forceonline_db.
The permission checks for sp_forceonline_page differ based on your granular permissions settings.
Setting | Description |
---|---|
Enabled | With granular permissions enabled, you must be the database owner or a user with own database privilege. |
Disabled | With granular permissions disabled, you must be a user with sa_role. |
Values in event and extrainfo columns from the sysaudits table are:
Information | Values |
---|---|
Event | 38 |
Audit option | exec_procedure |
Command or access audited | Execution of a procedure |
Information in extrainfo |
|