Bulk upload from Google Sheets Finished successfully, but No changes + File upload Error

161 views
Skip to first unread message

Paul

unread,
May 28, 2019, 4:29:29 AM5/28/19
to Google Ads Scripts Forum
Hello,

I am unsuccessfully attempting to Bulk upload a campaign from Google Sheets to Google Ads using Google Ads Scripts.

The script logic I am using is sourced from the Developer docs

And is:

function main() {
  // The format of this spreadsheet should match a valid bulk upload template.
  // for the list of supported bulk upload templates.
  var SPREADSHEET_URL = 'INSERT_SPREADSHEET_URL_HERE';
  var spreadSheet = SpreadsheetApp.openByUrl(SPREADSHEET_URL);
  var sheet = spreadSheet.getActiveSheet();

  var upload = AdsApp.bulkUploads().newFileUpload(sheet);
  upload.forCampaignManagement();

  // Use upload.apply() to make changes without previewing.
  upload.apply();
}

The other only differences between the Developer docs & my code that I can see are: 
- I am using my own Google Sheet URL in place of INSERT_SPREADSHEET_URL_HERE
- I named the function main() because otherwise the Scripts IDE gives me an error like the screenshot below

scripts_noMainfunc.png



Here is a screenshot of my campaign Google Sheet headers and row I want to Bulk upload:

googlesheets_bulkupload_campaign.png



The column headers are based on the Bulk upload - supported entities from this Developer docs resource:
 

When I run the script, I get a Finished successfully message - but the Results show No changes.

Strangely, I also get a Finished with errors status immediately after the Script run - for a File upload Source.  

Screenshot of both messages under All bulks actions here:

all_bulk_actions_errors-0.png



How can I fix this so I can bulk upload the Google Sheets campaigns using Google Ads Scripts?

I've already read these Groups threads with no luck:

Thanks.

Google Ads Scripts Forum Advisor Prod

unread,
May 28, 2019, 5:23:09 AM5/28/19
to adwords...@googlegroups.com

Hi Paul,

So I can further investigate the issue, could you provide the following information via Reply to author privately?

  • CID
  • script name
  • access to the spreadsheet
Regards,
Hiroyuki
Google Ads Scripts Team

ref:_00D1U1174p._5001UAqoVx:ref

Paul

unread,
May 28, 2019, 12:41:42 PM5/28/19
to Google Ads Scripts Forum
Thanks, Hiroyuki. I have replied to your message privately with the requested info.

Google Ads Scripts Forum Advisor Prod

unread,
May 30, 2019, 12:57:51 AM5/30/19
to adwords...@googlegroups.com

Hi Paul,

I'm sorry for the late response and thank you for providing your CID, script name and spreadsheet.

Upon checking the documentation that you are referring to, it seems that it is out of date. In the meanwhile, the best way to determine the right set of columns and values to use is to actually download an equivalent report from the UI. The column names provided there should match the allowed column names for bulk upload. You can change the content of the sheet to match the upload changes you want to make. If you don't have any campaigns in your account, I would suggest to create one in the Google Ads UI first so that you can download the report from UI.

I'm sorry for the inconvenience, I will file a feature request to update the said documentation.

Please let me know how it goes after trying the suggestion.



Regards,
Hiroyuki
Google Ads Scripts Team



ref:_00D1U1174p._5001UAqoVx:ref
Reply all
Reply to author
Forward
0 new messages