473,780 Members | 2,243 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

The correct way to set XSD namespaces?

Hi, I have created a set of schemas for messages that i need to exchange
between services. I set the targetNamespace ="http://mycompany/services/abc"
and the root elements have names like FindCustomerReq uest,
FindCustomerRes ponse, CreateCustomerR equest and so on.

In Biztalk when a message of any of the above comes in, it validates
correctly because the engine sets the subscription to
"http://mycompany/services/abc#FindCustome rRequest" .

I also managed to create a webservice with these XSDs. However when creating
a proxy i got an error saying that the targetNamespace was duplicated across
schemas. The only way the system will allow me to proceed is if i change the
targetNamespace of everyone of them and add something to it (for instance,
the root element name) . Is this behavior expected? Should i make every
targetnamespace unique? the thing is, all the XSDs import an architectural
schema which defines the core types and there isnt anything special in the
XSD which is why i left the targetNamespace to be common. Perhaps this is the
wrong approach/

Anyone care to comment?

TIA,
Benjy
Jun 24 '06 #1
2 1493
If two schemas A and B have a import relationship where A imports B, then
their targetNamespace s should be different. If you want to keep their
targetNamespace the same, you should use xs:include and not xs:import. ie A
includes B

Thanks,
Priya

"BizTalk Benjamin" <Bi************ *@discussions.m icrosoft.com> wrote in
message news:F4******** *************** ***********@mic rosoft.com...
Hi, I have created a set of schemas for messages that i need to exchange
between services. I set the targetNamespace
="http://mycompany/services/abc"
and the root elements have names like FindCustomerReq uest,
FindCustomerRes ponse, CreateCustomerR equest and so on.

In Biztalk when a message of any of the above comes in, it validates
correctly because the engine sets the subscription to
"http://mycompany/services/abc#FindCustome rRequest" .

I also managed to create a webservice with these XSDs. However when
creating
a proxy i got an error saying that the targetNamespace was duplicated
across
schemas. The only way the system will allow me to proceed is if i change
the
targetNamespace of everyone of them and add something to it (for instance,
the root element name) . Is this behavior expected? Should i make every
targetnamespace unique? the thing is, all the XSDs import an architectural
schema which defines the core types and there isnt anything special in the
XSD which is why i left the targetNamespace to be common. Perhaps this is
the
wrong approach/

Anyone care to comment?

TIA,
Benjy

Jun 26 '06 #2
Thanks Priya, thats useful ....

benjy

"Priya Lakshminarayana n" wrote:
If two schemas A and B have a import relationship where A imports B, then
their targetNamespace s should be different. If you want to keep their
targetNamespace the same, you should use xs:include and not xs:import. ie A
includes B

Thanks,
Priya

"BizTalk Benjamin" <Bi************ *@discussions.m icrosoft.com> wrote in
message news:F4******** *************** ***********@mic rosoft.com...
Hi, I have created a set of schemas for messages that i need to exchange
between services. I set the targetNamespace
="http://mycompany/services/abc"
and the root elements have names like FindCustomerReq uest,
FindCustomerRes ponse, CreateCustomerR equest and so on.

In Biztalk when a message of any of the above comes in, it validates
correctly because the engine sets the subscription to
"http://mycompany/services/abc#FindCustome rRequest" .

I also managed to create a webservice with these XSDs. However when
creating
a proxy i got an error saying that the targetNamespace was duplicated
across
schemas. The only way the system will allow me to proceed is if i change
the
targetNamespace of everyone of them and add something to it (for instance,
the root element name) . Is this behavior expected? Should i make every
targetnamespace unique? the thing is, all the XSDs import an architectural
schema which defines the core types and there isnt anything special in the
XSD which is why i left the targetNamespace to be common. Perhaps this is
the
wrong approach/

Anyone care to comment?

TIA,
Benjy


Jun 27 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

18
3051
by: Steven Bethard | last post by:
In the "empty classes as c structs?" thread, we've been talking in some detail about my proposed "generic objects" PEP. Based on a number of suggestions, I'm thinking more and more that instead of a single collections type, I should be proposing a new "namespaces" module instead. Some of my reasons: (1) Namespace is feeling less and less like a collection to me. Even though it's still intended as a data-only structure, the use cases...
24
3530
by: Marcin Vorbrodt | last post by:
Here is an example of my code: //Header file #include <vector> using std::vector; namespace Revelation { // class definitions, etc... // class members are of type std::vector }
2
1592
by: Mike Morse | last post by:
What see sample that show xs:element where the xs namespace = http://www.w3.org/2001/XMLSchema However, I see another example with xsi: where xsi = http://www.w3.org/2001/XMLSchema-instance What's the difference here? Are there right and wrong namespaces? Is there a global list of the ones to use? Does the namespace even need to point at http://www.w3.org.....? Or is this just the accepted way?
17
2075
by: clintonG | last post by:
Using 2.0 with Master Pages and a GlobalBaseClass for the content pages. I understand the easy part -- the hierarchical structure of a namespace naming convention -- but the 2.0 IDE does not write a signature for the developer and after getting a good start developing a 2.0 application I thought I should go through the code and start marking classes and with namespaces. I keep getting the following 'missing' error even when using a first...
11
1792
by: Random | last post by:
I'm confused about the proper use and usefulness of namespaces. I beleive I understand the purpose is so the developer can put classes within namespaces to essentially organize your code. And I understand that you declare your intention to use a namespace within a page through the "Inherits" attribute. I know that using "Inherits" isn't absolutely necessary, it's just recommended so the developer doesn't have to type out the entire...
0
9636
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9474
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10139
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10075
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8961
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
6727
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5373
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5504
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4037
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.