WebDAV search and urn:schemas:mailheader:expiry-date
Exchange Server Forum Index Exchange Server
Discussion forums for Microsoft Exchange Server users.
Microsoft Outlook
 
 FAQFAQ   MemberlistMemberlist     RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
 
Google
 
Web ExchangeServerHelp.com
WebDAV search and urn:schemas:mailheader:expiry-date

 
Post new topic   Reply to topic    Exchange Server Forum Index -> Development
Author Message
Diego Mijelshon
Guest





Posted: Tue Nov 30, 2004 12:13 am    Post subject: WebDAV search and urn:schemas:mailheader:expiry-date Reply with quote

Hi everybody.

I'm trying to get a list of messages that excludes expired ones, using the
urn:schemas:mailheader:expiry-date property.

I think the query should be something like this:

SELECT "urn:schemas:httpmail:subject"
FROM SCOPE('shallow traversal of http://server/exchange/user/inbox')
WHERE "urn:schemas:mailheader:expiry-date" > CAST("2004-11-29T00:00:00.000Z"
as "dateTime.tz")
OR "urn:schemas:mailheader:expiry-date" is null

But it doesn't work. I've tried several combinations, and it never returns
any messages with the expiry-date property set.

Any ideas?

Thanks!
Diego

Back to top
Michael
Guest





Posted: Tue Nov 30, 2004 12:28 am    Post subject: Re: WebDAV search and urn:schemas:mailheader:expiry-date Reply with quote

See our component "WebDAV .NET for Exchange".
http://www.independentsoft.com

See example how to use Search method:
http://www.independentsoft.de/webdavex/tutorial/search.html

You can specify condition like:
Condition condition1 = new Condition(propertyName[0],Operator.IsNull);
where.Add(condition1);

If you are interesting to see only "native" SQL then you can create query
with our API
and then use method "sqlQuery.ToSql()" to see "native" SQL.

Michael
-------------------------------
If you need WebDAV API for Exchange server,
use our component "WebDAV .NET for Exchange".
Check out http://www.independentsoft.com


"Diego Mijelshon" <no@thanks.com> wrote in message
news:e7RgJ8j1EHA.1152@TK2MSFTNGP14.phx.gbl...
Quote:
Hi everybody.

I'm trying to get a list of messages that excludes expired ones, using the
urn:schemas:mailheader:expiry-date property.

I think the query should be something like this:

SELECT "urn:schemas:httpmail:subject"
FROM SCOPE('shallow traversal of http://server/exchange/user/inbox')
WHERE "urn:schemas:mailheader:expiry-date"
CAST("2004-11-29T00:00:00.000Z"
as "dateTime.tz")
OR "urn:schemas:mailheader:expiry-date" is null

But it doesn't work. I've tried several combinations, and it never returns
any messages with the expiry-date property set.

Any ideas?

Thanks!
Diego

Back to top
Diego Mijelshon
Guest





Posted: Tue Nov 30, 2004 7:45 pm    Post subject: Re: WebDAV search and urn:schemas:mailheader:expiry-date Reply with quote

Michael,

Thanks for your answer.
I tried, and I get exactly the same SQL (and results) :-(

The strange thing here, is that it DOES WORK for other fields (like
DAV:creationdate)

Diego

"Michael" <michael@discussions.microsoft.com> wrote in message
news:#D94ZFk1EHA.304@TK2MSFTNGP11.phx.gbl...
Quote:
See our component "WebDAV .NET for Exchange".
http://www.independentsoft.com

See example how to use Search method:
http://www.independentsoft.de/webdavex/tutorial/search.html

You can specify condition like:
Condition condition1 = new Condition(propertyName[0],Operator.IsNull);
where.Add(condition1);

If you are interesting to see only "native" SQL then you can create query
with our API
and then use method "sqlQuery.ToSql()" to see "native" SQL.

Michael
-------------------------------
If you need WebDAV API for Exchange server,
use our component "WebDAV .NET for Exchange".
Check out http://www.independentsoft.com


"Diego Mijelshon" <no@thanks.com> wrote in message
news:e7RgJ8j1EHA.1152@TK2MSFTNGP14.phx.gbl...
Hi everybody.

I'm trying to get a list of messages that excludes expired ones, using
the
urn:schemas:mailheader:expiry-date property.

I think the query should be something like this:

SELECT "urn:schemas:httpmail:subject"
FROM SCOPE('shallow traversal of http://server/exchange/user/inbox')
WHERE "urn:schemas:mailheader:expiry-date"
CAST("2004-11-29T00:00:00.000Z"
as "dateTime.tz")
OR "urn:schemas:mailheader:expiry-date" is null

But it doesn't work. I've tried several combinations, and it never
returns
any messages with the expiry-date property set.

Any ideas?

Thanks!
Diego


Back to top
Diego Mijelshon
Guest





Posted: Tue Nov 30, 2004 7:58 pm    Post subject: Re: WebDAV search and urn:schemas:mailheader:expiry-date Reply with quote

I made it work.
The problem was that expiry-date IS *NOT* stored as dateTime field.
Back to top
 
Post new topic   Reply to topic    Exchange Server Forum Index -> Development All times are GMT
Page 1 of 1

 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum




Windows Server Dedicated Servers
New Topics Powered by phpBB