-- ================================================ -- Template generated from Template Explorer using: -- Create Inline Function (New Menu).SQL -- -- Use the Specify Values for Template Parameters -- command (Ctrl-Shift-M) to fill in the parameter -- values below. -- -- This block of comments will not be included in -- the definition of the function. -- ================================================ SET ANSI_NULLS ON GO SET QUOTED_IDENTIFIER ON GO -- ============================================= -- Author: -- Create date: -- Description: -- ============================================= CREATE FUNCTION LogLength ( -- Add the parameters for the function here ) RETURNS INT AS BEGIN DECLARE @LogLength INT; -- Add the SELECT statement with parameter references here SELECT @LogLength = COUNT(*) FROM dbo.Events; RETURN @LogLength; --select count(*) from events where project='src.mxml' END; GO