primary key

  • Thread starter Thread starter Guest
  • Start date Start date
Yes. Use the Index (Lightning) Icon to access the indexes and select the
three fields, using only one index name. be sure to set the correct
properties ( Primary = True).
 
Thanks.
-----Original Message-----
Yes. Use the Index (Lightning) Icon to access the indexes and select the
three fields, using only one index name. be sure to set the correct
properties ( Primary = True).




.
 
hi, and i hope i can join this thread:

i would like to reference my PK in an expression like

Me.txtCurKey = Me.nameofPKfield

where the nameofPKfield refers to a PK consisting of five fields in the
form's underlying table: LastName,FirstName,MI,MR_Number,IRB_Number

looking at the listing of the PK in the table's properties shows me a
default name of "PrimaryKey" in the column labeled Index Name, but that
doesnot in VBA code.

so, what is the name of the PK?
 
You are asking for trouble if all five of those fields make up the Primary
Key. The Primary Key is ususally only one field, two in some cases. If
MR_Number or IRB_Number is unique to each person, then eithe one would best
server as your PK.You should never use names as part of a Primary Key.

Create a textbox on your form and set the control source as such:
=[fieldname1] & "" & [fieldname2] & "" & ....
 
Back
Top