Re: SQL Send Adapter



I am trying to use this suggestion without success so far. I get an error re:
not being able to construct a message outside a construct block. Any
suggestions/insight?

Thanks.
-John

"Alan Smith" wrote:

Hi,

You can use an expression shape in the orchestration for this.

1 Set the field for the XML part of the SQL insert message to distinguished.
2 Add an XmlDocument as an orchestration variable.
3 Create an espresstion shape
4 Add code that looks a like this:

xmlDocument = theMessageYouWantToInsertAsXml;
sqlMessage.TheFieldThatShouldCOntianThisXml = xmlDocument.OuterXml;

5 send the message

Hope this helps, shout if it dosn't.

Regards,

Alan

--
The Bloggers Guide to BizTalk
http://geekswithblogs.com/asmith



"Nikki" wrote:

Marian,

thanks for the response.

I am clear on how to create the schema and the ports; however, I'm not clear
on how to pass the input XML message to the stored procedure. Does BTS do
that automatically or do I need to map the inbound message schema to the
adapter schema? if the latter, what functoid or other mapping mechanism do I
use to
pass the entire message, not elements, as input paremeter to the stored
procedure?

Thanks!!

"Marian Drumea" wrote:

The XML schema for the stored procedure call is generated when you use
the "Add Generated Item" feature on the project in VS. Is this what you
are trying? It will ask you to provide namespace and the name for the
request and response roots, as well as the connection string and the
stored procedure you want to call.

Then, in your orchestration, you can construct the message based on the
generated schema and send it with a Send shape linked to a port of the
type also generated. BTW, you don't need to prepare the parameters on
the stored procedure in any way in order to call it from BizTalk and
there is simple change to have the result returned in XML.

Does this help?

Thanks,

Marian Drumea
http://www.MarianDrumea.com/BizTalk


.



Relevant Pages

  • Re: SQL Send Adapter
    ... "Alan Smith" wrote: ... > 1 Set the field for the XML part of the SQL insert message to distinguished. ... >> I am clear on how to create the schema and the ports; ... >> on how to pass the input XML message to the stored procedure. ...
    (microsoft.public.biztalk.general)
  • Re: SQL Send Adapter
    ... You can use an expression shape in the orchestration for this. ... Set the field for the XML part of the SQL insert message to distinguished. ... > I am clear on how to create the schema and the ports; ... > on how to pass the input XML message to the stored procedure. ...
    (microsoft.public.biztalk.general)
  • BizTalk 2004: Orchestration question, string message -> xml message transformation
    ... Stored procedure and return some data. ... flat-file which I've already made the schema for. ... on that xml. ...
    (microsoft.public.biztalk.general)
  • RE: wish to not receive a response
    ... Their is no SPROC, ... I am mapping my schema to the SQLService.xsd schema. ... > XML to SQL, and it was taking one of the element names in my bad XML and ... > In your case he thinks the stored procedure is 'spTest'. ...
    (microsoft.public.biztalk.general)
  • Re: Error: You do not have permission to update the AD schema
    ... I tried Suggestion 1 but I could not find the "Schema may be modified on ... note that I have already modified the registry of my Operations Master in ... I have set the Temp directory environment variable to the ...
    (microsoft.public.exchange.setup)