Originally posted by: gunneyk
The whole purpose of a table valued function is for returning a rowset that can be accessed just like a table. This is mainly populated with selects inside the function.
Yes, you would use a table-valued function to return CSV list values in table format.
Why on earth (and heaven) would you use functions for regular queries? Much more limited than sprocs?
Beside in SQL Server 2008 sprocs can have table parms.
Kalman Toth - Database, Data Warehouse & Business Intelligence Architect
SQL Server 2008 Training, SSAS, SSIS, SSRS: http://www.sqlusa.com/