Skip navigation
Currently Being Moderated

[CF8] java.lang.NullPointerException

Oct 2, 2007 6:13 AM

Hello,

On my CF8 web host, I sometimes get strange java.lang.nullpointerexceptions errors. All my code works flawless since the year 2000. The same pages do work but sometimes, maybe 1 out of 30 try's, the error appears again. First I thought it was a session problem or a problem with Application.cfm. But I stripped those down and it even happens with simple queries. I think it has to do with queries or MySQL 5.

Has anyone encountered this error? The system says "The system has attempted to use an undefined value, which usually indicates a programming error, either in your code or some system code." But I have all my values defined and it is not a programming error. It is more like a server configuration error I guess.



The following information is meant for the website developer for debugging purposes.
Error Occurred While Processing Request
The system has attempted to use an undefined value, which usually indicates a programming error, either in your code or some system code.

Null Pointers are another name for undefined values.
500

ROOT CAUSE:
java.lang.NullPointerException
at com.mysql.jdbc.Statement.setMaxRows(Statement.java:2178)
at coldfusion.server.j2ee.sql.JRunStatement.setMaxRows(JRunStatement.jav a:214)
at coldfusion.sql.Executive.executeQuery(Executive.java:1229)
at coldfusion.sql.Executive.executeQuery(Executive.java:1008)
at coldfusion.sql.Executive.executeQuery(Executive.java:939)
at coldfusion.sql.SqlImpl.execute(SqlImpl.java:325)
at coldfusion.tagext.sql.QueryTag.executeQuery(QueryTag.java:831)
at coldfusion.tagext.sql.QueryTag.doEndTag(QueryTag.java:521)
at cfhetkoor2ecfm251397670.runPage(E:\westlandkoorconcordia.nl\wwwroot\h etkoor.cfm:1)
at coldfusion.runtime.CfJspPage.invoke(CfJspPage.java:192)
at coldfusion.tagext.lang.IncludeTag.doStartTag(IncludeTag.java:366)
at coldfusion.filter.CfincludeFilter.invoke(CfincludeFilter.java:65)
at coldfusion.filter.ApplicationFilter.invoke(ApplicationFilter.java:279 )
at coldfusion.filter.RequestMonitorFilter.invoke(RequestMonitorFilter.ja va:48)
at coldfusion.filter.MonitoringFilter.invoke(MonitoringFilter.java:40)
at coldfusion.filter.PathFilter.invoke(PathFilter.java:86)
at coldfusion.filter.ExceptionFilter.invoke(ExceptionFilter.java:70)
at coldfusion.filter.ClientScopePersistenceFilter.invoke(ClientScopePers istenceFilter.java:28)
at coldfusion.filter.BrowserFilter.invoke(BrowserFilter.java:38)
at coldfusion.filter.NoCacheFilter.invoke(NoCacheFilter.java:46)
at coldfusion.filter.GlobalsFilter.invoke(GlobalsFilter.java:38)
at coldfusion.filter.DatasourceFilter.invoke(DatasourceFilter.java:22)
at coldfusion.CfmServlet.service(CfmServlet.java:175)
at coldfusion.bootstrap.BootstrapServlet.service(BootstrapServlet.java:8 9)
at jrun.servlet.FilterChain.doFilter(FilterChain.java:86)
at coldfusion.monitor.event.MonitoringServletFilter.doFilter(MonitoringS ervletFilter.java:42)
at coldfusion.bootstrap.BootstrapFilter.doFilter(BootstrapFilter.java:46 )
at jrun.servlet.FilterChain.doFilter(FilterChain.java:94)
at jrun.servlet.FilterChain.service(FilterChain.java:101)
at jrun.servlet.ServletInvoker.invoke(ServletInvoker.java:106)
at jrun.servlet.JRunInvokerChain.invokeNext(JRunInvokerChain.java:42)
at jrun.servlet.JRunRequestDispatcher.invoke(JRunRequestDispatcher.java: 284)
at jrun.servlet.ServletEngineService.dispatch(ServletEngineService.java: 543)
at jrun.servlet.jrpp.JRunProxyService.invokeRunnable(JRunProxyService.ja va:203)
at jrunx.scheduler.ThreadPool$DownstreamMetrics.invokeRunnable(ThreadPoo l.java:320)
at jrunx.scheduler.ThreadPool$ThreadThrottle.invokeRunnable(ThreadPool.j ava:428)
at jrunx.scheduler.ThreadPool$UpstreamMetrics.invokeRunnable(ThreadPool. java:266)
at jrunx.scheduler.WorkerThread.run(WorkerThread.java:66)


javax.servlet.ServletException: ROOT CAUSE:
java.lang.NullPointerException
at com.mysql.jdbc.Statement.setMaxRows(Statement.java:2178)
at coldfusion.server.j2ee.sql.JRunStatement.setMaxRows(JRunStatement.jav a:214)
at coldfusion.sql.Executive.executeQuery(Executive.java:1229)
at coldfusion.sql.Executive.executeQuery(Executive.java:1008)
at coldfusion.sql.Executive.executeQuery(Executive.java:939)
at coldfusion.sql.SqlImpl.execute(SqlImpl.java:325)
at coldfusion.tagext.sql.QueryTag.executeQuery(QueryTag.java:831)
at coldfusion.tagext.sql.QueryTag.doEndTag(QueryTag.java:521)
at cfhetkoor2ecfm251397670.runPage(E:\westlandkoorconcordia.nl\wwwroot\h etkoor.cfm:1)
at coldfusion.runtime.CfJspPage.invoke(CfJspPage.java:192)
at coldfusion.tagext.lang.IncludeTag.doStartTag(IncludeTag.java:366)
at coldfusion.filter.CfincludeFilter.invoke(CfincludeFilter.java:65)
at coldfusion.filter.ApplicationFilter.invoke(ApplicationFilter.java:279 )
at coldfusion.filter.RequestMonitorFilter.invoke(RequestMonitorFilter.ja va:48)
at coldfusion.filter.MonitoringFilter.invoke(MonitoringFilter.java:40)
at coldfusion.filter.PathFilter.invoke(PathFilter.java:86)
at coldfusion.filter.ExceptionFilter.invoke(ExceptionFilter.java:70)
at coldfusion.filter.ClientScopePersistenceFilter.invoke(ClientScopePers istenceFilter.java:28)
at coldfusion.filter.BrowserFilter.invoke(BrowserFilter.java:38)
at coldfusion.filter.NoCacheFilter.invoke(NoCacheFilter.java:46)
at coldfusion.filter.GlobalsFilter.invoke(GlobalsFilter.java:38)
at coldfusion.filter.DatasourceFilter.invoke(DatasourceFilter.java:22)
at coldfusion.CfmServlet.service(CfmServlet.java:175)
at coldfusion.bootstrap.BootstrapServlet.service(BootstrapServlet.java:8 9)
at jrun.servlet.FilterChain.doFilter(FilterChain.java:86)
at coldfusion.monitor.event.MonitoringServletFilter.doFilter(MonitoringS ervletFilter.java:42)
at coldfusion.bootstrap.BootstrapFilter.doFilter(BootstrapFilter.java:46 )
at jrun.servlet.FilterChain.doFilter(FilterChain.java:94)
at jrun.servlet.FilterChain.service(FilterChain.java:101)
at jrun.servlet.ServletInvoker.invoke(ServletInvoker.java:106)
at jrun.servlet.JRunInvokerChain.invokeNext(JRunInvokerChain.java:42)
at jrun.servlet.JRunRequestDispatcher.invoke(JRunRequestDispatcher.java: 284)
at jrun.servlet.ServletEngineService.dispatch(ServletEngineService.java: 543)
at jrun.servlet.jrpp.JRunProxyService.invokeRunnable(JRunProxyService.ja va:203)
at jrunx.scheduler.ThreadPool$DownstreamMetrics.invokeRunnable(ThreadPoo l.java:320)
at jrunx.scheduler.ThreadPool$ThreadThrottle.invokeRunnable(ThreadPool.j ava:428)
at jrunx.scheduler.ThreadPool$UpstreamMetrics.invokeRunnable(ThreadPool. java:266)
at jrunx.scheduler.WorkerThread.run(WorkerThread.java:66)

at coldfusion.monitor.event.MonitoringServletFilter.doFilter(MonitoringS ervletFilter.java:70)
at coldfusion.bootstrap.BootstrapFilter.doFilter(BootstrapFilter.java:46 )
at jrun.servlet.FilterChain.doFilter(FilterChain.java:94)
at jrun.servlet.FilterChain.service(FilterChain.java:101)
at jrun.servlet.ServletInvoker.invoke(ServletInvoker.java:106)
at jrun.servlet.JRunInvokerChain.invokeNext(JRunInvokerChain.java:42)
at jrun.servlet.JRunRequestDispatcher.invoke(JRunRequestDispatcher.java: 284)
at jrun.servlet.ServletEngineService.dispatch(ServletEngineService.java: 543)
at jrun.servlet.jrpp.JRunProxyService.invokeRunnable(JRunProxyService.ja va:203)
at jrunx.scheduler.ThreadPool$DownstreamMetrics.invokeRunnable(ThreadPoo l.java:320)
at jrunx.scheduler.ThreadPool$ThreadThrottle.invokeRunnable(ThreadPool.j ava:428)
at jrunx.scheduler.ThreadPool$UpstreamMetrics.invokeRunnable(ThreadPool. java:266)
at jrunx.scheduler.WorkerThread.run(WorkerThread.java:66)
The system has attempted to use an undefined value, which usually indicates a programming error, either in your code or some system code. Text
 
Replies 1 2 3 Previous Next
  • Currently Being Moderated
    Oct 2, 2007 9:33 AM   in reply to yogonaise
    Looks like there might be a database driver issue for MySQL 5 in CF8, I do not use MySQL with CF8 so I cannot really go into it much more than that, but you might want to get the MySQL Connector 3.1.10 which I know works well with CF7 and MySQL 5.

    HTH
     
    |
    Mark as:
  • Currently Being Moderated
    Oct 2, 2007 11:48 PM   in reply to Stressed_Simon
    Hi,

    Could you please post some sample code that is causing the problem so that we can try reproducing and debugging it at our end? Also, do mention any relevant repro steps.

    Thanks,
    Dipanwita
     
    |
    Mark as:
  • Currently Being Moderated
    Oct 3, 2007 2:44 AM   in reply to yogonaise
    You should not install any drivers in Coldfusion 8 for current versions of MySQL. In fact, the Coldfusion Administrator will warn you if you attempt to configure an additional driver. Coldfusion 8 already has suitable JDBC drivers built in for MySQL 3, 4 and 5. These things usually fit tight. Installing other drivers might tip the balance and cause errors. Did your Admin install an extra driver?

    As the error message says, there could also be a mistake in your code. An error is likely to have occurred in your code or in system code similar to:

    Statement stmt = conn.createStatement();
    stmt.setMaxRows(67);

    Another possible source of a setMaxRows error is the Coldfusion Administrator. Do the datasource settings specify the maxRows? For example, does the Coldfusion Administrator define the connection URL as:

    jdbc:mysql://localhost:3306/myDSN?user=myUsername&password=myPassword &maxRows=200

    Finally, it is just possible that there is a bug in the driver or in Coldfusion's implementation of it.




     
    |
    Mark as:
  • Currently Being Moderated
    Oct 3, 2007 6:44 PM   in reply to yogonaise
    yogonaise wrote:
    > I am using CF8 and MySQL5 on my Windows host. It turned out to be that the
    > ColdFusion ODBC DNS's they made for me, were not working properly.

    the question is: why did your host use ODBC to connect to a MySQL
    database???

    --

    Azadi Saryev
    Sabai-dee.com
    http://www.sabai-dee.com
     
    |
    Mark as:
  • Currently Being Moderated
    Oct 17, 2007 3:09 PM   in reply to Newsgroup_User
    I have the same problem here (the same stackdump one out of five requests). The DSN was created using mysql (4/5) driver with default settings. The problem can happen on any kind of request, even the simplest.

    I solved this issue by making a new DSN (other) with driver class com.mysql.jdbc.Driver. It's only a workaround and I would really like to know what is the difference between the two methods. Maybe the problem is linked to the fact that I previously had a CF7 running on this server, and something happened during the upgrade ?
     
    |
    Mark as:
  • Currently Being Moderated
    Oct 17, 2007 10:30 PM   in reply to yogonaise
    NorbertAdobe wrote:
    I solved this issue by making a new DSN (other) with driver class com.mysql.jdbc.Driver. It's only a workaround and I would really like to know what is the difference between the two methods. Maybe the problem is linked to the fact that I previously had a CF7 running on this server, and something happened during the upgrade ?

    It is not a coincidence. MX7 doesn't have built-in Administrator services for the MySQL 5 driver. So it is indeed likely that the upgrade didn't go well.

    However, I cannot imagine that the issue is critical, as your MySQL 5 driver apparently works without you installing anything extra. The following code will display the list of database drivers. Confirm that MySQL 5 is in the list.

     
    |
    Mark as:
  • Currently Being Moderated
    Oct 18, 2007 12:15 AM   in reply to BKBK
    In my previous CF7 installation, I had to manually add the official mysql driver in coldfusion lib path to make mysql5 work. This jar file is not in my current CF8 installation tree. I did list installed drivers (result attached). I see nothing special, both mysql4/5 and mysql3 drivers are present. Is there a way to know which driver is using which DSN ?
     
    |
    Mark as:
  • Currently Being Moderated
    Oct 18, 2007 1:13 AM   in reply to yogonaise
    update : in fact changing the driver type to "other" didn't solve the issue. I still have the nullpointerexpection at com.mysql.jdbc.Statement.setMaxRows(Statement.java:2178).
     
    |
    Mark as:
  • Currently Being Moderated
    Oct 18, 2007 5:03 AM   in reply to yogonaise
    Let's rule out something. Do you have any JAR file in the directory /wwwroot/WEB-INF/lib/ whose name starts with mysql-connector?


     
    |
    Mark as:
  • Currently Being Moderated
    Oct 22, 2007 10:23 AM   in reply to yogonaise
    java.lang.NullPointerException
    at com.mysql.jdbc.Statement.setMaxRows(Statement.java:2178)


    Does indeed look like a bug in Coldfusion 8's built-in MySQL driver, mysql-connector-java-commercial-5.0.5-bin.jar. I have had a look round the web. Sadly, there's not much information about the error. Let's hope someone from Adobe will chime in.

     
    |
    Mark as:
  • Currently Being Moderated
    Mar 26, 2008 12:37 PM   in reply to yogonaise
    Are there any updates on this issue? I get the same error, intermittently, using CF 8 with MySQL 5. Hitting refresh makes it go away, temporarily anyway.

    java.lang.NullPointerException at com.mysql.jdbc.Statement.setMaxRows(Statement.java:2178)
     
    |
    Mark as:
  • Currently Being Moderated
    Mar 29, 2008 2:32 PM   in reply to yogonaise
    java.lang.NullPointerException
    at com.mysql.jdbc.Statement.setMaxRows(Statement.java:2178)


    I wonder if it could be caused by a temporarily broken connection between Coldfusion and the MySQL database server.

     
    |
    Mark as:
  • Currently Being Moderated
    Apr 7, 2008 10:30 PM   in reply to yogonaise
    I've also been getting this same error. It worked fine on my development machine however when I moved to my live server the error is occurring.

    I did some quick research and on my local server my tables were setup as InnoDB and on the live server they were setup as MyISAM. Unfortunately my hosting company only allows MyISAM on their servers so I can't switch back to InnoDB and test. Could this be part of the issue? Any help greatly appreciated!

    Thanks
     
    |
    Mark as:
  • Currently Being Moderated
    15. ,
    Apr 9, 2008 12:06 AM   in reply to FastmusicJimmy
    Hi,

    It would be great if you could post the sample code and provide us with the details about the environment setup, so that we can try reproducing the issue, since it happens to be an inconsistent issue.

    Thanks,
    Hareni
    Adobe CF Team
     
    |
    Mark as:
  • Currently Being Moderated
    Apr 9, 2008 8:42 AM   in reply to yogonaise
    Hi Hareni,

    I believe I finally found a solution. In my advanced settings for the datasource I turn "Maintain connections across client requests" off and it seems to work.

    My code is very similar to the code posted in this thread and my error is the same as well. If it will help I'm on CF Standard 8,0,0,176276. Changed the JVM to 1.5.0_15 for faster object creation. Using MySQL 5.0.22.

    On the server where my code was working without DB errors I'm using CF Developer 8,0,0,176276 , MySQL 5.0.51a-community-nt and the same JVM.

    Thanks,

    Jimmy
     
    |
    Mark as:
  • Currently Being Moderated
    Apr 9, 2008 9:59 AM   in reply to yogonaise
    @Jimmy - I would consider that a temporary workaround, but not a solution. With "Maintain connections" unchecked, CF is now creating a new connection with each query. You can imagine the performance degradation on high-traffic sites that will result. The fact that the error manifests after a lull in activity, and that unchecking "Maintain connections" fixes it, would point to a bug in CF's connection pool handling for MySQL.

    @Hareni - We are seeing the error in both CF 8 and CF 8.0.1, on both Windows XP and Mac OSX Leopard. We're connecting to MySQL 5.0.22. It could happen on any query, so I don't really have a code sample for you. But it always happens after a pause in activity - if I hit reload over and over, it won't happen, but if I step away for 10 minutes and come back, it probably will.

    My datasource settings are all the default settings for MySQL. I tried setting Connection String to autoReconnect=true&autoReconnectForPools=true, but that does not help.
     
    |
    Mark as:
  • Currently Being Moderated
    Apr 9, 2008 1:33 PM   in reply to rich.thibault
    I may be on to something. I extracted the MySQL driver c:\coldfusion8\lib\mysql-connector-java-commercial-5.0.5-bin.jar and opened the file Statement.class using a decompiler. The constructor looks like this:

    public Statement(com.mysql.jdbc.Connection c, String catalog) throws SQLException
    {
    cancelTimeoutMutex = new Object();
    wasCancelled = false;
    charConverter = null;
    charEncoding = null;
    connection = null;
    connectionId = 0L;
    currentCatalog = null;
    doEscapeProcessing = true;
    eventSink = null;
    fetchSize = 0;
    isClosed = false;
    lastInsertId = -1L;
    maxFieldSize = MysqlIO.getMaxBuf();
    maxRows = -1;
    maxRowsChanged = false;
    openResults = new ArrayList();
    pedantic = false;
    profileSQL = false;
    results = null;
    resultSetConcurrency = 0;
    resultSetType = 0;
    timeoutInMillis = 0;
    updateCount = -1L;
    useUsageAdvisor = false;
    warningChain = null;
    holdResultsOpenOverClose = false;
    batchedGeneratedKeys = null;
    retrieveGeneratedKeys = false;
    continueBatchOnError = false;
    if(c == null || c.isClosed())
    throw SQLError.createSQLException(Messages.getString("Statement.0"), "08003");
    connection = c;
    connectionId = connection.getId();
    currentCatalog = catalog;
    pedantic = connection.getPedantic();
    continueBatchOnError = connection.getContinueBatchOnError();
    if(!connection.getDontTrackOpenResources())
    connection.registerStatement(this);
    if(connection != null)
    {
    maxFieldSize = connection.getMaxAllowedPacket();
    int defaultFetchSize = connection.getDefaultFetchSize();
    if(defaultFetchSize != 0)
    setFetchSize(defaultFetchSize);
    }
    if(connection.getUseUnicode())
    {
    charEncoding = connection.getEncoding();
    charConverter = connection.getCharsetConverter(charEncoding);
    }
    boolean profiling = connection.getProfileSql() || connection.getUseUsageAdvisor();
    if(connection.getAutoGenerateTestcaseScript() || profiling)
    statementId = statementCounter++;
    if(profiling)
    {
    pointOfOrigin = new Throwable();
    profileSQL = connection.getProfileSql();
    useUsageAdvisor = connection.getUseUsageAdvisor();
    eventSink = ProfileEventSink.getInstance(connection);
    }
    int maxRowsConn = connection.getMaxRows();
    if(maxRowsConn != -1)
    setMaxRows(maxRowsConn);
    0
    }

    There appears to be an extraneous 0 at the end.


     
    |
    Mark as:
  • Currently Being Moderated
    Apr 9, 2008 2:21 PM   in reply to yogonaise
    Hey BKBK,

    I think that's an artifact from your decompiler - MySQL source code doesn't have that 0, and it would prevent compiling anyway:

    http://svn.mysql.com/svnpublic/connector-j/tags/5.0.5/connector-j/src/ com/mysql/jdbc/Statement.java

    But your post got me looking at their source code. The NPE happens at line 2178, which I believe is this line inside setMaxRows():

    this.connection.unsetMaxRows(this);

    So it looks like CF is invoking setMaxRows() after the connection has already gone dead (null). It should be detecting the dead connection, removing it from the pool, and starting a new one.
     
    |
    Mark as:
  • Currently Being Moderated
    Apr 9, 2008 9:02 PM   in reply to yogonaise
    rich.thibault wrote:
    I think that's an artifact from your decompiler

    You are right about the decompiler error. It has been confirmed on the same decompiler, but not on two others.(Thanks, Jack).

    ...MySQL source code doesn't have that 0, and it would prevent compiling anyway:
    I was thinking more of a bug in the binary, Statement.class, in the Coldfusion lib package. I expect the constructor to handle the case where the connection is null.

    P.S.: I have received four reactions (three in an hour!) repeating your point about the MySQL source code. To clarify, I thought of a bug in Coldfusion's jar because no other MySQL users are reporting the error. It's as simple as that.








     
    |
    Mark as:
  • Currently Being Moderated
    May 24, 2008 11:29 PM   in reply to yogonaise
    Any news on this bug?

    Maybe it's in the mysql 5 version or mysql 5 settings. I have 5.0.45-community-nt in production which has the errors and 5.0.51a-3buntu5 in development.

    I found the following differences between the mysql servers (mysql administrator->startup params->advanc network or Mysql administrator->health-server variables->connection)
    Dev box (working):
    Interactive timeout: 28800
    Wait timeout: 28800
    Production (not working):
    Interactive timeout: 30
    Wait timeout: 15
     
    |
    Mark as:
  • Currently Being Moderated
    May 25, 2008 12:41 AM   in reply to yogonaise
    Ok, I'm able to reproduce consistently on my devbox. The culprit is the wait timeout. If I set it to 15 seconds I get the error if I wait more then 15 seconds between request. If I set it to something like 21 seconds I get the error precisely after waiting more the 21 seconds between requests.

    The default coldfusion timeout is 1200 seconds. So the solution is to set the mysql wait timeout to something >1200.

    You can change it via the mysql administrator->startup parameters (select mysqld if asked)->tab advanced networking.
     
    |
    Mark as:
  • Currently Being Moderated
    May 27, 2008 2:56 PM   in reply to ChillyWillyReal
    Thanks ChillyWilly,

    Unfortunately that fix didn't work for us....our servers are already using 28800, but we still get the error.

    rich
     
    |
    Mark as:
  • Currently Being Moderated
    Jun 17, 2008 10:08 PM   in reply to rich.thibault
    Anyone have any insights into this? I am using dailyrazor as my host and am getting the error, exactly as described. Once in a while..refresh works fine...

    java.lang.NullPointerException
    at com.mysql.jdbc.Statement.setMaxRows(Statement.java:2178)
    at coldfusion.server.j2ee.sql.JRunStatement.setMaxRows(JRunStatement.jav a:214)
    at coldfusion.sql.Executive.executeQuery(Executive.java:1276)
    at coldfusion.sql.Executive.executeQuery(Executive.java:1008)
    at coldfusion.sql.Executive.executeQuery(Executive.java:939)
    at coldfusion.sql.SqlImpl.execute(SqlImpl.java:325)
    at coldfusion.tagext.sql.QueryTag.executeQuery(QueryTag.java:831)
    at coldfusion.tagext.sql.QueryTag.doEndTag(QueryTag.java:521)
     
    |
    Mark as:
  • Currently Being Moderated
    Jun 19, 2008 4:25 AM   in reply to yogonaise
    In the settings page in the Coldfusion Administrator for that particular datasource, choose to Show Advanced Settings. In the Connection String field, enter: autoReconnectForPools=true

    Press Submit to register the change. Does it solve the problem?


     
    |
    Mark as:
  • Currently Being Moderated
    Jun 19, 2008 7:26 AM   in reply to yogonaise
    I already had something in the connection string, so I tried to add another, with a semi-colon in between and am getting:

    zeroDateTimeBehavior=convertToNull;autoReconnectForPools=true

    Warning: gyro4_content: java.sql.SQLException: The connection property 'zeroDateTimeBehavior' only accepts values of the form: 'exception', 'round' or 'convertToNull'. The value 'convertToNull;autoReconnectForPools=true' is not in this set.

    Is a semi-colon not the value for multiple entries?

    If I uncheck this value, it 'solves' the problem, but I was reading about the possible performance issues with it:

    "Maintain connections across client requests"

     
    |
    Mark as:
  • Currently Being Moderated
    Jun 19, 2008 7:35 AM   in reply to yogonaise
    zeroDateTimeBehavior='convertToNull';autoReconnectForPools=true
     
    |
    Mark as:
  • Currently Being Moderated
    Jun 19, 2008 7:36 AM   in reply to yogonaise
    Oh, and ensure "Maintain connections across client requests" is checked.


     
    |
    Mark as:
  • Currently Being Moderated
    Jun 19, 2008 10:08 AM   in reply to yogonaise
    The Plesk control panel still doesn't like that:

    zeroDateTimeBehavior='convertToNull';autoReconnectForPools=true

    Warning: gyro4_content: java.sql.SQLException: The connection property 'zeroDateTimeBehavior' only accepts values of the form: 'exception', 'round' or 'convertToNull'. The value ''convertToNull';autoReconnectForPools=true' is not in this set.

    I'll have to check into whats different about plesk.
     
    |
    Mark as:
  • Currently Being Moderated
    Jun 19, 2008 10:43 AM   in reply to yogonaise
    try zeroDateTimeBehavior=convertToNull&autoReconnectForPools=true ?

    Azadi Saryev
    Sabai-dee.com
    http://www.sabai-dee.com/
     
    |
    Mark as:
  • Currently Being Moderated
    Jun 19, 2008 10:52 AM   in reply to dennis longnecker
    Try an ampersand....I believe these are like URL params:

    zeroDateTimeBehavior=convertToNull&autoReconnectForPools=true
     
    |
    Mark as:
  • Currently Being Moderated
    Jun 20, 2008 7:01 AM   in reply to yogonaise
    .. if it still complains, then slap it with

    autoReconnectForPools=true;zeroDateTimeBehavior=convertToNull
    or
    autoReconnectForPools=true&zeroDateTimeBehavior=convertToNull
     
    |
    Mark as:
  • Currently Being Moderated
    Jun 20, 2008 7:26 AM   in reply to yogonaise
    DOesn't accept the first format..same error message as before. When I try the second one, my code bombs because of the null date issue, so it is not converting it to null.
     
    |
    Mark as:
  • Currently Being Moderated
    Jun 20, 2008 10:03 AM   in reply to yogonaise
    Do you mean that

    zeroDateTimeBehavior=convertToNull

    and

    autoReconnectForPools=true

    work, but

    autoReconnectForPools=true&zeroDateTimeBehavior=convertToNull

    fails?


     
    |
    Mark as:
  • Currently Being Moderated
    Jun 20, 2008 10:17 AM   in reply to yogonaise
    zeroDateTimeBehavior=convertToNull fixes a error with zerodate's, but I have the connection issue.

    autoReconnectForPools=true fixes the connection problem, but I have the zerodate issue.

    autoReconnectForPools=true&zeroDateTimeBehavior=convertToNull I have both the connection isse and the zerodate problem. Its like its not doing either...but then it doesn't complain about it as a value either.

     
    |
    Mark as:
  • Currently Being Moderated
    Jun 21, 2008 1:28 AM   in reply to yogonaise
    Quite odd. What if you apply no connection string in the administrator, but do the following instead.

    Open the file {CF_installation_dir}/lib/neo-datasource.xml in a text editor. (Make a back-up). Locate the URL(s) which correspond to the datasources to which you want to apply the connection string.

    Suppose one such URL is

    jdbc:mysql://127.0.0.1:3306/my_orders?

    Modify the line to

    jdbc:mysql://127.0.0.1:3306/my_orders?autoReconnectForPools=true&zeroD ateTimeBehavior=convertToNull

    Restart Coldfusion.


     
    |
    Mark as:
  • Currently Being Moderated
    Jun 22, 2008 8:10 AM   in reply to dennis longnecker
    Previously, I was using ColdFusion 6.1 and I'm sure an older version of mySQL. I transferred hosting to dailyrazor with ColdFusion 8 as my host and am getting the error:

    quote:

    The system has attempted to use an undefined value, which usually indicates a programming error, either in your code or some system code.

    Null Pointers are another name for undefined values.
    500

    ROOT CAUSE:
    java.lang.NullPointerException



    When I refresh the page the error goes away for a while. Then it comes back after a while. It happens on all sorts of pages and it never happened before I migrated the site to the new host.

    quote:

    Originally posted by: dennis longnecker
    Anyone have any insights into this? I am using dailyrazor as my host and am getting the error, exactly as described. Once in a while..refresh works fine...

    java.lang.NullPointerException
    at com.mysql.jdbc.Statement.setMaxRows(Statement.java:2178)
    at coldfusion.server.j2ee.sql.JRunStatement.setMaxRows(JRunStatement.jav a:214)
    at coldfusion.sql.Executive.executeQuery(Executive.java:1276)
    at coldfusion.sql.Executive.executeQuery(Executive.java:1008)
    at coldfusion.sql.Executive.executeQuery(Executive.java:939)
    at coldfusion.sql.SqlImpl.execute(SqlImpl.java:325)
    at coldfusion.tagext.sql.QueryTag.executeQuery(QueryTag.java:831)
    at coldfusion.tagext.sql.QueryTag.doEndTag(QueryTag.java:521)



     
    |
    Mark as:
  • Currently Being Moderated
    Jun 28, 2008 11:06 AM   in reply to drjamiii
    We are experiencing the same issue on Crystaltech shared ColdFusion hosting. From reviews of the Crystaltech forum, this issue seems to have cropped up since the upgrade to CF8.1? This is a serious issue. It is crippling for sites with heavy data input capabilities, because the error forces the user to re-enter all the information from the submitting page. I've created a workaround cftry/cfcatch, but this only works effectively for display pages. Any form submission page which generates the error loses all the form data. Unacceptable.

    Adobe? Hello? Help us out here.
     
    |
    Mark as:
1 2 3 Previous Next
Actions

More Like This

  • Retrieving data ...

Bookmarked By (0)

Answers + Points = Status

  • 10 points awarded for Correct Answers
  • 5 points awarded for Helpful Answers
  • 10,000+ points
  • 1,001-10,000 points
  • 501-1,000 points
  • 5-500 points