Hi,
The campaign ID you mentioned is a *Search Network Only *campaign, not a
*Shopping* campaign. Have you tried this with a *Shopping* campaign? Also,
when you create an ad group through the API, AdWords will not automatically
create AdGroupCriterion objects for you, so it makes sense that you were
not able to find any AdGroupCriterion objects immediately after ADDing the
AdGroup.
Regarding removing the product partitions, I would *not* pass all of the
product partitions in a single mutate request. Using that approach, it's
highly likely you'll run into the PRODUCT_PARTITION_DOES_NOT_EXIST error
you mentioned earlier because of the dependencies between all of the
ProductPartitions. For example, if you have a product partition tree like
this:
A
/ \
B C
/ \
D E
and you passed REMOVE operations for A, B, C, D, and E in a single mutate
request in that order, then AdWords will:
1. Perform the REMOVE of A, which will automatically remove not only A but
B, C, D, and E as well because they are children of A
2. Attempt to perform the REMOVE of B but throw a
PRODUCT_PARTITION_DOES_NOT_EXIST because B was already removed as part of
the previous operation
Instead, you should simply pass a single REMOVE operation for A in your
mutate request.
Thanks,
Josh, AdWords API Team
On Wednesday, June 18, 2014 8:28:40 AM UTC-4, [email protected] wrote:
>
> Hi ,
>
> Sorry i can;t understand.
>
> I knew, Each Adgroup have ONLY ONE *parentCriterionId ( i-e NOT NULL or
> NOT Empty ),*
>
> i Just wanted to know about,
>
> 1. i created Adgroup using following code
>
> $adGroupService = $user->GetService('AdGroupService', ADWORDS_VERSION);
>
> // Create ad group.
> $adGroup = new AdGroup();
> $adGroup->campaignId = "24589366";
> $adGroup->name = "pla-test";
> // Create operation.
> $operation = new AdGroupOperation();
> $operation->operand = $adGroup;
> $operation->operator = 'ADD';
> // Make the mutate request.
> $result = $adGroupService->mutate(array($operation));
>
> 2. using created Adgroup id, i have used selection to get Adgroup details
> ( my Selection code in previous post, i tried with "*parentCriterionId * "
> as selection field too today)
>
> But i didn't get Any Product Partition with *parentCriterionId * HAS
> VALUE.
>
> if i get the *parentCriterionId * has value , i can make single REMOVE
> mutate request to delete all product partition within the Adgroup
>
>
> Thanks
>
>
>
>
>
--
--
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
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 [email protected]
To unsubscribe from this group, send email to
[email protected]
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 [email protected].
For more options, visit https://groups.google.com/d/optout.