Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Cannot add a record
Message
De
22/07/1999 00:09:05
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Divers
Thread ID:
00244414
Message ID:
00244547
Vues:
22
Hi Gerard,

As Ed said, don't leave the key as zero. I am reminded of the old joke, "Doctor, it hurts when I do this"..."So don't do that!".

Do not add via browse unless you have an INSERT trigger to gen a unique numeric value as a key. For programmatic appends, use INSERT INTO and always specify a value for the key.

>I've just created a Database with a few tables, all with numeric primary keys:
>I go in , browse a table, seelct option to add a record, and leave primary key as zero.
>I then try to add another record...it wont let me saying 'Uniqueness of index XXXXXX violated.
>I reckon the system is trying to assign a primary key of 0, but is there a way around this ?
------------------------------------------------
John Koziol, ex-MVP, ex-MS, ex-FoxTeam. Just call me "X"
"When the going gets weird, the weird turn pro" - Hunter Thompson (Gonzo) RIP 2/19/05
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform