Click here to Skip to main content
16,005,206 members
Home / Discussions / Database
   

Database

 
QuestionXML Support in SQL Server - does ANYONE use it? Pin
Nick Blumhardt2-Sep-01 21:42
Nick Blumhardt2-Sep-01 21:42 
GeneralFirehose mode error Pin
Not Active1-Sep-01 17:56
mentorNot Active1-Sep-01 17:56 
GeneralADO Errors Pin
_Magnus_31-Aug-01 0:54
_Magnus_31-Aug-01 0:54 
GeneralRe: ADO Errors Pin
Rashid Thadha31-Aug-01 3:08
Rashid Thadha31-Aug-01 3:08 
GeneralRe: ADO Errors Pin
_Magnus_31-Aug-01 4:03
_Magnus_31-Aug-01 4:03 
GeneralRe: ADO Errors Pin
Rashid Thadha2-Sep-01 22:21
Rashid Thadha2-Sep-01 22:21 
GeneralRe: ADO Errors Pin
_Magnus_2-Sep-01 23:50
_Magnus_2-Sep-01 23:50 
GeneralSending XML directly to a template using SQL Server & IIS Pin
Nick Blumhardt30-Aug-01 14:05
Nick Blumhardt30-Aug-01 14:05 
Hi all,

I'm trying to use IXMLHTTPRequest to send an XML document (from a C++ client app) to a template on a SQL Server. It appears IIS support is configured properly, because putting the document directly in the url works - like this:

http://myserver/virtualdir/templates/mytemplate.xml?doc='<root/>'

The template is:

<ROOT xmlns:sql='urn:schemas-microsoft-com:xml-sql'>
    <sql:header>
        <sql:param name='doc'>'default'</sql:param>
    <sql:header>
    <sql:query>
        exec usp_MySP @doc
    </sql:query>
<ROOT>


In code, I open an IXMLDOMDocument, and load xml into it. Then, I open an IXMLHTTPRequest and send the document:

hr = pIXMLHttpRequest->open(_bstr_t(_T("POST")),
                            _bstr_t(_T("http://myserver/virtualdir/templates/mytemplate.xml")),
                            _variant_t(VARIANT_FALSE),
                            _variant_t(""), _variant_t(""));

hr = pIXMLHttpRequest->setRequestHeader(_bstr_t(_T("Content-type")),
                            _bstr_t(_T("application/xml")));

hr = pIXMLHttpRequest->send((IDispatch *)pDoc);


The stored procedure always gets the default parameter, not whatever document I pass in.

Thanks for any help with this cryptic stuff

Cheers

NB
GeneralMDAC installation check Pin
John Smith30-Aug-01 0:47
John Smith30-Aug-01 0:47 
GeneralRe: MDAC installation check Pin
30-Aug-01 1:05
suss30-Aug-01 1:05 
GeneralRe: MDAC installation check Pin
Rashid Thadha30-Aug-01 1:09
Rashid Thadha30-Aug-01 1:09 
GeneralMulti-threading app using OLE DB calling into a shared Access DB Pin
Baz29-Aug-01 23:03
Baz29-Aug-01 23:03 
GeneralRe: Multi-threading app using OLE DB calling into a shared Access DB Pin
Rashid Thadha30-Aug-01 12:10
Rashid Thadha30-Aug-01 12:10 
GeneralRe: Multi-threading app using OLE DB calling into a shared Access DB Pin
Steen Krogsgaard3-Sep-01 23:25
Steen Krogsgaard3-Sep-01 23:25 
GeneralADO Refresh Method Problems (beginner) Pin
Bigge29-Aug-01 7:38
Bigge29-Aug-01 7:38 
GeneralRe: ADO Refresh Method Problems (beginner) Pin
Martin Bohring5-Sep-01 22:10
Martin Bohring5-Sep-01 22:10 
GeneralIdentity Columns Pin
27-Aug-01 8:45
suss27-Aug-01 8:45 
GeneralRe: Identity Columns Pin
Rashid Thadha30-Aug-01 12:14
Rashid Thadha30-Aug-01 12:14 
GeneralProblems with ODBC and MSACCESS Pin
Simone Giannecchini26-Aug-01 11:37
Simone Giannecchini26-Aug-01 11:37 
QuestionWhat are SQL or MSDE best practices for connections Pin
Rod Hamilton24-Aug-01 3:12
Rod Hamilton24-Aug-01 3:12 
GeneralAccess database!!!!! Pin
22-Aug-01 6:24
suss22-Aug-01 6:24 
GeneralRe: Access database!!!!! Pin
Anders Molin30-Aug-01 2:51
professionalAnders Molin30-Aug-01 2:51 
GeneralRe: Access database!!!!! Pin
Drawil6-Nov-01 20:19
Drawil6-Nov-01 20:19 
GeneralAccess 2000 Pin
21-Aug-01 3:00
suss21-Aug-01 3:00 
GeneralRe: Access 2000 Pin
CodeGuy21-Aug-01 4:59
CodeGuy21-Aug-01 4:59 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.