select count(*) as clickCount from tbl_EML_RecipientClicks with (nolock) where recipientid = and recipientId != 0 select hyperlink from tbl_EML_CampaignHyperlinks with (nolock) where campaignId = and hyperlinkId = select r.recipientId, c.campaignId, c.campaignType, c.targetListId, c.responderListId, c.fsl_tablecode, c.ownerId, r.fspro_userId from tbl_EML_CampaignRecipients r with (nolock) inner join tbl_EML_Campaign c with (nolock) on c.campaignId = r.campaignId where r.RecipientID = and r.Token = select top 1 hyperlinkId from tbl_EML_CampaignHyperlinks with (nolock) where campaignId = and hyperlink like INSERT tbl_EML_RecipientClicks ( RecipientID, Token, ClickDestination, DateTimeClicked, IPAddress, UserAgent, IgnoreClick, referer ) SELECT top 1 , , , getdate(), , , '#_ignoreClick#', FROM tbl_EML_RecipientClicks with (nolock) WHERE NOT EXISTS ( SELECT * FROM tbl_EML_RecipientClicks with (nolock) WHERE recipientid = AND clickDestination = AND DATEDIFF(minute,DateTimeClicked,getDate()) < 1 ) select orgId as partnerId, orgType as partnerType, fspro_userId from tbl_FSPro_Members with (nolock) where ownerId = and fsl_tablecode = and fspro_userId = insert into tbl_LST_PartnerLists ( ownerId, ownerType, listName, listType, partnerType, dateCreated, createdBy, locked, dateLocked, detailType, listUses, publishDate, unpublishDate ) select ownerId, ownerType, substring(listName + ' - Responders', 1, 50), listType, partnerType, getDate(), -1, 'Y', getDate(), detailType, 'SEARCH,TARGET,EMAIL', '#lsdateformat( now(), 'MM/DD/YYYY')#', '#lsdateformat( dateadd( 'yyyy', 1, now() ), 'MM/DD/YYYY' )#' from tbl_LST_PartnerLists where ownerId = and ownerType = and listId = update tbl_EML_Campaign set responderListId = where campaignId = and coalesce( responderListId, 0 ) = 0 select responderListId from tbl_EML_Campaign where campaignId = select partnerId from tbl_LST_PartnerListItems pli where listId = and partnerId = insert into tbl_LST_PartnerListItems ( listId, partnerId ) values ( , ) select detailId from tbl_LST_PartnerListItemDetails plid where listId = and partnerId = and detailId = insert into tbl_LST_PartnerListItemDetails ( listId, partnerId, detailId ) values ( , , )