I need to set two variables in a IF EXISTS statement . First to change the subject of an email and the other is to change the recipients list. Please help.. Thanx

```
SET DATEFORMAT mdy;
GO
DECLARE @datevar date = getdate();
DECLARE @subjectCheck AS NVARCHAR(MAX);
DECLARE @email AS NVARCHAR(MAX);

IF EXISTS (SELECT CurrentDate from LOG_SHIP_CHECK WHERE CurrentDate = @datevar)
 SET @subjectCheck = 'Check LogShip: Success'
 SET @email = 'recipient1@server.com'
 ELSE
SET @subjectCheck = 'Check LogShip: Failure'; @email = 'recipient2@server.com'
DECLARE @tableHTML  NVARCHAR(MAX) ;

SET @tableHTML =
    N'<H1>Ezis Raadpleeg</H1>' + 
    N'<table border="1">' +
    N'<th>Datum</th></tr>' +
    CAST ( ( SELECT td = CurrentDate 
              FROM LOG_SHIP_CHECK 
             FOR XML PATH('tr'), TYPE 
    ) AS NVARCHAR(MAX) ) +
    N'</table>' ;

EXEC msdb.dbo.sp_send_dbmail @profile_name = 'ProfileName', @recipients=@email,
    @subject = @subjectCheck,
    @body = @tableHTML,
    @body_format = 'HTML' ;

```