Home Forums SQLServerCentral.com Suggestions Must pass parameter number 4 and subsequent parameters as '@name = value'. After the form '@name = value' has been used, all subsequent parameters must be passed RE: Must pass parameter number 4 and subsequent parameters as '@name = value'. After the form '@name = value' has been used, all subsequent parameters must be passed

  • GOODS (6/27/2014)


    Hi Gail,

    One more question if I want multiple users to receive the email.how would I go about scripting it?

    Isn't recipients a semi-colon deliminated list? Try: -

    EXEC msdb.dbo.sp_send_dbmail

    @profile_name = 'SystemAlerts',

    @from_address = 'DBAlerts@blake.co.za',

    @recipients = 'Dlozi.Nzuke@interactivesa.co.za;nivashan.govender@interactivesa.co.za',

    @query = 'exec SP, Sp_Compare_Acc_Comment' ,

    @execute_query_database = 'IS_ND_BLAKE',

    @subject = 'Compare Table',

    @attach_query_result_as_file = 1 ;


    Forever trying to learn
    My blog - http://www.cadavre.co.uk/
    For better, quicker answers on T-SQL questions, click on the following...http://www.sqlservercentral.com/articles/Best+Practices/61537/
    For better, quicker answers on SQL Server performance related questions, click on the following...http://www.sqlservercentral.com/articles/SQLServerCentral/66909/