Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » M2T (model-to-text transformation) » Could be bug in JET
Could be bug in JET [message #37202] Fri, 30 November 2007 02:43 Go to next message
Eclipse UserFriend
Originally posted by: Thiru.Anugu.Summit.Fiserv.com

XML:

<?xml version="1.0" encoding="UTF-8"?>
<root xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<module>
<entity>
<column name="col1>
<FCM/>
</column>

<column name="col2"/>

</entity>
</uimodule>
</root>

JET Template:

<c:iterate select="/summit/module/entity/column" var="curColumn">

Col: <c:get select="$curColumn/@name" /> = FCM COUNT: <c:get
select="count($curColumn/FCM)" />

</c:iterate>

Output:

Col: col1 = FCM COUNT: 1
Col: col2 = FCM COUNT: 0

This is perfect output.

***************************************************

<?xml version="1.0" encoding="UTF-8"?>
<root xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="../schema/mySchemaName.xsd">
<module>
<entity>
<column name="col1>
<FCM/>
</column>

<column name="col2"/>

</entity>
</module>
</root>

Output for the sample JET template

Col: col1 = FCM COUNT: 1
Col: col2 = FCM COUNT: 1

col2 supposed to be '0'. The problem was if I specify the namespace
location of the XSD schema(2nd XML) then the result was incorrect.

How can I resolve this issue?

-Thiru
Re: Could be bug in JET [message #37270 is a reply to message #37202] Fri, 30 November 2007 03:13 Go to previous message
Eclipse UserFriend
Originally posted by: Thiru.Anugu.Summit.Fiserv.com

The right JET template for the previous posting was.


JET Template:

<c:iterate select="/root/module/entity/column" var="curColumn">

Col: <c:get select="$curColumn/@name" /> = FCM COUNT: <c:get
select="count($curColumn/FCM)" />

</c:iterate>


-Thiru
Previous Topic:Executing JET Transformations in ANT
Next Topic:NullPointer
Goto Forum:
  


Current Time: Fri Apr 19 11:02:32 GMT 2024

Powered by FUDForum. Page generated in 0.02420 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top