Skip to Content
avatar image
Former Member

Cannot create JDBC driver of class '' for connect URL 'null'

HI,

Can any one help why i am getting the below error:

Cannot create JDBC driver of class '' for connect URL 'null'


The Error Stack Trace is:


Cannot create JDBC driver of class '' for connect URL 'null'

java.lang.NullPointerException

    at sun.jdbc.odbc.JdbcOdbcDriver.getProtocol(Unknown Source)

    at sun.jdbc.odbc.JdbcOdbcDriver.knownURL(Unknown Source)

    at sun.jdbc.odbc.JdbcOdbcDriver.acceptsURL(Unknown Source)

    at java.sql.DriverManager.getDriver(Unknown Source)

    at org.apache.tomcat.dbcp.dbcp.BasicDataSource.createConnectionFactory(BasicDataSource.java:1437)

    at org.apache.tomcat.dbcp.dbcp.BasicDataSource.createDataSource(BasicDataSource.java:1371)

    at org.apache.tomcat.dbcp.dbcp.BasicDataSource.getConnection(BasicDataSource.java:1044)

    at com.crystaldecisions.reports.queryengine.driverImpl.jdbc.JDBCConnection.Open(Unknown Source)

    at com.crystaldecisions.reports.queryengine.JDBConnectionWrapper.Open(SourceFile:123)

    at com.crystaldecisions.reports.queryengine.Connection.br(SourceFile:1786)

    at com.crystaldecisions.reports.queryengine.Connection.bs(SourceFile:505)

    at com.crystaldecisions.reports.queryengine.Connection.t4(SourceFile:3020)

    at com.crystaldecisions.reports.dataengine.dfadapter.DFAdapter.a(SourceFile:697)

    at com.businessobjects.reports.sdk.requesthandler.DatabaseRequestHandler.a(SourceFile:309)

    at com.businessobjects.reports.sdk.requesthandler.DatabaseRequestHandler.long(SourceFile:264)

    at com.businessobjects.reports.sdk.JRCCommunicationAdapter.do(SourceFile:1150)

    at com.businessobjects.reports.sdk.JRCCommunicationAdapter.if(SourceFile:660)

    at com.businessobjects.reports.sdk.JRCCommunicationAdapter.a(SourceFile:166)

    at com.businessobjects.reports.sdk.JRCCommunicationAdapter$2.a(SourceFile:528)

    at com.businessobjects.reports.sdk.JRCCommunicationAdapter$2.call(SourceFile:526)

    at com.crystaldecisions.reports.common.ThreadGuard.syncExecute(SourceFile:102)

    at com.businessobjects.reports.sdk.JRCCommunicationAdapter.for(SourceFile:524)

    at com.businessobjects.reports.sdk.JRCCommunicationAdapter.int(SourceFile:423)

    at com.businessobjects.reports.sdk.JRCCommunicationAdapter.request(SourceFile:351)

    at com.businessobjects.sdk.erom.jrc.a.a(SourceFile:54)

    at com.businessobjects.sdk.erom.jrc.a.execute(SourceFile:67)

    at com.crystaldecisions.proxy.remoteagent.RemoteAgent$a.execute(SourceFile:716)

    at com.crystaldecisions.proxy.remoteagent.CommunicationChannel.a(SourceFile:125)

    at com.crystaldecisions.proxy.remoteagent.RemoteAgent.a(SourceFile:537)

    at com.crystaldecisions.sdk.occa.report.application.ds.a(SourceFile:186)

    at com.crystaldecisions.sdk.occa.report.application.ReportSource.a(SourceFile:878)

    at com.crystaldecisions.sdk.occa.report.application.ReportSource.getPromptDatabaseLogOnInfos(SourceFile:815)

    at com.crystaldecisions.sdk.occa.report.application.AdvancedReportSource.getPromptDatabaseLogOnInfos(SourceFile:338)

    at com.businessobjects.report.web.a.e.a(SourceFile:174)

    at com.businessobjects.report.web.a.e.a(SourceFile:97)

    at com.businessobjects.report.web.a.e.a(SourceFile:343)

    at com.businessobjects.report.web.a.t.a(SourceFile:1726)

    at com.businessobjects.report.web.event.bw.broadcast(SourceFile:97)

    at com.businessobjects.report.web.event.am.a(SourceFile:53)

    at com.businessobjects.report.web.a.t.if(SourceFile:2104)

    at com.businessobjects.report.web.e.a(SourceFile:300)

    at com.businessobjects.report.web.e.a(SourceFile:202)

    at com.businessobjects.report.web.e.a(SourceFile:135)

    at com.crystaldecisions.report.web.ServerControl.a(SourceFile:607)

    at com.crystaldecisions.report.web.ServerControl.processHttpRequest(SourceFile:342)

    at org.apache.jsp.CrystalReport_jsp._jspService(CrystalReport_jsp.java:205)

    at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)

    at javax.servlet.http.HttpServlet.service(HttpServlet.java:728)

    at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:432)

    at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:390)

    at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334)

    at javax.servlet.http.HttpServlet.service(HttpServlet.java:728)

    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:305)

    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)

    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:222)

    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:123)

    at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:502)

    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:171)

    at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:99)

    at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:953)

    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118)

    at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:408)

    at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1023)

    at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:589)

    at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:312)

    at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)

    at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)

    at java.lang.Thread.run(Unknown Source)

Cannot create JDBC driver of class '' for connect URL 'null'

java.lang.NullPointerException

    at sun.jdbc.odbc.JdbcOdbcDriver.getProtocol(Unknown Source)

    at sun.jdbc.odbc.JdbcOdbcDriver.knownURL(Unknown Source)

    at sun.jdbc.odbc.JdbcOdbcDriver.acceptsURL(Unknown Source)

    at java.sql.DriverManager.getDriver(Unknown Source)

    at org.apache.tomcat.dbcp.dbcp.BasicDataSource.createConnectionFactory(BasicDataSource.java:1437)

    at org.apache.tomcat.dbcp.dbcp.BasicDataSource.createDataSource(BasicDataSource.java:1371)

    at org.apache.tomcat.dbcp.dbcp.BasicDataSource.getConnection(BasicDataSource.java:1044)

    at com.crystaldecisions.reports.queryengine.driverImpl.jdbc.JDBCConnection.Open(Unknown Source)

    at com.crystaldecisions.reports.queryengine.JDBConnectionWrapper.Open(SourceFile:123)

    at com.crystaldecisions.reports.queryengine.Connection.br(SourceFile:1786)

    at com.crystaldecisions.reports.queryengine.Connection.

    

         

Thanks

Penchal

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • avatar image
    Former Member
    Sep 17, 2014 at 07:57 PM

    Hi Penchal,

    Please give more information about the issue.

    When you are facing this error message.

    By looking at your error stack trace, you are using JRC.

    What is your application workflow?

    Thanks,

    Shailendra

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member

      HI Shailendra,

      I think your expecting code. The Code is as follows. and also for few reports i am getting Unexpected Database Error help me in this also

      if(reportName != null && !"".equals(reportName) && reportSource==null){

              //Initializing report

             

              ReportClientDocument boReportClientDocument = new ReportClientDocument();

             

              boReportClientDocument.open(reportName, 0);

             

                Fields<IParameterField> parameterFields = boReportClientDocument.getDataDefController().getDataDefinition().getParameterFields();

                System.out.println("Param Fields Size:"+parameterFields.size());

           

                   

           if (parameterFields.size() > 0) {

              ParameterFieldController paramController = boReportClientDocument.getDataDefController().getParameterFieldController();

              for (int i = 0; i < parameterFields.size(); i++) {

                  String paramName = parameterFields.getField(i).getName().trim();

                  System.out.println("                    -          "+paramName);

                  if(request.getParameter(paramName) != null) {

                      paramController.setCurrentValue("", paramName, request.getParameter(paramName));

                     

                      System.out.println(paramName+":"+request.getParameter(paramName));

                  }else {

                      System.out.println("Param is Null:"+paramName+":"+request.getParameter(paramName));

                      paramController.setCurrentValue("", paramName, "");

                      }

                  }

              }  

          }

          reportSource = boReportClientDocument.getReportSource();

         

          //session.setAttribute("ReportSource", reportSource);

          boReportClientDocument.close();

             

          CrystalReportViewer crystalReportViewer = new CrystalReportViewer();

          crystalReportViewer.setName(reportName);

          crystalReportViewer.setOwnPage(true);

          crystalReportViewer.setBestFitPage(true);

          crystalReportViewer.setToolPanelWidth(0);

          crystalReportViewer.setHasToggleParameterPanelButton(false);

          crystalReportViewer.setHasToggleGroupTreeButton(false);

          crystalReportViewer.setReportSource(reportSource);

          crystalReportViewer.setEnableDrillDown(false);

         

                  crystalReportViewer.processHttpRequest(request, response,getServletConfig().getServletContext(),null);

         

      Thanks

      Penchal