Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Uniqueness of index PRIMARY is violated
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00144393
Message ID:
00145338
Vues:
44
>Here comes the other position. I follow the relational design principle that if two fields in two tables share the same domain they should have the same name

That's how I used to feel, too. It's similar to having a class called Foo, for example and calling a method Print() instead of PrintFoo(). Furthermore, the approach you're talking about takes less typing. :)

However, I do think that table prefixes are necessary. If you have a foreign key, it's nice to be able to unambigously generate it from the names of the tables involved.

>I don't worry about aliasing in SQL because I would alias even if I didn't have to to make the SQL self documenting for me in 6 months when I don't remember which table has the prefix fgc_.

The prefix approach makes the SQL self-documenting automatically. But I admit that my apps don't have a large number of tables, where selecting memorable prefixes would be difficult.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform