Hi Edward,
For your code to ignore removed adgroup and keywords, you would need to use 
predicates 
<https://developers.google.com/adwords/api/docs/reference/v201710/CampaignService.Predicate>
 in 
your selector 
<https://developers.google.com/adwords/api/docs/appendix/selectorfields> as 
below:

*// For AdGroups*
    // Create selector.
    SelectorBuilder builder = new SelectorBuilder();
    Selector selector = builder
        .fields(AdGroupField.Id, AdGroupField.Name, AdGroupField.Status)
        .orderAscBy(AdGroupField.Name)
        .offset(offset)
        .limit(PAGE_SIZE)
        *.in(AdGroupField.Status,"ENABLED","PAUSED")*
        .build();

*//For Keywords*
    // Create selector.
    SelectorBuilder builder = new SelectorBuilder();
    Selector selector = builder
        .fields(
            AdGroupCriterionField.Id,
            AdGroupCriterionField.CriteriaType,
            AdGroupCriterionField.AdGroupId,
            AdGroupCriterionField.Status
            )
        .orderAscBy(AdGroupCriterionField.KeywordText)
        .offset(offset)
        .limit(PAGE_SIZE)
        .in(AdGroupCriterionField.AdGroupId, adGroupId.toString())
        .in(AdGroupCriterionField.CriteriaType, "KEYWORD")
       * .in(AdGroupCriterionField.Status, "ENABLED", "PAUSED")*
        .build();


Regards,
Dhanya, AdWords API Team

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog and Google+:
https://googleadsdeveloper.blogspot.com/
https://plus.google.com/+GoogleAdsDevelopers/posts
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API Forum" group.
To post to this group, send email to adwords-api@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/adwords-api?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"AdWords API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to adwords-api+unsubscr...@googlegroups.com.
Visit this group at https://groups.google.com/group/adwords-api.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/8dcc2c11-f01b-4bf8-af56-9106401daa82%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
  • Skip Removed... Edward Bernays
    • Re: Ski... 'Dhanya Sundararaju (AdWords API Team)' via AdWords API Forum
      • Re:... Edward Bernays
        • ... 'Dhanya Sundararaju (AdWords API Team)' via AdWords API Forum

Reply via email to