Hi dear You need to put "return" not "returns" and also you have to tell which schema this function belongs to by default it belong to dbo hope this will help :)
create function fncube(@i int) returns int as begin declare @output int set @output = power(@i,3) return @output end SELECT dbo.fncube (3)