Hi, I'm trying to replicate the Excel TREND() function in SQL Server to get the same result. I'm using SQL Server 2016.
Below is the code to create the temporary table of values that I'm working with:
DECLARE @t TABLE
INSERT INTO @t
SELECT '44.51' [x],
SELECT '66.31' [x],
SELECT '84.6' [x],
SELECT NULL [x],
In excel I can calculate the TREND using the following equation:
But I'd like to calculate the same result of '88.23' in SQL Server?