[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

RE: How can I get context node in this complex expresi

Subject: RE: How can I get context node in this complex expresion? (current( ) didn't work)
From: "Jaime Stuardo" <jstuardo@xxxxxxxxxxx>
Date: Wed, 4 May 2005 18:07:08 -0400
cob_id
Yes, ROW has only 1 COB_ID.

How can I set XPATH version?

Let me explain you the problem I need to solve (in a simplified manner).

I have this XML:

<coberturas>
  <ROWSET>
    <ROW>
      <COB_ID>10</COB_ID>
      <COB_DESC>Description 0</COB_DESC>
    </ROW>
    <ROW>
      <COB_ID>2</COB_ID>
      <COB_DESC>Description 1</COB_DESC>
    </ROW>
    <ROW>
      <COB_ID>3</COB_ID>
      <COB_DESC>Description 2</COB_DESC>
    </ROW>
    <ROW>
      <COB_ID>5</COB_ID>
      <COB_DESC>Description 3</COB_DESC>
    </ROW>
    <ROW>
      <COB_ID>27</COB_ID>
      <COB_DESC>Description 4</COB_DESC>
    </ROW>
  </ROWSET>
</coberturas>
<cob_excluyentes>
  <ROWSET>
    <ROW>
      <CAD_ID>3</CAD_ID>
      <COB_ID>2</COB_ID>
    </ROW>
    <ROW>
      <CAD_ID>5</CAD_ID>
      <COB_ID>27</COB_ID>
    </ROW>
    <ROW>
      <CAD_ID>2</CAD_ID>
      <COB_ID>3</COB_ID>
    </ROW>
    <ROW>
      <CAD_ID>4</CAD_ID>
      <COB_ID>5</COB_ID>
    </ROW>
  </ROWSET>
</cob_excluyentes>
<cad_excluyentes>
  <ROWSET>
    <ROW>
      <CAD_ORI_ID>2</CAD_ORI_ID>
      <CAD_REL_ID>5</CAD_REL_ID>
    </ROW>
    <ROW>
      <CAD_ORI_ID>3</CAD_ORI_ID>
      <CAD_REL_ID>4</CAD_REL_ID>
    </ROW>
    <ROW>
      <CAD_ORI_ID>4</CAD_ORI_ID>
      <CAD_REL_ID>3</CAD_REL_ID>
    </ROW>
    <ROW>
      <CAD_ORI_ID>5</CAD_ORI_ID>
      <CAD_REL_ID>2</CAD_REL_ID>
    </ROW>
  </ROWSET>
</cad_excluyentes>

That XML is enclosed between a topmost tag. All XML comes from a database, so
the only thing I can modify is the fields returned, not the XML structure. The
explanation of each XML block is as follows:

1. <coberturas>
	The data I want to display
2. <cob_excluyentes>
	Represents the CAD that corresponds to this COB
3. <cad_excluyentes>
	Represents exclusions. That is, CAD_ID = 2 cannot be together with CAD_ID =
5

Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.