You could use SELECT - INTO Clause (Transact-SQL) and the bcp utility to export your file for further inspection.
SELECT - INTO Clause (Transact-SQL)
SELECT *
INTO #temp_UNION
FROM
(
SELECT *
FROM [#temp1]
UNION
SELECT *
FROM [#temp2]
UNION
SELECT *
FROM [#temp3]
UNION
SELECT *
FROM [#temp4]
UNION
SELECT *
FROM [#temp5]
) a
Cited from https://stackoverflow.com/questions/6456388/how-to-move-union-query-results-to-a-new-table
bcp Utility
bcp yourdbo.temptable out C:\Correct Path\tempfile.csv -c -U username -S Azure.database.windows.net
https://learn.microsoft.com/en-us/sql/tools/bcp-utility?view=sql-server-ver16