Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Auto-Inc field = 0
Message
From
13/09/2022 07:47:22
Lutz Scheffler (Online)
Lutz Scheffler Software Ingenieurbüro
Dresden, Germany
 
 
To
13/09/2022 07:40:37
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
01684957
Message ID:
01684961
Views:
40
Just fix the creation. It's just the NEXTVALUE. Do you use the interface to create tables? Possibly you touched the Nextvalue field of the designer. Should be 1 for new tables
Else you can check your tables with GETAUTOINCVALUE( ) and set to 1 or something meaningful if they return 0 via ALTER TABLE. I would try this before fiddling with the logic itself.


>I hate this but I can't trust it.
>
>So I'll fix my code to consider that the field value can be 0
>
>Thanks for your input.
>
>
>>>Hello all,
>>>
>>>I never saw something like that ever. Through my application I added a record to an empty table that contains a field that is Auto-Inc. The value of that field on that new record is 0.
>>>
>>>How can that be?
>>>
>>>I tried to reproduce but couldn't.
>>
>>Probably a deleted or blank record. Try Set Deketed Off and Browse the table.
Words are given to man to enable him to conceal his true feelings.
Charles Maurice de Talleyrand-Périgord

Weeks of programming can save you hours of planning.

Off

There is no place like [::1]
Previous
Reply
Map
View

Click here to load this message in the networking platform