Table valued function in SQL Server; the table in the function is temporary?
<p>For the table valued functions in SQL Server, when one executes something like the following, it only creates the temporary table <code>@Table</code>, just like with the variables (in scalar-valued functions), correct? Would any issues arise if many such statements were to be executed?</p>

<pre><code>CREATE FUNCTION some_function
     (@some_var varchar(20), @someDate date)
RETURNS @Table Table (id int, name varchar(50), DoB date)
AS
BEGIN
    INSERT INTO @Table
        SELECT id, Name, CAST(DoB as date) 
        FROM tblEmployees

    RETURN
END
</code></pre>