Question

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

Was it helpful?

Solution

Use the guid. It is the system internal identifier for your users. This then allows the ability to change usernames if people wish.

This then fits nicely with the concept of an internal ID that means something to your system, versus the external ID that means something to your users.

OTHER TIPS

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

Hm.. Are you asking about field used as primary or about using/not a relations (insert a GUID into a table having another table with GUID and user name associations) ?

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top