PaulCheung wrote:
I want to set up primary keys made up of several fields.
<snip>
This way I could use ACCOUNT as a primary key or if I so wished I could concatenate NAME and ACCOUNT and use that as primary key. Can concatenated fields be used as a primary key?
Most databases allow a *compound* primary key, so that you specify multiple columns as the primary key without concatenating them. This is better than concatenated keys because you can use columns of different types.
Paul _______________________________________________ New York PHP Community Talk Mailing List http://lists.nyphp.org/mailman/listinfo/talk NYPHPCon 2006 Presentations Online http://www.nyphpcon.com Show Your Participation in New York PHP http://www.nyphp.org/show_participation.php
-- Kenneth Downs Secure Data Software, Inc. www.secdat.com www.andromeda-project.org 631-689-7200 Fax: 631-689-0527 cell: 631-379-0010 _______________________________________________ New York PHP Community Talk Mailing List http://lists.nyphp.org/mailman/listinfo/talk NYPHPCon 2006 Presentations Online http://www.nyphpcon.com Show Your Participation in New York PHP http://www.nyphp.org/show_participation.php
