VFP Auto-Incremented Primary Key Fields

If you want to use a Visual FoxPro Integer(AutoInc) field type in a table in a VPME application to generate a sequential primary key, you must name the primary key field “PK_AUTOINC”. That names lets VPME know that the field is an Integer (AutoInc) type.

Visual FoxPro does not insert a value into an auto-incremented field until a new record is saved. That means that an auto-incremented primary key field would fail VPME’s primary key entity integrity checks. However, if the primary key Intger(AutoInc) field has the name “PK_AUTOINC”, VPME knows to skip the entity integrity checks.

Tip: Use of VFP’s Integer(AutoInc) field type to generate sequential primary keys is not recommened.

More:

Setting Table Properties