Board index » delphi » Paradox Table Header gets corrupted

Paradox Table Header gets corrupted

Hi everyone,
here's my problem:

I have a Paradox table that once in a while gets corrupted - usually in
its header. This seems to be randomly but is very annoying and because
of that our users don't have confidence in our software (and I don't
blame them). I use Delphi 2.01and the table is used in a networked
environment with about 6 users accessing it simultaneously. The table
holds some temporary data, therefore a lot of deletion and insertions
are performed on it. I've been under a lot of pressure  to go in debug
mode and find out where exactly the program/table crashes (?!?!?) - to
be honest I really cannot do that since all I'm using are Delphi-BDE
calls, but my supervisors wouldn't accept that - something has to wrong
in my code and it has to be pinned out!
I would appreciate any suggestion.
Thank you.

P.S. You may reply at luch...@easysoft-law.com

 

Re:Paradox Table Header gets corrupted


Well, it happens enough to be annoing to unacceptable. They are about 6
users accessing that table at the same time. That table is filled with
some calaculataed data. To fill a record might take up to 5 seconds and
there are an average of  15 records for each "user session" to be
calculated. I am required to keep the whole time under a minute - wich,
anyway, I cannot make it if all the users are doing their process
exactly in the same time. However, if I allow only one user to access
the table at one time then the time cost will be unacceptable. (By the
way, though, in the very beginning I did lock the table  for one user
only but mu boss requested me to abandon that approach.) Regarding the
location of the net file - yest, it is xactly the same (if wouldn't be
so, usually and normally BDE would come out with an error :Database
controlled by another net file" or something like that...) The BDE
version is 4.01.16. Local Share is set to TRUE, ... well what it is "New
file Sharing and locking semantics" - I don't know this one.
About more, there is one thing I've done yesterday and it looks like it
help - Win95 OSR2 cam with a "hidden improvement" - a bug: the
VREDIR.VXD file is faulty. There is a patch for that which I applied
yesterday (if you need it I can send it to you).

Quote
-----Original Message-----
From: Orlando Pobre [mailto:Orla...@TRAMS.com]
Sent: Monday, January 19, 1998 6:29 PM
To: 'Luchian Teodoropol'
Subject: RE: Paradox corrupt file

I'm curious.  How often does it happen to you.  There are other rules
too that
you must follow.

1) Making sure that the Drive letter that is mapped is EXACTLY the same
at
every work station.  Except the PC that has the database on the C drive
is ok.
 e.g.  Net Dir is T:\MYDATABASE  ... must be T on every PC's BDE
2) BDE version 2.52
3) Local Share set to TRUE
4) Win95 - Disable New file Sharing and locking semantics
5)  There may be more....

About guaranteeing that one person writes to a table:
Even though it is Multi-User, you can have a polling routine that locks
a file.
Any person that does the locking can do their Edit and Post and then
Unlock
that file (which would allow the next person to be able to do updates on

that
same table).  There are algorithms you can try for this to improve the
chances
that one person will lock that file.  The file locking routines can use
the
FileOpen function with fmShareExlcusive and poll for random intervals
and
check to see if you can lock that file again.

Luchian Teodoropol wrote:

> Hi everyone,
> here's my problem:

> I have a Paradox table that once in a while gets corrupted - usually
> in
> its header. This seems to be randomly but is very annoying and because

> of that our users don't have confidence in our software (and I don't
> blame them). I use Delphi 2.01and the table is used in a networked
> environment with about 6 users accessing it simultaneously. The table
> holds some temporary data, therefore a lot of deletion and insertions
> are performed on it. I've been under a lot of pressure  to go in debug

> mode and find out where exactly the program/table crashes (?!?!?) - to

> be honest I really cannot do that since all I'm using are Delphi-BDE
> calls, but my supervisors wouldn't accept that - something has to
> wrong
> in my code and it has to be pinned out!
> I would appreciate any suggestion.
> Thank you.

> P.S. You may reply at luch...@easysoft-law.com

Other Threads