-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 
Author Message
 Post subject: Hibernate et driver MS SQL Server
PostPosted: Fri Jan 20, 2006 6:17 am 
Beginner
Beginner

Joined: Thu Sep 02, 2004 4:54 am
Posts: 24
Bonjour,
est-ce quelqu'un sait si le nouveau driver de microsoft pour SQL server est utilisable par hibernate?
Outre le fait que le nom du driver a changé, j'obtient une erreur avec c3p0 qui ne trouve pas de driver...
par contre si j'active le cache par défaut d'hibernate ça marche.

faut-il supplanter les valeurs par défaut de c3p0 en créant un fichier c3p0.properties complet? (j'ai vaguement essayé mais sans succès)

merci

ju

Hibernate version: 3.1.1

Full stack trace of any exception that occurs:
20 11:07:07 DEBUG [com.mchange.v2.resourcepool.BasicResourcePool] An exception occurred while acquiring a resource.
java.sql.SQLException: No suitable driver
at java.sql.DriverManager.getDriver(DriverManager.java:243)
at com.mchange.v2.c3p0.DriverManagerDataSource.driver(DriverManagerDataSource.java:158)
at com.mchange.v2.c3p0.DriverManagerDataSource.getConnection(DriverManagerDataSource.java:81)
at com.mchange.v2.c3p0.WrapperConnectionPoolDataSource.getPooledConnection(WrapperConnectionPoolDataSource.java:96)
at com.mchange.v2.c3p0.impl.C3P0PooledConnectionPool$1.acquireResource(C3P0PooledConnectionPool.java:89)
at com.mchange.v2.resourcepool.BasicResourcePool.acquireUntil(BasicResourcePool.java:665)
at com.mchange.v2.resourcepool.BasicResourcePool.access$500(BasicResourcePool.java:32)
at com.mchange.v2.resourcepool.BasicResourcePool$AcquireTask.run(BasicResourcePool.java:1204)
at com.mchange.v2.async.ThreadPoolAsynchronousRunner$PoolThread.run(ThreadPoolAsynchronousRunner.java:368)


Name and version of the database you are using:
SQL SERVER 2000

20 11:06:54 INFO [org.hibernate.cfg.Environment] Hibernate 3.1.1
20 11:06:54 INFO [org.hibernate.cfg.Environment] loaded properties from resource hibernate.properties: {hibernate.jdbc.use_get_generated_keys=false, hibernate.connection.password=****, hibernate.c3p0.acquire_increment=2, hibernate.jdbc.batch_versioned_data=true, hibernate.query.substitutions=true 1, false 0, yes 'Y', no 'N', hibernate.cache.region_prefix=hibernate.test, hibernate.c3p0.idle_test_period=3000, hibernate.show_sql=true, hibernate.proxool.pool_alias=pool1, hibernate.c3p0.max_statements=100, hibernate.c3p0.validate=false, hibernate.c3p0.timeout=0, hibernate.default_batch_fetch_size=8, hibernate.jdbc.use_streams_for_binary=true, hibernate.max_fetch_depth=1, hibernate.c3p0.min_size=2, hibernate.connection.username=sa, hibernate.connection.driver_class=com.microsoft.sqlserver.jdbc.SQLServerDriver, hibernate.cache.provider_class=org.hibernate.cache.HashtableCacheProvider, hibernate.c3p0.max_size=5, hibernate.cglib.use_reflection_optimizer=true, hibernate.order_updates=true, hibernate.dialect=org.hibernate.dialect.SQLServerDialect, hibernate.connection.url=jdbc:microsoft:sqlserver://maldives;DatabaseName=evo_client DEVELOPPEMENT;SelectMethod=cursor}
20 11:06:54 INFO [org.hibernate.cfg.Environment] using java.io streams to persist binary types
20 11:06:54 INFO [org.hibernate.cfg.Environment] using CGLIB reflection optimizer
20 11:06:54 INFO [org.hibernate.cfg.Environment] using JDK 1.4 java.sql.Timestamp handling
20 11:06:55 INFO [org.hibernate.cfg.Configuration] Reading mappings from resource: fr/digimind/evolution/rssagent/databean/RSSItemBean.hbm.xml
20 11:06:55 DEBUG [org.hibernate.util.DTDEntityResolver] trying to locate http://hibernate.sourceforge.net/hibern ... ng-3.0.dtd in classpath under org/hibernate/
20 11:06:55 DEBUG [org.hibernate.util.DTDEntityResolver] found http://hibernate.sourceforge.net/hibern ... ng-3.0.dtd in classpath
20 11:06:56 INFO [org.hibernate.cfg.HbmBinder] Mapping class: fr.digimind.evolution.rssagent.databean.RSSItemBean -> rss_data
20 11:06:56 DEBUG [org.hibernate.cfg.HbmBinder] Mapped property: id -> id
20 11:06:56 DEBUG [org.hibernate.cfg.HbmBinder] Mapped property: title -> title
20 11:06:56 DEBUG [org.hibernate.cfg.HbmBinder] Mapped property: link -> link
20 11:06:56 DEBUG [org.hibernate.cfg.HbmBinder] Mapped property: text -> marked_text
20 11:06:56 DEBUG [org.hibernate.cfg.HbmBinder] Mapped property: date_pub -> date_pub
20 11:06:56 DEBUG [org.hibernate.cfg.HbmBinder] Mapped property: description -> description
20 11:06:56 DEBUG [org.hibernate.cfg.HbmBinder] Mapped property: sourceId -> source_id
20 11:06:56 DEBUG [org.hibernate.cfg.HbmBinder] Mapped property: date -> date
20 11:06:56 DEBUG [org.hibernate.cfg.HbmBinder] Mapped property: binary -> contenu
20 11:06:56 DEBUG [org.hibernate.cfg.HbmBinder] Mapped property: encoding -> encoding
20 11:06:56 DEBUG [org.hibernate.cfg.HbmBinder] Mapped property: type -> type
20 11:06:56 DEBUG [org.hibernate.cfg.HbmBinder] Mapped property: summary -> summary
20 11:06:56 DEBUG [org.hibernate.cfg.Configuration] Preparing to build session factory with filters : {}
20 11:06:56 DEBUG [org.hibernate.cfg.Configuration] processing extends queue
20 11:06:56 DEBUG [org.hibernate.cfg.Configuration] processing collection mappings
20 11:06:56 DEBUG [org.hibernate.cfg.Configuration] processing native query and ResultSetMapping mappings
20 11:06:56 DEBUG [org.hibernate.cfg.Configuration] processing association property references
20 11:06:56 DEBUG [org.hibernate.cfg.Configuration] processing foreign key constraints
20 11:06:56 INFO [org.hibernate.connection.C3P0ConnectionProvider] C3P0 using driver: com.microsoft.sqlserver.jdbc.SQLServerDriver at URL: jdbc:microsoft:sqlserver://maldives;DatabaseName=evo_client DEVELOPPEMENT;SelectMethod=cursor
20 11:06:56 INFO [org.hibernate.connection.C3P0ConnectionProvider] Connection properties: {user=sa, password=****}
20 11:06:56 INFO [org.hibernate.connection.C3P0ConnectionProvider] autocommit mode: false
20 11:06:58 INFO [com.mchange.v2.log.MLog] MLog clients using log4j logging.
20 11:06:58 INFO [com.mchange.v2.c3p0.C3P0Registry] Initializing c3p0-0.9.0 [built 11-July-2005 00:43:29 -0400; debug? true; trace: 10]
20 11:07:00 INFO [com.mchange.v2.c3p0.PoolBackedDataSource] Initializing c3p0 pool... com.mchange.v2.c3p0.PoolBackedDataSource@18235ed [ connectionPoolDataSource -> com.mchange.v2.c3p0.WrapperConnectionPoolDataSource@1d6f122 [ acquireIncrement -> 2, acquireRetryAttempts -> 30, acquireRetryDelay -> 1000, autoCommitOnClose -> false, automaticTestTable -> null, breakAfterAcquireFailure -> false, checkoutTimeout -> 0, connectionTesterClassName -> com.mchange.v2.c3p0.impl.DefaultConnectionTester, factoryClassLocation -> null, forceIgnoreUnresolvedTransactions -> false, identityToken -> 1d6f122, idleConnectionTestPeriod -> 3000, initialPoolSize -> 2, maxIdleTime -> 0, maxPoolSize -> 5, maxStatements -> 100, maxStatementsPerConnection -> 0, minPoolSize -> 2, nestedDataSource -> com.mchange.v2.c3p0.DriverManagerDataSource@8ee016 [ description -> null, driverClass -> null, factoryClassLocation -> null, identityToken -> 8ee016, jdbcUrl -> jdbc:microsoft:sqlserver://maldives;DatabaseName=evo_client DEVELOPPEMENT;SelectMethod=cursor, properties -> {user=******, password=******} ], preferredTestQuery -> null, propertyCycle -> 300, testConnectionOnCheckin -> false, testConnectionOnCheckout -> false, usesTraditionalReflectiveProxies -> false ], factoryClassLocation -> null, identityToken -> 18235ed, numHelperThreads -> 3 ]
20 11:07:00 DEBUG [com.mchange.v2.resourcepool.BasicResourcePool] awaitAvailable(): [unknown]
20 11:07:00 DEBUG [com.mchange.v2.resourcepool.BasicResourcePool] trace com.mchange.v2.resourcepool.BasicResourcePool@117f31e [managed: 0, unused: 0, excluded: 0]
20 11:07:00 DEBUG [com.mchange.v2.resourcepool.BasicResourcePool] An exception occurred while acquiring a resource.


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.