473,569 Members | 2,705 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Small xml:if problem

ina
Good Morning,

My Name is Ina and I have a problem if a test in the xsl file, I am
newbie in XML transformation :)

So this is a piece of my code xml. Contracts nodes I have fund contract
<garage>
<Contracts>
<Car>
<Contracts>
<CtoF_Contrac t From_Date="" To_Date="">
<CtoF_Contract_ Type Type="Administr ator"/>
<Company_FID>Co mpany_204736</Company_FID>
</CtoF_Contract>
<CtoF_Contrac t From_Date="" To_Date="">
<CtoF_Contract_ Type Type="Firm"/>
<Company_FID>Co mpany_204785</Company_FID>
</Contracts>
<Car>

<Companies>
<Company_FID>Co mpany_204736</Company_FID>
<Company_Legal_ Name From_Date="" To_Date="">
<Company_Name>C ompany A</Company_Name>
<Legal_Type>Unk nown</Legal_Type>
</Company_Legal_N ame>
<Legal_Domici le >
<Country>USA</Country>
</Legal_Domicile>
</Company>
<Company_FID>Co mpany_204785</Company_FID>
<Company_Legal_ Name From_Date="" To_Date="">
<Company_Name>C ompany B</Company_Name>
<Legal_Type>Unk nown</Legal_Type>
</Company_Legal_N ame>
<Legal_Domici le >
<Country>GB</Country>
</Legal_Domicile>
</Company>
</Companies>
</garage>
file.xsl DOESN'T WORK
<Company>
<xsl:if test="Contracts/CtoF_Contract/Company_FID =
.../../Companies/Company/Company_FID">
<xsl:value-of
select="../../Companies/Company/Company_Legal_N ame/Company_Name"/>
</xsl:if>
</Company>
I would like to obtain
<garage>
<carName>
<Administrator> company A</Administrator>
<domicile>USA </domicile>
<Firm>company B</Firm>
<domicile>GB</domicile>
</garage>

Any suggestions?

Ina

Jun 9 '06 #1
0 921

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

Similar topics

1
2572
by: Pivo Pijem | last post by:
Hey! I have a problem loading (transforming) XML file using DOM XML extension on OpenVMS (alpha). I have installed libxml2, mysql, apache,... following steps described here (http://www.pi-net.dyndns.org/anonymous/kits/) All I want to do is:
2
3418
by: loveNUNO | last post by:
Hi ~ Plz Help me ~~ My problem is.. XBRL Sample file ------------------ a.xbrl <?xml version="1.0" encoding="utf-8"?>
1
6812
by: Christian Schmidbauer | last post by:
Hello! I prepare my XML document like this way: ------------------------------------------------------- PrintWriter writer; Document domDocument; Element domElement; // Root tag
1
1380
by: Tjerk Wolterink | last post by:
Hello i'm using php with xml. I've an rather big xsl file, that has the following code in it: <?xml version="1.0" encoding="ISO-8859-1"?> <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:page="http://www.wolterinkwebdesign.com/xml/page" xmlns:menu="http://www.wolterinkwebdesign.com/xml/menu"...
0
1491
by: James Bright | last post by:
I have set up custom Intellisense for our project. (In a nutshell, we will have ASP.NET controls based on many of the statndard WebControls, but with a few extensions that we will be adding). I've put a custom XSD in the schemas\xml directory and it works pretty great. It's largely based on the asp.xsd. My problem is that while this works...
7
6154
by: Tim.D | last post by:
Folks, I did run into a small problem afterall. Running my first SP I am seeing a number of errors in the windows 2k server event viewer. Following is a paste: -- 2004-03-03-15.06.49.967001 Instance:DB2 Node:000 PID:2444(db2syscs.exe) TID:1696 Appid:*LOCAL.DB2.0115C3193403 data management sqldEndNoLogList Probe:1 Database:dbname
5
1220
by: ina | last post by:
Hello guys, My name is ina and I have a problem with a file xlst. I am newbie and sorry for this question, probably must be very simple. I have this xml file <?xml version="1.0"?> <Datasource> <cars><car><car_Short_Name>OPEL</car_Short_Name><car_Contracts><CtoF_Contract
27
5104
by: comp.lang.tcl | last post by:
My TCL proc, XML_GET_ALL_ELEMENT_ATTRS, is supposed to convert an XML file into a TCL list as follows: attr1 {val1} attr2 {val2} ... attrN {valN} This is the TCL code that does this: set contents ]; close $fileID
9
2002
by: Sidraa | last post by:
hello i hav come across this small problem...i made a small project using Access...now what happens is when i enter the data through a form it gets calculated by a query and then gets stored in a table...when i wish to re-enter some values the form opens wid the previous values and when i replace the previous values with the new ones i get an...
0
7698
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main...
0
7612
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language...
0
7924
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. ...
1
7673
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 Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
0
6284
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then...
1
5513
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 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 a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes...
0
5219
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert...
0
3640
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
937
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating...

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.