473,387 Members | 1,573 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,387 software developers and data experts.

XSD - Compare consecutive elements

Is there any way of requiring the value of an element's attribute to equal the value of a child element of the previous element. What I mean is hopefully explained by the following snippet from an XML file.
Expand|Select|Wrap|Line Numbers
  1. <venue city="London">
  2. <nextvenue>Sydney</nextvenue>
  3. </venue>
  4. <venue city="Sydney">
  5. <nextvenue>Rome</nextvenue>
  6. </venue> 
I have been asked to create an XSD file for existing XML files whose structure cannot be changed, and I need to ensure that each <nextvenue> element has a value that matches the city attribute of the following <venue> element. Is this possible?
Nov 17 '09 #1
0 1527

Sign in to post your reply or Sign up for a free account.

Similar topics

8
by: Adam | last post by:
Hi, I am trying to mark consective numbers in a data set and get a count as to how many consecutive numbers exist in the a given line of data. Here is an example line: 3, 5, 7, 9, 10, 13,...
4
by: alexis | last post by:
Hi, In a form I have the curent date <input name="datetoday" type="hidden" value="<? echo date("d/m/Y"); ?>"> and <input type=text name="datebox" size=15> The date format is d/m/Y...
122
by: Einar | last post by:
Hi, I wonder if there is a nice bit twiddling hack to compare a large number of variables? If you first store them in an array, you can do: for (i = 0; i < n; i++) { if (array != value) {...
10
by: lchian | last post by:
Hi, For two stl strings s1 and s2, I got different results from strcmp(s1.c_str(), s2.c_str()) and s1.compare(s2) can someone explain what these functions do? It seems that strcmp gives...
10
by: gallerto | last post by:
Hello, I woul like to know If there is any way to allocate two positions of memory for a pointer to double but in such way that this positions are not consecutive. What I really whant is to...
9
by: rochelle28 | last post by:
i want to compare the two consecutive rows in the table such that if the first row contains handset in the category column and the next row contins simcard in category column it will alert the user,...
6
by: mservice | last post by:
Hi there, newbie to Access, I would normally use cursors in SQL Plus to do this type of thing, however I have been tasked with modifying an access 2000 application and am stuck on the VB code/query...
6
by: cesco | last post by:
Hi, say I have a vector like the following: vec = and I'd like to know via a function (for example, ConsecutiveIntegers(vec, N)) whether there are N consecutive integers. So, for example,...
5
by: =?Utf-8?B?c2lwcHl1Y29ubg==?= | last post by:
Hi I have a Container that is an an Array List of Class Each ArrayList element can be the class or a another ArrayList of Class So there the ArrayList could look like Element 1 - Class...
8
by: gigonomics | last post by:
Hi all, I hope someone can help me out. I need to return the best available seats subject to the constraint that the seats are side by side (or return X consecutive records from a table column...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
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: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
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...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
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
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,...

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.