How come the following doesn't work?
CREATE FUNCTION Test (@top integer)
RETURNS TABLE
AS
RETURN
SELECT TOP @top * FROM SomeTable
GO
I just want to be able to be able to specify the number of results to be returned. [SQL Server 2000.]
Thanks!