473,395 Members | 1,471 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

namespaces and validating with heirarchical schemas

I'm a newbie to XML and primarily program in SAS, so even though I've
consulted documentation, I can't translate into language I understand.
I hope I can explain the problem clearly.

The project I'm currently on starts with XML files (say, 10 as an
example) that, after validation, are reconfigured via SAS for Teradata
loading. Since we're in development, the location of needed schemas
isn't fixed, often moving as phases are completed or copied to local
directories. Sometimes both the server and subdirectory name changes
and sometimes the subdirectory name changes but the server doesn't.

The 10 input files validate against 4 schemas and I'm looking for a way
to generalize file paths so I only have to edit as few files as
possible--preferably one--instead of multiple files.
============================================
In the following example the schemas are in the same subdirectories.

The File1.xml header looks like this:

<?xml version="1.0" encoding="UTF-8"?>
<Schema_1 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="\\Fil-1\User1\Schema_1.xsd "
version="1.0">

The relevant lines in Schemas _1 to _3:

<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" version="2.00"
id="R2006.1">
<xs:include schemaLocation="\\Fil-1\User1\Schema_2.xsd"/>

<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" version="2.00"
id="R2006.1">
<xs:include schemaLocation="\\Fil-1\User1\Schema_3.xsd"/>

<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" version="2.00"
id="R2006.1">
<xs:include schemaLocation="\\Fil-1\User1\Schema_4.xsd"/>

Schema_4 terminates the process.
=========================================

Now, suppose Schema_4 is moved to the Development subdirectory on the
same server,

"\\Fil-1\Development\Schema_4.xsd"/

and since it's used by all input files I have a bunch of files (at
level _3) to modify. If all the Schema_3's move, I have a bunch of
level _2's to modify. If only some files move, I have different
locations for the same schema level.

In SAS I would create a global variable that resolves to the locations
and they would be passed to subsequent programs. I guess I'm looking
for a way to declare the locations in the input file. Or, is there a
way to involve another schema where I can declare the locations?

Apr 19 '06 #1
0 1421

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

Similar topics

3
by: tysontate | last post by:
I've been charged with updating old schemas for various files that have never actually been validated against each other. I've got the schema itself in good form at this point - I'm positive that...
6
by: inerte | last post by:
Hello all! I need to build an XML file structure so a client can import data to one of our systems. Totally new to XML, I learned about Namespaces and DTD, and built a nice spec using them. Now...
6
by: Iain | last post by:
I've got a system which takes an XML file, translates it into an update gram and then loads it into my database with SQLXML3 (all in dot net). But it's fragile. And the SQLXML 3 error reporting...
1
by: Ryan | last post by:
I have a very complex XDR schema that uses namespaces: xmlns="urn:schemas-microsoft-com:xml-data" xmlns:b="urn:schemas-microsoft-com:BizTalkServer" xmlns:d="urn:schemas-microsoft-com:datatypes"...
3
by: John Smith | last post by:
Ok, I am not sure if it is possible. But what I'm trying to do is validate an XML file with out having to add namespace in the xml. What I mean is lets say I have 2 XSD they have different...
1
by: Dan Bass | last post by:
There's an XML message I have, that has no namespace information. Then there is a XSD schema that is must validate against, but this has a targetNamespace and xmlns of...
0
by: blat001 | last post by:
Hi, Not 100% sure if this is the correct group to post in but. I have a class that I want to serialize/deserialize to match the MM7 specifications, which I have done but now that we are...
0
by: Patrick Brunmayr | last post by:
Hello I have a big Problem with validating a Soap Envelope. I have downloaded the xsd for a soap envelope from http://schemas.xmlsoap.org/soap/envelope/ The validation succeeds as lonng as i...
0
by: theonlydavewilliams | last post by:
Hi there I'm hoping there's an easy answer to a (hopefully) not too long-winded issue... I'm building a C# web client using a proxy wsdl.exe'd from a wsdl file and six schemas, each in a different...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
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...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
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...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

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.