Hello Susie, The behavior you're seeing is expected for the Sandbox--all of the reporting methods are mocked out and will not generate actual reports that correspond to your Sandbox account. Except that you should see the report's status change from Pending to InProgress after a minute, so that part is odd.
If you want an actual report, you'll need to run your code against Production. Cheers, -Jeff Posnick, AdWords API Team On Jan 16, 4:23 am, Susie <[email protected]> wrote: > Hi Jeff, > > Thanks for getting back to me. I've let the code run for several > minutes but the status is remaining at Pending. > > I ran this a few times though and then later called the getAllJobs > method to see if I could retrieve details about them and, interesting, > this returns an array of four jobs: the first one is Pending, the > second one is In Progress, the third one is Completed and the final > one is Failed. > > I'm not sure if this is co-incidence or if the sandbox is hard-coded > to return this combination of reports for testing purposes? > > Also, the completed report is returning the following data: > > - <report> > - <table> > - <columns> > <column name="campaign" /> > <column name="adgroup" /> > <column name="agStatus" /> > <column name="imps" /> > <column name="clicks" /> > <column name="ctr" /> > <column name="cpc" /> > <column name="cost" /> > <column name="pos" /> > </columns> > <rows /> > </table> > - <totals> > <grandtotal imps="0" clicks="0" ctr="0.0" cpc="0" cost="0" > pos="0.0" /> > </totals> > </report> > > Again, is this a predefined report or is there any one of getting more > specific details back? I was hoping to get a daily keyword report > generated but can't see any keywords listed there. > > Many thanks, > Susie > > On Jan 15, 4:51 pm, AdWords API Advisor <[email protected]> > wrote: > > > Hello Susie, > > > I just wanted to make sure you were familiar with the behavior of the > > ReportService in the Sandbox: > > > http://code.google.com/intl/en/apis/adwords/docs/developer/adwords_ap... > > > If you wait longer than a minute does the status switch from Pending > > to InProgress? How long have you let the code run for? > > > Cheers, > > -Jeff Posnick, AdWords API Team > > > On Jan 15, 11:02 am, Susie <[email protected]> wrote: > > > > Hi there, > > > > I'm attempting to generate a report using the sandbox but the job > > > status seems to be stuck at Pending and not progressing any further. > > > > Please see below for sample code: > > > > Dim oReportService As New ReportService.ReportService > > > > 'Set up report headers. > > > With oReportService > > > .emailValue = New email > > > .emailValue.Text = New String() {"[email protected]"} > > > .passwordValue = New password > > > .passwordValue.Text = New String() {"test"} > > > .useragentValue = New useragent > > > .useragentValue.Text = New String() {"Test"} > > > .developerTokenValue = New developerToken > > > .developerTokenValue.Text = New String() > > > {"[email protected]++gbp"} > > > .applicationTokenValue = New applicationToken > > > .applicationTokenValue.Text = New String() {"TEST"} > > > End With > > > > Dim oDefinedReportJob As New DefinedReportJob > > > > 'Set up defined report job. > > > With oDefinedReportJob > > > .selectedReportType = "Keyword" > > > .name = "Keyword Report" > > > .aggregationTypes = New String() {"Daily"} > > > .adWordsType = AdWordsType.SearchOnly > > > .adWordsTypeSpecified = True > > > .keywordType = KeywordType.Exact > > > .keywordTypeSpecified = True > > > .startDay = New DateTime(2009, 1, 1) > > > .endDay = New DateTime(2009, 1, 2) > > > .selectedColumns = New String() {"Keyword", "KeywordId", > > > "KeywordTypeDisplay", "Clicks"} > > > End With > > > > 'Validate report. Validating a report job costs only 1 API > > > unit, whereas a failed call to scheduleReportJob will cost 500 API > > > units. > > > oReportService.validateReportJob(oDefinedReportJob) > > > > 'Schedule report. > > > Dim lJobId As Long = oReportService.scheduleReportJob > > > (oDefinedReportJob) > > > > 'Wait for report to finish. > > > Dim oStatus As ReportService.ReportJobStatus = > > > oReportService.getReportJobStatus(lJobId) > > > While oStatus <> ReportJobStatus.Completed And oStatus <> > > > ReportJobStatus.Failed > > > Console.WriteLine("Report job status is " & oStatus & ".") > > > Thread.Sleep(30000) > > > End While > > > > If oStatus = ReportJobStatus.Failed Then > > > Console.WriteLine("Report job generation failed.") > > > Else > > > 'Download report. > > > Dim sUrl As String = > > > oReportService.getGzipReportDownloadUrl(lJobId) > > > Console.WriteLine("Report is available at " & sUrl & ".") > > > End If > > > > Am I doing something wrong? Any pointers would be much appreciated. > > > > Many thanks, > > > Susie- Hide quoted text - > > > - Show quoted text - --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
