Loading ...
Sorry, an error occurred while loading the content.

Re: BasicReportRequest: startDate and endDate changed when report is returned

Expand Messages
  • verde160
    Yes, but according to the API documentation, I need to set startDate and endDate which are of the Date type. I can t set them to a string like you ve
    Message 1 of 9 , Nov 29, 2006
    • 0 Attachment
      Yes, but according to the API documentation, I need to set startDate
      and endDate which are of the Date type. I can't set them to a string
      like you've specificed. I mentioned '11/1/2006' as an example...it's
      not really a string, it's a Date.

      --- In yws-searchmarketing@yahoogroups.com, "Yahoo! Search Marketing
      Monkey" <plummerm@...> wrote:
      >
      > I think the problem is that you are sending ambiguous times.
      Date/time
      > objects need to be in UTC, specifying your timezone offset. If you
      are
      > in the Pacific Timezone, you'd say:
      > startDate='2006-11-01T00:00:00-08:00'
      > endDate='2006-11-01T23:59:59-08:00'
      >
      > Just sending '2006-11-01', and letting Yahoo servers assume you
      meant
      > UTC would put you at '2006-10-31T16:00:00-00:00'.
      >
      > Hope that helps,
      > -Y!SM Monkey
      >
      > verde160 wrote:
      > > I want to use startDate and endDate instead of dateRange since I
      need
      > > to have the ability to pull reports with a very specific date
      range.
      > > However, every time I get my report back, the dateStart and
      dateEnd
      > > fields are set to the previous day. For instance, if startDate
      > > = '11/1/2006' and endDate = '11/1/2006', my report returns...
      > >
      > > dateStart="2006-10-31-0800"
      > > dateEnd="2006-10-31-0800"
      > >
      > > Does that mean the statistics are for 10/31? How do I set the
      > > startDate and endDate to just 11/1?
      > >
      > >
      > >
      > >
      > > Yahoo! Groups Links
      > >
      > >
      > >
      >
    • Yahoo! Search Marketing Monkey
      From the WSDL for BasicReportService: And from w3.org
      Message 2 of 9 , Nov 29, 2006
      • 0 Attachment
        From the WSDL for BasicReportService:

        <xsd:element minOccurs="0" name="startDate" nillable="true"
        type="xsd:dateTime"/>

        And from w3.org (http://www.w3.org/TR/xmlschema-2/#dateTime), which is
        linked to from the online documentation:

        [Definition:] dateTime values may be viewed as objects with
        integer-valued year, month, day, hour and minute properties, a
        decimal-valued second property, and a boolean timezoned property. Each
        such object also has one decimal-valued method or computed property,
        timeOnTimeline, whose value is always a decimal number; the values are
        dimensioned in seconds, the integer 0 is 0001-01-01T00:00:00 and the
        value of timeOnTimeline for other dateTime values is computed using the
        Gregorian algorithm as modified for leap-seconds. The timeOnTimeline
        values form two related "timelines", one for timezoned values and one
        for non-timezoned values. Each timeline is a copy of the ·value space·
        of decimal, with integers given units of seconds.

        I'm not sure what language you are using, but the sample code in the
        tech portal (online docs) has proper usage of dateTime objects.

        I only used quotes to delineate, not to indicate a string.

        -Y!SM Monkey


        verde160 wrote:
        > Yes, but according to the API documentation, I need to set startDate
        > and endDate which are of the Date type. I can't set them to a string
        > like you've specificed. I mentioned '11/1/2006' as an example...it's
        > not really a string, it's a Date.
        >
        > --- In yws-searchmarketing@yahoogroups.com, "Yahoo! Search Marketing
        > Monkey" <plummerm@...> wrote:
        >> I think the problem is that you are sending ambiguous times.
        > Date/time
        >> objects need to be in UTC, specifying your timezone offset. If you
        > are
        >> in the Pacific Timezone, you'd say:
        >> startDate='2006-11-01T00:00:00-08:00'
        >> endDate='2006-11-01T23:59:59-08:00'
        >>
        >> Just sending '2006-11-01', and letting Yahoo servers assume you
        > meant
        >> UTC would put you at '2006-10-31T16:00:00-00:00'.
        >>
        >> Hope that helps,
        >> -Y!SM Monkey
        >>
        >> verde160 wrote:
        >>> I want to use startDate and endDate instead of dateRange since I
        > need
        >>> to have the ability to pull reports with a very specific date
        > range.
        >>> However, every time I get my report back, the dateStart and
        > dateEnd
        >>> fields are set to the previous day. For instance, if startDate
        >>> = '11/1/2006' and endDate = '11/1/2006', my report returns...
        >>>
        >>> dateStart="2006-10-31-0800"
        >>> dateEnd="2006-10-31-0800"
        >>>
        >>> Does that mean the statistics are for 10/31? How do I set the
        >>> startDate and endDate to just 11/1?
        >>>
        >>>
        >>>
        >>>
        >>> Yahoo! Groups Links
        >>>
        >>>
        >>>
        >
        >
        >
        >
        >
        > Yahoo! Groups Links
        >
        >
        >
      • verde160
        I m using C#.NET and the Date class. Where is the sample code? I only saw an rtf document explaining the API functions and sample report requests in XML
        Message 3 of 9 , Nov 30, 2006
        • 0 Attachment
          I'm using C#.NET and the Date class. Where is the sample code? I
          only saw an rtf document explaining the API functions and sample
          report requests in XML format (no code). I'm not sure how to change
          my startDate and endDate from a Date to a dateTime...

          Also, What are the rules for setting the time? Do I need to specify
          12:00am to 11:59pm to get a whole day's worth of results?

          --- In yws-searchmarketing@yahoogroups.com, "Yahoo! Search Marketing
          Monkey" <plummerm@...> wrote:
          >
          > From the WSDL for BasicReportService:
          >
          > <xsd:element minOccurs="0" name="startDate" nillable="true"
          > type="xsd:dateTime"/>
          >
          > And from w3.org (http://www.w3.org/TR/xmlschema-2/#dateTime), which
          is
          > linked to from the online documentation:
          >
          > [Definition:] dateTime values may be viewed as objects with
          > integer-valued year, month, day, hour and minute properties, a
          > decimal-valued second property, and a boolean timezoned property.
          Each
          > such object also has one decimal-valued method or computed
          property,
          > timeOnTimeline, whose value is always a decimal number; the values
          are
          > dimensioned in seconds, the integer 0 is 0001-01-01T00:00:00 and
          the
          > value of timeOnTimeline for other dateTime values is computed using
          the
          > Gregorian algorithm as modified for leap-seconds. The
          timeOnTimeline
          > values form two related "timelines", one for timezoned values and
          one
          > for non-timezoned values. Each timeline is a copy of the ·value
          space·
          > of decimal, with integers given units of seconds.
          >
          > I'm not sure what language you are using, but the sample code in
          the
          > tech portal (online docs) has proper usage of dateTime objects.
          >
          > I only used quotes to delineate, not to indicate a string.
          >
          > -Y!SM Monkey
          >
          >
          > verde160 wrote:
          > > Yes, but according to the API documentation, I need to set
          startDate
          > > and endDate which are of the Date type. I can't set them to a
          string
          > > like you've specificed. I mentioned '11/1/2006' as an
          example...it's
          > > not really a string, it's a Date.
          > >
          > > --- In yws-searchmarketing@yahoogroups.com, "Yahoo! Search
          Marketing
          > > Monkey" <plummerm@> wrote:
          > >> I think the problem is that you are sending ambiguous times.
          > > Date/time
          > >> objects need to be in UTC, specifying your timezone offset. If
          you
          > > are
          > >> in the Pacific Timezone, you'd say:
          > >> startDate='2006-11-01T00:00:00-08:00'
          > >> endDate='2006-11-01T23:59:59-08:00'
          > >>
          > >> Just sending '2006-11-01', and letting Yahoo servers assume you
          > > meant
          > >> UTC would put you at '2006-10-31T16:00:00-00:00'.
          > >>
          > >> Hope that helps,
          > >> -Y!SM Monkey
          > >>
          > >> verde160 wrote:
          > >>> I want to use startDate and endDate instead of dateRange since
          I
          > > need
          > >>> to have the ability to pull reports with a very specific date
          > > range.
          > >>> However, every time I get my report back, the dateStart and
          > > dateEnd
          > >>> fields are set to the previous day. For instance, if startDate
          > >>> = '11/1/2006' and endDate = '11/1/2006', my report returns...
          > >>>
          > >>> dateStart="2006-10-31-0800"
          > >>> dateEnd="2006-10-31-0800"
          > >>>
          > >>> Does that mean the statistics are for 10/31? How do I set the
          > >>> startDate and endDate to just 11/1?
          > >>>
          > >>>
          > >>>
          > >>>
          > >>> Yahoo! Groups Links
          > >>>
          > >>>
          > >>>
          > >
          > >
          > >
          > >
          > >
          > > Yahoo! Groups Links
          > >
          > >
          > >
          >
        • Yahoo! Search Marketing Monkey
          Sample Code: http://ysm.techportal.searchmarketing.yahoo.com/docs/sample_code/index.asp Since you are using .NET, you should read up on this:
          Message 4 of 9 , Nov 30, 2006
          • 0 Attachment
            Sample Code:
            http://ysm.techportal.searchmarketing.yahoo.com/docs/sample_code/index.asp

            Since you are using .NET, you should read up on this:
            http://ysm.techportal.searchmarketing.yahoo.com/docs/reference/index.asp#timezones

            -Y!SM Monkey

            verde160 wrote:
            > I'm using C#.NET and the Date class. Where is the sample code? I
            > only saw an rtf document explaining the API functions and sample
            > report requests in XML format (no code). I'm not sure how to change
            > my startDate and endDate from a Date to a dateTime...
            >
            > Also, What are the rules for setting the time? Do I need to specify
            > 12:00am to 11:59pm to get a whole day's worth of results?
            >
          • verde160
            Okay, the sample .NET code doesn t implement the BasicReportRequest object and the other line explaining .NET implementation of the timezone specifically
            Message 5 of 9 , Nov 30, 2006
            • 0 Attachment
              Okay, the sample .NET code doesn't implement the BasicReportRequest
              object and the other line explaining .NET implementation of the
              timezone specifically states "if your accounts reside in the same
              time zone as the servers that are running the code, you do not need
              to modify your code.". Why is the BasicReportService modifying my
              timezone when the report is returned? The WSDL translates the date
              properties in the BasicReportRequest to the Date type...not
              dateTime.

              Again, what time should I use for the start and end dates? 12am to
              11:59pm? Or does it matter? Since I am requesting the report in PST
              will the report return the correct information for that date (even
              though the report shows an earlier date with the PST timezone) or is
              it actually the previous day's statistics?

              --- In yws-searchmarketing@yahoogroups.com, "Yahoo! Search Marketing
              Monkey" <plummerm@...> wrote:
              >
              > Sample Code:
              >
              http://ysm.techportal.searchmarketing.yahoo.com/docs/sample_code/index
              .asp
              >
              > Since you are using .NET, you should read up on this:
              >
              http://ysm.techportal.searchmarketing.yahoo.com/docs/reference/index.a
              sp#timezones
              >
              > -Y!SM Monkey
              >
              > verde160 wrote:
              > > I'm using C#.NET and the Date class. Where is the sample code?
              I
              > > only saw an rtf document explaining the API functions and sample
              > > report requests in XML format (no code). I'm not sure how to
              change
              > > my startDate and endDate from a Date to a dateTime...
              > >
              > > Also, What are the rules for setting the time? Do I need to
              specify
              > > 12:00am to 11:59pm to get a whole day's worth of results?
              > >
              >
            • Yahoo! Search Marketing Monkey
              ... There s no modification going on on the server side. It s interpretation. Remember that the server won t know what timezone you are in, so you need to
              Message 6 of 9 , Nov 30, 2006
              • 0 Attachment
                > Okay, the sample .NET code doesn't implement the BasicReportRequest
                > object and the other line explaining .NET implementation of the
                > timezone specifically states "if your accounts reside in the same
                > time zone as the servers that are running the code, you do not need
                > to modify your code.". Why is the BasicReportService modifying my
                > timezone when the report is returned? The WSDL translates the date
                > properties in the BasicReportRequest to the Date type...not
                > dateTime.

                There's no modification going on on the server side. It's
                interpretation. Remember that the server won't know what timezone you
                are in, so you need to specify dateTime with a timezone offset properly.
                I'm not sure what you meant by the last sentence.

                > Again, what time should I use for the start and end dates? 12am to
                > 11:59pm? Or does it matter? Since I am requesting the report in PST
                > will the report return the correct information for that date (even
                > though the report shows an earlier date with the PST timezone) or is
                > it actually the previous day's statistics?

                Assume that the date returned is indeed the date reported on. If you
                pass in a dateTime object with UTC offsets, you'll get the correct
                expected response. I am not 100% sure about using 12am or 11:59pm, but
                a small bit of experimentation should do the trick. Reports really
                aren't able to be pulled for specific times, only full days, so using
                dateTime is a bit of a misnomer, but still the required usage for now.

                Hope this helps,
                -Y!SM Monkey
              • jim_nicholsonva
                ... I m not sure if anyone is still replying to this thread, but here goes So from what I gather, all I have to do in order to ensure the correct reporting
                Message 7 of 9 , Jul 24, 2009
                • 0 Attachment
                  --- In yws-searchmarketing@yahoogroups.com, "Yahoo! Search Marketing Monkey" <plummerm@...> wrote:
                  >
                  > > Okay, the sample .NET code doesn't implement the BasicReportRequest
                  > > object and the other line explaining .NET implementation of the
                  > > timezone specifically states "if your accounts reside in the same
                  > > time zone as the servers that are running the code, you do not need
                  > > to modify your code.". Why is the BasicReportService modifying my
                  > > timezone when the report is returned? The WSDL translates the date
                  > > properties in the BasicReportRequest to the Date type...not
                  > > dateTime.
                  >
                  > There's no modification going on on the server side. It's
                  > interpretation. Remember that the server won't know what timezone you
                  > are in, so you need to specify dateTime with a timezone offset properly.
                  > I'm not sure what you meant by the last sentence.
                  >
                  > > Again, what time should I use for the start and end dates? 12am to
                  > > 11:59pm? Or does it matter? Since I am requesting the report in PST
                  > > will the report return the correct information for that date (even
                  > > though the report shows an earlier date with the PST timezone) or is
                  > > it actually the previous day's statistics?
                  >
                  > Assume that the date returned is indeed the date reported on. If you
                  > pass in a dateTime object with UTC offsets, you'll get the correct
                  > expected response. I am not 100% sure about using 12am or 11:59pm, but
                  > a small bit of experimentation should do the trick. Reports really
                  > aren't able to be pulled for specific times, only full days, so using
                  > dateTime is a bit of a misnomer, but still the required usage for now.
                  >
                  > Hope this helps,
                  > -Y!SM Monkey
                  >

                  I'm not sure if anyone is still replying to this thread, but here goes

                  So from what I gather, all I have to do in order to ensure the correct reporting dates is to convert the local dateTime to UTC prior to submitting the request. Is that right?
                Your message has been successfully submitted and would be delivered to recipients shortly.