Hello,
I am trying to create a table containing the results of a query with lots of JOINs. I'm using SELECT...INTO. The statement runs and tells me that the correct number of rows were affected, but it doesn't create the table. I'd like opinions on why it's failing.
The query runs properly and produces the expected results without the INTO clause.
My query is:
USE MarketingAnalysis_BAK
GO
ALTER DATABASE MarketingAnalysis_BAK SET RECOVERY BULK_LOGGED;
GO
IF OBJECT_ID('dbo.RawData_SteelPoles', 'U') IS NOT NULL
DROP TABLE dbo.RawData_SteelPoles;
GO
SELECT (a long series of columns)
INTO dbo.RawData_SteelPoles
FROM (a long series of joined tables)
GROUP BY (a long series of columns)
;
GO
ALTER DATABASE MarketingAnalysis_BAK SET RECOVERY FULL;
GO
-- Thanks in advance.