UserName or guid UserID?

When saving data in different sql tables, is it best to use a GUID GUID or just use a username? is there any performance difference when using guid?

+6
sql guid
source share
2 answers

Use a pointer. This is an internal system identifier for your users. This then allows usernames to be changed if they wish.

This goes well with the concept of an internal identifier that means something on your system, and an external identifier that means something to your users.

+11
source share

I saw a lot of discussion about performance in GUID and INT (auto increment). But I could recommend you use a GUID.

Hm .. Are you asking about a field that is used as primary, or about the use / absence of relationships (insert a GUID into a table with another table with GUIDs and name associations)?

+5
source share

All Articles