100% of people found this useful
Creating a convention to override the default column naming for your ManyToOne relationships is simple, as follows:
mapper.BeforeMapManyToOne += (insp, prop, map) =>
map.Column(prop.LocalMember.GetPropertyOrFieldType().Name + "Id");
But, if any of the above are bi-directional relationships, be sure to equivalently map the inverse side's key as required for your collection types:
for set
mapper.BeforeMapSet += (insp, typ, map) => map.Key(km =>
km.Column(typ.GetContainerEntity(insp).Name + "Id"));
for bag
mapper.BeforeMapBag += (insp, typ, map) => map.Key(km =>
km.Column(typ.GetContainerEntity(insp).Name + "Id"));
etc...