[Building Sakai] Create tool with tables

Steve Swinsburg steve.swinsburg at gmail.com
Wed Jul 13 15:33:03 PDT 2011


From the looks of your original question, it didn't look like you were using hibernate since you were querying what the hbm.xml were for.

I'm just about to finalise the Spring JDBC support in the wicket maven archetype, which checks autoddl and vendor and creates tables, and has externalised SQL, so you can look at that if you like.

But as Matthew says, there is nothing magical here, either use hibernate which will automatically create the tables, or run some SQL.

cheers,
Steve


On 14/07/2011, at 1:57 AM, Paul Mungai wrote:

> > In your service startup (init) just run the SQL to create the tables. 
> 
> Should this not create the new table when I restart tomcat (hibernate)? 
> 
> Just wondering if there is a pom within the new tool that I need to add this so that the table is created upon restarting tomcat.
> 
> > You can check the vendor used as it is set in sakai.properties, and then just run the appropriate SQL
> mysql
> 
> > p.s. you'll want to also check if auto.ddl is enabled before you create any tables.
> It is set to enabled (true).
> 
> -- 
> Regards,
> Paul Mungai
> 
> Skype: pwando
> Twitter: pwando
> Facebook: paulwando
> LinkedIn: http://za.linkedin.com/pub/paul-mungai/b/388/512
> Blog: http://pmungai.wordpress.com
> Flickr: http://bit.ly/b84lip
> 
> "Ability is what youre capable of doing. Motivation determines what you do. Attitude determines how well you do it" By Lou Holtz, Notre Dame Football Coach

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://collab.sakaiproject.org/pipermail/sakai-dev/attachments/20110714/08543f98/attachment.html 


More information about the sakai-dev mailing list