Single quote ' in output difficulty

I'm trying to output a single quote, then a value, but I'm having trouble. Any solutions?
I've tried using '', ''', '(...)'.
    tabFIELD = 'tab-field'.
          varVALUE = 'CCC'.
          CONCATENATE cond
                    tabfield
                    'EQ'
                    <b>''varVALUE''</b>
                    INTO cond SEPARATED BY SPACE.
when using ''varVALUE'' my output is just CCC.
when using '''varVALUE''' my output is 'varVALUE'.
when using 'varVALUE' my output is just CCC.
when I try '''(varVALUE)''' my output is '(varVALUE)'.
I want 'CCC'.
Anybody know the solution? please help.
N L

To use a single quote you need to double it.  Try:
'''varVALUE'''
Since varValue is a variable, try:
'''' varvalue ''''
in your concatentation.
If you want no spacing, then you might need to put the last bit of code above in its own concatentation without seperating by space, then include that in final concatenation.
Let us know how it goes.
Message was edited by: Charles Folwell
Message was edited by: Charles Folwell

Similar Messages

  • Need Double quotes instead of Single quotes in output XML version header

    In XML output generated by XDODTEXE executable, its observed that header row looks like this:
    <?xml version = '1.0' encoding = 'UTF-8'?>
    It should look like this:
    <?xml version="1.0" encoding="UTF-8"?>
    Browsers like IE deceive. Opening the XML in Text editors show single quotes and spaces.
    Data Template and XSL template files have proper headers with double quotes.
    The output XML file is rejected by a Government Authority as parsing the header line fails.
    Are there any ways to configure this?

    I dont know if this has anything to do with my problem or not, but I thought I should add this:
    When a user is filling out the form that has the textarea,  they put whatever text they want into the textarea field.
    textarea name="text"></textarea
    Then, they click on a 'Continue' button and the system shows them a preview of what they are about to have inserted
    into the database.
    Within the code on this preview page is a hidden field, which holds the contents of their textarea data so it can be
    passed on through the process once the user verifies the preview.
    This is done using this: input type="hidden" name="text" value="<cfoutput>#text#</cfoutput>"
    Like I said, I don't know if that has anything to do with this problem, but thought it might be good to mention it
    Kudos

  • Html output genreated by the xsl should have a single quote

    hi
    i am trying to convert the xml into html .
    For one particular field i need to invoke a javscript method on
    click. a value has to be passed to this javascript method. for
    this i need a single quote or a double quote to come in the
    output.
    <a href ="javascript:loadPage('Student')"/> is what my output
    should look like but i ma getting it as
    <a href ="javascript:loadPage(&apos;Student&apos)"/> which is
    invalid.
    i am constructing the string like
    <xsl:variable name="pageName" select="'Student'"/>
    <a>
    <xsl:attribute name="href">
    <xsl:value-of select="concat('javascript:loadPage
    (',&apos;,$pageName,&apos;,')')"/>
    </xsl:attribute>
    Also i tried declaring a variable and using it instead of &apos;
    <xsl:varaible name="squote">'</xsl:variable>
    how to overcome this problem ?

    This was a bug in 9.0.1
    It's fixed in 9.0.2. For example, using the following slight
    modification of your example with 9.0.2D Beta, I get the right
    answer:
    <xsl:stylesheet version="1.0"
    xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
    <xsl:template match="/">
    <xsl:variable name="pageName" select="'Employee'"/>
    <xsl:variable name="apos">&apos;</xsl:variable>
    <a>
      <xsl:attribute name="href">
        <xsl:value-of select="concat('javascript:loadPage(',
                                     $apos,
                                     $pageName,
                                     $apos,
                                     )"/>
      </xsl:attribute>
    foo
    </a>
    </xsl:template>
    </xsl:stylesheet>Notice that I've created a variable named apos and use
    that in the concat() instead of directly using the character
    reference. This makes things clearer, I think, and easier to
    look at visually.

  • Any way to generate a single quote (') with XSLT?

    Hi:
    I guess this is really an XSLT question. I'm using the Transform() method of an XMLType variable to apply a style sheet. The XML in the variable is just something simple like
    <TBL>
    <LAST_NAME>LIKE|JONES</LAST_NAME>
    <FIRST_NAME>=|MARY</FIRST_NAME>
    <AGE>=|50</AGE>
    </TBL>
    I am trying to get a stylesheet to transform something like the above into SQL such as
    Select * from foo where LAST_NAME like 'JONES'
    and FIRST_NAME ='MARY'
    and AGE = 50But to do this, I need to generate the single quotes around the search terms and I can't get anything but LAST_NAME LIKE &apos;JONES&apos;. Is there a way to do this? For now I am generating a ~ and replacing ~ for ' throughout the generated SQL text but that's a pretty sorry solution.
    I thought that something like <xsl:text disable-output-escaping="yes">&amp;</xsl:text> was going to work but then found out it has been deprecated. I was thinking character-map might work but that's an XSLT 2.0 thing and apparently 10g is on XSLT 1.0? In any case, it had no idea what I was trying to do with a character map.
    So, am I overlooking an obvious way to get my stylesheet to insert apostrophes?
    Thanks.

    It's 10.2.0.4.
    Here's the procedure that accepts the XML/XSL clobs and tries to produce a SQL statement.
    PROCEDURE GetSQLQueryFromXML(XMLClob in CLOB, XSLStylesheet in CLOB,
                SQLQuery out CLOB, status out integer) IS
        -- Define the local variables
      xmldata               XMLType;  -- The XMLType format of the XML to transform
      xsldata               XMLType;  -- The XMLType format of the stylesheet to apply
      sqlQuery_XMLType      XMLType;  -- The XMLType format of the SQL query.
      v_SQLQuery            Clob;     -- Holds XML Clob before translating ~ to '
    BEGIN
    status := -1;  -- Initially unsuccessful
      -- Get the XML document using the getXML() function defined in the database.
      -- Since XMLType.transform() method takes XML data as XMLType instance,
      -- use the XMLType.createXML method to convert the XML content received
      -- as CLOB into an XMLType instance.
      xmldata := XMLType.createXML(XMLClob);
      -- Get the XSL Stylesheet using the getXSL() function defined in the database.
      -- Since XMLType.transform() method takes an XSL stylesheet as XMLType instance,
      -- use the XMLType.createXML method to convert the XSL content received as CLOB
      -- into an XMLType instance.
      xsldata := XMLType.createXML(XSLStylesheet);
      -- Use the XMLtype.transform() function to get the transformed XML instance.
      -- This function applies the stylesheet to the XML document and returns a transformed
      -- XML instance.
      sqlQuery_XMLType := xmldata.transform(xsldata);
      -- Return the transformed XML instance as a CLOB value.   
      v_SQLQuery := sqlQuery_XMLType.getClobVal();
      -- Change tildas to apostrophes.  Currently unable to get an XSLT transformation
      -- to insert single quotes, so we're inserting ~ instead.  Now we need to
      -- translate all ~s to 's in our query.
      SQLQuery := translate(to_char(v_SQLQuery),'~','''');
      status := 1; -- Everything went fine to get here
    EXCEPTION
      WHEN OTHERS THEN         
        raise_application_error
        (-20102, 'Exception occurred in GetSQLQueryFromXML :'||SQLERRM);
    END GetSQLQueryFromXML;The XML it works off of is
        someXML CLOB :=
        to_clob('<?xml version="1.0" encoding="windows-1252" ?>
    <variable table_name="SOME_PERSON_TABLE" query_type="PERSON">
      <item>
        <fieldName><![CDATA[PERSON_KEY]]></fieldName>
        <criteria><![CDATA[=]]></criteria>
        <fieldType><![CDATA[Integer]]></fieldType>
        <value><![CDATA[123456789]]></value>
      </item>
      <item>
        <fieldName><![CDATA[LAST_NAME]]></fieldName>
        <criteria><![CDATA[=]]></criteria>
        <fieldType><![CDATA[String]]></fieldType>
        <value><![CDATA[DOE]]></value>
      </item>
      <item>
        <fieldName><![CDATA[FIRST_NAME]]></fieldName>
        <criteria><![CDATA[=]]></criteria>
        <fieldType><![CDATA[String]]></fieldType>
        <value><![CDATA[JOHN]]></value>
      </item>
      <item>
        <fieldName><![CDATA[MIDDLE_NAME]]></fieldName>
        <criteria><![CDATA[-]]></criteria>
        <fieldType><![CDATA[String]]></fieldType>
        <value />
      </item>
      <item>
        <fieldName><![CDATA[SUFFIX]]></fieldName>
        <criteria><![CDATA[-]]></criteria>
        <fieldType><![CDATA[String]]></fieldType>
        <value />
      </item>
    </variable>');And the corresponding XSLT that should translate it is:
      myStylesheet  CLOB :=
      to_clob('<?xml version="1.0" encoding="ISO-8859-1"?>
    <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
    <!-- <xsl:preserve-space elements="list-of-element-names"/> -->
      <!-- We just want the SQL text output.  No XML declaration etc. -->
      <xsl:output method="text" omit-xml-declaration="yes" indent="no"/>
    <!-- Apostrophes will be made tildas and the PL/SQL will translate those to -->
    <!-- apostrophes for the final SQL string. -->
    <xsl:variable name="apos">~</xsl:variable>
      <xsl:template match="/">
        select * from
        <xsl:value-of select="variable/@table_name"/>
        where 1=1
        <xsl:for-each select="variable/child::node()">
          <xsl:choose>
            <!-- if the value node is not null... -->
            <xsl:when test="./value/text()[normalize-space(.)]">
            <!-- There is another predicate.  Add the AND term and the predicate -->
              AND <xsl:value-of select="./fieldName"/>
              <xsl:text> </xsl:text>
              <xsl:value-of select="./criteria"/>
              <xsl:text> </xsl:text>       
              <xsl:choose>
                <xsl:when test="string(./fieldType)=''String''">
                  <xsl:copy-of select="$apos" />
                  <xsl:value-of select="./value"/>
                  <xsl:copy-of select="$apos" />
                </xsl:when>         
                <xsl:when test="string(./fieldType)=''Clob''">
                  <xsl:copy-of select="$apos" />
                  <xsl:value-of select="./value"/>
                  <xsl:copy-of select="$apos" />
                </xsl:when>
                <xsl:otherwise>
                  <xsl:value-of select="./value"/>
                </xsl:otherwise>
              </xsl:choose>
            </xsl:when>
          </xsl:choose>
        </xsl:for-each>
      </xsl:template>
    </xsl:stylesheet>');Basically if the VALUE element has a value then the fieldType is checked. If fieldType is String or Clob then we'll need the apostrophes. For now I'm putting in tildas and changing them later.

  • Replacing " (double quote) with ' (single quote)

    Hi there,
    I have the following method to manipulate user input. All I want to do is, to replace the double quote with a single quote. The implementation I tried was,
    this.replace(desc, "\"", "'");
    This does not work for me. It jsut removes the double quote and does not introduces the single quote. Could any one please advise?
    Thanks,
    Des
    public static String replace(String line, String oldString, String newString) {
              if(line != null && oldString != null && newString != null) {
                   int index = 0;
                   while ((index = line.indexOf(oldString, index)) >= 0) {
                        line = line.substring(0, index) +
                             newString +
                             line.substring(index + oldString.length());
                        index += newString.length();
              return line;
         }

    Bad luck.. I am unable to get it still.
    This is the code I am using (implemetation is in a JSP. I am using this code to test it).
    public class Test{
    public static void main(String args[]){
         String s = args[0];
         Test t = new Test();
         String doubleQuote = "\"";
         System.out.println(" output :"+ t.replace(s,doubleQuote,"'"));
         //System.out.println(" output :"+ t.replace(s,"\"","'"));
         //System.out.println(" output :"+ t.replace('"', '\''));
    public static String replace(String line, String oldString, String newString) {
              if(line != null && oldString != null && newString != null) {
                   int index = 0;
                   while ((index = line.indexOf(oldString, index)) >= 0) {
                             System.out.println(" line count :");
                        line = line.substring(0, index) +
                             newString +
                             line.substring(index + oldString.length());
                        index += newString.length();
              return line;
    }mshn02
    The main problem is I am stuck with the server's version of Java (which I have no control on it). I could not use 1.4.2

  • XML invalid character -  a single quote problem

    Hi, I am reading in an xml file, then write the file to output. The problem is that the input file has a strange single quote character [ *�*  ] - lets call it single quoate A, which is different from [  *'*  ] , that is the key next to the [ ; ] key on an English keyboard - lets call it single quate B. And in fact there isnt a key to input single quote A, I guess the appearance of single quote A is due to encoding.
    If I open the input xml file in browser, it works ok and displays the single quote A.
    Once I read in the xml file into memory, by debugging I can still see that single quote A is corrected encoded;
    However once I rewrite the same content to output, the single quote A character is changed, and if i open the file in browser, it says 'invalid character' because single quote A were changed when written to output and cannot be rendered.
    Both input and output xml are using UTF-8 encoding. How can I solve this problem please?
    The xml file looks:
    <?xml version="1.0" encoding="UTF-8" ?>
    <content>....1980�s (Peacock and Williams, 1986; Keay, 1984)</content> My code for reading
    String _xquery ="//content/text()";
    Document _xmlDoc= DocumentBuilderFactory.newInstance().newDocumentBuilder().parse("myxml.xml");
    XPath _xpath = XPathFactory.newInstance().newXPath();
    NodeList nodes = (NodeList) _xpath.compile(query).evaluate(_xmlDoc, XPathConstants.NODESET);
    List<String> res = new ArrayList<String>(nodes.getLength());
    for (int i = 0; i < nodes.getLength(); i++) {
        res.add(nodes.item(i).getNodeValue());
    String valueToOuput=res.toString() //this is the value to be output to xml, it shoud look like "[....1980�s (Peacock and Williams, 1986; Keay, 1984)]"my code for writing xml
    Element root=new Element("root");;
    Element content= new Element("output-content")
    content.setText(valueToOutput);
    root.addContent(content);
    PrintWriter writer = new PrintWriter(new FileWriter(f));
    new XMLOutputter().output(domDocument, writer);
    writer.close();

    Hi, sorry I have fixed the problem... instead of using PrintWriter, I used Fileoutputstream, and it solved the problem. Thanks!

  • String value changes single quote ' to double quote "

    I am creating a list with different bill codes within single
    quotes as follows
    <cfset corlist = " '1100 ','1200 ','1300 ','1700 ','1800
    ','1950 ','7001 ' ">
    when I do an output
    for
    <cfoutput>AND idbillcode IN ( #corlist
    #)</cfoutput>
    I get the values as follows
    AND idbillcode IN ( '1100 ','1200 ','1300 ','1700 ','1800
    ','1950 ','7001 ')
    However when I put the same string within a cfquery the
    single quotes get replaced by double quotes as follows
    AND idbillcode IN ( ''1100 '',''1200 '',''1300 '',''1700
    '',''1800 '',''1950 '',''7001 '') which throws an error.
    Anybody has any clues.
    Thanks.

    However when I put the same string within a cfquery the
    single quotes
    get replaced by double quotes as follows
    AND idbillcode IN ( ''1100 '',''1200 '',''1300 '',''1700
    '',''1800
    '',''1950
    '',''7001 '') which throws an error.
    Anybody has any clues.
    That is ColdFusion escaping the single quotes, by doubling
    them so that
    you can search for strings such as "singhpk's code does not
    work".
    (Note the single quote/apostrophe that would normally break
    this string
    if it was not escaped.
    To tell CF not to do this, one uses the
    preserveSingleQuotes() function.
    The documentation has all the details.

  • SQL: Need help putting single quote around string

    I want to put single quotes around string in my output.
    I am running the following command as a test:
    select ' ' hello ' ' from dual;
    My expectation is to get 'hello' (Single quote around hello)
    However I am getting the following error:
    ERROR at line 1:
    ORA-00923: FROM keyword not found where expected
    When I do SHOW ALL at my SQL command prompt, the escape is set as follows:
    escape "\" (hex 5c)
    I even tried: select '\'hello\'' from dual;
    I get back: select ''hello'' from dual
    ERROR at line 1:
    ORA-00923: FROM keyword not found where expected

    Hi,
    user521525 wrote:
    I want to put single quotes around string in my output.
    I am running the following command as a test:
    select ' ' hello ' ' from dual;
    My expectation is to get 'hello' (Single quote around hello)You probably read that you can get a single-quote within a string literal by using two of them in a row.
    That's true, but they really have to be in a row (no spaces in between), and you still need the single-quotes at the beiginning and end of the literal.
    So what you want is
    SELECT  '''hello'''
    FROM    dual;Starting in Oracle 10, you can also use Q-notation, For example:
    SELECT  Q'['hello']'
    FROM    dual;

  • SQL*Loader and data enclosed by single quotes

    Hello,
    I need to migrate some data from Sybase to Oracle. Can't use the Migration Workbench because this is Sybase's SQL Anywhere product. We are therefore trying to load via SQL*Loader.
    Sybase outputs its data into text files and encloses it with single quotes, like:
    'ABC123',
    'UR94LL',
    '7YUHII'
    We are running into a problem because we cannot figure out how to use the OPTIONALLY ENCLOSED BY parameter with single quotes. If we just use the FIELDS TERMINATED BY parameter, then the entire string, including the quotation marks, gets loaded into the Oracle table. This causes bad records to be created when the data is exactly the length of the column width - the two quotation markss make the field longer than is allowed in the table. Plus - the data shouldn't have quotes around it in normal situations.
    We can do 'Find and Replace' to replace the single quotation marks with double quotations, but some of the Sybase tables are huge, and we'd like to avoid having to open and edit them. However, if this is the only way to go, then we'll have to use it. I just wondered whether anyone had run into this before and been able to solve it.
    Thanks.
    -melissa

    We are running into a problem because we cannot figure out how to use the OPTIONALLY ENCLOSED BY parameter with single quotesTry
    OPTIONALLY ENCLOSED BY X'27'http://download-uk.oracle.com/docs/cd/B10501_01/server.920/a96652/ch06.htm#1015083

  • Problem with lookup-table and single quotes

    SOA Suite 10.1.3.3. I have an ESB project with an XSLT map that uses orcl:lookup-table to translate values. I use this instead of lookup-dvm because I want non-IT users to manage the mappings without having access to the ESB Console.
    According to the doco:-
    G.1.79 lookup-table
    orcl:lookup-table(table, inputColumn, key, outputColumn, datasource)
    This function returns a string based on the SQL query generated from the parameters.
    The string is obtained by executing:
    SELECT outputColumn FROM table WHERE inputColumn = key
    The problem I'm having is that it seems if "key" contains a single quote (i.e an apostrophe), then lookup-table fails to find the corresponding value - even though the value in table.inputColumn also contains the single quote.
    I've put the incoming into an XSL variable, but to no avail.
    <xsl:variable name="incoming">
    <xsl:value-of select="/obj1:DEV_MESSAGE_TYP/DATA1"/>
    </xsl:variable>
    <xsl:variable name="dvm-text">
    <xsl:value-of select="orcl:lookup-table('MYTABLE','INVAL',$incoming,'OUTVAL','ds/dev')"/>
    </xsl:variable>
    Are there any XSLT Gurus out there that have come across this or can think of ways around it?
    Thanks in advance...
    Regards,
    Greg

    Ok - the above was on the right track but wasn't 100% because it can't handle more than 1 single quote (apostrophe) in the input to lookup-table.
    I've since found a better solution - an XSLT re-usable template that operates recursively and so can replace multiple occurances of single quotes. I've modified it to handle a null input value, otherwise lookup-table will just return the value of the first row in the lookup table - doh! The way I've done it below, if null is passed in, then null will be returned.
    This goes at the top of your XSLT map file...
    <!-- reusable replace-string function -->
    <xsl:template name="replace-string">
    <xsl:param name="text"/>
    <xsl:param name="from"/>
    <xsl:param name="to"/>
    <xsl:choose>
    <xsl:when test="contains($text, $from)">
         <xsl:variable name="before" select="substring-before($text, $from)"/>
         <xsl:variable name="after" select="substring-after($text, $from)"/>
         <xsl:value-of select="$before"/>
         <xsl:value-of select="$to"/>
    <xsl:call-template name="replace-string">
    <xsl:with-param name="text" select="$after"/>
    <xsl:with-param name="from" select="$from"/>
    <xsl:with-param name="to" select="$to"/>
         </xsl:call-template>
    </xsl:when>
    <xsl:when test="$text=''">NULL</xsl:when>
    <xsl:otherwise>
    <xsl:value-of select="$text"/>
    </xsl:otherwise>
    </xsl:choose>
    </xsl:template>
    Then you call it from within the XSLT map as follows:-
    <!-- if contains a single quote, replace with 2x single quotes. This makes lookup-table work! -->
    <xsl:variable name="incoming">
    <xsl:call-template name="replace-string">
    <xsl:with-param name="text" select="inp1:myinputfield"/>
    <xsl:with-param name="from">'</xsl:with-param>
    <xsl:with-param name="to" select="'&amp;apos;&amp;apos;'"/>
    </xsl:call-template>
    </xsl:variable>
    <xsl:variable name="dvm-text">
    <xsl:value-of select="orcl:lookup-table('MYLOOKUPTABLE','INVAL',$incoming,'OUTVAL','ds/dev')"/>
    </xsl:variable>
    <!-- lookup-table returns null if input value not found. Output original value instead -->
    <xsl:choose>
    <xsl:when test="$dvm-text=''">
    <xsl:value-of select="inp1:myinputfield"/>
    </xsl:when>
    <xsl:otherwise>
    <xsl:value-of select="$dvm-text"/>
    </xsl:otherwise>
    </xsl:choose>
    Much Thanks to everyone who shares information and methods on the Internet!
    Cheers,
    Greg

  • XMLType Transform Single Quotes

    When performing a transform into html on an XMLType column in the database, single quotes are getting converted to &apos;.
    Here is a sample XSL:
    <?xml version="1.0" encoding="UTF-8"?>
    <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:fo="http://www.w3.org/1999/XSL/Format">
         <xsl:template match="/">
              <html>
                   <head>
                        <title></title>
                   </head>
                   <script type="Javascript">alert('here');</script>
                   <body>HERE</body>
              </html>
         </xsl:template>
    </xsl:stylesheet>
    This is the SQL query I use to perform the transform:
    select X.XMLData.transform((Select xmldata from xmltest where title='HTMLTest')).getstringval()
    from xmltest X where title='HTMLTest'
    This is the result of performing the transform/query:
    <html>
    <head>
    <title/>
    </head>
    <script type="Javascript">alert(&apos;here&apos;);</script>
    <body>HERE</body>
    </html>
    Under XMLspy's xslt processor and even Oracle's parser.v2.oraxsl, the output is not escaped.
    I have tried using CDATA and <xsl:text disable-output-escaping="yes"> as well, but non of them worked.
    I am new to XSL, so am probably missing something, anyone have any ideas on how to get around this?
    Thanks,
    Tom Hubbard

    This is a limitation of the current implementation. The correct solution is 'disable-output-escaping' but we do not support it. THe rules of thumb is that the XML DB transform can (currently) only be used to generate valid XML....

  • Include Single Quote

    Hi alll,
    I have a query like this..
    WITH t AS (
    SELECT 'GreatkannAd' colnm FROM dual
    UNION ALL
    SELECT 'Greatka' FROM dual
    UNION ALL
    SELECT 'GreatKaNNa' FROM dual
    SELECT 'SELECT * from yourtable_name' ||' '|| 'where columnname like' ||' '||'%'||colnm||'%'  from t The output am getting is
    SELECT * from yourtable_name where columnname like %GreatkannAd%
    SELECT * from yourtable_name where columnname like %Greatka%
    SELECT * from yourtable_name where columnname like %GreatKaNNa%But my requirement is to include single quote (') before beginning and end of each string .
    Output required is
    SELECT * from yourtable_name where columnname like '%GreatkannAd%'
    SELECT * from yourtable_name where columnname like '%Greatka%'
    SELECT * from yourtable_name where columnname like '%GreatKaNNa%'Regards,
    achyut
    Edited by: Achyut K on Jan 10, 2011 4:38 AM

    try
    WITH t AS (
    SELECT 'GreatkannAd' colnm FROM dual
    UNION ALL
    SELECT 'Greatka' FROM dual
    UNION ALL
    SELECT 'GreatKaNNa' FROM dual
    SELECT 'SELECT * from yourtable_name' ||' '|| 'where columnname like' ||' '||'''%'||colnm||'%''' from t
    Nimish Garg
    http://nimishgarg.blogspot.com/

  • Bash error messages: backtick vs single quote

    I'm running xfstests over NFS... the expected output for test 306 is:
    touch: cannot touch `SCRATCH_MNT/this_should_fail': Read-only file system
    ^^^
    But I'm seeing:
    touch: cannot touch 'SCRATCH_MNT/this_should_fail': Read-only file system
    ^^^
    The test is failing because my system is printing a single quote instead of a backtick before SCRATCH_MNT.  Is there an easy way to control this?

    Hi,
    What is your locale ?
    Sometimes, the quote characters in the program's output depends on the current locale.
    You should try some of these:
    LC_ALL=C your-command
    LC_ALL=en_US.UTF-8 your-command
    For instance:
    $ LC_ALL=C cp -v a b
    'a' -> 'b'
    $ LC_ALL=en_US.UTF-8 cp -v a b
    ‘a’ -> ‘b’
    $ LC_ALL=fr_FR.UTF-8 cp -v a b
    « a » -> « b »
    Last edited by nowahn (2013-03-29 08:56:42)

  • Escaping Single Quotes in UIX LOVs

    Hello all,
    I am creating an application using ADF and UIX. In the system, I am using the standard UIX LOV, and I am curious if there is an existing way of handling single quotes entered by users in the search area. By default (at least in my case), single quotes cause an error in the SQL query, so I would like to escape them before the query is run. I attempted to override the onLovFilter method to handle this, but it seems like the LOV window does not actually fire any events or call overridden methods. I also overrode prepareMode to simply output "hello" when it is called, to test if any events were really being fired, but my method looks like it is simply being ignored. Is there a simpler way to avoid troubles caused by single quotes? Or can anyone help me override methods in LOVs? Thanks in advance.
    Regards,
    John

    No. Please use PreparedStatements. That is theonly
    correct answer to this question.Ok please tell us. how would you use prepare
    statement.. no just say USE PREPARE STATE.. givethe
    guy the code... or help..What size spoon would you like to be fed with? There
    was nothing about gob size in the original post.
    http://www.javaalmanac.com
    well duffymo.. i think you gave a link, is quite of help, but my friend preparestatement just gave "use preparestatement"..
    i think even you when you start coding you needed help... and some one just tell you use preparestatement how do you feel..
    There is a level of help. i think it will be (((as much as you can)))

  • XLIFF escaping (single quote)

    i have a resource string that looks like,
    <trans-unit id="...">
    <source>'{0}'</source>
    <target/>
    </trans-unit>
    notice the single quotes around the token. when i do this, the token won't get replaced by MessageFormat.format(). i tried escaping the single quotes like \'{0}\' which had no effect.
    thanks.

    answering my own question ... this has nothing to do w/ XLIFF. looking at the MessageFormat javadocs, there are some rather confusing details about how single quotes are used to escape. it turns out that a double single quote gets a single quote in the output,
    ''{0}''

Maybe you are looking for

  • How can I execute a batch file from my java program

    Hi, Can someone help me or direct me to a link, How can I execute a DOS batch file from my java program? Thanks

  • File adapter read activity.

    Hi, is it possible to make the file adapter to look for specific files and ignore others in the same directory or do you have to write a web service for that? I want the file adapter to poll for certain files only. Best Regards Johan

  • 8 bit jpeg files in Aperture 3?

    Can I save my images as 8 bit jpeg files in Aperture 3? If so, how? Thank you!

  • Siebel Adapter on OAS 10.1.3.3 without BPEL?

    Is it possible to run the Siebel Adapter on OAS 10.1.3.3 without installing BPEL? We are using the ESB, and otherwise have no need for BPEL, but after installation and configuration of the adapter, it does not show in the OC4J container, and cannot b

  • Choose kind of tax on F-28

    Hi experts, I am practicing in t-code F-28. First, I choose a bank account. Second, in post incoming payments process open items, I choose invoice to paid. Addition, I want to more 1item (tax: posting key = 50, account = tax), but I can't choose kind