XML Editor
Sign up for a WebBoard account Sign Up Keyword Search Search More Options... Options
Chat Rooms Chat Help Help News News Log in to WebBoard Log in Not Logged in
Show tree view Topic
Topic Page 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 Go to previous topicPrev TopicGo to next topicNext Topic
Postnext
Henry FangSubject: Stylus Studio crash - log attached
Author: Henry Fang
Date: 06 Feb 2002 09:36 PM
This is how it happened:

1) open an existing XSLT file (myXSLT.xslt) in Studio.

2) specify source and target DTDs for the XSLT.

3) Studio displayed both DTDs fine in 'XML Mapper' panel, as well as the mapping rules.

4) Now click on other panels, such as 'XSL source' or 'params/other', "Application Error" window pops out, saying unrecoverable error occured. So I'm attaching the log, as well as the XSLT, and both DTDs.



Anything wrong w/ my files, or it's a product bug?



Thanks,

Henry Fang


ApplicationmyXSLT.xslt


Applicationsource.dtd
source interface definition

Applicationtarget.dtd
target interface definition

DocumentmyXSLT(1).xslt


Documentsource(1).dtd
source interface definition

Documenttarget(1).dtd
target interface definition

DocumentStruzzo(77).log
log

Postnext
Henry FangSubject: Stylus Studio crash - log attached
Author: Henry Fang
Date: 06 Feb 2002 09:44 PM
Sorry I attached the XSLT, DTD files mistakingly as wrong file type, then reattched as correct type. Pls ignore those file s w/"application" type.

Henry

Postnext
Minollo I.Subject: Re: Stylus Studio crash - log attached
Author: Minollo I.
Date: 06 Feb 2002 09:56 PM
Henry,
if there is a crash, there is a bug; and we will fix it.

But in this specific case you can easily workaround the problem: mapper
assumes that mapping stylesheets begin with the "stylesheet" element, and
not with the "transform" one (the XSLT processor properly handles both of
them).

As "stylesheet" and "transform" are synonyms in XSLT 1.0, you can modify
the top-level element into {x:stylesheet}...{/x:stylesheet}
That will fix the crash.

Sorry for the trouble,
Minollo

Postnext
Henry FangSubject: Re: Stylus Studio crash - log attached
Author: Henry Fang
Date: 06 Feb 2002 10:10 PM
Carlo,

I just tried your suggestion. Still crash.
Attached log again.

Thanks,
Henry


DocumentStruzzo(78).log

Postnext
Henry FangSubject: Re: Stylus Studio crash - log attached
Author: Henry Fang
Date: 06 Feb 2002 10:38 PM
Carlo,

Thanks for quick response. I'm on Studio 3.1, build 069k.
Here's the steps:
1) click 'open', select myXSLT.xslt. Studio displays XSLT source correctly in "XSLT source" panel.
2) click on "XML Mapper" panel, "choose source and destination schema" window pops out, select source.dtd as source and source_feed as its root, then select target.dtd as destination and path_env as its root. Both schemas are displayed fine, with the rules also displayed.
3) click on either "XSLT source" or "params/other" panel, the crash error window pops out.

Regarding the Xalan issue, I did define the external Xalan-J processor in menu option -> Plugin Settings -> XSLT Editor -> external XSLT. Pls check the attached screenshot. Xalan is reachable on command line with the same classpath provided. Any other suggestions?

Thanks,
Henry


Documentscreenshot(1).doc

Postnext
Minollo I.Subject: Re: Stylus Studio crash - log attached
Author: Minollo I.
Date: 06 Feb 2002 11:07 PM

>...
>Here's the steps:
>1) click 'open', select myXSLT.xslt. Studio displays XSLT source correctly
>in "XSLT source" panel.
>2) click on "XML Mapper" panel, "choose source and destination schema"
>window pops out, select source.dtd as source and source_feed as its root,
>then select target.dtd as destination and path_env as its root. Both
>schemas are displayed fine, with the rules also displayed.
>3) click on either "XSLT source" or "params/other" panel, the crash error
>window pops out.

Yup; now I can reproduce it; I was missing the selection of the proper roots.
We will work on it as soon as possible; we'll let you know when a patch is
available.

>Regarding the Xalan issue, I did define the external Xalan-J processor in
>menu option -> Plugin Settings -> XSLT Editor -> external XSLT. Pls check
>the attached screenshot. Xalan is reachable on command line with the same
>classpath provided. Any other suggestions?

No; we are trying to understand what might be going wrong; but we don't
have suggestions at this point.
We may have to ask you to run an instrumented version of Stylus Studio that
logs some more information about this issue; would you be willing to run it
for us on your box?

Thanks,
Minollo

Postnext
Henry FangSubject: Re: Stylus Studio crash - log attached
Author: Henry Fang
Date: 07 Feb 2002 03:35 AM
Carlo,

As long as I don't have to uninstall my current install, I sure can do it.

Now I have another issue: I have a DTD, whose root element is "ADD_QUOTE". Well, happen to be another element several levels down with the same name. After I select this name as the root element when I open the schema, the studio only displays the later. Anyway to set default to open schema root element? Or anyway I can select which element when multiple elements shares the same name? Attached is the DTD.

Thanks,
Henry


Applicationoagis_domains.dtd


Documentoagis_domains(1).dtd


Documentoagis_extensions.dtd


Documentoagis_fields.dtd


Documentoagis_resources.dtd


Documentoagis_resources(1).dtd


Documentoagis_segments.dtd


DocumentVegaSoft_TargetInterface.dtd
Base DTD, referencing other DTDs

Postnext
Minollo I.Subject: Re: Stylus Studio crash - log attached
Author: Minollo I.
Date: 07 Feb 2002 09:27 AM

>...
>Now I have another issue: I have a DTD, whose root element is "ADD_QUOTE".
>Well, happen to be another element several levels down with the same name.
>After I select this name as the root element when I open the schema, the
>studio only displays the later. Anyway to set default to open schema root
>element?

DTD and XML Schema don't have any notion of schema root; the schema root is
set in the context of the XML using that DTD or that XML Schema; in theory
you could use the same DTD or XM Schema for different XML all choosing
different roots. That's why we give you a chance to choose it.

>Or anyway I can select which element when multiple elements shares the
>same name? Attached is the DTD.

We understand the problem; the solution will be to better qualify
duplicated paths so that you can choose among them. Let us see if this is
something we can do as a quick fix.

Thanks,
Minollo

Postnext
Minollo I.Subject: Re: Stylus Studio crash - log attached
Author: Minollo I.
Date: 07 Feb 2002 11:58 AM

>...
>Now I have another issue: I have a DTD, whose root element is "ADD_QUOTE".
>Well, happen to be another element several levels down with the same name.
>After I select this name as the root element when I open the schema, the
>studio only displays the later. Anyway to set default to open schema root
>element? Or anyway I can select which element when multiple elements
>shares the same name? Attached is the DTD.

Actually, thinking about this again, and seeing that you are talking about
DTD and not XML Schema, I'm a bit puzzled.
How can you define the same element in two different ways in the same DTD?
That would be possible in XML Schema; but DTD is flat.

Looking at the DTDs you attached, ADD_QUOTE is defined only once; then you
have an ADD_QUOTE_002 definition, but that's a different element.
Or what is confusing you is the fact that ADD_QUOTE can be interpreted both
as a root and as a sub-element of another element?

Minollo

Postnext
Henry FangSubject: Re: Stylus Studio crash - log attached
Author: Henry Fang
Date: 07 Feb 2002 01:54 PM
In this case, ADD_QUOTE is used both as root element and sub-element of another element in the same XML doc. It's allowed, right?
Another question, does Studio store and display the element or attribute properties of DTD or schema (and allow user modify?), such as whether it's required, optional, empty, or even have enumerate values or value ranges? I can't find it anywhere. I'm asking 'cuz I'm losing some requirement elements on target side when those are not mapped to anything on source side. Attached is the XSLT, source/target DTD, and the output XML. As you can see, 'CNTROLAREA' is required element, but is missing in output. Any thoughts?
Sorry to strech the questions broader, really appreacite all your help!!

Henry


DocumentVegaSoft_to_OAG.xsl


DocumentVegaSoft_SourceInterface.dtd


DocumentVegaSoft_TargetInterface(1).dtd

Postnext
Minollo I.Subject: Re: Stylus Studio crash - log attached
Author: Minollo I.
Date: 07 Feb 2002 02:06 PM
At 02:04 PM 2/7/2002 -0500, you wrote:
>From: "Henry Fang"
>
>In this case, ADD_QUOTE is used both as root element and sub-element of
>another element in the same XML doc. It's allowed, right?

Yes; but what's the problem with how Stylus Studio handles this? No matter
from where you start, the sub-tree below ADD_QUOTE is the same.

>Another question, does Studio store and display the element or attribute
>properties of DTD or schema (and allow user modify?), such as whether it's
>required, optional, empty, or even have enumerate values or value ranges?
>I can't find it anywhere. I'm asking 'cuz I'm losing some requirement
>elements on target side when those are not mapped to anything on source side.

It does in the DTD editor; Mapper doesn't allow you to take advantage of
that kind of information.

>Attached is the XSLT, source/target DTD, and the output XML. As you can
>see, 'CNTROLAREA' is required element, but is missing in output. Any thoughts?

As mentioned, Mapper doesn't do anything to enforce DTD/XML Schema
restrictions. As your mapping is not defining a mapping for CNTROLAREA,
that element is not created.
If CTTROLAREA only needs to be created with a fixed value, you can right
click on it and choose "Set Literal Value..."; that will force it's
creation with the specified value.

In a few hours we will have a new version fixing the crashes you have
reported yesterday night; it will also contain some additional
instrumentation to let us understand why you are being unable to run
Xalan-J debugging. I'll let you know when that's ready for download.

Thanks,
Minollo

Postnext
Henry FangSubject: Re: Stylus Studio crash - log attached
Author: Henry Fang
Date: 07 Feb 2002 02:39 PM
1) My problem or puzzle on Studio is it always only displays "ADD_QUOTE" which is the sub-element (i.e. only part of the DTD is displayed and can be mapped) but not the real root element.
2) I probably confused you. I'm not trying to modify the DTD. Studio should keep all those properties when import the DTD. My understandng is even though some required elements are not mapped, they'll be in target as empty elements. I assume I only use the 'set literal vale' when those elements are assigned fixed values. Correct me if I'm wrong.
It might be easier for us to clear some issues over the phone, if that's ok to you. My office phone is 408-570-8855. Feel free to call me. Or I can call you if you prefer that way and let me know your phone #.
Thanks a lot on the quick response, looking forward to getting the fix version.

Henry

Postnext
Henry FangSubject: Re: Stylus Studio crash - log attached
Author: Henry Fang
Date: 07 Feb 2002 04:49 PM
Minollo,

Thanks for the call. Attached are the DTDs I mentioned regarding the falttening mapping issue. The source DTD is SO_CRM.dtd, while the target is SO_ERP.dtd.
Here's the requirements: XMLDoc -> Body -> LineItemsDetails is a top repeating element, Schedules is its sub, also repeating, element. On target side, PurchaseOrderAcknowledgement ->LineItem is also a repeating element. The requirement is, its sub element 'LineNumber' (target side), needs to get values from both 'LineNumber' (source side) and 'ScheduleID', i.e., the 'LineNumber' (target side) value should be concat of 'LineNumber' (source side) and 'ScheduleID'. Besides, 'ItemNumber' (source) map to 'ItemId' (target), and 'Quantity' under 'Schedules' (source) map to 'Quantity' under 'LineItem' (target).
Hope I explained clearly. If not, feel free to contact me by phone or email.

Thanks,
Henry


DocumentSO_CRM.dtd
source interface definition

DocumentSO_ERP.dtd
target interface definition

DocumentSO_CRMtoERP.xsl
incomplete map

Postnext
Minollo I.Subject: Re: Stylus Studio crash - log attached
Author: Minollo I.
Date: 07 Feb 2002 06:06 PM
First of all: an updated 3.1 BL69l installation package is now available on:
http://www.stylusstudio.com/update
It fixes the crashes you have reported yesterday, and addresses a couple of
other issues. I would recommend that you download and install it before
doing any additional work on Stylus Studio.

This version also dumps some additional information in the struzzo.log file
when an external process (like Xalan-J processing) is spawned. If you still
have troubles in that area, please send us the most updated struzzo.log
file you have.

Back to your Mapper question.
From what I can understand, I would guess you need a block like this in
your mapping:

{xsl:for-each select="XMLDoc/Body/LineItemsDetails/LineNumber"}
{LineItem}
{!-- maybe you don't need to copy the LineNumber source value in the
target --}
{xsl:value-of select="."/}
{LineNumber}
{xsl:for-each select="../Schedules/ScheduleID"}
{!-- concatenate LineNumber (source) with ScheduleIDs --}
{xsl:value-of select="../../LineNumber"/}
{xsl:value-of select="."/}
{/xsl:for-each}
{/LineNumber}
{!-- one-to-one mapping ItemId->ItemNumber? -->
{ItemId}
{xsl:value-of select="../ItemNumber"/}
{/ItemId}
{Quantity}
{xsl:for-each select="../Schedules/Quantity"}
{!-- concatenate Quantity (repeating on source) on flat target?
weird -->
{xsl:value-of select="."/}
{/xsl:for-each}
{/Quantity}
{/LineItem}
{/xsl:for-each}

Assuming this (or something similar to this) is what you want to do, I'm
sure your next question will be: how to do that in Mapper?
Well, in Mapper you can't currently visually create blocks like
{LineNumber}
{for-each}
content
{/for-each}
{/LineNumber}

but only blocks like:
{for-each}
{LineNumber}
content
{/LineNumber}
{/for-each}

In order to let you visually create blocks with internal and not external
for-eaches, we will have to expose the concepts of text nodes in the GUI
somehow; that was something we did in past beta releases, but we removed it
because it was creating confusion; but we can probably bring it back
on-demand at least on some elements.

In the meanwhile, you can draw normal repeating arcs in Mapper, and then
move the for-each inside the generated element in the XSLT source. Build
69l which is now available fixes a problem which made Mapper mess this
change in the source when going back to Mapper.

Hope this helps; you are being an excellent source of information for us
not only to fix bugs, but also to understand in which directions we should
move in the future with the Mapper functionality in Stylus Studio.

Thanks for your patience,
Minollo

Postnext
Henry FangSubject: Re: Stylus Studio crash - log attached
Author: Henry Fang
Date: 07 Feb 2002 10:23 PM
Minollo,

1) I installed the updated version. It did fix the crash problem. :)
2) Still have the problem running external Xalan-J processor in the Studio. Attached is the log. I took a look at it, from the path info. in the log, seems the path of java.exe I specified in either Menu Option or Scenario is not picked up. And I noticed JDK 1.3 is not in my System or User path. so I added my JRE 1.3\bin to my user path, and then it worked, which confirmed my observation. Why it's not picked up? Let me know if you nedd more info. Anyway, I'm glad I found a way to get around.
3) I'll look into your instructions on the flatterning issue, try it and get back to you. I'm so impressed with the speed your guys fixing problems.
4) I mentioned to you this morning, now it looks a big issue to me: the required elements on target side are missing if it's not mapped and not assigned with a literal value. The transformation result is not acceptable 'cuz XML validation could be just the downstream operation. In real life, it could be many, maybe thousands of unmapped elements. It's a tedious and error-prone job for a user have to assign literal values to each of those elements. It would be nice the tool automatically assigns an empty literal value to all non-mapped required elements. Could you raise this as an urgent enhancement request? Let me know your thoughts.

Henry


DocumentStruzzo(79).log

Postnext
Minollo I.Subject: Re: Stylus Studio crash - log attached
Author: Minollo I.
Date: 07 Feb 2002 10:44 PM

>...
>1) I installed the updated version. It did fix the crash problem. :)

This is good.

>2) Still have the problem running external Xalan-J processor in the
>Studio. Attached is the log. I took a look at it, from the path info. in
>the log, seems the path of java.exe I specified in either Menu Option or
>Scenario is not picked up. And I noticed JDK 1.3 is not in my System or
>User path. so I added my JRE 1.3\bin to my user path, and then it worked,
>which confirmed my observation. Why it's not picked up? Let me know if you
>nedd more info. Anyway, I'm glad I found a way to get around.

Yup; reading the log file it looks like we are ignoring the additional path
you specified in the scenario window. We are investigating.

>...
>4) I mentioned to you this morning, now it looks a big issue to me: the
>required elements on target side are missing if it's not mapped and not
>assigned with a literal value. The transformation result is not acceptable
>'cuz XML validation could be just the downstream operation. In real life,
>it could be many, maybe thousands of unmapped elements. It's a tedious and
>error-prone job for a user have to assign literal values to each of those
>elements. It would be nice the tool automatically assigns an empty literal
>value to all non-mapped required elements. Could you raise this as an
>urgent enhancement request? Let me know your thoughts.

I think this is relatively easy to achieve. Let me have a chat with the
rest of the group tomorrow; we'll let you know soon.

Thanks,
Minollo

Postnext
Henry FangSubject: Re: Stylus Studio crash - log attached
Author: Henry Fang
Date: 08 Feb 2002 02:20 AM
Minollo,

One more added regarding 4), it would be a very big plus if Studio can display the properties of the element/attributes so mappers have visual awareness during mapping, such as display uniquely for repeat elements or something like that. I don't quite agree what you said this morning on Studio should display the superset of the schema, I think it should display exactly what the schema defines.

Thanks,
Henry

Postnext
Minollo I.Subject: Re: Stylus Studio crash - log attached
Author: Minollo I.
Date: 08 Feb 2002 09:07 AM

>...
>One more added regarding 4), it would be a very big plus if Studio can
>display the properties of the element/attributes so mappers have visual
>awareness during mapping, such as display uniquely for repeat elements or
>something like that. I don't quite agree what you said this morning on
>Studio should display the superset of the schema, I think it should
>display exactly what the schema defines.

We agree that Mapper should take better advantage of Schema information and
make you aware of which elements are repeatable and which not, and other
properties that we can extract from DTD/XML Schema and that could be
helpful during Mapping.

My comment yesterday about Mapper displaying a super-set of the real schema
information was mostly related to "choice" structures contained in the
schema; Mapper displays all branches of a choice, so that you have the
possibility to create a mapping to each of them. This also could be
improved, but it is how things are now: the user needs to be aware of
details about the schemas that he's trying to map. We agree this is a
sub-optimal solution, but it was a very convenient solution that allowed us
to unify the Mapper behavior when working with XML document instances, or
DTD/XML Schema documents.

So, we are aware that we are taking very limited advantage of the
information contained in a schema (really not much, as we gather the same
information we would gather from an XML document instance); there are a few
things that we can do pretty quickly, like creating default mapping for
required elements and marking repeating ones with different icons; but
being really Schema friendly will be a longer task that is not at the top
of our priorities at this point.

Thanks,
Minollo

Postnext
Henry FangSubject: Re: Stylus Studio crash - log attached
Author: Henry Fang
Date: 08 Feb 2002 12:27 PM
Understood. Appreciate the quick actions your guys taking.

Henry

Postnext
Henry FangSubject: Re: Stylus Studio crash - log attached
Author: Henry Fang
Date: 08 Feb 2002 02:13 PM
I have a new problem now. Pls let me know if I should open a new issue.
I'm attaching source/target interface, XSLT created from Studio, input XML and output XML. As you can see in target DTD, the correct path is path_env -> path_body -> path_root -> compound -> protocol -> protocol_office -> protocol_country -> protocol_centre, but in the output XML, the path is ... ->protocol -> protocol_centre. Two levels in between are missing.
Any thoughts why?

Henry


Documentsource(2).dtd
source interface definition

Documenttarget(2).dtd
target interface definition

Documentcpms_patient_data_to_path_GSK_excelon.xsl
XSLT

DocumentinputXML.xml


DocumentoutputXML.xml

Postnext
Minollo I.Subject: Re: Stylus Studio crash - log attached
Author: Minollo I.
Date: 08 Feb 2002 02:21 PM
Reading the XSLT you attached I can't see how protocol_centre would be
created as child of protocol instead of protocol_country.

If you send us the XML file used to run the XSLT processor, maybe we can
better understand what you are describing.

Minollo

Postnext
Henry FangSubject: Re: Stylus Studio crash - log attached
Author: Henry Fang
Date: 08 Feb 2002 02:34 PM
Test input data is named as 'inputXML.xml', output data is 'outputXML.xml'. Both were in my attachments.

Henry

Postnext
(Deleted User) Subject: RE: Stylus Studio crash - log attached
Author: (Deleted User)
Date: 08 Feb 2002 02:45 PM
Henry,

I noticed that there are many for-each xpath select pattern in your xsl
is modfied to xxx[1]. Did you purposely do that to make sure only the
first element is taken. If this is the case, there is a better way in
mapper to achieve the same result. In mapper if you select a link and go
to property window, you can turn off the for-each property so that
mapper will generate a only.

Just a tip.

Song.




Postnext
Henry FangSubject: RE: Stylus Studio crash - log attached
Author: Henry Fang
Date: 08 Feb 2002 04:35 PM
Minollo and Song,

Pls ignore my last problem reported. I used the wrong map. Sorry for the mistake.

Song, thanks for the tip. BTW, I got this map from a customer, didn't build my own.

Henry

Postnext
Minollo I.Subject: Re: Stylus Studio crash - log attached
Author: Minollo I.
Date: 08 Feb 2002 03:00 PM

>...
>Test input data is named as 'inputXML.xml', output data is
>'outputXML.xml'. Both were in my attachments.

Sorry, it wasn't there in my browser when I checked; probably you were
still adding it.

So, re-reading the stylesheet it looks like there is a block in the second
part which starts with...
{x:for-each select="protocol_center"}
{protocol_centre}
...

....and that is completely out of context; reading the block it looks like
it has mostly been re-written by you (several structures used there are not
generated by Mapper); so I would guess that there has been some confusion
there between what Mapper has generated (which is in the block above, where
protocol_centre is created in the right context) and the block below, which
seems to be mostly manually written.

If you take a look at the stylesheet, you'll see what I mean.

Also, as Song as pointed out, it looks like you have modified most of the
for-each statements generated by Mapper to be select="path[1]"; I can only
guess you have done this to avoid looping. But you can more easily do that
asking mapper to make the link not do for-each; just select the link and
ask Mapper to make it not implemented as a for-each (in the property window).

Minollo

Postnext
Henry FangSubject: Re: Stylus Studio crash - log attached
Author: Henry Fang
Date: 08 Feb 2002 08:11 PM
>there are a few things that we can do pretty quickly, like creating default mapping for required elements and marking repeating ones with different icons;

Minollo, just curious when it'll be available?
Don't mean to be greedy. :)

Henry

Postnext
Minollo I.Subject: Re: Stylus Studio crash - log attached
Author: Minollo I.
Date: 08 Feb 2002 08:18 PM

>...
>Minollo, just curious when it'll be available?
>Don't mean to be greedy. :)

We are planning to work on that during the weekend and early next week.
We are trying to shoot for a Wednesday evening release.

Minollo

Postnext
Henry FangSubject: Re: Stylus Studio crash - log attached
Author: Henry Fang
Date: 11 Feb 2002 12:59 PM
Hi there,

How to do in Mapper: extract the right-most 13 characters of a string? Any existing FUNCTION can do that?

Thanks,
Henry

Postnext
Henry FangSubject: Re: Stylus Studio crash - log attached
Author: Henry Fang
Date: 11 Feb 2002 01:06 PM
Any how to do if...else condition checking? Any existing FUNCTION can do that? I can't find in doc.

Thanks,
Henry

Postnext
(Deleted User) Subject: RE: Stylus Studio crash - log attached
Author: (Deleted User)
Date: 11 Feb 2002 01:25 PM
Henry,

You can't find it in document, because we don't have it..:-). From
mapper GUI, you can't do condition checking like if, choose. This is in
our to do list. To perform condition checking , you have to switch to
source and modify code there. When you switch back to mapper, your
changes will not be lost...

The reason we didn't implement this feature in the first place was
because we think it might need much more steps in GUI to specify the
conditions than doing it in source. We are afraid this will make the GUI
not as easy to use...but since more and more users asking for this
feature, we are considering to have this in mapper but don't have a
definite date for it yet..

Hope this help...

song

> -----Original Message-----
> From: stylus-studio-tech Listmanager [mailto:listmanager]
> Sent: Monday, February 11, 2002 1:17 PM
> To: Recipients of 'stylus-studio-tech' suppressed
> Subject: Re: Stylus Studio crash - log attached
>
> From: "Henry Fang"
>
> Any how to do if...else condition checking? Any existing FUNCTION can
do
> that? I can't find in doc.
>
> Thanks,
> Henry
>
>
>
> To reply: mailto:stylus-studio-tech.4639@edn.exceloncorp.com
> To start a new topic: mailto:stylus-studio-tech@edn.exceloncorp.com
> To login: http://edn.exceloncorp.com/~SSDN

Postnext
Minollo I.Subject: RE: Stylus Studio crash - log attached
Author: Minollo I.
Date: 11 Feb 2002 01:31 PM
Just make it clear, what Song means with "switch to source and modify code
there" is adding xsl:if or xsl:choose instructions directly in the XSLT source.
I'm not sure how much you are familiar with XSLT; one of the best sources
of information is http://www.w3.org/TR/xslt

Hope this helps,
Minollo

Postnext
Henry FangSubject: RE: Stylus Studio crash - log attached
Author: Henry Fang
Date: 11 Feb 2002 01:35 PM
Song,

What's your estimated timeframe to have if-else function in your studio?
also, could you help me on this question:

How to do in Mapper: extract the right-most 13 characters of a string? Any existing FUNCTION can do that? If not, do I have to write a Java function to do that?

Thanks,
Henry

Postnext
Minollo I.Subject: RE: Stylus Studio crash - log attached
Author: Minollo I.
Date: 11 Feb 2002 01:41 PM

>...
>What's your estimated timeframe to have if-else function in your studio?
>also, could you help me on this question:

xsl:if and xsl:choose are supported by Stylus Studio; but not by the Mapper
view.
There won't be much difference (in terms of efforts on the user side)
between creating xsl:if/xsl:choose statements in the source XSLT or
creating them in whatever GUI we will come up with in Mapper.
Still, we agree it would be nicer to have visibility of conditional links
in the Mapper view.

As we are not perceiving this as a show-stopper, we are planning to do this
improvement in Mapper not before XML-to-HTML wysiwyg is available; my best
guess at this point would be at some point this summer.

Thanks,
Minollo

Postnext
Henry FangSubject: RE: Stylus Studio crash - log attached
Author: Henry Fang
Date: 11 Feb 2002 01:51 PM
Yes, I understand what Song said. I'm not a XSLT expert, but comfortable with it.
Thanks for clarification. I'm looking forward to your help on my another question regarding substring function starting from right-most.
BTW, your doc. is not helpful in most cases. E.g., most of the shipped XSLT FUNCTION are straight forward to Java developers, but some are not that intuitive. I tried choose "Go to Function Definition" (there's a typo -> "Goto to ..."), but nothing happened. Description to these functions are spread in the doc. and are really hard to find. Just comment from an user point of view.

Henry

Postnext
Minollo I.Subject: RE: Stylus Studio crash - log attached
Author: Minollo I.
Date: 11 Feb 2002 01:55 PM

>...
>Thanks for clarification. I'm looking forward to your help on my another
>question regarding substring function starting from right-most.

Yup; we are not ignoring it; Song is working on the answer that should be
quite helpful.

>BTW, your doc. is not helpful in most cases. E.g., most of the shipped
>XSLT FUNCTION are straight forward to Java developers, but some are not
>that intuitive. I tried choose "Go to Function Definition" (there's a typo
>-> "Goto to ..."), but nothing happened. Description to these functions
>are spread in the doc. and are really hard to find. Just comment from an
>user point of view.

We are aware of that; documentation is being revamped in 4.0, which will be
in beta in early March, GA by the end of April.

Thanks,
Minollo

Postnext
(Deleted User) Subject: RE: Stylus Studio crash - log attached
Author: (Deleted User)
Date: 11 Feb 2002 01:56 PM
>
> How to do in Mapper: extract the right-most 13 characters of a string?
Any
> existing FUNCTION can do that? If not, do I have to write a Java
function
> to do that?

There is NOT a function like right-string(str, 13) in XSLT( I wish they
have), so you won't see direct support in mapper. However you can work
around by using XSLT function 'substring'. It is not straight-forward
but will work and you can avoid writing a java extension function.

You can create a substring function block and link the source node to
the first parameter. Then you need to go to the property window of this
link to specify the second and third parameter. The third is easier, it
is expected to be the length of the substring which is 13 in your case.
The second parameter is little bit trickier. It is expected to be the
start of the substring. I guess you don't have a fixed start position,
you have to use another function 'string-length(source-node)-12' to
achieve this...

By the way, you can also look at substring-after or substring-before if
you know the patterns for your substring...

Hope this help

song


Postnext
Henry FangSubject: RE: Stylus Studio crash - log attached
Author: Henry Fang
Date: 11 Feb 2002 02:10 PM
Song, I can't find string-length() function in my function list, is that called count()?
I have Studio 3.1.069l.

Henry

Postnext
(Deleted User) Subject: RE: Stylus Studio crash - log attached
Author: (Deleted User)
Date: 11 Feb 2002 02:43 PM
Henry,

At this point, string-length() is not in the function list. What I meant
is you need to type the string_length()-12 in the property window for
second parameter...sorry for the confusion...

I'm adding to the list and it will be available in next build which I
expect it to be mid of this week..

Sorry for the confusion..

song


> -----Original Message-----
> From: stylus-studio-tech Listmanager [mailto:listmanager]
> Sent: Monday, February 11, 2002 2:21 PM
> To: Recipients of 'stylus-studio-tech' suppressed
> Subject: RE: Stylus Studio crash - log attached
>
> From: "Henry Fang"
>
> Song, I can't find string-length() function in my function list, is
that
> called count()?
> I have Studio 3.1.069l.
>
> Henry
>
>
>
> To reply: mailto:stylus-studio-tech.4647@edn.exceloncorp.com
> To start a new topic: mailto:stylus-studio-tech@edn.exceloncorp.com
> To login: http://edn.exceloncorp.com/~SSDN

Postnext
Henry FangSubject: RE: Stylus Studio crash - log attached
Author: Henry Fang
Date: 12 Feb 2002 12:53 PM
Hi there, I encountered another problem with the same map. In the middle of developing a XSLT, once I defined the rules for element 'GuarAmt', I switched to Source panel from Mapper panel, no problem, I can see all my XSLT source, and when I tried to switch back, the "Choose Source and Destination Schema" window pops out, ask me to select root elements again, even if I selected the correct schema and root elements, it just stuck there and wouldn't open the mapper.
Attached is the current XSLT and source/target XSD.

Henry


DocumentFM_SourceInterface.xsd
source schema, root is 'FiveFileMCODES'

DocumentIncomeExpense.xsd
target XSD, root is 'IncomeExpenses'

DocumentFM_IncomeExpense_excelon.xsl

Postnext
(Deleted User) Subject: RE: Stylus Studio crash - log attached
Author: (Deleted User)
Date: 12 Feb 2002 01:31 PM
Henry,

Your string_length(...) should be string-length(...)

song

> -----Original Message-----
> From: stylus-studio-tech Listmanager [mailto:listmanager]
> Sent: Tuesday, February 12, 2002 1:04 PM
> To: Recipients of 'stylus-studio-tech' suppressed
> Subject: RE: Stylus Studio crash - log attached
>
> From: "Henry Fang"
>
> Hi there, I encountered another problem with the same map. In the
middle
> of developing a XSLT, once I defined the rules for element 'GuarAmt',
I
> switched to Source panel from Mapper panel, no problem, I can see all
my
> XSLT source, and when I tried to switch back, the "Choose Source and
> Destination Schema" window pops out, ask me to select root elements
again,
> even if I selected the correct schema and root elements, it just stuck
> there and wouldn't open the mapper.
> Attached is the current XSLT and source/target XSD.
>
> Henry
>
>
>
> To reply: mailto:stylus-studio-tech.4655@edn.exceloncorp.com
> To start a new topic: mailto:stylus-studio-tech@edn.exceloncorp.com
> To login: http://edn.exceloncorp.com/~SSDN

Postnext
Henry FangSubject: RE: Stylus Studio crash - log attached
Author: Henry Fang
Date: 12 Feb 2002 04:15 PM
You're right. But Studio should be able to handle it better rather than leave me in blind, right? Maybe validate the command right after user types in?
could you open this as as enhancement request?

Thanks,
Henry

Postnext
Minollo I.Subject: RE: Stylus Studio crash - log attached
Author: Minollo I.
Date: 12 Feb 2002 04:34 PM
Of course; it has been already filed as a bug.

Thanks,
Minollo

Postnext
Henry FangSubject: RE: Stylus Studio crash - log attached
Author: Henry Fang
Date: 12 Feb 2002 06:59 PM
One step forward. I add a logic to my XSLT, somehow it's not working. In result, it just prints out the section. I'm attaching the XSLT and the result XML. Note the element in result. Do I have syntax error? If not, what's the problem?

Henry


DocumentFM_IncomeExpense_excelon(1).xsl


Documentresult6.xml

Postnext
Henry FangSubject: RE: Stylus Studio crash - log attached
Author: Henry Fang
Date: 12 Feb 2002 09:03 PM
I meant element "WashDryIncm".

Postnext
Minollo I.Subject: RE: Stylus Studio crash - log attached
Author: Minollo I.
Date: 12 Feb 2002 09:42 PM
You are using {choose} and {when}; but they are elements which have a
meaning only in the XSLT namespace; they should be {xsl:choose} and {xsl:when}

Minollo

Postnext
Henry FangSubject: RE: Stylus Studio crash - log attached
Author: Henry Fang
Date: 13 Feb 2002 04:52 PM
General questions:
1) is Stylus Studio fully I18N compliant? i.e., can Studio handle foreign characters as schema/DTD element/attribute name or literal values?
2) Can Stylus Studio allow multiple source schema/DTD map to a single destination schema/DTD (which is many-to-one)? what about one-to-many and many-to-many?

BTW, when will the next new build available (fixing the mandatory elements missing problem)? Is it today?

Thanks,
Henry

Postnext
Minollo I.Subject: RE: Stylus Studio crash - log attached
Author: Minollo I.
Date: 13 Feb 2002 04:57 PM

>...
>1) is Stylus Studio fully I18N compliant? i.e., can Studio handle foreign
>characters as schema/DTD element/attribute name or literal values?

Yes.

>2) Can Stylus Studio allow multiple source schema/DTD map to a single
>destination schema/DTD (which is many-to-one)?

Not in mapper (the XSLT processor supports it through the document()
directive).

>what about one-to-many and many-to-many?

No, but this is not possible in XSLT 1.0 (it will be in XSLT 2.0).

>BTW, when will the next new build available (fixing the mandatory elements
>missing problem)? Is it today?

It is today.
Minollo

Postnext
Minollo I.Subject: RE: Stylus Studio crash - log attached
Author: Minollo I.
Date: 13 Feb 2002 09:45 PM

>...
> >BTW, when will the next new build available (fixing the mandatory elements
> >missing problem)? Is it today?

3.1 BL69m is available now from:
www.stylusstudio.com/update

It will display repeating elements in Mapper trees with a different icon,
and it will create default (empty) entries for un-mapped required elements.

Hope this helps,
Minollo

Postnext
Henry FangSubject: RE: Stylus Studio crash - log attached
Author: Henry Fang
Date: 13 Feb 2002 09:51 PM
Great! I'll try that.
Your guys rocks!!

Henry

Postnext
Henry FangSubject: RE: Stylus Studio crash - log attached
Author: Henry Fang
Date: 14 Feb 2002 06:33 PM
Minollo,

I tried 69M, the icon in Mapper indicating repeating elements looks good. The non-mapped mandatory elements in target side does got populated in output XML, however, it's overkill now since all optional elements also got populated.
Another general XSLT question: if I need a loop element to have 10 occurrences in output XML, but the corresponding input data elements either is empty or has less occurrences, is anyway to do the padding in XSLT? If yes, how and is it possible in Mapper?

Thanks,
Henry

Postnext
Minollo I.Subject: RE: Stylus Studio crash - log attached
Author: Minollo I.
Date: 14 Feb 2002 06:53 PM

>...
>I tried 69M, the icon in Mapper indicating repeating elements looks good.
>The non-mapped mandatory elements in target side does got populated in
>output XML, however, it's overkill now since all optional elements also
>got populated.

That shouldn't happen; we'll look into it.

>Another general XSLT question: if I need a loop element to have 10
>occurrences in output XML, but the corresponding input data elements
>either is empty or has less occurrences, is anyway to do the padding in XSLT?

I can't think of any easy way to do that other than looping 10-X times (X
being the number of data elements in the source) and generating (empty?)
entries in the output. The only easy way to loop N times in XSLT that I
know of is recursively calling templates using a parameter value to act as
the counter.

>If yes, how and is it possible in Mapper?

No; you have to create it in the XSLT source.

Hope this helps,
Minollo

Posttop
(Deleted User) Subject: RE: Stylus Studio crash - log attached
Author: (Deleted User)
Date: 12 Feb 2002 04:35 PM
This is a multi-part message in MIME format.

------=_NextPart_000_0004_01C1B3E5.144C1E20
Content-Type: text/plain;
charset="us-ascii"
Content-Transfer-Encoding: 7bit

We have noticed this problem and it is already fixed. Stylus will jump
to the line contains error when you try to switch rather than popping up
the schema dialog. You will see this in our next release which will be
available soon.



song


------=_NextPart_000_0004_01C1B3E5.144C1E20
Content-Type: text/html;
charset="us-ascii"
Content-Transfer-Encoding: quoted-printable

















We have noticed this problem and it is already fixed. =Stylus
will jump to the line contains error when you try to switch rather than =popping
up the schema dialog. You will see this in our next release which will =be available
soon…



 



song









------=_NextPart_000_0004_01C1B3E5.144C1E20--

 
Topic Page 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 Go to previous topicPrev TopicGo to next topicNext Topic
Download A Free Trial of Stylus Studio 6 XML Professional Edition Today! Powered by Stylus Studio, the world's leading XML IDE for XML, XSLT, XQuery, XML Schema, DTD, XPath, WSDL, XHTML, SQL/XML, and XML Mapping!  
go

Log In Options

Site Map | Privacy Policy | Terms of Use | Trademarks
Stylus Scoop XML Newsletter:
W3C Member
Stylus Studio® and DataDirect XQuery ™are from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2016 All Rights Reserved.