From: NHibernate J. <mik...@us...> - 2006-11-02 13:31:46
|
[ http://jira.nhibernate.org/browse/NH-789?page=comments#action_14276 ] Johannes Schmidt commented on NH-789: ------------------------------------- #1 http://ora-08177.ora-code.com/ : using oracle 9i with optimistic lock strategy # 2 configuration <nhibernate> <add key="hibernate.connection.provider" value="NHibernate.Connection.DriverConnectionProvider" /> <add key="hibernate.dialect" value="NHibernate.Dialect.Oracle9Dialect" /> <add key="hibernate.connection.driver_class" value="NHibernate.Driver.OracleClientDriver" /> <add key="hibernate.connection.connection_string" value="Enlist=false;Data Source=pc;User Id=user;Password=secret;" /> <add key="hibernate.connection.isolation" value="Serializable" /> </nhibernate> # 3 mapping <hibernate-mapping xmlns = "urn:nhibernate-mapping-2.0" namespace = "OraclePoc" assembly = "OraclePoc"> <class name="OraclePoc.MyTest" table="MyTest"> <!-- technical header --> <id name="TechnicalId" column="TechnicalId" type="String"> <generator class="uuid.hex"/> </id> <!-- properties --> <property name="TimeTest" type="Timestamp"/> <property name="Name" type="String" not-null="true"/> </class> </hibernate-mapping> When I'm using OracleClientDriver the TimeTest will not save milliseconds. If I'm using OracleDataClientdriver, the milliseconds will be saved correctly. But there is no StaleObjectException, just an exception from ADOExceptionReporter. > ORA-08177 not wrapped as StaleObjectException with Oracle.DataAcess > ------------------------------------------------------------------- > > Key: NH-789 > URL: http://jira.nhibernate.org/browse/NH-789 > Project: NHibernate > Type: Bug > Components: Core > Versions: 1.0.2 > Reporter: Johannes Schmidt > > The OracleClientDriver does not support milliseconds for Timestamp mapping. So, I decided to used OracleDataClientDriver. I'm using OptimisticLock settings in the mapping file. If there is a concurrency problem, I except a StaleObjectException, but the ADOExceptionReporter throws an exceptions that contains only the text of the Oracle exception for ORA-08177. -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.nhibernate.org/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |