Information générale
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
I totally respect your POV on integer primary keys, and I am moving toward it. But I do have a fondness for character keys, and am somewhat reluctant to let them go.
I like them because they can make use of information (i.e. base them on system, user, date, etc). Since they are surrogate keys you in effect have a permanent marker about when and who created the created the record. If one does any auditing at all, then you have this information being stored anyway.
As for the speed and size issue. Yes, but, by far, a character primary key is not going to be the biggest or slowest object in a VFP system. I see more performance gains optimizing page creation, using parameterized views, and so on.
>How much space does it take to store your GUID? Integers are small and VERY fast. Faster than character.
Précédent
Suivant
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement