Hi,
I'm using .NET sdk to create and update a Google Campaign and met the following issue:
I'm using the following way to create a campaign with MaxClicks bidding scheme and everything goes well:
campaign.BiddingStrategyType = BiddingStrategyType.TargetSpend;
campaign.TargetSpend = new TargetSpend();
However, when I try to update a campaign (without any actual) like:
campaign.ResourceName = campaignResourceName;
campaign.BiddingStrategyType = BiddingStrategyType.TargetSpend;
campaign.TargetSpend = new TargetSpend();
The API returns the error:
errors": [
{
"errorCode": {
"fieldMaskError": "FIELD_HAS_SUBFIELDS"
},
"message": "The field mask updated a field with subfields: 'target_spend'.",
"location": {
"fieldPathElements": [
{
"fieldName": "operations",
"index": 0
}
]
But I don't receive the error when setting "campaign.TargetSpend.CpcBidCeilingMicros" to some value in the update call.
I'm using the following way to call:
return new CampaignOperation()
{
Update = CampaignToUpdate,
UpdateMask = FieldMasks.AllSetFieldsOf(CampaignToUpdate)
};
Is the behavior expected?