Re: Database structure versus speed question

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Re: Database structure versus speed question

Timothy Washington
This post highlights a question I had regarding
relationships between nodes of xml data. XML is a tree
structure. But what if, in fig.1 for example, <f/> is
just a reference to <c/>. Is there syntax to denote
this relationship?

<a>
        <b>
                <c cid="123" />
        </b>
</a>

<d>
        <e>
                <f cid="123" />
        </e>
</d>
fig.1

XPointer and XPath just deal with the location of data
in xml documents. FLWOR expressions in XQuery can be
used for joins. And XUpdate
(http://www.smb-tec.com/xmldb/xupdate/index.html) is
still a work in progress. None of these syntaxes deal
with relationships in xml data (like primary keys in
SQL). Is there a default approach to this problem?

-- tim


On Aug 3, 2005, at 8:55 AM, Jonas Lundberg wrote:

Hi,
I need to store a number of documents, which will map
to a number of
virtual hierarchies.
The question is, will the searches be slow, when I
have a flat structure?

All content documents will be stored in one
collection, as individual xml files.
Each document will store the contents enclosed by a
contents tag.
It will also store metadata, such as authors enclosed
by a metadata tag.
It will also store several virtual locations for each
content,
enclosed by a location tag, for instance saying that
it is a blog
entry on the front page, but also an entry on an FAQ
page.
Thus, I cannot store the document in each location
(then I have two
documents), and I cannot store it in just one
location. Then if I
delete it where it is stored, it will vanish from both
locations.
Also, if I stored the document only in the FAQ folder,
then I would
have to search all documents anyway to build the blog
section.

Thus, to present one virtual location, I have to find
all documents
with that particular location, in the location tag.
For instance all
documents with a Blogs/Hans/Travel location structure.

Now, since all content documents will be stored in one
collection,
will this be much slower than if I had had a
hierarchical structure?

Best regards
Hans


-------------------------------------------------------
SF.Net email is sponsored by: Discover Easy Linux
Migration Strategies
from IBM. Find simple to follow Roadmaps,
straightforward articles,
informative Webcasts and more! Get everything you need
to get up to
speed, fast.
<a href="http://ads.osdn.com/?ad_idt77&alloc_id492&op=click">http://ads.osdn.com/?ad_idt77&alloc_id492&op=click
_______________________________________________
Exist-open mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/exist-open




       

       
               
__________________________________________________________
Find your next car at http://autos.yahoo.ca


-------------------------------------------------------
This SF.Net email is sponsored by:
Power Architecture Resource Center: Free content, downloads, discussions,
and more. http://solutions.newsforge.com/ibmarch.tmpl
_______________________________________________
Exist-open mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/exist-open