I'm attempting to write a stored procedure that can read from a file and act on the contents
This can be done simply with powershell. Use get-content to get queries from file, invoke-sqlcmd to run the queries, and write-sqltabledata to output results to table. Save example below to .ps1 and run in powershell session passing the path to file with queries. (ex. C:\you\powershell> .\run-tsql.ps1 C:\temp\sql_queries.txt)

#paramter passed to script
param( [string] $auditlist)

#read contents of file
$queries = Get-Content $auditlist

#adds sql server module to get the sql server commands
import-module sqlserver

#cycle though all results retrived from file
foreach ($query in $queries)
{
    #run each command and load into table
    Invoke-Sqlcmd -serverinstance &lt;instance name&gt; -database &lt;databasename&gt; -query $query -OutputAs DataTables |Write-SqlTableData -ServerInstance &lt;instance name&gt; -DatabaseName &lt;dbname&gt; -SchemaName &lt;schema&gt; -TableName &lt;table&gt;
}