Posts

No Dialect mapping for JDBC type: -1

This Hibernate error came at me out of the blue while working on FilmSuggestions.com - I innocently added a constraint to one of my Grails domain models, setting the maxSize of one of the fields to 2000. This changed the table schema making the column type TEXT instead of VARCHAR. The problem came from a native query: sessionFactory.getCurrentSession().createSQLQuery(mostPopularFilmsSQL).list() This selects the TEXT column which results in the error (as described here ). Setting the dialect didn't seem to make any difference, so for now I've changed the constraint so it's back to being a VARCHAR.

Recycling electronic waste - www.thegreenpages.com.au

I've got a couple of old computers and a collection of components that are good for nothing in todays world. But I've had trouble finding somewhere that will take it off my hands and dispose of it in an environmentally friendly way. Imagine my surprise when I saw a google advert on my own blog for  http://www.thegreenpages.com.au/  - a directory of Eco friendly organisations which includes a category on recycling. Hopefully it won't be long before I can clean out some of the rubbish.

Rhythmbox

I've just been playing with RhythmBox for the first time, and am very pleasantly surprised. This application so far takes care of my music and podcast requirements, and also supports the iTunes links you see on so many sites. You can either copy the iTunes link and add it manually, or in FireFox, clicking on the link pops up a dialog asking what application should be used - specifying /usr/bin/rhythmbox achieves the desired result, and the podcast is added just like that. Rhythmbox also supports my wifes ipod, which is great for managing that. Although I don't use internet radio, I'd like to and it takes care of that too. I've still got more to play with, but so far I'm happy and will be sticking with it for the foreseeable future. (Ubuntu 8.04Beta, Linux Dell Inspiron 1525 Laptop, 2.6.24-16-generic #1 SMP Thu Apr 10 13:23:42 UTC 2008 i686 GNU/Linux)

Wordpress error - Allowed memory size of ## bytes exhausted

I just came across a problem using wordpress that stopped everything working - any request to the Wordpress site resulted in a blank page. In the log file for the host, I could see: PHP Fatal error:  Allowed memory size of 8388608 bytes exhausted (tried to allocate 14592 bytes) in <path to a plugin php file> Removing the plugin specified just meant that the error was reported for the next plugin. Searching Google showed many discussions about this problem. Luckily the solution for me was easy enough - as described in this topic : In <wordpress root>/wp-includes/cache.php I just added: ini_set("memory_limit","12M");

grails-selenium-0.4

This information is out of date - please see http://www.grails.org/Selenium+plugin Version 0.4 of the grails selenium plugin is now available. This version adds: scripts to create and run tests a postResults url for displaying the final test results Details are as follows: run-selenium Runs Selenium in the specified browser. Specify the path to your browser as a command line parameter i.e. grails run-selenium /usr/bin/firefox or, if the executable is on the path you would just need grails run-selenium firefox In your application.properties, you can specify: selenium.auto=true selenium.close=true selenium.multiWindow=true selenium.highlight=true selenium.resultsUrl=/your/url/here (defaults to ${appContext}/selenium/postResults) selenium.runInterval=1000 selenium.baseUrl= See http://selenium.openqa.org/installing.html (section titled Continuous Integration) for more information on selenium and continuous integration. create-selenium-test Generates a new empty selenium test. Supply th...

grails-jsunit-0.1

This information is out of date - please see http://www.grails.org/jsUnit+plugin grails-jsunit provides an easy and convenient way to utilize the JsUnit framework to your grails application. JsUnit allows you to unit test JavaScript functions in a similar way to using JUnit for Java. To install the plugin, use: grails install-plugin http://www.javathinking.com/grails/grails-jsunit-plugin/0.1/grails-jsunit-0.1.zip This plugin adds the following new scripts: create-jsunit-test Generates a new empty jsunit test. Supply the path of the test you want to create, relative to 'test/jsunit/tests'. Example use: grails create-jsunit-test registration/mytest creates ${basedir}/test/jsunit/tests/registration/mytest.html run-jsunit Runs JsUnit in the specified browser. Specify the path to your browser as a command line parameter i.e. grails run-jsunit /usr/bin/firefox or, if the executable is on the path you would just need grails run-jsunit firefox In your application.properties, you can s...

Firefox profiles

If you share a login with someone else (ie. family) Firefox profiles can be very useful. Likewise, if you are a developer and you have several different contexts or modes of operation, profiles can make life a lot easier. I use them at home with family members - you can set each person up with their own profile, so all you have to do is restart Firefox (rather than logging out out of the operating system and then back on as someone else). Firefox will prompt you - asking who you want to be right now. At work, how many times have you cleared all of your private settings while debugging, just to see if the problem is related to caching or some other previous state. Creating a profile is much easier - especially since you probably want to stay logged in to all of those websites you use every day. Just start firefox from the command line with the parameter '-profilemanager' - you'll be prompted with a dialog so you can mange your profiles. Read more about it here : http://www....