If your business uses relational databases to store data, it helps to use the SQL SELECT command with the INTO clause to create new tables from query results. This method isn't ANSI-standard SQL, but ...
In SQL Server 2017, when the query optimizer encounters code with a multi-statement TVF, the query optimizer will pause optimization, execute the TVF subtree to get a very accurate cardinality ...