--- title: "Capture Logon Trigger Event Data | Microsoft Docs" ms.custom: "" ms.date: "03/06/2017" ms.prod: sql ms.reviewer: "" ms.technology: ms.topic: conceptual ms.assetid: e05b1ab4-c10b-402a-9591-f6ec1e3db8c0 author: "rothja" ms.author: "jroth" monikerRange: "=azuresqldb-current||>=sql-server-2016||=sqlallproducts-allversions||>=sql-server-linux-2017||=azuresqldb-mi-current" --- # Capture Logon Trigger Event Data [!INCLUDE[tsql-appliesto-ss2008-appliesto-ss-asdbmi-xxxx-xxx-md](../../includes/tsql-appliesto-ss2008-asdbmi-xxxx-xxx-md.md)] To capture XML data about LOGON events for use inside logon triggers, use the [EVENTDATA](../../t-sql/functions/eventdata-transact-sql.md) function. The LOGON event returns the following event data schema: `` `event_type` `post_time` `spid` `server_name` `login_name` `login_type` `sid` `client_host` `is_pooled` `` `` Contains `LOGON`. `` Contains the time when a session is requested to be established. `` Contains the base 64-encoded binary stream of the security identification number (SID) for the specified login name. `` Contains the host name of the client from where the connection is made. The value is '``' if the client and server name are the same. Otherwise, the value is the IP address of the client. `` Is `1` if the connection is reused by using connection pooling. Otherwise, the value is `0`.