 |
BorlandTalk.com Borland discussion newsgroups
|
| View previous topic :: View next topic |
| Author |
Message |
Henrik Guest
|
Posted: Fri Dec 05, 2003 7:04 am Post subject: Parameters & Strings |
|
|
Hi,
I'm having an XML Document, that I want to send as parameter to my MSSQL
Server.
I want to use the following approach:
paramXMLString := inXML.getImplementation.XML.Text;
paramADOXML := cmdCommand.CreateParameter('@inXML',
adVarChar, adParamInput, 255, paramXMLString );
When I do this, I get the error -"Value is of wrong type". I've tried with
string as well as with widestring
But, if I change the code and enter:
paramXML := '';
.....
paramADOXML.Value := '<DAL typ="logMessage"><Message Sender="Henrik"
Receiver="Collins" CorrelationID="0" TransactionID="0"
Message="NoNo"/></DAL>';
then it works!!
I'm breaking my brain on this one... plz help!
cheers,
henrik
|
|
| Back to top |
|
 |
Henrik Guest
|
Posted: Fri Dec 05, 2003 7:33 am Post subject: Re: Parameters & Strings |
|
|
Problem solved, the size was the problem.
"Henrik" <henrikinderarbeit (AT) web (DOT) de> schrieb im Newsbeitrag
news:bqpamu$di1$06$1 (AT) news (DOT) t-online.com...
| Quote: | Hi,
I'm having an XML Document, that I want to send as parameter to my MSSQL
Server.
I want to use the following approach:
paramXMLString := inXML.getImplementation.XML.Text;
paramADOXML := cmdCommand.CreateParameter('@inXML',
adVarChar, adParamInput, 255, paramXMLString );
When I do this, I get the error -"Value is of wrong type". I've tried with
string as well as with widestring
But, if I change the code and enter:
paramXML := '';
....
paramADOXML.Value := '<DAL typ="logMessage"><Message Sender="Henrik"
Receiver="Collins" CorrelationID="0" TransactionID="0"
Message="NoNo"/></DAL>';
then it works!!
I'm breaking my brain on this one... plz help!
cheers,
henrik
|
|
|
| Back to top |
|
 |
|
|
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
|
|