Hi all,
I am using a SQLite database. Previously I was on 1.2.0 and just upgraded to 2.0.0.Aplha1. I am now receiving the following error:
NHibernate.HibernateException : The database returned no natively generated identity value
Mapped Class
Code:
public class Person
{
private int _id;
private string _name;
///<summary>
///</summary>
[Id(0, Name = "Id"),
Generator(1, Class = "native")]
public virtual int Id
{
get { return _id; }
set { _id = value; }
}
[Property]
public virtual string Name
{
get { return _name; }
set { _name= value; }
}
}
Test
Code:
[Test]
public void AckTest()
{
Person person = new Person();
person.Name= "Foo Bar";
Session.Save(person);
}
Any help would be appreciated.
Thanks.