oracle11g - Grails: Error while trying to configure with Oracle 11g XE -


i have oracle 11g xe (express edition) instance installed locally. make grails db environments. have username/password oracle user, , have ojdbc6.jar file located here:

\myappname\lib\ojdbc6.jar

and have not created tables in database yet - assuming grails smart enough create tables needed, if not, problem...

here's datasource.groovy file contents:

datasource {     //oracle     dbcreate = "create-drop"     url = "jdbc:oracle:thin:@127.0.0.1:1521:xe"     pooled = true     username = "mills_gtunes"     password = "*******"     driverclassname = "oracle.jdbc.driver.oracledriver"     //          dialect= "org.hibernate.dialect.oracle10gdialect"     dialect= "org.hibernate.dialect.oracledialect"      properties {         maxactive = -1         minevictableidletimemillis=1800000         timebetweenevictionrunsmillis=1800000         numtestsperevictionrun=3         testonborrow=true         testwhileidle=true         testonreturn=true         validationquery="select 1"     } }   hibernate {     cache.use_second_level_cache = true     cache.use_query_cache = false     cache.region.factory_class = 'net.sf.ehcache.hibernate.ehcacheregionfactory' } // environment specific settings environments {     development {         datasource {              //h2             //  dbcreate = "create-drop" // 1 of 'create', 'create-drop', 'update', 'validate', ''             //  url = "jdbc:h2:mem:devdb;mvcc=true;lock_timeout=10000"              //oracle             dbcreate = "create-drop"             url = "jdbc:oracle:thin:@127.0.0.1:1521:xe"             pooled = true             username = "mills_gtunes"             password = "******"             driverclassname = "oracle.jdbc.driver.oracledriver"             dialect= "org.hibernate.dialect.oracledialect"              properties {                 maxactive = -1                 minevictableidletimemillis=1800000                 timebetweenevictionrunsmillis=1800000                 numtestsperevictionrun=3                 testonborrow=true                 testwhileidle=true                 testonreturn=true                 validationquery="select 1"             }         }     } 

and here error getting after running "grails run-app" windows command line:

->>   91 | newsqlexception in oracle.jdbc.driver.sqlstatemapping - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |    133 | newsqlexception in oracle.jdbc.driver.databaseerror |    206 | throwsqlexception in     '' |    455 | processerror in oracle.jdbc.driver.t4cttioer |    413 | processerror in     '' |   1034 | receive   in oracle.jdbc.driver.t4c8oall |    183 | dooall8 . in oracle.jdbc.driver.t4cstatement |    780 | executefordescribe in     '' |    855 | executemaybedescribe in     '' |   1186 | doexecutewithtimeout in oracle.jdbc.driver.oraclestatement |   1377 | executequery in     '' |    387 | executequery in oracle.jdbc.driver.oraclestatementwrapper |    208 | executequery in org.apache.commons.dbcp.delegatingstatement |    658 | validateconnection in org.apache.commons.dbcp.poolableconnectionfacto ry |   1558 | validateconnectionfactory in org.apache.commons.dbcp.basicdatasource |   1545 | createpoolableconnectionfactory in     '' |   1388 | createdatasource in     '' |   1044 | getconnection in     '' |    334 | innerrun  in java.util.concurrent.futuretask$sync |    166 | run       in java.util.concurrent.futuretask |   1110 | runworker in java.util.concurrent.threadpoolexecutor |    603 | run       in java.util.concurrent.threadpoolexecutor$worker ^    722 | run . . . in java.lang.thread | error 2013-05-04 14:47:22,691 [localhost-startstop-1] error context.grailscont extloader  - error initializing grails: error creating bean name 'transacti onmanagerpostprocessor': initialization of bean failed; nested exception org. springframework.beans.factory.beancreationexception: error creating bean na me 'transactionmanager': cannot resolve reference bean 'sessionfactory' while  setting bean property 'sessionfactory'; nested exception org.springframework .beans.factory.beancreationexception: error creating bean name 'sessionfact ory': cannot resolve reference bean 'lobhandlerdetector' while setting bean p roperty 'lobhandler'; nested exception org.springframework.beans.factory.bean creationexception: error creating bean name 'lobhandlerdetector': invocatio n of init method failed; nested exception org.springframework.jdbc.support.me tadataaccessexception: error while extracting databasemetadata; nested exception  org.apache.commons.dbcp.sqlnestedexception: cannot create poolableconnection factory (ora-00923: keyword not found expected ) message: error creating bean name 'transactionmanagerpostprocessor': initia lization of bean failed; nested exception org.springframework.beans.factory.b eancreationexception: error creating bean name 'transactionmanager': cannot  resolve reference bean 'sessionfactory' while setting bean property 'session factory'; nested exception org.springframework.beans.factory.beancreationexce ption: error creating bean name 'sessionfactory': cannot resolve reference bean 'lobhandlerdetector' while setting bean property 'lobhandler'; nested ex ception org.springframework.beans.factory.beancreationexception: error creati ng bean name 'lobhandlerdetector': invocation of init method failed; nested  exception org.springframework.jdbc.support.metadataaccessexception: error wh ile extracting databasemetadata; nested exception org.apache.commons.dbcp.sql nestedexception: cannot create poolableconnectionfactory (ora-00923: keywor d not found expected )     line | method ->>  334 | innerrun  in java.util.concurrent.futuretask$sync - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |    166 | run       in java.util.concurrent.futuretask |   1110 | runworker in java.util.concurrent.threadpoolexecutor |    603 | run       in java.util.concurrent.threadpoolexecutor$worker ^    722 | run . . . in java.lang.thread  caused beancreationexception: error creating bean name 'transactionmanag er': cannot resolve reference bean 'sessionfactory' while setting bean proper ty 'sessionfactory'; nested exception org.springframework.beans.factory.beanc reationexception: error creating bean name 'sessionfactory': cannot resolve  reference bean 'lobhandlerdetector' while setting bean property 'lobhandler' ; nested exception org.springframework.beans.factory.beancreationexception: e rror creating bean name 'lobhandlerdetector': invocation of init method fai led; nested exception org.springframework.jdbc.support.metadataaccessexceptio n: error while extracting databasemetadata; nested exception org.apache.commo ns.dbcp.sqlnestedexception: cannot create poolableconnectionfactory (ora-00923: keyword not found expected ) ->>  334 | innerrun  in java.util.concurrent.futuretask$sync - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |    166 | run       in java.util.concurrent.futuretask |   1110 | runworker in java.util.concurrent.threadpoolexecutor |    603 | run       in java.util.concurrent.threadpoolexecutor$worker ^    722 | run . . . in java.lang.thread  caused beancreationexception: error creating bean name 'sessionfactory':  cannot resolve reference bean 'lobhandlerdetector' while setting bean proper ty 'lobhandler'; nested exception org.springframework.beans.factory.beancreat ionexception: error creating bean name 'lobhandlerdetector': invocation of init method failed; nested exception org.springframework.jdbc.support.metadat aaccessexception: error while extracting databasemetadata; nested exception o rg.apache.commons.dbcp.sqlnestedexception: cannot create poolableconnectionfacto ry (ora-00923: keyword not found expected ) ->>  334 | innerrun  in java.util.concurrent.futuretask$sync - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |    166 | run       in java.util.concurrent.futuretask |   1110 | runworker in java.util.concurrent.threadpoolexecutor |    603 | run       in java.util.concurrent.threadpoolexecutor$worker ^    722 | run . . . in java.lang.thread  caused beancreationexception: error creating bean name 'lobhandlerdetect or': invocation of init method failed; nested exception org.springframework.j dbc.support.metadataaccessexception: error while extracting databasemetadata; ne sted exception org.apache.commons.dbcp.sqlnestedexception: cannot create pool ableconnectionfactory (ora-00923: keyword not found expected ) ->>  334 | innerrun  in java.util.concurrent.futuretask$sync - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |    166 | run       in java.util.concurrent.futuretask |   1110 | runworker in java.util.concurrent.threadpoolexecutor |    603 | run       in java.util.concurrent.threadpoolexecutor$worker ^    722 | run . . . in java.lang.thread  caused metadataaccessexception: error while extracting databasemetadata; nest ed exception org.apache.commons.dbcp.sqlnestedexception: cannot create poolab leconnectionfactory (ora-00923: keyword not found expected ) ->>  334 | innerrun  in java.util.concurrent.futuretask$sync - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |    166 | run       in java.util.concurrent.futuretask |   1110 | runworker in java.util.concurrent.threadpoolexecutor |    603 | run       in java.util.concurrent.threadpoolexecutor$worker ^    722 | run . . . in java.lang.thread  caused sqlnestedexception: cannot create poolableconnectionfactory (ora-00923 : keyword not found expected ) ->> 1549 | createpoolableconnectionfactory in org.apache.commons.dbcp.basicdatas ource - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |   1388 | createdatasource in     '' |   1044 | getconnection in     '' |    334 | innerrun  in java.util.concurrent.futuretask$sync |    166 | run . . . in java.util.concurrent.futuretask |   1110 | runworker in java.util.concurrent.threadpoolexecutor |    603 | run . . . in java.util.concurrent.threadpoolexecutor$worker ^    722 | run       in java.lang.thread  caused sqlsyntaxerrorexception: ora-00923: keyword not found expec ted  ->>   91 | newsqlexception in oracle.jdbc.driver.sqlstatemapping - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |    133 | newsqlexception in oracle.jdbc.driver.databaseerror |    206 | throwsqlexception in     '' |    455 | processerror in oracle.jdbc.driver.t4cttioer |    413 | processerror in     '' |   1034 | receive   in oracle.jdbc.driver.t4c8oall |    183 | dooall8 . in oracle.jdbc.driver.t4cstatement |    780 | executefordescribe in     '' |    855 | executemaybedescribe in     '' |   1186 | doexecutewithtimeout in oracle.jdbc.driver.oraclestatement |   1377 | executequery in     '' |    387 | executequery in oracle.jdbc.driver.oraclestatementwrapper |    208 | executequery in org.apache.commons.dbcp.delegatingstatement |    658 | validateconnection in org.apache.commons.dbcp.poolableconnectionfacto ry |   1558 | validateconnectionfactory in org.apache.commons.dbcp.basicdatasource |   1545 | createpoolableconnectionfactory in     '' |   1388 | createdatasource in     '' |   1044 | getconnection in     '' |    334 | innerrun  in java.util.concurrent.futuretask$sync |    166 | run       in java.util.concurrent.futuretask |   1110 | runworker in java.util.concurrent.threadpoolexecutor |    603 | run       in java.util.concurrent.threadpoolexecutor$worker ^    722 | run . . . in java.lang.thread | error 2013-05-04 14:47:22,729 [localhost-startstop-1] error [localhost].[/gtun es]  - exception sending context initialized event listener instance of class  org.codehaus.groovy.grails.web.context.grailscontextloaderlistener message: error creating bean name 'transactionmanagerpostprocessor': initia lization of bean failed; nested exception org.springframework.beans.factory.b eancreationexception: error creating bean name 'transactionmanager': cannot  resolve reference bean 'sessionfactory' while setting bean property 'session factory'; nested exception org.springframework.beans.factory.beancreationexce ption: error creating bean name 'sessionfactory': cannot resolve reference bean 'lobhandlerdetector' while setting bean property 'lobhandler'; nested ex ception org.springframework.beans.factory.beancreationexception: error creati ng bean name 'lobhandlerdetector': invocation of init method failed; nested  exception org.springframework.jdbc.support.metadataaccessexception: error wh ile extracting databasemetadata; nested exception org.apache.commons.dbcp.sql nestedexception: cannot create poolableconnectionfactory (ora-00923: keywor d not found expected )     line | method ->>  334 | innerrun  in java.util.concurrent.futuretask$sync - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |    166 | run       in java.util.concurrent.futuretask |   1110 | runworker in java.util.concurrent.threadpoolexecutor |    603 | run       in java.util.concurrent.threadpoolexecutor$worker ^    722 | run . . . in java.lang.thread  caused beancreationexception: error creating bean name 'transactionmanag er': cannot resolve reference bean 'sessionfactory' while setting bean proper ty 'sessionfactory'; nested exception org.springframework.beans.factory.beanc reationexception: error creating bean name 'sessionfactory': cannot resolve  reference bean 'lobhandlerdetector' while setting bean property 'lobhandler' ; nested exception org.springframework.beans.factory.beancreationexception: e rror creating bean name 'lobhandlerdetector': invocation of init method fai led; nested exception org.springframework.jdbc.support.metadataaccessexceptio n: error while extracting databasemetadata; nested exception org.apache.commo ns.dbcp.sqlnestedexception: cannot create poolableconnectionfactory (ora-00923: keyword not found expected ) ->>  334 | innerrun  in java.util.concurrent.futuretask$sync - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |    166 | run       in java.util.concurrent.futuretask |   1110 | runworker in java.util.concurrent.threadpoolexecutor |    603 | run       in java.util.concurrent.threadpoolexecutor$worker ^    722 | run . . . in java.lang.thread  caused beancreationexception: error creating bean name 'sessionfactory':  cannot resolve reference bean 'lobhandlerdetector' while setting bean proper ty 'lobhandler'; nested exception org.springframework.beans.factory.beancreat ionexception: error creating bean name 'lobhandlerdetector': invocation of init method failed; nested exception org.springframework.jdbc.support.metadat aaccessexception: error while extracting databasemetadata; nested exception o rg.apache.commons.dbcp.sqlnestedexception: cannot create poolableconnectionfacto ry (ora-00923: keyword not found expected ) ->>  334 | innerrun  in java.util.concurrent.futuretask$sync - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |    166 | run       in java.util.concurrent.futuretask |   1110 | runworker in java.util.concurrent.threadpoolexecutor |    603 | run       in java.util.concurrent.threadpoolexecutor$worker ^    722 | run . . . in java.lang.thread  caused beancreationexception: error creating bean name 'lobhandlerdetect or': invocation of init method failed; nested exception org.springframework.j dbc.support.metadataaccessexception: error while extracting databasemetadata; ne sted exception org.apache.commons.dbcp.sqlnestedexception: cannot create pool ableconnectionfactory (ora-00923: keyword not found expected ) ->>  334 | innerrun  in java.util.concurrent.futuretask$sync - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |    166 | run       in java.util.concurrent.futuretask |   1110 | runworker in java.util.concurrent.threadpoolexecutor |    603 | run       in java.util.concurrent.threadpoolexecutor$worker ^    722 | run . . . in java.lang.thread  caused metadataaccessexception: error while extracting databasemetadata; nest ed exception org.apache.commons.dbcp.sqlnestedexception: cannot create poolab leconnectionfactory (ora-00923: keyword not found expected ) ->>  334 | innerrun  in java.util.concurrent.futuretask$sync - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |    166 | run       in java.util.concurrent.futuretask |   1110 | runworker in java.util.concurrent.threadpoolexecutor |    603 | run       in java.util.concurrent.threadpoolexecutor$worker ^    722 | run . . . in java.lang.thread  caused sqlnestedexception: cannot create poolableconnectionfactory (ora-00923 : keyword not found expected ) ->> 1549 | createpoolableconnectionfactory in org.apache.commons.dbcp.basicdatas ource - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |   1388 | createdatasource in     '' |   1044 | getconnection in     '' |    334 | innerrun  in java.util.concurrent.futuretask$sync |    166 | run . . . in java.util.concurrent.futuretask |   1110 | runworker in java.util.concurrent.threadpoolexecutor |    603 | run . . . in java.util.concurrent.threadpoolexecutor$worker ^    722 | run       in java.lang.thread  caused sqlsyntaxerrorexception: ora-00923: keyword not found expec ted  ->>   91 | newsqlexception in oracle.jdbc.driver.sqlstatemapping - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |    133 | newsqlexception in oracle.jdbc.driver.databaseerror |    206 | throwsqlexception in     '' |    455 | processerror in oracle.jdbc.driver.t4cttioer |    413 | processerror in     '' |   1034 | receive   in oracle.jdbc.driver.t4c8oall |    183 | dooall8 . in oracle.jdbc.driver.t4cstatement |    780 | executefordescribe in     '' |    855 | executemaybedescribe in     '' |   1186 | doexecutewithtimeout in oracle.jdbc.driver.oraclestatement |   1377 | executequery in     '' |    387 | executequery in oracle.jdbc.driver.oraclestatementwrapper |    208 | executequery in org.apache.commons.dbcp.delegatingstatement |    658 | validateconnection in org.apache.commons.dbcp.poolableconnectionfacto ry |   1558 | validateconnectionfactory in org.apache.commons.dbcp.basicdatasource |   1545 | createpoolableconnectionfactory in     '' |   1388 | createdatasource in     '' |   1044 | getconnection in     '' |    334 | innerrun  in java.util.concurrent.futuretask$sync |    166 | run       in java.util.concurrent.futuretask |   1110 | runworker in java.util.concurrent.threadpoolexecutor |    603 | run       in java.util.concurrent.threadpoolexecutor$worker ^    722 | run . . . in java.lang.thread | error 2013-05-04 14:47:22,761 [localhost-startstop-1] error core.standardconte xt  - error listenerstart | error 2013-05-04 14:47:22,764 [localhost-startstop-1] error core.standardconte xt  - context [/gtunes] startup failed due previous errors | server running. browse http://localhost:8080/gtunes | application loaded in interactive mode. type 'stop-app' shutdown. 

(any insight appreciated - new grails. thanks).

sorry don't know grails, might problem:

validationquery="select 1" 

that's not valid query oracle, , ora-00923 you're getting come that.

try (replace in both places appears in config file):

validationquery="select 1 dual" 

Comments

Popular posts from this blog

Perl - how to grep a block of text from a file -

delphi - How to remove all the grips on a coolbar if I have several coolbands? -

javascript - Animating array of divs; only the final element is modified -