This is the mail archive of the
xsl-list@mulberrytech.com
mailing list .
xsl:if or template?
- To: <XSL-List at mulberrytech dot com>
- Subject: xsl:if or template?
- From: "BoJo Allen" <rallen at griddata dot com>
- Date: Fri, 5 May 2000 09:15:36 -0700
- Reply-To: xsl-list at mulberrytech dot com
I'm having trouble with the specifics on using XSL to format my data
properly. The problem is that I need to display groups of like data. I
have written functions that format the dates and times for me, but I am
having trouble only printing the like data once. For example, I am sorting
by the <Tracker_ID> and then the <Event_GMT>. I want to then display the
Tracker_ID if it is unique followed by all the data for the specific
tracker. I have been working with scripts, xsl:if and templates to try and
solve this. Any help would be greatly appreciated.
BoJo Allen
Sample data:
<EventData xmlns:dt="urn:schemas-microsoft-com:datatypes">
<Event>
<Event_GMT dt:dt="dateTime">2000-03-14T02:15:21</Event_GMT>
<Description>Bob</Description>
<Engineering>
<Tracker_ID>1477</Tracker_ID>
</Engineering>
</Event>
<Event>
<Event_GMT dt:dt="dateTime">2000-03-14T23:12:32</Event_GMT>
<Description>Joe</Description>
<Engineering>
<Tracker_ID>1477</Tracker_ID>
</Engineering>
</Event>
<Event>
<Event_GMT dt:dt="dateTime">2000-03-15T09:57:21</Event_GMT>
<Description>Sam</Description>
<Engineering>
<Tracker_ID>1477</Tracker_ID>
</Engineering>
</Event>
<Event>
<Event_GMT dt:dt="dateTime">2000-03-14T10:11:47</Event_GMT>
<Description>George</Description>
<Engineering>
<Tracker_ID>2255</Tracker_ID>
</Engineering>
</Event>
</EventData>
Desired output:
1477
03-14-2000
2:15:21 AM - Bob
11:12:32 PM - Joe
03-25-2000
9:57:21 AM - Sam
2255
03-14-2000
10:11:47 AM - George
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list