Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Uniqueness of...
Message
From
24/10/2000 13:34:38
 
 
To
24/10/2000 13:32:38
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00433662
Message ID:
00433673
Views:
22
>>Hi,
>>
>>I have a variable that needs to be unique in a table. Of course, I created an index on it and made this variable "primary". Now, when I try to enter a new row of data with the value of this variable identical to another row of data I get a message saying "Uniqueness of index [...] is violated." That's great! It's exactely what I want. But afterwards, I'm having problems with my app because the table can't be closed because VFP is still trying to update the table. What I would like for VFP to do is to cancel the addition of the new row when this kind of error arises. Is that possible? Or do I have to programmatically make sure that no other row of data has this value before I try to insert it in the table?
>>
>>Thanks a lot in advance, Stephane.
>
>TABLEREVERT() after the failure.

It's always simple isn't it?

Thanks a lot!
Previous
Reply
Map
View

Click here to load this message in the networking platform