0
I see many models of systems on the net where Id fields are set with GUID type instead of INT, as in the example below:
public class Product
{
public Guid Id { get; protected set; }
public string Name { get; protected set; }
public int Quantity { get; protected set; }
public DateTime Created { get; protected set; }
public DateTime Modified { get; protected set; }
public bool Active { get; protected set; }
}
- What is the advantage of using GUID instead of INT?
- This may impair the performance of the App and/or database?
- I have a commercial system that is still being designed... If I use GUIDS instead of INTS in my tables, this would be recommended?
A hug to all!
Possible duplicate of: Should I use GUID or int as the primary key?
– Vinícius Lima