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: Testing with SQLITE and Rowversion Issue
PostPosted: Mon Sep 01, 2008 11:12 pm 
Newbie

Joined: Fri Aug 15, 2008 6:47 am
Posts: 6
Hello I am wondering if anyone has a solution to my issue, I am using SQLite for my testing, and have run into an issue with my RowVersion column. In SQL 2005 this is a timestamp column and I have no issues issuing an update.

But when running the test on my SQLite instance, I get a locking error. My code looks something like so, I assume mostly due to not generating the timestamp, is there a way around this to be able to do my testing with sqlite.

// Select and update name.
var ins = repository.SelectById(id);
ins.Name = name;

// Update
repository.Update(ins);

The error I get is : "Row was updated or deleted by another transaction"


As I said running that update against my SQL server has no issues I
assume because the rowversion is being generated: I am mapping the
version like so using a custom type:

<version name="RowVersion" column="RowVersion"
type="NHTimestamp, Core"
generated="always" unsaved-value="null" />


Cheers


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.