Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7582093
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 30, 20262026-05-30T18:21:14+00:00 2026-05-30T18:21:14+00:00

I’ve been with this exception all day and now I’m going crazy, I cannot

  • 0

I’ve been with this exception all day and now I’m going crazy, I cannot find what’s wrong in my code. I’ve checked and rechecked the method but I wasn’t able to find a solition, I have checked and rechecked the date formats and they are all fine… Why is this sending the month invalidexception. The full stacktrace is the following, I also had found that the program throws that exception when calling ResultSet.next() method.

feb 27, 2012 4:03:38 PM mx.gob.sagarpa.utilidades.Database generarReporteArchivos
SEVERE: null
java.sql.SQLDataException: ORA-01843: not a valid month

        at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:445)
        at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:396)
        at oracle.jdbc.driver.T4C8Oall.processError(T4C8Oall.java:879)
        at oracle.jdbc.driver.T4CTTIfun.receive(T4CTTIfun.java:450)
        at oracle.jdbc.driver.T4CTTIfun.doRPC(T4CTTIfun.java:192)
        at oracle.jdbc.driver.T4C8Oall.doOALL(T4C8Oall.java:531)
        at oracle.jdbc.driver.T4CStatement.doOall8(T4CStatement.java:193)
        at oracle.jdbc.driver.T4CStatement.fetch(T4CStatement.java:1108)
        at oracle.jdbc.driver.OracleResultSetImpl.close_or_fetch_from_next(OracleResultSetImpl.java:373)
        at oracle.jdbc.driver.OracleResultSetImpl.next(OracleResultSetImpl.java:
277)
        at mx.gob.sagarpa.utilidades.Database.generarReporteArchivos(Database.ja
va:160)
        at mx.gob.sagarpa.beans.TableBean.generarReportes(TableBean.java:60)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:57)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:601)
        at org.apache.el.parser.AstValue.invoke(AstValue.java:262)
        at org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:2
78)
        at org.ajax4jsf.component.behavior.MethodExpressionAjaxBehaviorListener.
processAjaxBehavior(MethodExpressionAjaxBehaviorListener.java:71)
        at javax.faces.event.AjaxBehaviorEvent.processListener(AjaxBehaviorEvent
.java:113)
        at javax.faces.component.behavior.BehaviorBase.broadcast(BehaviorBase.ja
va:106)
        at org.ajax4jsf.component.behavior.AjaxBehavior.broadcast(AjaxBehavior.j
ava:291)
        at javax.faces.component.UIComponentBase.broadcast(UIComponentBase.java:
760)
        at javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:794)

        at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:1
259)
        at com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicat
ionPhase.java:81)
        at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:101)
        at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)

        at javax.faces.webapp.FacesServlet.service(FacesServlet.java:593)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appl
icationFilterChain.java:304)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF
ilterChain.java:210)
        at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperV
alve.java:224)
        at org.apache.catalina.core.StandardContextValve.invoke(StandardContextV
alve.java:169)
        at org.apache.catalina.authenticator.AuthenticatorBase.invoke(Authentica
torBase.java:472)
        at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.j
ava:168)
        at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.j
ava:100)
        at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:
929)
        at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineVal
ve.java:118)
        at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.jav
a:405)
        at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp
11Processor.java:964)
        at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(
AbstractProtocol.java:515)
        at org.apache.tomcat.util.net.AprEndpoint$SocketProcessor.run(AprEndpoin
t.java:1824)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.
java:1110)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor
.java:603)
        at java.lang.Thread.run(Thread.java:722)

CODE

public List<RegistroReporteArchivo> generarReporteArchivos(
        int idUsuario, String nombreArchivo,
        String fechaInicio, String fechaFin) {
    CallableStatement cs;
    ResultSet rs = null;
    List<RegistroReporteArchivo> list = new ArrayList<RegistroReporteArchivo>();
    try {
        connect();
        cs = connection.prepareCall("{call getreportearchivo(?,?,?,?,?)}");
        cs.setInt(1, idUsuario);
        cs.setString(2, nombreArchivo);
        cs.setString(3, fechaInicio);
        cs.setString(4, fechaFin);
        cs.registerOutParameter(5, OracleTypes.CURSOR);
        cs.execute();
        rs = (ResultSet) cs.getObject(5); 
        while (rs.next()) {  //The exception marks this line as the responsible !!
            list.add(new RegistroReporteArchivo(rs.getString(1),
                    rs.getInt(2), rs.getInt(3), rs.getInt(4),
                    rs.getInt(5)));
        }
        disconnect();
    } catch (SQLException ex) {
        Logger.getLogger(Database.class.getName()).log(Level.SEVERE, null, ex);
    }
    return list;
}
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-30T18:21:15+00:00Added an answer on May 30, 2026 at 6:21 pm

    What is the signature of the getreportearchivo procedure? Are one or more of the parameters declared to be a DATE? If so, you should really be calling setDate rather than setString.

    If all the parameters to the procedure are, in fact, VARCHAR2 parameters, do you convert the strings to dates in the procedure? If so, the format mask specified in the TO_DATE function doesn’t appear to match the string that is being passed in.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a string like this: La Torre Eiffel paragonata all&#8217;Everest What PHP function
I have a jquery bug and I've been looking for hours now, I can't
this is what i have right now Drawing an RSS feed into the php,
Seemingly simple, but I cannot find anything relevant on the web. What is the
I'm parsing an RSS feed that has an &#8217; in it. SimpleXML turns this
I have this code: - (void)parser:(NSXMLParser *)parser foundCDATA:(NSData *)CDATABlock { NSString *someString = [[NSString
I have this code to decode numeric html entities to the UTF8 equivalent character.
link Im having trouble converting the html entites into html characters, (&# 8217;) i
For some reason, after submitting a string like this Jack’s Spindle from a text
I have a text area in my form which accepts all possible characters from

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.