This week's giveaway is in the Spring forum.
We're giving away four copies of REST with Spring (video course) and have Eugen Paraschiv on-line!
See this thread for details.
The moose likes Groovy and the fly likes Oracle DB Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of REST with Spring (video course) this week in the Spring forum!
JavaRanch » Java Forums » Languages » Groovy
Bookmark "Oracle DB" Watch "Oracle DB" New topic

Oracle DB

kim paul

Joined: Oct 24, 2009
Posts: 1

i'm just trying out some grails apps that i've found online and wanted to get the tables (those Domain Classes) that are made to work on my Oracle DB server instead of the HSQLDB.

I've got it working on one of the apps (by editting that Datasource.groovy file), but with the other one, it tries to create a table called User. And Oracle doesnt seem to like that. I've tried all sorts of things to try and change the table name but it keeps trying to make that User table.
Any advice?

Dave Klein
Ranch Hand

Joined: Aug 29, 2007
Posts: 77
You can tell it what table name to use with a mapping block. Something like this:

class User {

static mapping = {
table 'user_table_name'


However, you may have other problems with a class named "User". It might be better overall to change the class name if you can.


Author of Grails: A Quick-Start Guide
subject: Oracle DB
It's not a secret anymore!