Home All Groups Group Topic Archive Search About

Incremental email updates via webdav

Author
26 Jan 2009 9:05 PM
Doug

I am trying to do incremental updates from a exchange users mail via a
webdav query,  but when I use dates it seems inaccurate,  is there
another or better way to get changes for a mailbox folder from one
query to the next?

Here is my current query:

<?xml version="1.0"?>
<D:searchrequest xmlns:D="DAV:">
<D:sql>
  SELECT
"urn:schemas:mailheader:bcc","urn:schemas:mailheader:cc","urn:schemas:mailheader:to",
               "urn:schemas:mailheader:message-id",
"urn:schemas:httpmail:datereceived", "DAV:contentclass",
               "urn:schemas:mailheader:from",
"urn:schemas:httpmail:fromname",
               "urn:schemas:httpmail:displayto",
"urn:schemas:httpmail:displaycc",
               "DAV:href"
  FROM "$url"
  WHERE "urn:schemas:httpmail:datereceived\" &gt; CAST("$adate" as
'dateTime')
  AND  "urn:schemas:httpmail:datereceived" &lt;= CAST("$now" as
'dateTime')
  </D:sql>
</D:searchrequest>
Author
28 Jan 2009 2:14 AM
Glen Scales [MVP]
Exchange stores dates as UTC so this mean you need to covert your datetime
to and from UTC which might account for the inaccuracies. You might want to
have a look at webdav replication which is documented in the Exchange 2003
SDK which you can download from http://msdn.microsoft.com/exchange and also
http://msdn.microsoft.com/en-us/library/dd299445.aspx

Cheers
Glen

Show quoteHide quote
"Doug" <ddal***@gmail.com> wrote in message
news:9284bd33-4f32-45ca-ae3d-bc7f2094168f@w39g2000prb.googlegroups.com...
>I am trying to do incremental updates from a exchange users mail via a
> webdav query,  but when I use dates it seems inaccurate,  is there
> another or better way to get changes for a mailbox folder from one
> query to the next?
>
> Here is my current query:
>
> <?xml version="1.0"?>
> <D:searchrequest xmlns:D="DAV:">
> <D:sql>
>  SELECT
> "urn:schemas:mailheader:bcc","urn:schemas:mailheader:cc","urn:schemas:mailheader:to",
>               "urn:schemas:mailheader:message-id",
> "urn:schemas:httpmail:datereceived", "DAV:contentclass",
>               "urn:schemas:mailheader:from",
> "urn:schemas:httpmail:fromname",
>               "urn:schemas:httpmail:displayto",
> "urn:schemas:httpmail:displaycc",
>               "DAV:href"
>  FROM "$url"
>  WHERE "urn:schemas:httpmail:datereceived\" &gt; CAST("$adate" as
> 'dateTime')
>  AND  "urn:schemas:httpmail:datereceived" &lt;= CAST("$now" as
> 'dateTime')
>  </D:sql>
> </D:searchrequest>
Are all your drivers up to date? click for free checkup

Author
28 Jan 2009 3:25 AM
Doug
Is there a pointer in a mailbox like an item counter other than date
to tell what has been added from the last query?

Regards,
Doug


Show quoteHide quote
On Jan 27, 6:14 pm, "Glen Scales [MVP]" <gsca***@outlookexchange.com>
wrote:
> Exchange stores dates as UTC so this mean you need to covert your datetime
> to and from UTC which might account for the inaccuracies. You might want to
> have a look at webdav replication which is documented in the Exchange 2003
> SDK which you can download fromhttp://msdn.microsoft.com/exchangeand alsohttp://msdn.microsoft.com/en-us/library/dd299445.aspx
>
> Cheers
> Glen
>
> "Doug" <ddal***@gmail.com> wrote in message
>
> news:9284bd33-4f32-45ca-ae3d-bc7f2094168f@w39g2000prb.googlegroups.com...
>
> >I am trying to do incremental updates from a exchange users mail via a
> > webdav query,  but when I use dates it seems inaccurate,  is there
> > another or better way to get changes for a mailbox folder from one
> > query to the next?
>
> > Here is my current query:
>
> > <?xml version="1.0"?>
> > <D:searchrequest xmlns:D="DAV:">
> > <D:sql>
> >  SELECT
> > "urn:schemas:mailheader:bcc","urn:schemas:mailheader:cc","urn:schemas:mailheader:to",
> >               "urn:schemas:mailheader:message-id",
> > "urn:schemas:httpmail:datereceived", "DAV:contentclass",
> >               "urn:schemas:mailheader:from",
> > "urn:schemas:httpmail:fromname",
> >               "urn:schemas:httpmail:displayto",
> > "urn:schemas:httpmail:displaycc",
> >               "DAV:href"
> >  FROM "$url"
> >  WHERE "urn:schemas:httpmail:datereceived\" &gt; CAST("$adate" as
> > 'dateTime')
> >  AND  "urn:schemas:httpmail:datereceived" &lt;= CAST("$now" as
> > 'dateTime')
> >  </D:sql>
> > </D:searchrequest>
Author
28 Jan 2009 4:48 AM
Doug
For example does DAV:uid increment up or an object id?
Author
28 Jan 2009 4:48 AM
Glen Scales [MVP]
There are item counts (DAV:objectcount or PR_CONTENT_COUNT) and folder size
properties but if this folder is being accessed by users then these values
could vary as users delete,move messages etc. WebDAV replication will tell
you what items have been added,deleted,moved since the last time you made a
request.

Cheers
Glen

"Doug" <ddal***@gmail.com> wrote in message
news:390b8741-f0e9-41a3-867d-39bfd7a79e19@i20g2000prf.googlegroups.com...
Is there a pointer in a mailbox like an item counter other than date
to tell what has been added from the last query?

Regards,
Doug


Show quoteHide quote
On Jan 27, 6:14 pm, "Glen Scales [MVP]" <gsca***@outlookexchange.com>
wrote:
> Exchange stores dates as UTC so this mean you need to covert your datetime
> to and from UTC which might account for the inaccuracies. You might want
> to
> have a look at webdav replication which is documented in the Exchange 2003
> SDK which you can download fromhttp://msdn.microsoft.com/exchangeand
> alsohttp://msdn.microsoft.com/en-us/library/dd299445.aspx
>
> Cheers
> Glen
>
> "Doug" <ddal***@gmail.com> wrote in message
>
> news:9284bd33-4f32-45ca-ae3d-bc7f2094168f@w39g2000prb.googlegroups.com...
>
> >I am trying to do incremental updates from a exchange users mail via a
> > webdav query, but when I use dates it seems inaccurate, is there
> > another or better way to get changes for a mailbox folder from one
> > query to the next?
>
> > Here is my current query:
>
> > <?xml version="1.0"?>
> > <D:searchrequest xmlns:D="DAV:">
> > <D:sql>
> > SELECT
> > "urn:schemas:mailheader:bcc","urn:schemas:mailheader:cc","urn:schemas:mailheader:to",
> > "urn:schemas:mailheader:message-id",
> > "urn:schemas:httpmail:datereceived", "DAV:contentclass",
> > "urn:schemas:mailheader:from",
> > "urn:schemas:httpmail:fromname",
> > "urn:schemas:httpmail:displayto",
> > "urn:schemas:httpmail:displaycc",
> > "DAV:href"
> > FROM "$url"
> > WHERE "urn:schemas:httpmail:datereceived\" &gt; CAST("$adate" as
> > 'dateTime')
> > AND "urn:schemas:httpmail:datereceived" &lt;= CAST("$now" as
> > 'dateTime')
> > </D:sql>
> > </D:searchrequest>

Bookmark and Share