From: Monty Taylor Date: April 30 2007 6:44pm Subject: Re: More datatype support List-Archive: http://lists.mysql.com/ndb-connectors/53 Message-Id: <463638FD.3060101@mysql.com> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit You may have noticed from the commits that I merged your changes in. Turns out the %cstring macros are not implemented in Java, so we'll have to figure out another way to do that. I haven't gone into it in a heavy way yet as I've been mostly working on getting synced up with NDB/J. To that end, I've been moving a few things around. One of the things they did in NDB/J is to have different methods for some of the different data types. (setString, setInt, etc) If we do the same thing, it could make some of the datatype conversions at least a little easier. Maybe. Or maybe not. :) Also to that end, I've started adding code to throw custom exceptions. It seems to work fine in Perl (I did test that this time) although it's giving me some interesting Python problems. (Namely, I can throw mysql.cluster.ndbapi.NdbApiException, but I can't catch it.) And I added NdbFactory and renamed Ndb_cluster_connection to NdbClusterConnection. Let me know if you are still having destructor crashes. Also, make sure that if you are loading DBD::mysql as well as ndbapi, that they are both using the same version... there seem to be some ABI problems between 5.0 and 5.1 libmysqlclient and libndbclient. Yay. Anyway, there is absolutely no problem sharing code with mod_ndb. We may interact with JD further on integration for the PHP code, since mod_ndb might be our ticket to getting a global Ndb_cluster_connection for apache, rather than one per thread, which would be disastrous. Monty Mika Raento wrote: > The attached patch adds support for datetime, date and time types by > converting them to/from strings. The output is only for perl - it should > be rewritten to use the appropriate SWIG target language independent > functions. I haven't tested DATE and TIME yet (nor longvarchar, > longvarbinary or the padding). > > At least with this I can do equal, setValue and value on binary, > varchar, int and datetime which is quite a bit more than I was able to > before. > > I've been modelling some of the conversions from mod_ndb, which should > be fine as its copyright is given to MySQL too. > > Mika > -- Monty Taylor Senior Consultant MySQL Inc., www.mysql.com Get More with MySQL! www.mysql.com/consulting