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 Go to previous topicPrev TopicGo to next topicNext Topic
Postnext
M KlineSubject: XSLT help - newbie
Author: M Kline
Date: 31 Oct 2006 01:22 PM
Hello,
I posted originally in XQuery board, but maybe that was the wrong board.
I have an 820 (EDI Receiving Advice) from a Customer. I would like to extract (forgive the terminology) certain parts of the XML they send, however I cannot figure out how. I have it broken down to Item, then Value, however everything in the XML is an <Item> or <Value> even though the data content is different.
I'm attaching an example with the areas that I'd like to get on a report somehow, sorted, for my Accounting Department.
StylusStudio is my last attempt before we have to pay the web-host a lot of money to produce our desired results. Unfortunately, I do not know enough about XML/XSLT to do this myself so I'm hoping someone could offer me some assistance.
We receive this document weekly so the XSLT would be "applied" against the new XML (by me) on a weekly basis.

Thanks,
Mary

Postnext
M KlineSubject: Re: XSLT help - newbie
Author: M Kline
Date: 31 Oct 2006 02:04 PM

Sorry, here is the attached XML file.


(See attached file: 820_Example.xml)



|---------+------------------------------------------------->
| | "stylus-studio-xslt Listmanager" |
| | <stylus-studio-xslt.listmanager@stylus|
| | studio.com> |
| | |
| | 10/31/2006 01:38 PM |
| | Please respond to "XSLT Help and |
| | Discussion" |
|---------+------------------------------------------------->
>----------------------------------------------------------------------------------------------------|
| |
| To: (Recipients of 'stylus-studio-xslt' suppressed) |
| cc: |
| Subject: XSLT help - newbie |
>----------------------------------------------------------------------------------------------------|




From: Mary Kline

Hello,
I posted originally in XQuery board, but maybe that was the wrong board.
I have an 820 (EDI Receiving Advice) from a Customer. I would like to
extract (forgive the terminology) certain parts of the XML they send,
however I cannot figure out how. I have it broken down to Item, then Value,
however everything in the XML is an <Item> or <Value> even though the data
content is different.
I'm attaching an example with the areas that I'd like to get on a report
somehow, sorted, for my Accounting Department.
StylusStudio is my last attempt before we have to pay the web-host a lot of
money to produce our desired results. Unfortunately, I do not know enough
about XML/XSLT to do this myself so I'm hoping someone could offer me some
assistance.
We receive this document weekly so the XSLT would be "applied" against the
new XML (by me) on a weekly basis.

Thanks,
Mary



--
To reply:stylus-studio-xslt.17397@stylusstudio.com
To start a new topic:stylus-studio-xslt@stylusstudio.com
To login:http://www.stylusstudio.com/SSDN/
To (un)subscribe:stylus-studio-xslt.list-request@stylusstudio.com



Unknown820_Example.xml

Postnext
Ivan PedruzziSubject: XSLT help - newbie
Author: Ivan Pedruzzi
Date: 31 Oct 2006 04:12 PM

Mary,

We can't do the job for you but we can provide a point to start.

The attached solution generates a .csv file that can be open using Microsoft Excel; it covers most of the fields you are looking for

Now is up to you complete the task.


Ivan Pedruzzi
Stylus Studio Team


Document820.xsl


Unknown820.csv
example of output

Postnext
M KlineSubject: Re: XSLT help - newbie
Author: M Kline
Date: 01 Nov 2006 08:28 AM

Ivan,

Thank You. I appreciate your help.

Might I ask, was the formatting on this XML a bit unusual compared to most?
By that I mean, the tags were not descriptive, rather everything was an
<Item> and <Value> or is it just because I do not know enough about XML?

Mary



|---------+------------------------------------------------->
| | "stylus-studio-xslt Listmanager" |
| | <stylus-studio-xslt.listmanager@stylus|
| | studio.com> |
| | |
| | 10/31/2006 04:27 PM |
| | Please respond to "XSLT Help and |
| | Discussion" |
|---------+------------------------------------------------->
>---------------------------------------------------------------------------------------------------------------------------------------------|
| |
| To: (Recipients of 'stylus-studio-xslt' suppressed) |
| cc: |
| Subject: XSLT help - newbie |
>---------------------------------------------------------------------------------------------------------------------------------------------|




From: Ivan Pedruzzi


Mary,

We can't do the job for you but we can provide a point to start.

The attached solution generates a .csv file that can be open using
Microsoft Excel; it covers most of the fields you are looking for

Now is up to you complete the task.


Ivan Pedruzzi
Stylus Studio Team


--
Attachment: http://www.stylusstudio.com/SSDN/upload/820.xsl (3KB)

http://www.stylusstudio.com/SSDN/upload/820.csv (1KB)
example of output


--
To reply:stylus-studio-xslt.17403@stylusstudio.com
To start a new topic:stylus-studio-xslt@stylusstudio.com
To login:http://www.stylusstudio.com/SSDN/
To (un)subscribe:stylus-studio-xslt.list-request@stylusstudio.com



Postnext
Ivan PedruzziSubject: Re: XSLT help - newbie
Author: Ivan Pedruzzi
Date: 01 Nov 2006 11:40 AM
Hi Mary,

Automated system like this form submission convert each field to input/value for commodity, doing so they don't need to deal with names conversion.
For instance "Order ID" is an invalid XML element name that would need to be escaped for example to Order_ID.



Ivan Pedruzzi
Stylus Studio Team

Postnext
Tony LavinioSubject: Re: XSLT help - newbie
Author: Tony Lavinio
Date: 01 Nov 2006 01:40 PM
It's too bad you couldn't have gotten the straight EDI X12 820 file.
The deployment adapters we have would have generated XML from it that
would be ideal for mapping.

Postnext
M KlineSubject: Re: XSLT help - newbie
Author: M Kline
Date: 01 Nov 2006 02:33 PM

Yes, I'm sure it would have been much easier, even for a newbie like me to
understand. They basically forced us into this situation and now we're
trying to get it into a usable/sortable format. We could pay the web-host
a chunk of money to do this for us, however my Accounting Department is a
bit hesitant on spending the money.

I was able to add some data to the xsl that Ivan sent me (Thank You Ivan)
after I drew (literally) all over the XML to get the nesting (forgive me if
that's the wrong terminology) format figured out. I'm now trying to get
the .CSV output with the added columns and not having much luck. I
can see the results in my results window with the added data, but the CSV
doesn't include the new data...just blank cells. I'm sure it's
something easy that I've missed. I also have to get the XSLT to repeat
through the entire XML (which is huge).

I'm thinking I need to search the website and maybe watch a video or two
amongst all the phone-calls and other support issues I have. ugh

Thanks,

Mary



|---------+------------------------------------------------->
| | "stylus-studio-xslt Listmanager" |
| | <stylus-studio-xslt.listmanager@stylus|
| | studio.com> |
| | |
| | 11/01/2006 01:43 PM |
| | Please respond to "XSLT Help and |
| | Discussion" |
|---------+------------------------------------------------->
>---------------------------------------------------------------------------------------------------------------------------------------------|
| |
| To: (Recipients of 'stylus-studio-xslt' suppressed) |
| cc: |
| Subject: Re: XSLT help - newbie |
>---------------------------------------------------------------------------------------------------------------------------------------------|




From: Tony Lavinio

It's too bad you couldn't have gotten the straight EDI X12 820 file.
The deployment adapters we have would have generated XML from it that
would be ideal for mapping.


--
To reply:stylus-studio-xslt.17425@stylusstudio.com
To start a new topic:stylus-studio-xslt@stylusstudio.com
To login:http://www.stylusstudio.com/SSDN/
To (un)subscribe:stylus-studio-xslt.list-request@stylusstudio.com



Postnext
Tony LavinioSubject: Re: XSLT help - newbie
Author: Tony Lavinio
Date: 03 Nov 2006 11:59 AM
Here is perhaps one other option.
This XSLT sort of 'denormalizes' your XML back into something
that you can use with the XSLT Mapper.
If you use this, please become a customer :)


Unknownkline.xsl

Posttop
M KlineSubject: Re: XSLT help - newbie
Author: M Kline
Date: 03 Nov 2006 01:15 PM

Hi Tony,

Thank You. I will take a look at this.

I have added columns to the result, and added more in the <xsl:value-of
select statement to get the information I want on the .csv. The issue
I'm having at the moment, which I've not had too much time today to look
at, is getting this selection criteria to repeat throughout the entire XML
until it reaches the end. There might be 100, 200+ "sections" to go
through until the end of the document. Right now, it's only pulling the
very first grouping (if that makes any sense) in the result, and ultimately
on the .csv

I looked briefly at the <xsl:key function last night, however I kept
looking at my XSL, then back to the <xsl:key examples and my head started
to hurt. :-) Would you be able to tell me if the <xsl:key would
work for this type of thing or is there a different/better function I could
use? (sorry about the long file name)

(See attached file: 820_from_SS_add_Quantity.xsl)

Mary


|---------+------------------------------------------------->
| | "stylus-studio-xslt Listmanager" |
| | <stylus-studio-xslt.listmanager@stylus|
| | studio.com> |
| | |
| | 11/03/2006 12:14 PM |
| | Please respond to "XSLT Help and |
| | Discussion" |
|---------+------------------------------------------------->
>---------------------------------------------------------------------------------------------------------------------------------------------|
| |
| To: (Recipients of 'stylus-studio-xslt' suppressed) |
| cc: |
| Subject: Re: XSLT help - newbie |
>---------------------------------------------------------------------------------------------------------------------------------------------|




From: Tony Lavinio

Here is perhaps one other option.
This XSLT sort of 'denormalizes' your XML back into something
that you can use with the XSLT Mapper.
If you use this, please become a customer :)

--
Attachment: http://www.stylusstudio.com/SSDN/upload/kline.xsl (2KB)



--
To reply:stylus-studio-xslt.17458@stylusstudio.com
To start a new topic:stylus-studio-xslt@stylusstudio.com
To login:http://www.stylusstudio.com/SSDN/
To (un)subscribe:stylus-studio-xslt.list-request@stylusstudio.com



Unknown820_from_SS_add_Quantity.xsl

 
Topic Page 1 2 3 4 5 6 7 8 9 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.