Temporary table vs. Table Valued function

I need to return a table of values calculated from other tables. I have about 10 reports which will use approx. 6 different table structures.

Would it be better performance wise to create a physical table in the database to update while calculating using an identity field to id the stored procedure call, return the data and delete the records. For Example:

StrVal1,Strval2,StrVal4,IntVal1,IntVal2,FloatVal1...

Or using a table-valued function to return a temp table as the result.

I just dont know which overhead is worst, creating a table per function call, or using a defined table then deleting the result set per sp call.

[665 byte] By [RossB.] at [2007-12-21]
# 1
sorry wrong forum
RossB. at 2007-9-10 > top of Msdn Tech,SQL Server,Transact-SQL...
# 2

Moving thread to another forum.

-- Robert

RobertBrucknerMSFT at 2007-9-10 > top of Msdn Tech,SQL Server,Transact-SQL...

SQL Server

Site Classified