Xsl:text

xsl:text elements always are shown as errors in xslt. It appears that the dtd being used by JDeveloper is wrong. Can someone at Oracle respond to this and tell me either where a good dtd is, and how to get jdeveloper to recognize it, or when a patch will be available. Incorrectly flagging xsl:text is making the syntax validation within the code editor useless.
TIA,

In JDeveloper 10g <xsl:text> gets added.
Which Jdev version produces xsl:text error?

Similar Messages

  • XSL-TEXT: how to import subtemplates in XSL and use xdofx tags?

    Hi,
    I am working on a BI Publisher Report (XML Publisher 5.6.3 in EBS) to generate labels on a label printer. The output needs to be in plain text format, therefore I decided to use the XSL-TEXT template and create my own XSL translation.
    In principle this works pretty fine, but there are two things that worry me a bit:
    1. Does anybody know how I could import other XSL files, like sub-templates in RTF? The problem I have is that I don't know the URI or the sub-template. At the moment I store those other XSL files in the OA_MEDIA folder, but this is not really nice. In RFT you can refer to subtemplates with some xdofx commands... this brings me to my second question:
    2. In RTF templates you can use the Oracle specific XML tags, including the <xdofx:%> and <xdoxslt:%> tags. Does anybody know if and how I can use them in XSL templates?
    Any ideas are highly appreciated!
    regards,
    David.

    Hi Vetsrini,
    1. but what is the absolute path for my subtemplates if I store them in the Template Manager? How can I refer to them?
    This is what the manual says for RTFs:
    >
    Enter the Import Syntax in the Primary Template
    Import the subtemplate to the primary template by entering the following syntax in the
    primary template. The import syntax tells the XML Publisher engine where to find the
    subtemplate RTF in the Template Manager. This syntax may be entered anywhere in the
    template prior to the call-template syntax:
    <?import:xdo://APPCODE.TEMPLATE_CODE.lang.TERR?>
    where
    APPCODE is the Application code you assigned to the subtemplate in the Template
    Manager. For example, if you associated this template with the Receivables application,
    enter "AR".
    TEMPLATE_CODE is the template Code you assigned to the subtemplate in the Template
    Manager. For example, AR_CommonComponents.
    >
    sounds good and easy to me. But I don't have a RTF template. I have just a plain XSLT and those XML Publisher tags do not work there. So how do I get the absolute path of my XSLT templates stored in the Template Manager?
    2. I've included the namespace, no error anymore. But the syntax does not result in actions:
    <xsl:value-of select="xdoxslt:substr((PRODUCT_NAME),1,2)"/>
    {code}
    This does not substring() my string, the full string is returned. But anyway, I don't get an error message anymore. Maybe I just used the wrong XDOXSLT function... I need to search for a list of XDOXSLT functions, but that's not very urgent for now. I think I can do the most with plain XSL and inside the DB itself.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • Xsl text output help

    I would like to use an xsl transform to output an xml dom tree as a text file.
    I have tried using <xsl:output method="text" media-type="text/plain"/>
    and I use <xsl:text > to output text but my resulting file only contains the following line:
    <?xml version="1.0" encoding="UTF-8"?>
    Anyone know what I am doing wrong?
    Thank you,
    --Elliot                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

    It should work fine. Just check if template matchings are correct. Seems some xslt problem; post your translator and xml file so somebody can help
    Message was edited by:
    winay

  • XSL:Text img ... Breaks in transformation

    Hi
    I am sure this is a nobrainer. I am using Java to transform an XML document on the server. What I want to do however is to transform values to a corresponding image on the server. eg Database has value 2 stored. The XSL style sheet then transfroms this to <img src="2">.
    I am using the following
    <td class="tableText"><xsl:text><img src="</xsl:text><xsl:value-of select="PRICE"/><xsl:text>"></xsl:text>I have tried using the disable-output-escaping flag and it doesn't seem to make much difference. If I substitute < for < then this is treated as text by the browser. I am sure I am being stupid so please stop me going mad.

    What you have shown there is not even valid XML, as you are not allowed to have the character < in an attribute. You have to escape it by typing &lt; instead. However, your comments "If I substitute < for < ..." indicate that you probably haven't shown what you actually have, because you don't know how to type the input so that it displays correctly in HTML.
    To get a < character, you must type "&lt;". And if you want to see "&lt;" you must type "&amp;lt;".
    So try again, and show us what you actually have.

  • xsl:text not preserving whitespace

    When I try to use <xsl:text> to put spaces into the output of a transform, it does'nt work. Leading/trailing spaces gets stripped and a single space by itself gets dropped altogether.
    This is using the PL/SQL XSLT on an XMLType in 9.0.2.
    If I run the same transform on the same data but using XALAN XSLT it works fine.

    Was that supposed to read:
    <xsl:text>& amp;#xa0;</xsl:text>?
    (I added whitespace so you could see the ampersand, but that's not a non-breaking space, that's an actual printable character.
    I later found a solution that worked in this thread:
    Cannot get to print NEWLINE in XMLTransform using XSLT
    Posted: May 2, 2007 10:16 AM
    Cannot get to print NEWLINE in XMLTransform using XSLT
    Thanks,
    Eric

  • SQL data transformed by XSL-TEXT template

    Hi,
    please, how can I transform data retrived by SQL query using XSL-TEXT template (need to generate text file using rpad/lpad XSL function)? There is no problem if the data set is 'XML file', with setting the data set as SQL querry I'm lost..
    Thanks for all replies.
    Rad

    Hi,
    problem solved by using data template.
    Rad

  • Form XSL Text E-Mail?

    I have been searching online to determine if I can use Adobe Forms for my application. For various reasons related to existing downstream processing, I need a flow as follows:
    - User downloads form from the web.
    - User enters data into a the form offline.
    - User presses "submit" and the form data is sent via the user's e-mail client to a static e-mail address contained in the form definition.
    All of the above seems possible with Adobe Forms. The complication is that I need the form data to arrive at the given e-mail inbox in a specific text format, not in XML. I can write an XSLT Stylesheet to transform the XML into the required text format, and I see that there is some XSL support in the Adobe Forms system. It wasn't clear
    A - where in the process the XSL is applied or
    B - if it is acceptable for the XSL output type to be set to text.
    If push comes to sove, I can apply the XSL downstream, i.e., I can send XML via e-mail and then apply the transformation. Other circumstances I won't describe here make that a PITA and so I'd rather do the transform earlier in the process.
    Thanks in advance for any help or advice.

    When comparing strings, you should use the .equalsMethod.
    You should also check for null in most cases.
    if (escalationType != null && escalationType.equals("Tipo1"))
    // an equivalent but shorter way of doing this...
    if ("Tipo1".equals(escalationType))

  • XSL text output problem

    Hi:
    I was trying to output a text from a XSL with XML file, It seems that it spits out all the values from xml file inbetween all the element tags. But all I really need is just a small chunk of it. Does any one know how to get rid of the extra stuff from the generated text?
    Thanks

    Cross-posted: http://forum.java.sun.com/thread.jsp?thread=419800&forum=33&message=1860339

  • Need help with text() processing in XSL

    Hello,
    I have an xml that contains such text in my xml:
    before<a>inside</a>after
    and an xsl that transforms it to HTML (a cut for xsl):
    <xsl:template match="a">
    <xsl:apply-templates/>
    </xsl:template>
    <xsl:template match="text()">
    <xsl:value-of disable-output-escaping="yes" select="."/>
    </xsl:template>
    The result is: inside before after
    but I need: before inside after
    It seems it happens 'cause of this: http://www.w3.org/TR/xslt#conflict
    but I cannot find a way to solve this problem :(
    I had tried to use priority in xsl:template, but it didn't help :(
    Thanks a lot.

    DrClap
    here are xml and xsl.
    That's not a real xml and xsl, but they might describe the idea and problem. I hope I miss nothing.
    P.S. I cannot control xml, that's why I cannot use: <xsl:text> in xml.
    Thank you!
    xml:
    <?xml version="1.0" encoding="UTF-8"?>
    <root>
    <title>Page title</title>
    <page>
    Location: <red>http://host</red>
    </page>
    </root>
    xsl:
    <?xml version='1.0' encoding='ISO-8859-1'?>
    <xsl:stylesheet version="1.0"
    xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
    xmlns:fo="http://www.w3.org/1999/XSL/Format"
    xmlns:fox="http://xml.apache.org/fop/extensions"
    exclude-result-prefixes="fo">
    <xsl:template match="root">
    <html>
    <head>
    <title>
    <xsl:apply-templates select="title"/>
    </title>
    </head>
    <body>
    <xsl:apply-templates select="page"/>
    </body>
    </html>
    </xsl:template>
    <xsl:template match="page">
    <xsl:apply-templates/>
    </xsl:template>
    <xsl:template match="title">
    [Test]: <xsl:apply-templates/>
    </xsl:template>
    <xsl:template match="red">
    <xsl:element name="span"><xsl:attribute name="style">color:red</xsl:attribute><xsl:apply-templates/></xsl:element>
    </xsl:template>
    <xsl:template match="text()">
    <xsl:value-of disable-output-escaping="yes" select="."/>
    </xsl:template>
    </xsl:stylesheet>

  • Howto add static text in xsl stylesheet

    Hi,
    I'am having problems trying to write a static text to a fixed length file using the file adapter.
    I'am using the FlatStructure sample provided.
    When I run the sample, there's no problem... But when I remove the mapping from tns:State <-> fix:State (in addr1Toaddr2.xsl) and change the fix:State to a static text (Set Text option in right mouse popup menu) then this text will NOT show up in the written fixed length file.
    My addr1Toaddr2.xsl looks like this:
    <?xml version="1.0" encoding="windows-1252"?>
    <?oracle-xsl-mapper
    <!-- SPECIFICATION OF MAP SOURCES AND TARGETS, DO NOT MODIFY. -->
    <mapSources>
    <source type="XSD">
    <schema location="file://D:/OraBPELPM_2/integration/bpelpm/orabpel/samples/tutorials/121.FileAdapter/FlatStructure/address-csv.xsd"/>
    <rootElement name="Root-Element" namespace="http://xmlns.oracle.com/pcbpel/demoSchema/csv"/>
    </source>
    </mapSources>
    <mapTargets>
    <target type="XSD">
    <schema location="file://D:/OraBPELPM_2/integration/bpelpm/orabpel/samples/tutorials/121.FileAdapter/FlatStructure/address-fixedLength.xsd"/>
    <rootElement name="Root-Element" namespace="http://xmlns.oracle.com/pcbpel/demoSchema/fixedLength"/>
    </target>
    </mapTargets>
    <!-- GENERATED BY ORACLE XSL MAPPER 1.0 AT [WED MAY 18 11:29:24 CEST 2005]. -->
    ?>
    <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:tns="http://xmlns.oracle.com/pcbpel/demoSchema/csv" xmlns:nxsd="http://xmlns.oracle.com/pcbpel/nxsd" xmlns:fix="http://xmlns.oracle.com/pcbpel/demoSchema/fixedLength" xmlns:ldap="http://schemas.oracle.com/xpath/extension/ldap" xmlns:xp20="http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.Xpath20" xmlns:bpws="http://schemas.xmlsoap.org/ws/2003/03/business-process/" xmlns:ora="http://schemas.oracle.com/xpath/extension" xmlns:orcl="http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.ExtFunc" exclude-result-prefixes="xsl xsd tns nxsd fix ldap xp20 bpws ora orcl">
    <xsl:template match="/">
    <fix:Root-Element>
    <xsl:for-each select="/tns:Root-Element/tns:Address">
    <fix:Address>
    <fix:Name>
    <xsl:value-of select="tns:Name"/>
    </fix:Name>
    <fix:Street>
    <xsl:value-of select="concat(tns:Street1,' ',tns:Street2)"/>
    </fix:Street>
    <fix:City>
    <xsl:value-of select="string('C2345678901')"/>
    </fix:City>
    <fix:State>
    <xsl:text disable-output-escaping="no">D2345678901
    </xsl:text>
    </fix:State>
    <fix:Country>
    <xsl:value-of select="string('E234567')"/>
    </fix:Country>
    </fix:Address>
    </xsl:for-each>
    </fix:Root-Element>
    </xsl:template>
    </xsl:stylesheet>
    Note:
    The construct "<xsl:value-of select="string('E234567')"/>" is my 'patch'to write a static text.
    Can you tell me what I'am doing wrong? Or is this a bug...
    greetings,
    Jan.

    Hi ,
    I am assuming you are using Oracle JDeveloper XSL Mapper for designing the XSL. Currently , our XSL Mapper has a limitation due to that whenever you add any static text to target node in mapper, it adds an extra "\n" with that static text. And so our Native format translator doesn't find the definition for that and that's why it doesn't get printed in the file.
    Workaround [although little painful] is remove those extra "\n" after you finish your XSL design.
    We are working to fix this issue asap.
    HTH.
    Thanks,
    Rakesh

  • XSLProcessor support of xsl:output method="text"?

    I'm having trouble getting my processor to format the output as a big string. Actually, the output is html, but because of some browser bugs I want to avoid linebreaks between tags. Specifically table cell tags <td> and the content of the cell.
    Right now, even though I write my xsl like this:
    <table><tr><td>content</td></tr></table>
    the processor formats the output like this:
    <table>
    <tr>
    <td>content</td>
    </tr>
    </table>
    Is there any way to avoid these line breaks and indentation?
    When I add the lines
    <xsl:output method="text"/>
    <xsl:output indent="no"/>
    to my xsl document, nothing happens.
    Thanks in advance.
    null

    Oh. One more thing. I tried parsing that very simple xml file using the xsl sheet you suggested with the class XSLSample that downloads with the parser. Same problem. Any ideas?
    xml file:
    <root>
    <foo>test text</foo>
    </root>
    xsl file:
    <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
    <xsl:output method="html" indent="no"/>
    <xsl:template match="/">
    <html>
    <body>
    <table>
    <tr>
    <td><xsl:value-of select="foo"/></td>
    <td><xsl:text>SomeText</xsl:text></td>
    </tr>
    </table>
    </body>
    </html>
    </xsl:template>
    </xsl:stylesheet>
    output:
    <root>
    <html>
    <body>
    <table>
    <tr>
    <td/>
    <td>SomeText</td>
    </tr>
    </table>
    </body>
    </html>
    </root>
    null

  • Function MAX is not working in xsl

    Hi ,
    iam facing a unique issue
    i want to print maximum postion by using the function MAX
    My style sheet is working fine in Jdev but same XSL sheet is giving error when i run it in oracle Applications.
    below is xsl logic
    <xsl:template name="ttpgds" match="ARXEURSL" mode="temp2">
    <xsl:variable name="x">     
    <xsl:for-each-group select="G_ROW[INTRA_EU_TRX_CODE =('GOOD')]" group-by="concat(VAT_TAX_NO,BILL_CUST_NAME,INTRA_EU_TRX_CODE)">
    <CHKPST><xsl:value-of select="position()"/></CHKPST><xsl:text>&#xD;</xsl:text>
    </xsl:for-each-group>
    </xsl:variable>
    <xsl:for-each select="$x">
    <xsl:variable name="jCount" select="max(CHKPST)"/>
    <xsl:value-of select="ceiling($jCount)"/>
    </xsl:for-each>
    </xsl:template>in oracle applications iam getting below error:
    Caused by: oracle.xdo.parser.v2.XPathException: Expected ')' instead of 'CHKPST'.
    Any suggestions?
    Thanks
    Anil

    The JDeveloper probably has a differnet vesion of the XDK - we have to be careful of the uptake of new versions to make sure we don't have any regressions.
    <?xslt:maximum?> in the RTF becomes
    <xsl:value-of select="xdoxslt:minimum(.//Measures.Dollars)" xdofo:field-name="xdoxslt:minimum(Measures.Dollars)" />
    with:
    <xsl:stylesheet version="2.0" xmlns:xdoxslt="http://www.oracle.com/XSL/Transform/java/oracle.xdo.template.rtf.XSLTFunctions">
    Of course that works ONLY in xml publisher. I also would strongly recommend that you try the RTF templates.
    Klaus
    Edited by: KlausFabian on Mar 17, 2010 1:08 PM - correct typo

  • Creating a text output using XML Publisher

    Hi All,
    Recently i created a  report for my client using XMl Publisher. The Data Definition was XML and the template type was RTF and i got the output in a PDF format. All was going smoothly until the client decided at the last moment that they wanted to print this in a dot matrix printer!
    I've read some articles on XSL- Text layout templates. But i can't get my head around it (I'm Functio-Technical as opposed to Techno-Functional )
    How do i convert my RTF template to give me a text output?
    Miranga

    From what I know, you will have to create another template based on "XSL" layout or eText layout (both of them require different coding methods). The RTF can not create text outputs even in 11g. This is based on my experience so far. You can create RTF output (available by default) based on the current layout that you use for PDF and see if it can be printed in a dot matrix printer though.

  • How to use Function MAX in xsl

    Hi ,
    iam facing a unique issue
    i want to print maximum postion by using the function MAX
    My style sheet is working fine in Jdev but same XSL sheet is giving error when i run it in oracle Applications.
    below is xsl logic
    <xsl:template name="ttpgds" match="ARXEURSL" mode="temp2">
    <xsl:variable name="x">     
    <xsl:for-each-group select="G_ROW[INTRA_EU_TRX_CODE =('GOOD')]" group-by="concat(VAT_TAX_NO,BILL_CUST_NAME,INTRA_EU_TRX_CODE)">
    <CHKPST><xsl:value-of select="position()"/></CHKPST><xsl:text>
    </xsl:text>
    </xsl:for-each-group>
    </xsl:variable>
    <xsl:for-each select="$x">
    <xsl:variable name="jCount" select="max(CHKPST)"/>
    <xsl:value-of select="ceiling($jCount)"/>
    </xsl:for-each>
    </xsl:template>in oracle applications iam getting below error:
    Caused by: oracle.xdo.parser.v2.XPathException: Expected ')' instead of 'CHKPST'.
    may i know how i can use the function MAX in XSl ??
    Any suggestions?
    Thanks
    Anil

    Hi,
    Hope the following helps..
    1)
    LOOP AT IT_OUTPUT.
    Call the function module to get the tracking number and store the output in the
    variable V_TRACKINGNO.
      IT_OUTPUT-TRACKING_NO = V_TRACKINGNO.
      MODIFY IT_OUTPUT TRANSPORTING TRACKING_NO.
    ENDLOOP.
    2) Date conversion
    DATA: V_CHAR(10) VALUE '2006.11.17'.
    DATA: V_DATE       TYPE SYDATUM.
    CONCATENATE V_CHAR(4) V_CHAR5(2) V_CHAR8(2) INTO V_DATE.
    WRITE: V_DATE TO V_CHAR MM/DD/YYYY.
    WRITE: / 'MM/DD/YYY Format - ',  V_CHAR.
    Please make sure to reward points for helpful answers..
    Thanks,
    Naren

  • XSL-How to get value of a variable from inside loop-- to the outside loop?

    Pls help
    hi im currently working on this xsl file..
    This works on generating a txt file,my problem right now is
    ' how can i get the value of a variable generated from the inside forloop,
    i have to get the total,sum value of this variables after performing the loop
    ***this is the for loop
    <xsl:for-each select="OutboundPayment">
    <xsl:variable name='id' select='generate-id(OutboundPayment)'/>
    <xsl:sort select="PaymentNumber/CheckNumber" data-type="text" />
    <xsl:variable name='PValue' select='format-number(100*PaymentAmount/Value,"0000000000000")'/>
    <xsl:value-of select='$id'/>
    <xsl:text>D</xsl:text>
    <xsl:value-of select='$DDate'/>
    <xsl:value-of select='$Batch'/>
    <xsl:text>3</xsl:text>
    <xsl:value-of select='format-number(PaymentNumber/PaymentReferenceNumber,"0000000000")'/>
    <xsl:value-of select='format-number(PayeeBankAccount/BankAccountNumber,"0000000000")'/>
    <xsl:value-of select='substring(Payee/Name,1,20)'/>
    <xsl:value-of select='$PValue'/>
    <xsl:variable name='Addend' select='concat($DDate,substring($DAcct,5,5),$Batch)'/>
    <xsl:variable name="LHash">
    <xsl:call-template name="GetHash">
    <xsl:with-param name="A1" select="$PValue" />
    <xsl:with-param name="A2" select="$Addend" />
    </xsl:call-template>
    </xsl:variable>
    <xsl:value-of select="concat('[',$LHash,']')" />
    <!--LHash*i have to get the total amount of this one from the outside loop /---->
    <xsl:call-template name='NewLine'/>
    </xsl:for-each>
    <!--I have to put in here the total value of that LHash/---->
    <!--This is the template on how to get the value of that variable in the inside loop/---->
    <xsl:template name="GetHash">
    <xsl:param name='A1'/>
    <xsl:param name='A2'/>
    <xsl:variable name='TwoSum' select='format-number($A1+$A2,"000000000000000")'/>
    <xsl:variable name='Weight' select='317191314191112'/>
    <xsl:call-template name="WDigit">
    <xsl:with-param name="Cnt" select="15"/>
    <xsl:with-param name="Sum" select="$TwoSum"/>
    <xsl:with-param name="Wgt" select="$Weight"/>
    <xsl:with-param name="Tot" select="0"/>
    </xsl:call-template>
    </xsl:template>
    <xsl:template name='WDigit'>
    <xsl:param name='Cnt'/>
    <xsl:param name='Sum'/>
    <xsl:param name='Wgt'/>
    <xsl:param name='Tot'/>
    <xsl:choose>
    <xsl:when test="$Cnt > 0">
    <xsl:variable name='Multip' select='substring($Wgt,$Cnt,1)'/>
    <xsl:variable name='Factor' select='substring($Sum,$Cnt,1)'/>
    <xsl:variable name='Prduct' select='$Multip$Factor'/>
    <!--xsl:value-of select="concat($Tot,'[',$Cnt,']')"/-->
    <!--xsl:value-of select="concat($Multip,'x',$Factor,'=',$Prduct)"/-->
    <!--xsl:call-template name='NewLine'/-->
    <xsl:call-template name="WDigit">
    <xsl:with-param name="Cnt" select="$Cnt - 1"/>
    <xsl:with-param name="Sum" select="$Sum"/>
    <xsl:with-param name="Wgt" select="$Wgt"/>
    <xsl:with-param name="Tot" select="$Tot+$Prduct"/>
    </xsl:call-template>
    </xsl:when>
    <xsl:otherwise>
    <xsl:variable name="Rem" select="$Tot mod 11"/>
    <xsl:variable name="Chk" select="11 - $Rem"/>
    <xsl:value-of select="format-number(concat($Tot,$Chk),'00000')"/>
    </xsl:otherwise>
    </xsl:choose>
    <xsl:template name='GetTotal'>
    </xsl:template>
    Thanks in advance for those who are willing to help.
    -Leighya

    It would have helped if you had posted your code as CODE but as it is, I could hardly read it. My guess about what you are asking is, if you want a template to return a value, just write that value to the result stream inside the template.
    If that wasn't what you were asking, then please post your code in a readable format.

Maybe you are looking for