9 messages in com.mysql.lists.javaProblem with migrating from 4.0 to 4...
FromSent OnAttachments
Jeff Mathis04 Aug 2004 11:45 
Mark Matthews04 Aug 2004 11:56 
Jeff Mathis04 Aug 2004 12:31 
Heikki Tuuri09 Aug 2004 10:49 
Jeff Mathis09 Aug 2004 12:40 
Heikki Tuuri10 Aug 2004 07:00 
Mufaddal Khumri10 Aug 2004 09:21 
Mufaddal Khumri26 Aug 2004 16:37 
Kevin Dougan26 Aug 2004 17:00 
Subject:Problem with migrating from 4.0 to 4.1 ?
From:Mufaddal Khumri (mufa@wmotion.com)
Date:08/10/2004 09:21:11 AM
List:com.mysql.lists.java

Hi,

Am using MySQL Connector/J 3.0 JDBC driver with 4.1.3-beta-standard on OS X.

I have the following code snipet: // ...... while (rs1 != null && rs1.next()) { // ...... Calendar cal = Calendar.getInstance(); cal.clear(); cal.setTime(rs1.getTimestamp(i)); < ---------- I get a NullPointerException here. // ........... } // .....

java.lang.NullPointerException at java.util.Calendar.setTime(Calendar.java:902) at com.db.export.SomeClass(SomeClass.java:191)

NOTE: This same code works perfectly fine when i use MySQL Connector/J 3.0 JDBC driver with mysqladmin Ver 8.40 Distrib 4.0.16.

The table was created like this:

CREATE TABLE user ( ID int(11) NOT NULL auto_increment, USERNAME varchar(20) NOT NULL default '', PASSWORD varchar(20) NOT NULL default '', FIRSTNAME varchar(50) NOT NULL default '', LASTNAME varchar(50) NOT NULL default '', EMAILADD varchar(255) NOT NULL default '', PHONENUMBER varchar(255) NOT NULL default '', WEBSITEADDRESS varchar(255) default NULL, PERSONALINFO text, ORGANIZATION varchar(255) default NULL, ENABLED tinyint(1) NOT NULL default '0', OWNERID int(11) NOT NULL default '0', TS datetime default NULL, PRIMARY KEY (ID), UNIQUE KEY USERNAME (USERNAME) ) TYPE=InnoDB;

Does anybody know why I might be getting that exception? Has something changed in 4.1.3 beta ?

Thanks.

On Aug 10, 2004, at 7:01 AM, Heikki Tuuri wrote:

Jeff,

http://dev.mysql.com/doc/mysql/en/InnoDB_news-4.1.4.html

If you recreated the TIMESTAMP table in 4.1.3, then you have recreate it again when you upgrade to >= 4.1.4.

Regards,

Heikki

when did 4.1.4 come out? as of last week, we couldn't see it on the website. at any rate, it was only a minor inconvenience. we've moved on, and everything appears stable right now.

thanks for your repsonse

jeff Heikki Tuuri wrote:

Jeff,

please look at the changelog of InnoDB-4.1.4 in the MySQL manual.

An upgrade 4.0 --> 4.1.4 or later does NOT need any TIMESTAMP conversion.

It is a bug in 4.1.0 to 4.1.3.

Regards,

Heikki

----- Alkuperäinen viesti ----- Lähettäjä: "Jeff Mathis" <jmat@predict.com> Vastaanottaja: "Mark Matthews" <ma@mysql.com> Kopio: <ja@lists.mysql.com>; "Heikki Tuuri" <Heik@innodb.com> Lähetetty: Wednesday, August 04, 2004 10:31 PM Aihe: Re: timestamps

yes, they are innodb tables. i populated the new time_zone tables using the system time zone files as per the manual recommendations, but, alas, no change.

are you saying that its all messed up? dumping and reloading really isn't the greatest option :(

jeff Mark Matthews wrote:

-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1

Jeff Mathis wrote: | hello, | | sorry if this is a know issue. we just upgraded our server from 4.0.4

to

| 4.1.3, and are now using the 3.1.3 CJ release. | | i noticed that after the upgrade, all our timestamp columns are wrong! | | | 2036-07-09 05:45:55 | | | 2036-07-15 05:42:42 | | | 2036-07-15 05:42:45 | | | 2036-07-15 05:42:45 | | | 2036-07-16 05:42:35 | | | everything is wrong; the year, month and day. what happened? anyone

else

| seen this? | | jeff |

Jeff...Are these InnoDB tables? (If so, unfortunately it looks like you'll have to dump and re-load, from what I hear).

-Mark

- -- Mr. Mark Matthews MySQL AB, Software Development Manager, J2EE and Windows Platforms Office: +1 708 332 0507 www.mysql.com

MySQL Guide to Lower TCO http://www.mysql.com/it-resources/white-papers/tco.php -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.3 (MingW32) Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org

iD8DBQFBETGItvXNTca6JD8RArFgAKCBlujs3RqozStFLCn2Fkyf7AuzFwCgkHA6 6bshoNnrkKIjVOgIrjn8fHw= =5HFm -----END PGP SIGNATURE-----