Using SQLCMD Mode in SSMS (not the SQLCMD Utility) and a file path to a SQL query script, I would like to store the results into a temp table.
I am aware the following command executes the query from a file path, but not sure how to store the results into a temp table.
:setvar path "C:\filepath"
:r $(path)