Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Gijs 38 posts 133 karma points
    Apr 03, 2015 @ 12:35
    Gijs
    0

    Hacking Newsletter Studio

    In some weird cases the newsletter is not send to the entire list. Resending it to the list will send it twice to the people who were in the first run, so this should be avoided. With the following query I tried to add everyone that wasn't added the first time. The thing is that the send out is now stuck. Am I missing something here? What query does the send out task do, to see to whom he should sent a newsletter? (I tried the below script with bot Status = 0 and status = 1 for the ns_EmailTrackingItems table)

    DECLARE @NewsletterId int;
    DECLARE @SubscriptionId int;
    
    SET @NewsletterId = [NEWSLETTERID];
    SET @SubscriptionId = [SUBSCRIPTIONLISTID]
    
    INSERT INTO ns_EmailTrackingItems(Newsletter_Id, SubscriberId, [Status], Name, Email, CreateDate, SubscriptionAlias)
    SELECT @NewsletterId AS Newsletter_Id, ns_Subscribers.Id, 0 As [Status], ns_Subscribers.Name, ns_Subscribers.Email, getDate(),  'NewsletterStudioSubscriptionProvider_' + CAST(@SubscriptionId AS char(1)) AS SubscriptionAlias FROM ns_Subscribers 
    LEFT JOIN ns_EmailTrackingItems ON ns_EmailTrackingItems.Email = ns_Subscribers.Email AND ns_Subscribers.SubscriptionId = @SubscriptionId AND ns_EmailTrackingItems.Newsletter_Id = @NewsletterId
    WHERE ns_Subscribers.SubscriptionId = @SubscriptionId AND ns_EmailTrackingItems.Id IS NULL
    
    
    UPDATE ns_Newsletters 
    SET Status = 2
    WHERE Id = @NewsletterId
    
  • Gijs 38 posts 133 karma points
    Apr 03, 2015 @ 15:05
    Gijs
    0

    This is what I ended up doing. Not as nice, but it worked nonetheless:

    DECLARE @NewsletterId int
    SET @NewsletterId = [NEWSLETTERID]
    UPDATE ns_Subscribers 
    SET [Status] = 4
    WHERE Id IN (
    SELECT SubscriberId FROM ns_EmailTrackingItems WHERE Newsletter_Id = @NewsletterId)
    AND [Status] = 1
    

    Copy the newsletter that was sent to too little subscribers and send it to the same list.

    Send it to the same list. Directly after the send out is started run this sql script, faking an error so that the send out stops. If you do this quickly at most 100 people will get the newsletter twice:

    DECLARE @NewsletterId int;
    SET @NewsletterId = [NEW_NEWSLETTERID];
    UPDATE ns_Newsletters SET Status = 3 WHERE Id = @NewsletterId
    
    DELETE FROM ns_EmailTrackingItems WHERE SubscriberId IN (
    SELECT Id FROM ns_Subscribers WHERE [Status] = 4) AND Newsletter_Id = @NewsletterId
    
    UPDATE ns_Subscribers
    SET [Status] = 1
    WHERE [Status] = 4
    
    UPDATE ns_Newsletters SET Status = 2 WHERE Id = @NewsletterId
    
  • keilo 568 posts 1023 karma points
    Apr 06, 2015 @ 06:55
    keilo
    0

    Hi Gijs 

    Thats one hell of a hack indeed. I read before similar issues where sending stuck in the middle and I didnt get to utilize NS yet but it will happen soon - so this is indeed interesting to see how you handled that particular case.

    Can I check if the bounce collection and marking of email address is working for you properly?

     

    cheers

  • Markus Johansson 1938 posts 5866 karma points MVP 2x c-trib
    Apr 07, 2015 @ 11:05
    Markus Johansson
    0

    Hi!

    This "hack" should not be needed as the send out should work from the beging - let's work on this one.

    What version are of Newsletter Studio are you running? Do you see any errors in the logs when the send out fails?

    / m

  • Gijs 38 posts 133 karma points
    Nov 16, 2015 @ 16:59
    Gijs
    0

    Hey Markus,

    Sorry I didn't get back to you sooner.

    It happened a few times again since last April. Today was one of those times.

    A successful sendout returns the following results in the dashboard:

    Subscribers: 13170 Sent: 16/11/2015 16:16:52 List: Scheltema Subject: Al uw cadeaus gratis bij u thuis bezorgd! Sender name: Scheltema Boekverkopers sinds 1853 Sender e-mail: [email protected]

    But that list has 15085 active subscribers.

    Umbraco v6.2.5

    Newsletter Studio v1.4.5.1

  • Markus Johansson 1938 posts 5866 karma points MVP 2x c-trib
    Nov 23, 2015 @ 14:58
    Markus Johansson
    0

    Hi!

    So what you are saying is that some of the subscribers are left out? This works in all other enviroments - might be related to duplication or errors in the validation?

    To be 100% we would need to investigate your data - would that be possible?

    Please send me a PM at markus [at sign goes here] enkelmedia.se

    // m

Please Sign in or register to post replies

Write your reply to:

Draft