Error java: "Dangling meta character '+' near index 0 + ^"

Hi,
I'm receiving a runtime error, when I was trying to run search engine (only when I insert a symbol "+" plus or "\" slash) in B2B (E-selling of CRM-ISA 5.0).
This is the text error:
<b>
java.util.regex.PatternSyntaxException: Dangling meta character '+' near index 0
+
^
     at java.util.regex.Pattern.error(Pattern.java:1541)
     at java.util.regex.Pattern.sequence(Pattern.java:1658)
     at java.util.regex.Pattern.expr(Pattern.java:1558)
     at java.util.regex.Pattern.compile(Pattern.java:1291)
     at java.util.regex.Pattern.(Pattern.java:1047)
     at java.util.regex.Pattern.compile(Pattern.java:808)
     at com.sap.isa.catalog.uiclass.ProductsUI.getHighlightedResults(ProductsUI.java:487)
     at jsp_ProductsISA1173566617857._jspService(jsp_ProductsISA1173566617857.java:507)
     at com.sap.engine.services.servlets_jsp.server.jsp.JspBase.service(JspBase.java:112)
     at com.sap.engine.services.servlets_jsp.server.servlet.JSPServlet.service(JSPServlet.java:544)
     at com.sap.engine.services.servlets_jsp.server.servlet.JSPServlet.service(JSPServlet.java:186)
     at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
     at com.sap.engine.services.servlets_jsp.server.runtime.RequestDispatcherImpl.doWork(RequestDispatcherImpl.java:321)
     at com.sap.engine.services.servlets_jsp.server.runtime.RequestDispatcherImpl.forward(RequestDispatcherImpl.java:377)
     at org.apache.struts.action.RequestProcessor.doForward(RequestProcessor.java:1069)
     at org.apache.struts.action.RequestProcessor.processForwardConfig(RequestProcessor.java:455)
     at com.sap.isa.core.RequestProcessor.processForwardConfig(RequestProcessor.java:267)
     at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:279)
     at com.sap.isa.core.RequestProcessor.process(RequestProcessor.java:391)
     at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1482)
     at com.sap.isa.core.ActionServlet.process(ActionServlet.java:243)
     at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:507)
     at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
     at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
     at com.sap.engine.services.servlets_jsp.server.runtime.RequestDispatcherImpl.doWork(RequestDispatcherImpl.java:321)
     at com.sap.engine.services.servlets_jsp.server.runtime.RequestDispatcherImpl.forward(RequestDispatcherImpl.java:377)
     at org.apache.struts.action.RequestProcessor.doForward(RequestProcessor.java:1069)
     at org.apache.struts.action.RequestProcessor.processForwardConfig(RequestProcessor.java:455)
     at com.sap.isa.core.RequestProcessor.processForwardConfig(RequestProcessor.java:267)
     at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:279)
     at com.sap.isa.core.RequestProcessor.process(RequestProcessor.java:391)
     at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1482)
     at com.sap.isa.core.ActionServlet.process(ActionServlet.java:243)
     at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:507)
     at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
     at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
     at com.sap.engine.services.servlets_jsp.server.runtime.RequestDispatcherImpl.doWork(RequestDispatcherImpl.java:321)
     at com.sap.engine.services.servlets_jsp.server.runtime.RequestDispatcherImpl.forward(RequestDispatcherImpl.java:377)
     at org.apache.struts.action.RequestProcessor.doForward(RequestProcessor.java:1069)
     at org.apache.struts.action.RequestProcessor.processForwardConfig(RequestProcessor.java:455)
     at com.sap.isa.core.RequestProcessor.processForwardConfig(RequestProcessor.java:267)
     at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:279)
     at com.sap.isa.core.RequestProcessor.process(RequestProcessor.java:391)
     at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1482)
     at com.sap.isa.core.ActionServlet.process(ActionServlet.java:243)
     at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:507)
     at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
     at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
     at com.sap.engine.services.servlets_jsp.server.runtime.RequestDispatcherImpl.doWork(RequestDispatcherImpl.java:321)
     at com.sap.engine.services.servlets_jsp.server.runtime.RequestDispatcherImpl.forward(RequestDispatcherImpl.java:377)
     at org.apache.struts.action.RequestProcessor.doForward(RequestProcessor.java:1069)
     at org.apache.struts.action.RequestProcessor.processForwardConfig(RequestProcessor.java:455)
     at com.sap.isa.core.RequestProcessor.processForwardConfig(RequestProcessor.java:267)
     at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:279)
     at com.sap.isa.core.RequestProcessor.process(RequestProcessor.java:391)
     at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1482)
     at com.sap.isa.core.ActionServlet.process(ActionServlet.java:243)
     at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:507)
     at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
     at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
     at com.sap.engine.services.servlets_jsp.server.runtime.RequestDispatcherImpl.doWork(RequestDispatcherImpl.java:321)
     at com.sap.engine.services.servlets_jsp.server.runtime.RequestDispatcherImpl.forward(RequestDispatcherImpl.java:377)
     at org.apache.struts.action.RequestProcessor.doForward(RequestProcessor.java:1069)
     at org.apache.struts.action.RequestProcessor.processForwardConfig(RequestProcessor.java:455)
     at com.sap.isa.core.RequestProcessor.processForwardConfig(RequestProcessor.java:267)
     at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:279)
     at com.sap.isa.core.RequestProcessor.process(RequestProcessor.java:391)
     at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1482)
     at com.sap.isa.core.ActionServlet.process(ActionServlet.java:243)
     at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:507)
     at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
     at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
     at com.sap.engine.services.servlets_jsp.server.runtime.RequestDispatcherImpl.doWork(RequestDispatcherImpl.java:321)
     at com.sap.engine.services.servlets_jsp.server.runtime.RequestDispatcherImpl.forward(RequestDispatcherImpl.java:377)
     at org.apache.struts.action.RequestProcessor.doForward(RequestProcessor.java:1069)
     at org.apache.struts.action.RequestProcessor.processForwardConfig(RequestProcessor.java:455)
     at com.sap.isa.core.RequestProcessor.processForwardConfig(RequestProcessor.java:267)
     at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:279)
     at com.sap.isa.core.RequestProcessor.process(RequestProcessor.java:391)
     at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1482)
     at com.sap.isa.core.ActionServlet.process(ActionServlet.java:243)
     at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:507)
     at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
     at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
     at com.sap.engine.services.servlets_jsp.server.runtime.FilterChainImpl.runServlet(FilterChainImpl.java:117)
     at com.sap.engine.services.servlets_jsp.server.runtime.FilterChainImpl.doFilter(FilterChainImpl.java:62)
     at com.tealeaf.capture.LiteFilter.doFilter(Unknown Source)
     at com.sap.isa.isacore.TealeafFilter.doFilter(TealeafFilter.java:61)
     at com.sap.engine.services.servlets_jsp.server.runtime.FilterChainImpl.doFilter(FilterChainImpl.java:58)
     at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.runServlet(HttpHandlerImpl.java:373)
     at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.handleRequest(HttpHandlerImpl.java:264)
     at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:347)
     at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:325)
     at com.sap.engine.services.httpserver.server.RequestAnalizer.invokeWebContainer(RequestAnalizer.java:887)
     at com.sap.engine.services.httpserver.server.RequestAnalizer.handle(RequestAnalizer.java:241)
     at com.sap.engine.services.httpserver.server.Client.handle(Client.java:92)
     at com.sap.engine.services.httpserver.server.Processor.request(Processor.java:148)
     at com.sap.engine.core.service630.context.cluster.session.ApplicationSessionMessageListener.process(ApplicationSessionMessageListener.java:33)
     at com.sap.engine.core.cluster.impl6.session.MessageRunner.run(MessageRunner.java:41)
     at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37)
     at java.security.AccessController.doPrivileged(Native Method)
     at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:100)
     at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:170)</b>
Any help will be appreciated.
Regards
Mark

split() takes a regular expression, not just simple text. The + symbol means something special. Try something like split("\\+TO\\+")

Similar Messages

  • PatternSyntaxException: Dangling meta character '*' near index 0

    Hi,
    I am using DocumentFilter to control the input in a JtextField In accordance with model of a mask.
    The mask can contain the following characters:
        //  # :  for  =---> NUMBER only
        //  ? :  for  =---> LETTER only
        //  A :  for  =---> LETTER end for NUMBER
        //  * :  for  =---> ANYTHING    I made a class that extends DocumentFilter and it look like this:
    public class MydocumentFilter extends DocumentFilter {
    public void insertString(...){
    // do anything
        } // insertString()
    public void remove(...)
    // do anything
        } // remove()
    @Override
        public void replace(
                DocumentFilter.FilterBypass fb,
                int offset, // posizione del cursore
                int length, // Length of text to delete (solo per sostituzioni...)
                String text,// testo da inserire
                AttributeSet attrs) throws BadLocationException {
    // here are some controls that change the value of the text variable, and at last call the super class..:
            super.replace(fb, offset, length, text.replaceAll(text, replace), attrs);
        } // replace()
    } // class  MydocumentFilterI have a problem when the user write wildcards (='*' OR '?').
    Then I get the message:
    Exception in thread "AWT-EventQueue-0" java.util.regex.PatternSyntaxException: Dangling meta character '*' near index 0.I know that '*' and “?” are is a metachars and for that I added this code before calling super.replace(...);
            if (text.compareTo("*") == 0){
                replace = "\\*";
            }but I don't get the expected result. I get -\*- instead then -*-
    here the code of the program that I use to make tests:
    * http://www.java2s.com/Tutorial/Java/0260__Swing-Event/CustomDocumentFilter.htm
    * @author Owner
    //public class IntegerRangeDocumentFilter extends DocumentFilter {
    public class NavBean_documentFilter extends DocumentFilter {
        enum CharAcceptability_ENUM {
            valid, invalid, overrite
        String mask;
        public NavBean_documentFilter(String mask_) { // constructor
            mask = mask_;
        } // constructor
        @Override
        public void insertString(
                DocumentFilter.FilterBypass fb,
                int offset,
                String string,
                AttributeSet attr) throws BadLocationException {
            System.out.println("insert string" + string);
            System.out.println(offset);
            super.insertString(fb, offset, string, attr);
        } // insertString()
        @Override
        public void remove(DocumentFilter.FilterBypass fb, int offset, int length)
                throws BadLocationException {
            System.out.println("remove");
            super.remove(fb, offset, length);
        } // remove()
        public void replace(
                DocumentFilter.FilterBypass fb,
                int offset, // posizione del cursore
                int length, // Length of text to delete (solo per sostituzioni...)
                String text,// testo da inserire
                AttributeSet attrs) throws BadLocationException {
            boolean valid = true;
            if (offset > mask.length()) {
                return;
            if (text.length() != 1) {
                return;
            CharAcceptability_ENUM charAcceptability_ENUM = checkTheInput(text, offset);
            String replace = null;
            switch (charAcceptability_ENUM) {
                case invalid:
                    replace = "";
                    break;
                case valid:
                    replace = text;
                    break;
                case overrite:
                    char cc = mask.charAt(offset);
                    replace = String.valueOf(cc);
                    break;
            // It is because * is used as a metacharacter to signify one or more
            // occurences of previous character.
            // So if i write M* then it will look for files MMMMMM..... !
            // Here you are using * as the only character so the compiler
            // is looking for the character to find multiple occurences of,
            // so it throws the exception.:)
            if (text.compareTo("*") == 0){
                replace = "\\*";
            text = replace;
            super.replace(fb, offset, length, text.replaceAll(text, replace), attrs);
    //        super.replace(fb, offset, length, text, attrs);
        } // replace()
        private CharAcceptability_ENUM checkTheInput(String text, int cursorPosition) {
            if (cursorPosition >= mask.length()) {
                return CharAcceptability_ENUM.invalid;
            char mappedCharInTheMask = mask.charAt(cursorPosition); // qui erro
            char charToSet = text.charAt(0);
            System.out.println("carattere da mettere = " + charToSet + " ; carattere della maschera = " + mappedCharInTheMask);
            boolean placeHolderFree = mask.contains(String.valueOf(mappedCharInTheMask));
            if (!placeHolderFree) {
                return CharAcceptability_ENUM.invalid;
            CharAcceptability_ENUM charAcceptability_ENUM =
                    CharAcceptability_ENUM.invalid;
            char holdPlace = mask.charAt(cursorPosition);
            switch (holdPlace) {
                case '*': // 
                    charAcceptability_ENUM = CharAcceptability_ENUM.valid;
                    break;
                case '#': // only numbers
                    if ( Character.isDigit(charToSet)) {
                    charAcceptability_ENUM = CharAcceptability_ENUM.valid;
                    break;
                case '?': //only letters
                    if (Character.isLetter(charToSet)){
                        charAcceptability_ENUM = CharAcceptability_ENUM.valid;
                    break;
                case 'A': // letters and numbers
                    if (Character.isLetterOrDigit(charToSet)){
                    charAcceptability_ENUM = CharAcceptability_ENUM.valid;
                    break;
                    default:
                        charAcceptability_ENUM = CharAcceptability_ENUM.overrite;
            System.out.println("valore di charAcceptability_ENUM = " + charAcceptability_ENUM.toString());
            return charAcceptability_ENUM;
        } // checkTheInput()
    } // class UsingDocumentFilter
    class RangeSample {
        public static void main(String args[]) {
            JFrame frame = new JFrame("Range Example");
            frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
            // questo (in generale) e' quanto si deve fare per usare un filtro...
            JTextField textFieldOne = new JTextField();
            JLabel jLabMask = new JLabel();
            JPanel panel = new JPanel();
            String explanation1 = "      ---  use of wildCard: ---";
            String explanation2 = " #  :  is for  =---> only NUMBER ";
            String explanation3 = " ?  :  is for  =---> only LETTER ";
            String explanation4 = " A  :  is for  =---> LETTER end NUMBER";
            String explanation5 = " *  :  is for  =---> ANYTHING      ";
            JLabel jLabExplanat1 = new JLabel(explanation1);
            JLabel jLabExplanat2 = new JLabel(explanation2);
            JLabel jLabExplanat3 = new JLabel(explanation3);
            JLabel jLabExplanat4 = new JLabel(explanation4);
            JLabel jLabExplanat5 = new JLabel(explanation5);
            panel.setLayout(new GridLayout(5, 1));
            panel.add(jLabExplanat1);
            panel.add(jLabExplanat2);
            panel.add(jLabExplanat3);
            panel.add(jLabExplanat4);
            panel.add(jLabExplanat5);
            jLabExplanat1.setForeground(Color.green);
            jLabExplanat2.setForeground(Color.red);
            jLabExplanat3.setForeground(Color.red);
            jLabExplanat4.setForeground(Color.red);
            jLabExplanat5.setForeground(Color.red);
            jLabMask.setForeground(Color.blue);
            //AAA-##:***
            String mask = "##-A#A:#????  ***";
    //        String mask = "***";
            Document textDocOne = textFieldOne.getDocument();
            NavBean_documentFilter filterOne = new NavBean_documentFilter(mask);
            ((AbstractDocument) textDocOne).setDocumentFilter(filterOne);
            String jLabelTxt = "mask to use :  " + filterOne.mask + "   ";
            jLabMask.setText(jLabelTxt);
            frame.setLayout(new GridLayout(3, 1));
            frame.add(panel);
            frame.add(jLabMask);
            frame.add(textFieldOne);
            frame.pack();
            frame.setLocation(300, 150);
            frame.setVisible(true);
        } // main()
    } // class RangeSampleany advice shall be appreciated
    thank you
    regards
    Angelo Moreschini

    All that many lines for a regex question (where the error message already pointed to), which has nothing to do with Swing. An SSCCE looks different.
    if (text.compareTo("*") == 0){
    replace = "\\*";
    text = replace;
    super.replace(fb, offset, length, text.replaceAll(text, replace), attrs);You must keep the text, the regex and the replacement string apart:
    String text= "A", regEx= "A", rep= "B";
    //String text= "*", regEx="\\*", rep= "*";
    text= text.replaceAll(regEx, rep);
    System.out.println(text);And why don't you use a JFormattedTextField with a MaskFormatter which does all the job for you.

  • Dangling Meta Character*

    Hi
    I am getting following exception while executing this statement.can any body give anyt idea and how to fix this problem?
    String sbr="this is kdfdanth redd*t from fdgkanth";
    String bol=sbr.replaceAll("*"," ");
    System.out.println("********* " + bol);
    Exception in thread "main" java.util.regex.PatternSyntaxException: Dangling meta
    character '*' near index 0
    ^
    at java.util.regex.Pattern.error(Unknown Source)
    at java.util.regex.Pattern.sequence(Unknown Source)
    at java.util.regex.Pattern.expr(Unknown Source)
    at java.util.regex.Pattern.compile(Unknown Source)
    at java.util.regex.Pattern.<init>(Unknown Source)
    at java.util.regex.Pattern.compile(Unknown Source)
    at java.lang.String.replaceAll(Unknown Source)
    at Max.main(Max.java:23)

    in regular expression , a* means a,aa,....,aaaaa...a
    u pass some other string other than wild characters like *,?.
    the string u want to replace has * at its first place . even though the string has * at some other position like java*sun*com. it will not replace
    * with ur specified string. it will treat a* and n* i.e a,aa,aa.. or n,nn,nn....

  • Dangling meta character exception

    Hi,
    we get this exception after a readAll query with conformResultsInUnitOfWork. The presence of the "+" in the text seems to confuse toplink.
    Is it a known bug or should we open a TAR?
    java.util.regex.PatternSyntaxException: Dangling meta character '+' near index 0
    +20019G KRUEGER RENATE.*
    ^
    at java.util.regex.Pattern.error(Pattern.java:1528)
    at java.util.regex.Pattern.sequence(Pattern.java:1645)
    at java.util.regex.Pattern.expr(Pattern.java:1545)
    at java.util.regex.Pattern.compile(Pattern.java:1279)
    at java.util.regex.Pattern.<init>(Pattern.java:1035)
    at java.util.regex.Pattern.compile(Pattern.java:779)
    at java.util.regex.Pattern.matches(Pattern.java:865)
    at oracle.toplink.internal.helper.JDK14Platform.conformLike(JDK14Platform.java:51)
    at oracle.toplink.internal.helper.JavaPlatform.conformLike(JavaPlatform.java:57)
    at oracle.toplink.expressions.ExpressionOperator.doesRelationConform(ExpressionOperator.java:769)
    at oracle.toplink.internal.expressions.RelationExpression.doesConform(RelationExpression.java:133)
    at oracle.toplink.publicinterface.UnitOfWork.getAllFromNewObjects(UnitOfWork.java:1493)
    at oracle.toplink.queryframework.ReadAllQuery.conformResult(ReadAllQuery.java:332)
    at oracle.toplink.queryframework.ReadAllQuery.registerObjectInUnitOfWork(ReadAllQuery.java:684)
    at oracle.toplink.publicinterface.UnitOfWork.internalExecuteQuery(UnitOfWork.java:2222)
    at oracle.toplink.publicinterface.Session.executeQuery(Session.java:1086)
    at oracle.toplink.publicinterface.Session.executeQuery(Session.java:1038)
    We use Toplink 9.0.4.4, jdk 1.4.

    This is a known bug. It will be fixed in TopLink 9.0.4.6.

  • 500 Internal Server Error - java.sql.SQLException: Invalid column index

    500 Internal Server Error
    java.sql.SQLException: Invalid column index     at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:137)     at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:174)     at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:239)     at oracle.jdbc.driver.OracleResultSetImpl.getObject(OracleResultSetImpl.java:851)     at com.stardeveloper.servlets.db.InsertServlet.doPost(InsertServlet.java:88)     at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)     at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)     at com.evermind[Oracle Application Server Containers for J2EE 10g (10.1.2.0.2)].server.http.ResourceFilterChain.doFilter(ResourceFilterChain.java:65)     at oracle.security.jazn.oc4j.JAZNFilter.doFilter(Unknown Source)     at com.evermind[Oracle Application Server Containers for J2EE 10g (10.1.2.0.2)].server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:663)     at com.evermind[Oracle Application Server Containers for J2EE 10g (10.1.2.0.2)].server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:330)     at com.evermind[Oracle Application Server Containers for J2EE 10g (10.1.2.0.2)].server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:830)     at com.evermind[Oracle Application Server Containers for J2EE 10g (10.1.2.0.2)].server.http.HttpRequestHandler.run(HttpRequestHandler.java:285)     at com.evermind[Oracle Application Server Containers for J2EE 10g (10.1.2.0.2)].server.http.HttpRequestHandler.run(HttpRequestHandler.java:126)     at com.evermind[Oracle Application Server Containers for J2EE 10g (10.1.2.0.2)].util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:192)     at java.lang.Thread.run(Thread.java:534)
    This is the connection part of the java code
         // connecting to database
              Connection con = null;
              Statement stmt = null;
              ResultSet rs = null;
              PreparedStatement ps = null;
              try {
                   Class.forName("oracle.jdbc.driver.OracleDriver");
              con=DriverManager.getConnection("host:port:sid, userName, password");
                   String sql;
              sql = "INSERT INTO USERSS(user_id, username) VALUES (?,?)";
                   ps = con.prepareStatement(sql);
                   stmt = con.createStatement();
                   // inserting records
                   if(proceed) {
                        ps.setString(1, user_id);
                        ps.setString(2, username);
                        ps.executeUpdate();
    desc userss;
    Name Null? Type
    USER_ID NOT NULL NUMBER(5)
    USERNAME VARCHAR2(15)
    Index_Name table_name
    USERSS_PK1 USERSS
    when I try to insert values, it is inserting, but at the end I am getting the above error. I am using JDeveloper 10g and database [Oracle9i Enterprise Edition Release 9.2.0.7.0 - 64bit Production
    With the Partitioning, OLAP and Oracle Data Mining options
    JServer Release 9.2.0.7.0 - Production]

    I suggest you should alter the JDBC Driver and select one for Oracle 9i.
    Which version is your JDev10g?

  • Error Connecting to MySql (character set index '49')

    I downloaded the Oracle Sql Developer extensions and went to Tools / Preferences / Third Part and set the location for the Jar file.
    When I try and test the connection to the MySql database I get this error:
    An error was encountered performing the requested operation:
    Unknown initial charater set index '49' received from the server.
    Initial client character set can be forced via the 'characterEncoding' property.
    Vendor code 0
    My dba's used Sql developer to connect to the same MySql database fine. If I use MySql Workbench, I can connect. (I prefer Sql Developer, so I was hoping to get this connection to work.)
    I even tried going to MySql to get their Connection/J JDBC jar file; but the same results.
    Any suggestions?
    Thanks,
    Mike

    Are your colleagues using the same sqldev/JDBC versions? Which?
    Did you follow the guide on setting it up, and the driver from http://dev.mysql.com/downloads/connector/j/ ?
    K.

  • How to use : bind character in DB adapter Select Query SOA11g. Getting Error code :17003 .java.sql.SQLException: Invalid column index error

    Hi All,
    The Actual query to perform is below.
    SELECT name,number from emp  WHERE CASE WHEN :1='T' AND term_date IS Not NULL THEN 1 WHEN :1='A' AND term_date IS NULL THEN 1 WHEN :1='ALL' THEN 1 ELSE  1 END = 1;
    I have tried in DB adapter like below as a parameter for :1 as #vInputParam
    SELECT name,number from emp  WHERE CASE WHEN #vInputParam='T' AND term_date IS Not NULL THEN 1 WHEN #vInputParam='A' AND term_date IS NULL THEN 1 WHEN #vInputParam='ALL' THEN 1 ELSE  1 END = 1;
    Getting Error code :17003 .java.sql.SQLException: Invalid column index error.
    Please suggest me on using ':' bind character in DB adapter Select Query SOA11g.
    Can someone help me on this please?
    Thanks,
    Hari

    Hi,
    Could you please make sure your binding style(Oracle Positional,Oracle named..etc) of the Seeded VO and Custom Vo are same.
    This is the option you will get when you are extending your vo. So make sure that both are same.
    You can refer the below link too
    VO extension leads to "Invalid column index" exception
    Thanks
    Bharat

  • Unexpected internal error near index 1

    Hi,
    I am convering al l occurance of "\" into "/" in a string.
    private String format(){
            input="java\\software\\";
            System.out.println("Before formating, input:" + input);
            try{           
                input=input.replaceAll("\\", "/");
                System.out.println("After formating, Input:" + input);
            }catch(Exception e){
                System.out.println("Error in formatting:" + e.getMessage());
            return input;
        }And I am getting this Error:
    Unexpected internal error near index 1
    Any idea whats wrong with above code?

    If you want to replace two backslashes with asingle
    forward slash, then you need to specify the former
    (as a regular expression) as "\\\\"OH! Thanks. I got another way and its working.
    I am using
    s.replace('\\', '/'); insteadd of
    replaceAll
    Yes, that's definitely better in this case, since that API is simpler for single-char replacements. If you sometime need to replace strings though (back to the replaceAll) you'll need to be aware of how regular expressions are formed and how the backslash character plays a part in forming them.

  • Unclosed character class near index 0

    Hi foks,
    I am tryin to remove few characters from a string with the help of replaceAll ( String, String ) method.
    But at the first replacement itself it gives error "Unclosed character class near index 0".
    what does this error mean? I dont have any ' [ ' character in that string. It used to be there, but now I am removing all the occuring of the ' [ ' char right at the creation of string.
    Thanks in advance.

    Hi,
    Here is the code.
    [ CODE ]
    public static String extract(String para)
    String definition = para.substring(para.indexOf("<ol>"),para.indexOf("</ol>"));
    StringBuffer meanings=new StringBuffer();
    StringReader reader = new StringReader(definition);
    StringWriter writer = new StringWriter();
    boolean append=false;
    int ch;
    try
    while((ch=reader.read()) != -1)
    if(ch=='<' || ch=='&')
    append = false;
    continue;
    else if(ch=='>' || ch==';')
    append = true;
    continue;
    if(append && ch != '[' && ch != ']')
    writer.write(ch);
    catch(IOException e)
    System.out.println("IOException:"+e.getMessage());
    catch(Exception e)
    System.out.println("IOException:"+e.getMessage());
    meanings=writer.getBuffer();
    String temp = meanings.toString();
    System.out.println("temp:"+temp);
    temp=temp.replaceAll("["," ");
    System.out.println("temp:"+temp);
    temp=temp.replaceAll(" "," ");
    System.out.println("temp:"+temp);
    return temp;
    [ /CODE ]

  • PatternSyntaxException: Unclosed character class near index

    Hi,
    I want to replace in a string a expression like "^1:2" by "^(1/2)":
    For example, "V/Hz^1:2" would be converted to "V/Hz^(1/2)".
    I tried the following code:
    String oldExponent = "[^](\\d+):(\\d+)"; // e.g. ^1:2
    String newExponent = "^($1/$2)";         // e.g. ^(1/2)
    myString = myString.replaceAll(oldExponent, newExponent);but the following exception is thrown in the third line:
    java.util.regex.PatternSyntaxException: Unclosed character class near index 13
    [^](\d+):(\d+)
                 ^Any idea?
    Thanks in advance.

    Thank you, jverd, you are pretty right.
    Now I tried with
    "\\^(\\d+):(\\d+)"and it works.
    I tried to avoid ^ being interpreted as the beginning of the line, and didn't realize the interpretation inside the brackets.
    Escaping this character works well.

  • Portal error : java.lang.IndexOutOfBoundsException: Index: 2, Size: 2

    Hi Experts,
    Through protal I am changing Other Bank details (IT0009 subtype 0001) for US employee.
    I get the error java.lang.IndexOutOfBoundsException: Index: 2, Size: 2  when I am edditing the other bank details.
    Please help me out in this.
    Prasad

    Hi,
    java.lang.IndexOutOfBoundsException occurs when the runtime environment tries to access the index of an array which doesn't exist. (Index 2 = third entry, you only seem to have 2 entries though).
    Are you certain, the Pernr's Infotype is maintained correctly?
    Could you post the entire error log from NWA so we can see the JAVA Stack? Maybe the error is nested.
    Check Notes 1356222 and 1359671 as well. They might solve your error right away.
    best regards, Lukas
    Edited by: Lukas Weigelt on Jul 14, 2011 9:36 AM

  • Getting error java.lang.StringIndexOutOfBoundsException: String index out of range:

    Hi,
    I have a project in jdev 3.2 and i have migrated to jdev 9i.
    Once i run the project,in some of the pages i am getting the below error..The application runs fine in jdev 3.2 without any errors..
    Where can be the problem..
    Any help will be appreciated..
    500 Internal Server Error
    java.lang.StringIndexOutOfBoundsException: String index out of range: -1
         java.lang.String java.lang.String.substring(int, int)
         int oracle.jbo.html.jsp.datatags.ApplicationModuleTag.doStartTag()
         void jspautomate_html._TkeyautomateView__Edit._jspService(javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse)
         [JSPAutomate_html/TkeyautomateView_Edit.jsp]
         void com.orionserver[Oracle9iAS (9.0.2.0.0) Containers for J2EE].http.OrionHttpJspPage.service(javax.servlet.ServletRequest, javax.servlet.ServletResponse)
         void oracle.jsp.runtimev2.JspPageTable.service(javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse, java.lang.String)
         void oracle.jsp.runtimev2.JspServlet.internalService(javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse)
         void oracle.jsp.runtimev2.JspServlet.service(javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse)
         void javax.servlet.http.HttpServlet.service(javax.servlet.ServletRequest, javax.servlet.ServletResponse)
         void com.evermind[Oracle9iAS (9.0.2.0.0) Containers for J2EE].server.http.ServletRequestDispatcher.invoke(javax.servlet.ServletRequest, javax.servlet.ServletResponse)
         void com.evermind[Oracle9iAS (9.0.2.0.0) Containers for J2EE].server.http.ServletRequestDispatcher.forwardInternal(javax.servlet.ServletRequest, javax.servlet.http.HttpServletResponse)
         boolean com.evermind[Oracle9iAS (9.0.2.0.0) Containers for J2EE].server.http.HttpRequestHandler.processRequest(com.evermind[Oracle9iAS (9.0.2.0.0) Containers for J2EE].server.ApplicationServerThread, com.evermind[Oracle9iAS (9.0.2.0.0) Containers for J2EE].server.http.EvermindHttpServletRequest, com.evermind[Oracle9iAS (9.0.2.0.0) Containers for J2EE].server.http.EvermindHttpServletResponse, java.io.InputStream, java.io.OutputStream, boolean)
         void com.evermind[Oracle9iAS (9.0.2.0.0) Containers for J2EE].server.http.HttpRequestHandler.run(java.lang.Thread)
         void com.evermind[Oracle9iAS (9.0.2.0.0) Containers for J2EE].util.ThreadPoolThread.run()

    Sorry for the late reply.
    It is problably a problem with the configname attribute of the ApplicationModule tag which is wrong.
    Can you try to open the JSP file with the problem and look at the ApplicationModule tag setting.
    If you create a new ApplicationModule tag under it using the Component Palette, it will give you a clue to what setting is espected for the configname. Make sure to keep the same value for the "id" property.
    Charles.

  • MySQL to Oracle Migration Issue - Unknown character set index for field.

    Hi,
    Looking for help..!!!
    Migrating mySQL - version 4 database to Oracle 10g using oracle migration work bench. It went well until the last step. But, during the data migration, OMWB has given the following error:
    +++++++++++
    Unable to migrate data from source table gets.sales_order_01 to destination table gets_ora.sales_order_oracle10: gets_ora.sales_order_oracle10; Unknown character set index for filed "12596" received from ser.
    +++++++++++
    Log file shows:
    java.sql.SQLException: Unknown character set index for field '12596' received from server.
         at com.mysql.jdbc.Connection.getCharsetNameForIndex(Connection.java:1692)
         at com.mysql.jdbc.Field.<init>(Field.java:161)
         at com.mysql.jdbc.MysqlIO.unpackField(MysqlIO.java:510)
         at com.mysql.jdbc.MysqlIO.getResultSet(MysqlIO.java:285)
         at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:1326)
         at com.mysql.jdbc.MysqlIO.sqlQuery(MysqlIO.java:1225)
         at com.mysql.jdbc.Connection.execSQL(Connection.java:2278)
         at com.mysql.jdbc.Connection.execSQL(Connection.java:2225)
         at com.mysql.jdbc.Statement.executeQuery(Statement.java:1163)
         at oracle.mtg.migrationServer.LoadTableData._migrateTableData(LoadTableData.java:563)
         at oracle.mtg.migrationServer.LoadTableData.run(LoadTableData.java:326)
         at oracle.mtg.migration.WorkerThread.run(Worker.java:268)
    I appreciate your help in this regards.
    Regards,
    K

    Hi K,
    Whats the default character set of you MySQL and Oracle Databases.
    What version of JDBC driver are you using?
    Is there any unicode characters used in your data?
    Have you tried offline data move?
    Thanks
    Dermot.
    Message was edited by:
    dooneill

  • Unknown initial character set index '48'

    Hello,
    I have installed today the Mysql connector/j and every time I try to connect to mysql I get the following error.
    "java.sql.SQLException: Unknown initial character set index '48' received from server. Initial client character set can be forced via the 'characterEncoding' property."
    The line that produces this error is the following:
    conn = DriverManager.getConnection (url, userName, password);
    I have read some solutions from other people faced the same error as me but nothing really helped me.
    I have changed the character-set-server = latin1 and the collation-server = latin1_swedish_ci lines of win.ini several times today but no luck.
    Anyone know what should I do to manage to connect to the database?

    just in case anybody else face the same problem as I did, the solution that worked for me is to install an older version of connector/j.
    I had the problem with mysql-connector-java-5.0.4 but with mysql-connector-java-3.1.14 everything is fine and I can now connect to my db.

  • While opening SXMB_IFR i am getting a error  Java.lang.noclassFounderror

    U have installed SAP XI in my laptop while opening 
    SXMB_IFR i am getting a error  Java.lang.noclassFounderror
    so i not able to go further please help me
    thanking you
    sridhar

    Hi,
    There are number of ways to do that :
    1. Try this url
    http://<host-name or IP address of XI server>:<java Port number)>/rep/start/index.jsp
    If this is successful that means your J2EE server and services are fucntioning fine. The problem could then be on the ABAP stack.
    2. Can you start visual admin tool and check that all the services are running. You might have to manually start those which have not automatically started. Check the connectivity with all system & server (inc n/w) & Register the hostserver entry in your sys32/ host file
    e.g 10.2.4.56 <server name>
    3. Have you download java sdk 1.4 on you laptop?
    http://java.sun.com/j2se/1.4.2/download.html
    also have a look at this sap note: 801868
    (make sure not to install the 1.5 version of JWS. XI does not work properly with the 1.5 version)
    4. Lastly, u might have some problem with ur JRE installation. In that case i would sugesst you to re-install JRE/ Java WebStart.
    This blog may help you to analyze the errors-
    /people/krishna.moorthyp/blog/2006/07/23/http-errors-in-xi
    Refer
    XI Installation problem  
    XI Installation problem
    503 error in SXMB_IFR
    XI Initial screen problem  
    XI Initial screen problem
    thanks
    Swarup
    Edited by: Swarup Sawant on Feb 19, 2008 8:42 AM

Maybe you are looking for

  • Business Services Configuration in SCSM or SCOM?

    Hi Everyone, I'm looking for someone with both SCOM 2012 and SCSM 2012 experience who can advise the best and/or preferred method of creating/populating Business Services in Service Manager 2012... The reason that I ask is that once we have a rock so

  • Capability or admingroup to lock and unlock views

    Hi all, I am trying to lock and unlock users via lockObject(com.waveset.object.Type.USER, user, map); on a lighthouse session object and unlockObject((Object) com.waveset.object.Type.USER, user, map); on a session object but I get the error: WavesetE

  • Oracle 9iAS Database cache

    Hi We are using Oracle 9iAS 9.0.3. I am interested to confirm if the Database Cache technology supplied with previous versions of Oracle 9iAS app server has been phased out. Does Oracle 9iAS 9.0.3 support it? Waiting for a quick reply. Thanks All nit

  • CP5 - W7 - TIPS - Motion paths

    I want to give back a little to this community, I got a lot of answers on my questions. And I am greatfull for the help. I wanted to animate an image to come up from the bottom, but could not find the right animation path. So... Follow this guide to

  • Why is Contacts delete greyed out?

    I can not find a way to delete contacts. I select a name and there is no delete button. The delete under edit menu is greyed out.