Uses @@identity to get the Id value.

Namespace: NHibernate.Dialect
Assembly: NHibernate (in NHibernate.dll) Version: 3.2.0.4000 (3.2.0.4000)

Syntax

C#
public override string IdentitySelectString { get; }
Visual Basic
Public Overrides ReadOnly Property IdentitySelectString As String
	Get
Visual C++
public:
virtual property String^ IdentitySelectString {
	String^ get () override;
}

Remarks

There is a well known problem with @@identity and triggers that insert into rows into other tables that also use an identity column. The only way I know of to get around this problem is to upgrade your database server to Ms Sql 2000.

See Also