我正在为公司应用程序创建一个传输数据工具,将数据从旧版本移动到新版本,并返回。由于现在我们使用的是NHibernate和FluentMapping,我将不得不映射所有旧表,并且组合主键的表有问题。该表是这样的: public class OldTable {
public string KeyOne {get;set}
public string KeyTwo {get;set}
publi
我无法弄清楚如何在使用复合键时映射接口。 我想要做的是这样的: interface Ifoo
{
int someInt {get;}
int id {get;}
}
class bar1: Ifoo
{
int someInt {get; protected internal set;}
int id {get; protected intern
我想要做的就是构建一个HQL查询,它接受一个id列表并返回一个加载objets列表。过了一会儿,我发现,这样的事情可以工作 from Foo foo where foo.ID in (:IdList)
然而,这仅适用于单一的IDS怎么一回事,因为当我尝试使用它的复合ID的应用程序抛出一个异常: System.ArgumentOutOfRangeException:索引超出范围。必须是非负数且小
大家好,我的方案 public class Permission
{
public virtual Function Function { get; set; }
public virtual Profile Profile { get; set; }
}
public class MapPermission : ClassMap<Permission>
{