Board index » delphi » "BLOB has been modified"

"BLOB has been modified"

After trying to read memo field of a local Paradox table (D4.02):

var  m: TStringList;
...
with Table1 do begin
   open;
   m:= TStringList.Create;
   m.text:= TMemoField(fieldByName('Parametri')).AsString; //error

I get the EDBEngineError "BLOB has been modified" and m.text remains
empty :-(

1. What can I do to prevent this kind of errors?
(it seems they are connected with program crashes. At that time I
believe my Table1 is open, but *not* in edit/insert state).

2. Is there a way retrieve value stored in BLOB field *after* this error
has happend?
(it will save me and my "customers" a lot of work- BLOBs are holding
long and complex data)

3. Is there a way to programically correct this kind of errors?

TIA, Bojan

 

Re:"BLOB has been modified"


Quote
Bill Todd (TeamB) wrote:

> See http://community.borland.com/article/0,1410,15209,00.html.

Bill, thanx.

I checked the article, but it doesn't seem to solve any of my problems:

Quote
>1. What can I do to prevent this kind of errors?

I already know what's the cause of error (crashes). The "solution" in
article: "Paradox tables are not designed to withstand such behavior. If
this is a possibility in your environment, we recommend you use a Client
Server database that can recover from such conditions." doesn't make
much sense in a stand-alone (local machine) application. Also, my
customers (sportsmen, coaches) can't afford C/S.

Quote
> 2. Is there a way to retrieve value stored in BLOB field *after* this error
> has happened?
> 3. Is there a way to programically correct this kind of errors?

As suggested by the author of article, I downloaded TUtility, but it
doesn't detect any errors on my table ("Verification successful.
Verification completed").

AFAIK, the only way to correct the error is to delete the record
(possibly moving the values of all *non*-BLOB fields to a new record
before that).

Strange enough, using hex editor I can see all (and correct) content of
BLOB field in the .MB file, maybe even at the right place (offset)? (I
don't know the structure of MB files).

So, any (less painful) solution?

TIA, Bojan

Re:"BLOB has been modified"


If crashes are a problem try setting Local Share to True in the BDE
Administrator or calling DbiSaveChanges in the AfterPost event handler of
every dataset. Either of these will disable the BDE's write caching. Closing
and reopening the tables frequently may also help.

--
Bill

Bill Todd (TeamB)
(TeamB cannot respond to questions received via email)

Re:"BLOB has been modified"


As fas as tutility goes, I have found that "Verification successful.
Verification completed" means the table does require a rebuild.
I always rebuild them unless it says "Table has no Errors"

Quote
Bojan Leskosek wrote:
> Bill Todd (TeamB) wrote:

> > See http://community.borland.com/article/0,1410,15209,00.html.

> Bill, thanx.

> I checked the article, but it doesn't seem to solve any of my problems:

> >1. What can I do to prevent this kind of errors?

> I already know what's the cause of error (crashes). The "solution" in
> article: "Paradox tables are not designed to withstand such behavior. If
> this is a possibility in your environment, we recommend you use a Client
> Server database that can recover from such conditions." doesn't make
> much sense in a stand-alone (local machine) application. Also, my
> customers (sportsmen, coaches) can't afford C/S.

> > 2. Is there a way to retrieve value stored in BLOB field *after* this error
> > has happened?
> > 3. Is there a way to programically correct this kind of errors?

> As suggested by the author of article, I downloaded TUtility, but it
> doesn't detect any errors on my table ("Verification successful.
> Verification completed").

> AFAIK, the only way to correct the error is to delete the record
> (possibly moving the values of all *non*-BLOB fields to a new record
> before that).

> Strange enough, using hex editor I can see all (and correct) content of
> BLOB field in the .MB file, maybe even at the right place (offset)? (I
> don't know the structure of MB files).

> So, any (less painful) solution?

> TIA, Bojan

Other Threads