Topic Last Modified: 2006-06-12
The following is a sample client/server dialog. The client requests
the creation of a search folder at the URL
"http://somedomain.example.com/public2/ps1/" that contains the items that
satisfy the following Structured Query Language (SQL) SELECT Statement:
SELECT *
FROM scope('shallow traversal of
"http:// somedomain.example.com/public2/templates/"')
WHERE "DAV:ishidden" = False
AND "DAV:contentclass" = "urn:schemas-mydomain-tld:reporttemplate"
The client connects to port 80 (
HTTP) on
the host with Domain Name System (DNS) name somedomain.example.com and sends
the command in the following example to the server. (Note that, for purposes of
brevity and clarity, some standard headers that are usually sent with these
requests (such as Accept-Language:) have been omitted from this example.)
MKCOL /pub2/templates/search_folder/ HTTP/1.1
Host: somedomain.example.com
Content-Length: XXX
Content-type: text/xml
<?xml version="1.0"?>
<a:propertyupdate xmlns:a="DAV:">
<a:set>
<a:prop>
<a:searchrequest>
<a:sql>
SELECT *
FROM scope('shallow traversal of
"http://somedomain.example.com/pub2/templates"')
WHERE "DAV:ishidden" = False
AND "DAV:contentclass" = "urn:schemas-mydomain-tld:reporttemplate"
</a:sql>
</a:searchrequest>
</a:prop>
</a:set>
</a:propertyupdate>
The server then sends the following
response to the client:
HTTP/1.1 207 Multi-Status
Server: Microsoft-IIS/5.0
Date: Tue, 22 Feb 1999 12:54:46 GMT
WWW-Authenticate: Negotiate AADAB...
MS-Exchange-Permanent-URL:
http://hostname/pub2/-FlatUrlSpace-/ab7e2af09631
b745981c6d39445456f2-17/
Location: http://hostname/pub2/templates/search_folder/
Timeout: Infinity
Repl-UID: <rid:ab7e2af09631b745981c6d39445456f2000000001371>
Content-Type: text/xml
Content-Length: XXX
ResourceTag: <rt:ab7e2af09631b745981c6d39445456f200000000
1371ab7e2af09631b745981
c6d39445456f2000000001573>
<?xml version="1.0"?>
<a:multistatus xmlns:a="DAV:">
<a:response>
<a:href>
http://hostname/pub2/templates/search_folder
</a:href>
<a:status>HTTP/1.1 201 Created</a:status>
<a:propstat>
<a:status>HTTP/1.1 200 OK</a:status>
<a:prop><a:searchrequest/></a:prop>
</a:propstat>
</a:response>
</a:multistatus>
After
this successful response has been sent, the
Exchange store begins
populating the search folder with the items that satisfy the SQL request. Be
aware that not all items that match the criteria appear in the search folder
until the
Exchange store completes the construction of the folder.
Note: |
|---|
|
The server has sent a different Timeout
value for the search. The Location header returned can be different from the
value sent by the client when the MKCOL Method request was made.
|