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

Representing duplicated data in XML

Does XML have a way to refer to duplicated data?

Suppose I create a source text that consists of rules for
generating an object text of expanded material when parsed by
a program that knows the rules. Suppose that
one of the rules is long and occurs multiple times in
the source text. I want to have only one instance of this
rule in the source text for compactness and ease of editing
it later. In this example...

..
..
..
<situationsomething </situation>
<action1action specific to something </action1>
<action2>
Aug 28 '08 #1
2 1065
Charles Packer <ma*****@cpacker.orgwrote:
>Does XML have a way to refer to duplicated data?

Suppose I create a source text that consists of rules for
generating an object text of expanded material when parsed by
a program that knows the rules. Suppose that
one of the rules is long and occurs multiple times in
the source text. I want to have only one instance of this
rule in the source text for compactness and ease of editing
it later. In this example...
Why not define all your rules in one section and assign a unique ID to
each? And later simply reference that ID at the location of the
application instead of textually copying the rule. That's how it is
usually done.
However, what on earth does this have to do with Perl modules?

jue
Aug 29 '08 #2
On Aug 28, 5:04 pm, Troy Cauble <t...@alcatel-lucent.comwrote:
You could have optional id and ref elements.

<action id='myUniqueId'>blah....</action>
...
<action ref='myUniqueId'/>

with documentation saying to use a ref attribute *OR* content.
Better than documentation is something you can validate
with DTD/XML Schema/whatever. Such as

Thanks very much for your help. Is this what you had in mind?
<actiondefs>
<action id='oftendone'>
Aug 29 '08 #3

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

Similar topics

7
by: Amy | last post by:
I'm trying to add an autoincrementing id to a table based on an existing field Name, but Name has duplicated records. How can I do that in ACCESS? Thanks. Amy
1
by: anonieko | last post by:
> This is a common problem with some solution > > /*********************************************************************************** * * Problem: * Determine the Duplicated Records in a...
6
by: Niyazi | last post by:
Hi all, What is fastest way removing duplicated value from string array using vb.net? Here is what currently I am doing but the the array contains over 16000 items. And it just do it in 10 or...
3
by: PJ6 | last post by:
First up, I know I'll get some good answers here, but in general, are there any newsgroups devoted to overall application architecture? Second, sorry for cross-posting but in this case I think...
1
by: Greg | last post by:
Hi, I need to implement a table in XBRL. Let's assume I have 2 simple tables to define: TABLE 1 col1 col2 row1 A C row2 B D TABLE 2
2
by: keisha | last post by:
I have a access database. I have a form that as a field that i need to check to make sure is not been duplicated. Possible validation required? The field data type is number so the user have to input...
6
by: Ryan Liu | last post by:
Hi, If I have tens of thousands DataRow in a DataTable and allow the end user to pick any DataColumn(s) to check for duplicated lines, the data is so large, is there a better API, algorithm can...
1
by: Chris Ashley | last post by:
Hi, If I create a Bitmap object from a stream, is the data making up the image from that stream duplicated in the Bitmap object, or does the Bitmap just point to the stream somehow without...
6
by: asp2 | last post by:
I have a cursor inside a program unit in Oracle Forms 6 and its supposed to get one row from this cursor .. but in some values (only some and others not) it gets the same row twice (duplicated) in...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

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.