Executing Stored Procedure: Multiple-step OLE DB operation generated errors. Check each OLE DB status value, if available. No work was done.

Answered Executing Stored Procedure: Multiple-step OLE DB operation generated errors. Check each OLE DB status value, if available. No work was done.

  • Tuesday, February 12, 2013 8:17 PM
     
     

    Hi All,

    I have the following stored procedure

    CREATE PROCEDURE [dbo].[GetEmailAddress]
           @SrcName varchar(50)
      
    AS
    BEGIN
    DECLARE @combinedString varchar(255)
    DECLARE @ToAddress varchar(255)
    SELECT @combinedString = COALESCE(@combinedString + ';','') + ToAddress ,@Toaddress =(select distinct FromAddress from dbo.acn_GetEmailDetails)
     FROM dbo.acn_GetEmailDetails
    where MailMessage='Missing File' and Flag=1  and SourceName=@SrcName  

    SELECT @combinedString,@ToAddress

    END

     I am using a SQL Task for executing this procedure,

    EXECUTE [dbo].[GetEmailAddress] ?

    I am getting the below error message,Not sure what is wrong,i checked the parameter mapping and result set ,everything look okay..

    [Execute SQL Task] Error: Executing the query "
    " failed with the following error: "Multiple-step OLE DB operation generated errors. Check each OLE DB status value, if available. No work was done.". Possible failure reasons: Problems with the query, "ResultSet" property not set correctly, parameters not set correctly, or connection not established correctly.

    Appreciate any help..

    Thanks

All Replies