Hi
I've changed the SQL a bit 'DateTime' can now be null!
CREATE TABLE IF NOT EXISTS `phone_apps` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`name` varchar(50) DEFAULT NULL,
`description` text,
`price` float DEFAULT NULL,
`created` datetime DEFAULT NULL,
`modified` datetime DEFAULT NULL,
`url` varchar(255) DEFAULT NULL,
`pic1` varchar(255) DEFAULT NULL,
`pic2` varchar(255) DEFAULT NULL,
`pic3` varchar(255) DEFAULT NULL,
`pic4` varchar(255) DEFAULT NULL,
`pic5` varchar(255) DEFAULT NULL,
`category_id` int(11) DEFAULT NULL,
`platform_id` int(11) DEFAULT NULL,
PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 AUTO_INCREMENT=3 ;
and the Scala Model:
case class Apps {
id: Pk[Long]
name: String,
description: String,
url: String,
created: Option[java.util.Date],
modified: Option[java.util.Date],
url: String,
pic1: String,
pic2: String,
pic3: String,
pic4: String,
pic5: String,
category_id: Int,
platform_id: Int
}
Is this on the right track ?
On Wednesday, 6 June 2012 16:08:12 UTC+1, danny wrote: