Skip to content

Latest commit

 

History

History
44 lines (37 loc) · 1.81 KB

sys-openkeys-transact-sql.md

File metadata and controls

44 lines (37 loc) · 1.81 KB
title description author ms.author ms.date ms.service ms.subservice ms.topic f1_keywords helpviewer_keywords dev_langs monikerRange
sys.openkeys (Transact-SQL)
sys.openkeys (Transact-SQL)
rwestMSFT
randolphwest
06/10/2016
sql
system-objects
reference
openkeys_TSQL
sys.openkeys_TSQL
openkeys
sys.openkeys
sys.openkeys catalog view
TSQL
=azuresqldb-current||>=sql-server-2016||>=sql-server-linux-2017||=azuresqldb-mi-current||=azure-sqldw-latest

sys.openkeys (Transact-SQL)

[!INCLUDE SQL Server Azure SQL Database Azure SQL Managed Instance]

This catalog view returns information about encryption keys that are open in the current session.

Column name Data type Description
database_id int ID of the database that contains the key.
database_name sysname Name of the database that contains the key.
key_id int ID of the key. The ID is unique within the database.
key_name sysname Name of the key. Unique within the database.
key_guid varbinary GUID of the key. Unique within the database.
opened_date datetime Date and time when the key was opened.
status int 1 if the key is valid in metadata. 0 if the key is not found in metadata.

Permissions

[!INCLUDEssCatViewPerm] For more information, see Metadata Visibility Configuration.

See Also

Encryption Hierarchy
OPEN SYMMETRIC KEY (Transact-SQL)