Kristina D. H. Anderson wrote:
Also you can try to avoid your own confusion by giving longer, more detailed names to fields. Some people hate this idea but to me a little extra typing is worth the clarity.

Not only for yourself, but everyone else dealing with your database and code. Also, I recommend naming fields with the same content by the same name across the database. So rather than calling a field "RecordID" call it "FooRecordID" even when that is obvious when that field is in table Foo. It doesn't get that obvious anymore when you use that record ID in the table Bar. Calling it just there "FooRecordID" may be OK, but I come across way too many tables where such a field is called "GizmoID" because table Foo stores the records for gizmos, but it isn't called "Gizmo". That really rapidly inhales. And in any case create and maintain a data dictionary so that one doesn't have to sift through all the field descriptions in the table views.

David
_______________________________________________
New York PHP User Group Community Talk Mailing List
http://lists.nyphp.org/mailman/listinfo/talk

http://www.nyphp.org/show_participation.php

Reply via email to