BorlandTalk.com Forum Index BorlandTalk.com
Borland discussion newsgroups
 
Archives   FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Paradox AutoIncrement Corruption

 
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi Databases (Desktop)
View previous topic :: View next topic  
Author Message
Steve Harp
Guest





PostPosted: Sat Jan 06, 2007 4:54 am    Post subject: Paradox AutoIncrement Corruption Reply with quote



Hi All,

I have an old application that uses Paradox 7 tables. One of the
tables uses an AutoIncrement field to store a unique ItemID. The
current records in the table start at an ItemID of 3 and go to 314.
When adding a new record, the first new record is assigned 1 and the
second is assigned 2. Of course, when they try to put in the 3rd it
barfs.

I read an earlier post where restructuring was suggested to fix this
but it doesn't work. I use Database Desktop v7 to restructure and the
problem still exists. I even added a new field to make sure that the
restructure actually took place.

Is there another way to fix this table?

Thanks,
Steve
Back to top
Bill Todd
Guest





PostPosted: Sat Jan 06, 2007 6:12 am    Post subject: Re: Paradox AutoIncrement Corruption Reply with quote



Just restructuring is not enough. Restructure and change the field type
from autoinc to integer. Restructure again and change the field type
from integer to autoinc. That should correct the problem.

--
Bill Todd (TeamB)
Back to top
Steve Harp
Guest





PostPosted: Sat Jan 06, 2007 8:15 am    Post subject: Re: Paradox AutoIncrement Corruption Reply with quote



On 5 Jan 2007 16:12:40 -0800, "Bill Todd" <no (AT) no (DOT) com> wrote:

Quote:
Just restructuring is not enough. Restructure and change the field type
from autoinc to integer. Restructure again and change the field type
from integer to autoinc. That should correct the problem.

I tried that an Database Desktop complained that it could'nt
restructure. The error I get is "Field ItemID: existing field type
cannot be converted to requested type". I assumed that was because
the table has records in it and can assign autoincrement values to
existing records. Is this not correct?

Steve
Back to top
Bill Todd
Guest





PostPosted: Sat Jan 06, 2007 10:43 am    Post subject: Re: Paradox AutoIncrement Corruption Reply with quote

Quote:

I tried that an Database Desktop complained that it could'nt
restructure. The error I get is "Field ItemID: existing field type
cannot be converted to requested type". I assumed that was because
the table has records in it and can assign autoincrement values to
existing records. Is this not correct?

Steve

Did the error occur on the autoinc->integer restructure or the
integer->autoinc restructure?

Try rebuilding the table with the table repair program at
www.rksolution.cz and see if that corrects the problem.

--
Bill Todd (TeamB)
Back to top
Steve Harp
Guest





PostPosted: Sun Jan 07, 2007 8:48 am    Post subject: Re: Paradox AutoIncrement Corruption Reply with quote

On 5 Jan 2007 20:43:02 -0800, "Bill Todd" <no (AT) no (DOT) com> wrote:

Quote:

I tried that an Database Desktop complained that it could'nt
restructure. The error I get is "Field ItemID: existing field type
cannot be converted to requested type". I assumed that was because
the table has records in it and can assign autoincrement values to
existing records. Is this not correct?

Steve

Did the error occur on the autoinc->integer restructure or the
integer->autoinc restructure?

I failed with the integer->autoinc restructure.
Back to top
Bill Todd
Guest





PostPosted: Sun Jan 07, 2007 9:20 am    Post subject: Re: Paradox AutoIncrement Corruption Reply with quote

Quote:

I failed with the integer->autoinc restructure.

It works for me. I think the table is corrupt. Rebuild it with the
table repair program at www.rksolution.cz.

--
Bill Todd (TeamB)
Back to top
Display posts from previous:   
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi Databases (Desktop) All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2006 phpBB Group
SEO toolkit © 2004-2006 webmedic.