Web Server forum
Back To The Forum Home!Search!Private Messaging System

This is Interesting: Free IT Magazines Now Free shipping to   
Web Server Talk Web Server Talk > Web Servers reviews > BizTalk Server > BizTalk Server General > Target Namespace in schemas.




  Last Thread   Next Thread Next
  Show Printable Version Email this Page Subscribe to this Thread      Post New Thread    Post A Reply      

froque is offline     Target Namespace in schemas.  
froque


View Ip Address Report This Message To A Moderator Edit/Delete Message


Click Here to See the Profile for froque Click here to Send froque a Private Message Find more posts by froque Add froque to your buddy list
 
06-08-04 01:07 PM

I have a problem relating target namespaces in the schemas.

first :


If I set a target namespace in the schema the resulting xml will look like t
his for example:

-------------------------------------------------
<ns0:Invoice xmlns:ns0="http://HelloWorld.InvoiceSchema">
  <Number>Number_0</Number>
  <TotalPrice>TotalPrice_0</TotalPrice>
</ns0:Invoice>
-------------------------------------------------

and I need to be like this:

-------------------------------------------------
<Invoice>
  <Number>Number_0</Number>
  <TotalPrice>TotalPrice_0</TotalPrice>
<Invoice>
-------------------------------------------------

If I leave empty the target namespace for the schema, Then I get the msg as 
I want, but unfortunatelly I have to deploy in the same server another schem
a with the same root name (Invoice) and then I will get an error.

My questions is. 

If I have to specify the target namespace, how to obtain the msg in the way 
I need?




[ Post a follow-up to this message ]



    RE: Target Namespace in schemas.  
David Downing [MSFT]


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
06-09-04 10:01 PM

Try clearing the Target Namespace property.
--
Dave

This posting is provided "AS IS" with no warranties, and confers no rights.






[ Post a follow-up to this message ]



    Re: Target Namespace in schemas.  
Christof


Report This Message To A Moderator Edit/Delete Message


 
06-09-04 10:01 PM

When adhering the XML spec and guidance, you should use targetnamespaces.
Why does your XML have to look like this please?

<Invoice>
<Number>Number_0</Number>
<TotalPrice>TotalPrice_0</TotalPrice>
<Invoice>

You can't do anything with this kind of message that you can't do with a
namespaced instance...

If you *really* need it to be this way, you may remove the targetnamespace
and use a custom pipeline.  Configure the XML(dis)assembler to use one
specific XML schema then...

Kind regards,
Christof



"froque" <froque.17l3fq@mail.webservertalk.com> wrote in message
news:froque.17l3fq@mail.webservertalk.com...
>
> I have a problem relating target namespaces in the schemas.
>
> first :
>
>
> If I set a target namespace in the schema the resulting xml will look
> like this for example:
>
> -------------------------------------------------
> <ns0:Invoice xmlns:ns0="http://HelloWorld.InvoiceSchema">
> <Number>Number_0</Number>
> <TotalPrice>TotalPrice_0</TotalPrice>
> </ns0:Invoice>
> -------------------------------------------------
>
> and I need to be like this:
>
> -------------------------------------------------
> <Invoice>
> <Number>Number_0</Number>
> <TotalPrice>TotalPrice_0</TotalPrice>
> <Invoice>
> -------------------------------------------------
>
> If I leave empty the target namespace for the schema, Then I get the
> msg as I want, but unfortunatelly I have to deploy in the same server
> another schema with the same root name (Invoice) and then I will get an
> error.
>
> My questions is.
>
> If I have to specify the target namespace, how to obtain the msg in the
> way I need?
>
>
>
> --
> froque
> ------------------------------------------------------------------------
> Posted via http://www.webservertalk.com
> ------------------------------------------------------------------------
> View this thread: http://www.webservertalk.com/message254468.html
>







[ Post a follow-up to this message ]



froque is offline       
froque


View Ip Address Report This Message To A Moderator Edit/Delete Message


Click Here to See the Profile for froque Click here to Send froque a Private Message Find more posts by froque Add froque to your buddy list
 
06-10-04 08:32 AM

Hello.

Dave, thank you again... 

Christof, I need the msg to go this way.. No targetnamespaces, The receiver 
system will hang otherwhise. The parser is very simple.

Finally I left empty the targetnamespace as you told me to do.


Thank you..

Felipe Roque.




[ Post a follow-up to this message ]



    RE: Target Namespace in schemas.  
Maran


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
09-02-04 11:20 PM

There is only 2 ways BizTalk 2004 can find out what schema to use. Through
the namespace or root node name.

If you have no namespace in the incoming document you should not have any in
the schema either, but then there is "trouble" if you have other schemas
(without namespace) that are using the same namespace. How should BizTalk
know which schema to validate with?

One aproach is to specify the schemas to use by including them in the
"Document schema collection" in a "XML Disassembler" in a "Receive Pipeline"
and also in a "XML Validator" in the same pipeline. That way you can specify
which kind of documents will be valid in that pipeline and also which schema
s
to use for the validation.

Please feel free to come back with any questions.

Regards Maran

"froque" wrote:

>
> I have a problem relating target namespaces in the schemas.
>
> first :
>
>
> If I set a target namespace in the schema the resulting xml will look
> like this for example:
>
> -------------------------------------------------
> <ns0:Invoice xmlns:ns0="http://HelloWorld.InvoiceSchema">
> <Number>Number_0</Number>
> <TotalPrice>TotalPrice_0</TotalPrice>
> </ns0:Invoice>
> -------------------------------------------------
>
> and I need to be like this:
>
> -------------------------------------------------
> <Invoice>
> <Number>Number_0</Number>
> <TotalPrice>TotalPrice_0</TotalPrice>
> <Invoice>
> -------------------------------------------------
>
> If I leave empty the target namespace for the schema, Then I get the
> msg as I want, but unfortunatelly I have to deploy in the same server
> another schema with the same root name (Invoice) and then I will get an
> error.
>
> My questions is.
>
> If I have to specify the target namespace, how to obtain the msg in the
> way I need?
>
>
>
> --
> froque
> ------------------------------------------------------------------------
> Posted via http://www.webservertalk.com
> ------------------------------------------------------------------------
> View this thread: http://www.webservertalk.com/message254468.html
>
>





[ Post a follow-up to this message ]



    Re: Target Namespace in schemas.  
David Downing [MSFT]


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
09-02-04 11:20 PM

Christof is correct, by removing the target namespace, you're removing one
of the two names we use to identify a schema.  If you do find the need to
remove the target namespace because you don't have control over the XML you
receive, it's better to bind directly to these schema in the pipeline to
avoid conflicts in the future.

Dave
--------------------[vbcol=seagreen] 
cpmsftngxa10.phx.gbl!TK2MSFTFEED01.phx.gbl!TK2MSFTNGP08.phx.gbl!TK2MSFTNGP10
.phx.gbl[vbcol=seagreen] 

This posting is provided "AS IS" with no warranties, and confers no rights.

EBusiness Server Team






[ Post a follow-up to this message ]



    Re: Target Namespace in schemas.  
Todd Sussman


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
09-02-04 11:20 PM

We have a large number of projects, that use the same Root, and no
NameSpace.  We have a seperate pipeline with the XMLDisassembler pointed to
the actusal schema, and it works fine.  I also havn't noticed any major
performance issues when using a custom pipeline over the XMLReceive
pipeline.

Todd


""David Downing [MSFT]"" <ddowning@online.microsoft.com> wrote in messag
e
news:TluBKrPkEHA.2516@cpmsftngxa10.phx.gbl...
> Christof is correct, by removing the target namespace, you're removing one
> of the two names we use to identify a schema.  If you do find the need to
> remove the target namespace because you don't have control over the XML
> you
> receive, it's better to bind directly to these schema in the pipeline to
> avoid conflicts in the future.
>
> Dave
> -------------------- 
> cpmsftngxa10.phx.gbl!TK2MSFTFEED01.phx.gbl!TK2MSFTNGP08.phx.gbl!TK2MSFTNGP
10
> phx.gbl 
>
> This posting is provided "AS IS" with no warranties, and confers no
> rights.
>
> EBusiness Server Team
>







[ Post a follow-up to this message ]



    Sponsored Links  




 





   All times are GMT. The time now is 02:49 AM.      Post New Thread    Post A Reply      
  Last Thread   Next Thread Next


Most Popular forums 

Forum Jump:
Rate This Thread:

Forum Rules:
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is OFF
vB code is ON
Smilies are ON
[IMG] code is OFF
 

Back To The Top
Home | Usercp | Faq | Register