Tonci Grgin | 2 May 08:05
Picon
Favicon

MySQL Connector/J 5.1.20 has been released

Hello all,

MySQL Connector/J 5.1.20, a maintenance release of the production 5.1 
branch has been released.
Connector/J is the Type-IV pure-Java JDBC driver for MySQL.

Version 5.1.20 is suitable for use with many MySQL server versions, 
including 4.1, 5.0, 5.1, 5.4 and 5.5.

It is now available in source and binary form from the Connector/J 
download pages at
http://dev.mysql.com/downloads/connector/j/5.1.html
and mirror sites as well as Maven-2 repositories.

As always, we recommend that you check the "CHANGES" file in the 
download archive to be aware of changes in behavior that might affect 
your application.

We welcome and appreciate your feedback, bug reports, bug fixes, patches 
etc:
http://forge.mysql.com/wiki/Contributing

MySQL Connector/J 5.1.20 includes the following general bug fixes and 
improvements also listed in more detail on 
http://dev.mysql.com/doc/connector-j/en/cj-news-5-1-20.html:
   - Fix for Bug#64983, 5.1.19 not working with JBoss AS 4.2.3.GA.
   - Fix for Bug#13960556, java.lang.StringIndexOutOfBoundsException in 
com.mysql.jdbc.PreparedStatement.formatNanos(int nanos).
   - Fix for pluggable authentication tests to run on Windows.
   - Fix for Bug#13897714, NPE in 
(Continue reading)

Tonci Grgin | 4 Apr 09:22
Picon
Favicon

MySQL Connector/J 5.1.19 has been released

Hello all,

MySQL Connector/J 5.1.19, a maintenance release of the production 5.1 
branch has been released.
Connector/J is the Type-IV pure-Java JDBC driver for MySQL.

Version 5.1.19 is suitable for use with many MySQL server versions, 
including 4.1, 5.0, 5.1, 5.4 and 5.5.

It is now available in source and binary form from the Connector/J 
download pages at
http://dev.mysql.com/downloads/connector/j/5.1.html
and mirror sites as well as Maven-2 repositories.

As always, we recommend that you check the "CHANGES" file in the 
download archive to be aware of changes in behavior that might affect 
your application.

We welcome and appreciate your feedback, bug reports, bug fixes, patches 
etc:
http://forge.mysql.com/wiki/Contributing

MySQL Connector/J 5.1.19 includes the following general bug fixes and 
improvements:

   - Fix for Bug#64621, setMaxRows was not correctly processed during CS 
PS metadata
     collection causing entire resultset to be fetched and possibly 
leading to OOM.

(Continue reading)

gmx | 15 Jan 09:21
Picon
Picon

NullPointerException in GregorianCalendar.java:2026 when upgrading to debian squeeze

From mysqld  Ver 5.0.51a-24+lenny2-log for debian-linux-gnu on i486 
To      mysqld  Ver 5.1.49-3-log for debian-linux-gnu on i486
java.lang.NullPointerException
	at
java.util.GregorianCalendar.computeFields(GregorianCalendar.java:2026)
	at
java.util.GregorianCalendar.computeFields(GregorianCalendar.java:1996)
	at java.util.Calendar.setTimeInMillis(Calendar.java:1109)
	at java.util.Calendar.setTime(Calendar.java:1075)
	at java.text.SimpleDateFormat.format(SimpleDateFormat.java:876)

It appears that in mysql-connector-java-5.1.10-bin.jar:
com.mysql.jdbc.PreparedStatement line: 4728

this.tsdf.setTimeZone(this.connection.getServerTimezoneTZ());

is null.

The combination "
useGmtMillisForDatetimes=true&serverTimezone=Europe/Zurich&" in my
tomcat's server.xml appears to fix it.
Any better hints?

    Thanks in advance

          Ralf

--

-- 
MySQL Java Mailing List
For list archives: http://lists.mysql.com/java
(Continue reading)

Victor Cifuentes | 15 Jan 06:48
Picon

How disable innodb support.

Hi!  Can any body tell me how disable innodb support in mysql embedded
connector/MXJ?
I know that exist a skip-innodb option for my.cnf file and --skip-innodb as
parameter for mysqld, but when i try use it into the server options map
this does not disable innodb, i don't know why.
I don't need innodb support and it make very slow the mysqld startup.

I am using mysql-connector-mxj-gpl-5-0-12.jar and
mysql-connector-java-5.1.18-bin.jar

Thanks, any help is important to me.
Pierre Goupil | 29 Dec 17:05
Picon

Re: Problem with in-memory connector MXJ

Mmmmmh. It looks like it works!

Thanx!

Pierre

2011/12/21 Celil Germeyan <celilg <at> itg.com.tr>

> Try something like this... please change some variables based on your
> environment:
> ==============================**=
>  Connection con = null ;
>  Class.forName( "org.gjt.mm.mysql.Driver" ).newInstance( ) ;
>
>  Properties prop = new Properties( ) ;
>  prop.put( "user", "myusername" ) ;
>  prop.put( "password", "mypassword" ) ;
>  prop.put( "characterEncoding", "utf8" ) ;
>  prop.put( "useUnicode", "true" ) ;
>  prop.put( "zeroDateTimeBehavior", "convertToNull" ) ;
>  prop.put( "useServerPrepStmts", "false" ) ;
>  prop.put( "cachePreparedStatements", "true" ) ;
>
>  String url = "jdbc:mysql://localhost/**mysqldbname";
>
>  con = DriverManager.getConnection( url, prop ) ;
>
> ==================
>
> Celil
(Continue reading)

Pierre Goupil | 21 Dec 15:24
Picon

Problem with in-memory connector MXJ

Good afternoon,

I'm currently trying and configure MySQL in order to have an in-memory
database in my unit tests. My environment is: Linux 3.0.0, Java 6 openJDK,
MySQL connector 5.0.7 and MXJ 5.0.12.

Here's my code:

------------------
String driver = System.getProperty("SQL_DRIVER", "com.mysql.jdbc.Driver");
String defaultUrl =
"jdbc:mysql:///test?propertiesTransform=com.mysql.management.jmx.ConnectorMXJPropertiesTransform";

String url = System.getProperty("SQL_URL", defaultUrl);
String user = System.getProperty("SQL_USER", "root");
String password = System.getProperty("SQL_PW", "");

Class.forName(driver);

Connection conn = DriverManager.getConnection(url, user, password);
------------------

I get an exception at the last line:

------------------
Exception in thread "main" java.lang.IndexOutOfBoundsException: Index: 0,
Size: 0
at java.util.ArrayList.rangeCheck(ArrayList.java:571)
at java.util.ArrayList.get(ArrayList.java:349)
at
(Continue reading)

Ryan Beckes | 12 Dec 18:35
Picon

jdbc: values from mysql table always null

Hello,

I am trying to copy one table to another using jdbc (see code below). The
table is copied fine, but the last column is NULL for all values. I am also
having problems retrieving the value from that table (the value is always
returned as null). If I run the same sql commands via the mysql client, the
table is copied OK.

Thanks,
Ryan

    Connection conn = null;
    PreparedStatement ps1 = null;
    PreparedStatement ps2 = null;
    PreparedStatement ps3 = null;
    try {
      String userName = "user";
      String password = "password";
      String url = "jdbc:mysql://localhost:3306/plus";
      Class.forName ("com.mysql.jdbc.Driver").newInstance ();
      conn = DriverManager.getConnection (url, userName, password);
      System.out.println ("Database connection established");
      String dropQuery="DROP TABLE IF EXISTS CLASSMEMBERSHIPTMP";
      ps1 = conn.prepareStatement(dropQuery);
      ps1.executeUpdate();
      String createTmpQuery="CREATE TABLE IF NOT EXISTS CLASSMEMBERSHIPTMP
(ID bigint(20), SUBCLASS1 varchar(255), SUBCLASS2 varchar(255), SUBCLASS3
varchar(255), SUBCLASS4 varchar(255), SUBCLASS5 varchar(255), SUBCLASS6
varchar(255), CLASSMEMBERSHIP_ITEM_ID bigint(20))";
      ps2 = conn.prepareStatement(createTmpQuery);
(Continue reading)

Picon
Favicon

escaping in a non-prepared query

Hello,

 In my application I have a query which is very hard to rewrite to a preparedstatement for legacy reasons. Is
there some method so I can do the right escaping by hand?

 query = "SELECT * FROM foo WHERE bar = '" + MySQLUtils.escapeString("bla") + "'";

 Something like that.

 Thanks in advance,
 Ronald.
Tonci Grgin | 4 Oct 10:36
Picon
Favicon

MySQL Connector/J 5.1.18 has been released

Hello all,

MySQL Connector/J 5.1.18, a maintenance release of the production 5.1 branch has been released.
Connector/J is the Type-IV pure-Java JDBC driver for MySQL.

Version 5.1.18 is suitable for use with any MySQL version including MySQL-5.1 or MySQL-5.5.

It is now available in source and binary form from the Connector/J download pages at

http://dev.mysql.com/downloads/connector/j/5.1.html

and mirror sites as well as Maven-2 repositories.

As always, we recommend that you check the "CHANGES" file in the download 
archive to be aware of changes in behavior that might affect your application.

We welcome and appreciate your feedback, bug reports, bug fixes, patches etc.:

http://forge.mysql.com/wiki/Contributing

MySQL Connector/J 5.1.18 includes the following general bug fixes and improvements:

 - Fix for Bug#12565726, not putting the space between VALUES() and ON DUPLICATE KEY UPDATE
   causes C/J a) enter rewriting the query although it has ON UPDATE
   and b) to generate the wrong query with multiple ON DUPLICATE KEY

 - Fix for Bug#12784170, "process fork failure" errors while running test suite via ant on Windows.
   Added new ant flag, com.mysql.jdbc.junit.fork, which controls whether JUnit will fork new processes
   for testing ("on", default and legacy behavior) or not ("off", required for Windows). 
 - Reverting changes made to ConnectionImpl.java,
(Continue reading)

pravin kalbhor | 4 Oct 07:31
Picon

executing Java code from database trigger.

Hi,

I wanted to run java method from trigger. for that i need to write java db
procedure.. as mention in
http://download.oracle.com/javase/tutorial/jdbc/basics/storedprocedures.html#creating_stored_procedures_java_db
but i am getting sql syntax error at 'AS LANGUAGE' please let me know if you
have th solution for  the same..

my create procedure statement is =

          "CREATE PROCEDURE log_sal(IN idsal float, IN old_sal float, IN
new_sal float) " +
            //"PARAMETER STYLE JAVA " +
          "AS "+
            "LANGUAGE JAVA " +
            //"DYNAMIC RESULT SETS 1 " +
            "EXTERNAL NAME 'com.trigger.DBTrigger.logSal'";
java-help | 20 Aug 05:00
Picon
Favicon

confirm unsubscribe to java <at> lists.mysql.com

To confirm that you would like

  gcdmj-java <at> m.gmane.org

removed from the java mailing list, please click on
the following link:

  http://lists.mysql.com/u/java/4e4f2360d44b612a/gcdmj-java=m.gmane.org

This confirmation serves two purposes. First, it verifies that we are
able to get mail through to you. Second, it protects you in case
someone forges a subscription request in your name.

We haven't checked whether your address is currently on the mailing list.
To see what address you used to subscribe, look at the messages you are
receiving from the mailing list. Each message has your address hidden
inside its return path; for example, john <at> example.com receives messages
with return path: java-return-≤number>-john=example.com <at> lists.mysql.com.

--- Administrative commands for the java list ---

I can handle administrative requests automatically. Please
do not send them to the list address! Instead, send
your message to the correct command address:

To subscribe to the list, send a message to:
   <java-subscribe <at> lists.mysql.com>

To remove your address from the list, just send a message to
the address in the ``List-Unsubscribe'' header of any list
(Continue reading)


Gmane