Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Primary Key

Status
Not open for further replies.

demopro

Programmer
Apr 23, 2001
117
0
0
US
Can dBase have a PK? I need to have just one column set as a PK to ensure that duplicate data does not happen. I am using dBase4.
 
I would say
SET UNIQUE ON
then create an index and always handle your database with that index open

I'm not sure what dBase does if you try to add a record with the same key. You can try.

Bye
Jan
 
Using SET UNIQUE ON will always give you the first unique occurance of a record. Using the COPY TO command will create a table with only those unique records.

Jim C.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top