I'm with the following situation, I'm using EF with IDbSet entities and my property has a GUID as a PK, but I need one of the entities owned an auto-increment. If I put the key attribute on the property that should be auto-increment property is no longer GUID PK.
Anyone know any way to just put an auto-increment property to EF through without turning it on PK?
namespace Service.Entity.Order
{
[Serializable]
public class Order : IEntity
{
#region Properties
public Guid Id { get; set; }
public DateTime DateImplementation { get; set; }
public DateTime? DateDelivery { get; set; }
//Field Auto-Increment
public int NrOrder { get; set; }
#endregion
#region Status
public int ProcessStatus { get; set; }
public Status Created { get; set; }
public Status Approved { get; set; }
public Status PolicyDefined { get; set; }
#endregion
#region RelationShips
public Client Client { get; set; }
public User User { get; set; }
public Representation Representation { get; set; }
public Contact Contact { get; set; }
#endregion
}
}