Getting unwanted values between the XML tags in XSLT mapping

Posted on 2014-09-13
Last Modified: 2014-09-14
Hi Folks
I have come across a very strange situation with my xslt mapping.
I am getting unwated values "11" between xml tags
as follows
I am not sure why I am getting these values in between the tags. Any suggestions would be appreciated. I have also attached the code snippet pertaining to these 2 tags
Question by:kalyangkm
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3

Author Comment

ID: 40320895
              <xsl:for-each select="E1EDKA1">
                  <xsl:when test="normalize-space(PARVW) = 'WE' and normalize-space(LIFNR) = 'U960'">
                    <xsl:value-of select="'1'" />
                  <xsl:when test="normalize-space(PARVW) = 'WE' and normalize-space(LIFNR) = 'U300'">
                    <xsl:value-of select="'3'" />
                  <xsl:when test="normalize-space(PARVW) = 'WE' and normalize-space(LIFNR) = 'U930'">
                    <xsl:value-of select="'1'" />
                  <xsl:when test="normalize-space(PARVW) = 'WE' and normalize-space(LIFNR) = 'U400'">
                    <xsl:value-of select="'3'" />
                    <xsl:value-of select="'1'" />

Open in new window


Author Comment

ID: 40320950
Hi Folks,

Anyone out there please?
LVL 35

Accepted Solution

mccarl earned 500 total points
ID: 40321400
The problem will be on line 27 (of the snippet that you posted above), if none of the other "tests" of the choose pass then the "otherwise" gets evaluated and in there all you are doing is outputting a '1' with no surrounding xml tag

Author Comment

ID: 40321761

I already changed the code by removing the otherwise part, thanks anyway.


Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

A short article about a problem I had getting the GPS LocationListener working.
Today, the web development industry is booming, and many people consider it to be their vocation. The question you may be asking yourself is – how do I become a web developer?
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…

726 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question