Subject Re: [firebird-support] Re: using TIBValidateService with FB 1.5 database (IBX 7.08)
Author ibrahim bulut
hi
this is my database repair application's delphi code
i am using Firebird 1.5.2 and IBX 7.08
i am using it without problems
you can use it

///
if (IBValidationService1.Active = True) Then
IBValidationService1.Active:=False;

IBValidationService1.Protocol:=TCP;
IBValidationService1.ServerName:='SERVER';
IBValidationService1.DatabaseName:='C:\DATA\DATABASE.FDB';

IBValidationService1.Options:=[];
IBValidationService1.Options:=[CheckDB,IgnoreChecksum,KillShadows,ValidateDB,ValidateFull];
IBValidationService1.Active:=True;

IBValidationService1.ServiceStart; // Check database

Memo1.Lines.Clear;
While (IBValidationService1.Eof = False) Do
Begin
Application.ProcessMessages;
Memo1.Lines.Add(IBValidationService1.GetNextLine);
End;
Memo1.Lines.Text:=Trim(Memo1.Lines.Text);

if (Memo1.Lines.Count > 0) Then
Begin
IBValidationService1.Active:=False;
IBValidationService1.Options:=[];
IBValidationService1.Options:=[IgnoreChecksum,MendDB];
IBValidationService1.Active:=True;

IBValidationService1.ServiceStart; // Repair database

While (IBValidationService1.Eof = False) Do
Begin
Application.ProcessMessages;
Memo1.Lines.Add(IBValidationService1.GetNextLine);
End;
End Else Memo1.Text:='NO ERROR FOUND';

IBValidationService1.Active:=False;

///






----- Original Message -----
From: "Helen Borrie" <helebor@...>
To: <firebird-support@yahoogroups.com>
Sent: Wednesday, August 03, 2005 9:52 AM
Subject: Re: [firebird-support] Re: using TIBValidateService with FB 1.5
database (IBX 7.08)


Eugene,

At 05:40 AM 3/08/2005 +0000, you wrote:
>Helen,
>
>Single [CheckDB] option doesnt work...It raises exception "Please
>retry specifying option". So looks like i need to add one more
>option to this set for this to work.
>
>Single [ValidateDB] works fine...And no messages is logged
>when database is ok. Can you tell me what text i should be looking
>for in case of erros? I just dont have any corrupt databases here to
>run gfix on to see :)
>
>So if i parse ValidateDB output and see this text i will do another
>pass with MendDB, right?

You will answer all of your own questions if you read the article I linked
you to in the previous message.

It looks as if you also need to read Chapter 39 of The Firebird Book; or
at least acquaint yourself with what the IB 6 Opguide.pdf has to say about
gfix.

./heLen





++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Visit http://firebird.sourceforge.net and click the Resources item
on the main (top) menu. Try Knowledgebase and FAQ links !

Also search the knowledgebases at http://www.ibphoenix.com

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Yahoo! Groups Links








__________ NOD32 1.1185 (20050801) Information __________

This message was checked by NOD32 antivirus system.
http://www.eset.com