|
dev
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
Incremental email updates via webdavwebdav 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\" > CAST("$adate" as 'dateTime') AND "urn:schemas:httpmail:datereceived" <= CAST("$now" as 'dateTime') </D:sql> </D:searchrequest> 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\" > CAST("$adate" as > 'dateTime') > AND "urn:schemas:httpmail:datereceived" <= CAST("$now" as > 'dateTime') > </D:sql> > </D:searchrequest> 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\" > CAST("$adate" as > > 'dateTime') > > AND "urn:schemas:httpmail:datereceived" <= CAST("$now" as > > 'dateTime') > > </D:sql> > > </D:searchrequest> 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 Is there a pointer in a mailbox like an item counter other than datenews:390b8741-f0e9-41a3-867d-39bfd7a79e19@i20g2000prf.googlegroups.com... 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\" > CAST("$adate" as > > 'dateTime') > > AND "urn:schemas:httpmail:datereceived" <= CAST("$now" as > > 'dateTime') > > </D:sql> > > </D:searchrequest>
Other interesting topics
Delegated Admin View Only
Query Exchange 2003 mailbox store (mailbox sizes etc) Intercepting emails as they are sent Forms-based authentication in Exchange 2003 AND Exchange 2007 Exchange Web Service - Listening events on all user's mailboxes Exchange 2003 store.exe CPU usage Exchange 2007 Backup/Restore API problem Adding a new property to the mail Problems adding appointments to the calendar of a different user using web services Transport Agent Debugging Question |
|||||||||||||||||||||||