Hello, first post on this group
I've had a performance problem with an insert query based on a selection. The query is something like:INSERT INTO FRED SELECT DATA FROM MARTHA
I've been firing this SQL statement at my SQL Server database using ADO Version 2.5 using this statement:mConnection.Execute vstrSQL, , adExecuteNoRecords
But I get better performance passing in the SQL statement directly into a stored procedure that just executes the SQL statement. Any thoughts?Thanks, Kevin.CREATE PROCEDURE amsp_SQLSubmit@SQL varchar(1000)ASselect @SQL=replace(@SQL,'`','''')set nocount on exec (@SQL)GO
Note - in passing in the string to SQL Server I'm replacing the ' with ' and decoding.