[firebase-br] SetReserveSpace

Paulo Geloramo paulogeloramo em terra.com.br
Seg Nov 8 14:17:02 -03 2004


Ola Pessao,

Usando:
Delphi 7
Firebird 1.5

O componente IBConfigService da pasta InterbaseAdmin tem
o metodo SetReserveSpace, qual a finalidade de reservar espaço?

Quando cria o banco de dados o padrao seria SetReserveSpace(True)?

Quando seria indicado o uso de SetReserveSpace(False)?

Este metodo tem alguma influencia sobre o Firebird ou
teria somente no Interbase?

The following example shows how to activate the database shadow, set the
async and access modes, and reserve disk space for versioning.  Note that
the SetReadOnly method is set to False in the beginning; this is to ensure
that the other parameters can be set, in case the database has been
previously set to read-only.  The call to the Windows API Sleep between each
method is to ensure that each service completes before going on to the next.

procedure TForm1.Button1Click(Sender: TObject);
begin
 with IBConfigService1 do
  begin
    ServerName := 'Poulet';
    LoginPrompt := False;
    Params.Add('user_name=SYSDBA');
    Params.Add('password=masterkey');
    DatabaseName := 'c:\interbase\tutorial\tutorial.gdb';
    Active := True;
    try
    SetReadOnly(False);
    while IsServiceRunning do Sleep(5);
    if CheckBox1.Checked then

      ActivateShadow;
    while IsServiceRunning do Sleep(5);
    if CheckBox2.Checked then
      SetAsyncMode(True);
    while IsServiceRunning do Sleep(5);
      if CheckBox3.Checked then
      SetReserveSpace(True);
    while IsServiceRunning do Sleep(5);
    if CheckBox4.Checked then
      SetReadonly(True);
    finally
      Active := False;
    end;

  end;
end;


[]s
Paulo Geloramo





Mais detalhes sobre a lista de discussão lista