create a function to return all the data from a table in sql code example Example: execute table valued function in sql SELECT * FROM udfProductInYear(2017);