OK Jiri, you are right, I didn't give any clue about the error.
I'm trying to restore the database on top of the original. I suppouse that with
the option Replace | Create, the original will be overwrited, but it should not
be the case. Then I tryed to Shutdown the database, but I've got the same error.
Steps to try Database Restoring:
FirebirdSql.Data.Services.FbRestore restoreSvc = new
FirebirdSql.Data.Services.FbRestore();
restoreSvc.ConnectionString = "character set=WIN1252;password=masterkey;initial
catalog=MyAlias;user id=SYSDBA;data source=localhost";
restoreSvc.BackupFiles.Add(new FirebirdSql.Data.Services.FbBackupFile(BAKFile,
2048));
restoreSvc.Verbose = true;
restoreSvc.PageSize = 8192;
restoreSvc.Options = Opciones; // Opciones = Replace | Create
restoreSvc.ServiceOutput += new
FirebirdSql.Data.Services.ServiceOutputEventHandler(ServiceOutput);
try
{
restoreSvc.Execute()
...
and then, I get the exception:
Se produjo una excepción de tipo 'FirebirdSql.Data.Common.IscException'.
en FirebirdSql.Data.Client.Gds.GdsConnection.ReadStatusVector()
en FirebirdSql.Data.Client.Gds.GdsConnection.ReadResponse()
en
FirebirdSql.Data.Client.Gds.GdsServiceManager.Query(ServiceParameterBuffer spb,
Int32 requestLength, Byte[] requestBuffer, Int32 bufferLength, Byte[] buffer)
en FirebirdSql.Data.Services.FbService.QueryService(Byte[] items)
en FirebirdSql.Data.Services.FbService.GetNextLine()
en FirebirdSql.Data.Services.FbService.ProcessServiceOutput()
en FirebirdSql.Data.Services.FbRestore.Execute()
en Excatrans.DataModule.RestauraCopia(String Fichero, FbRestoreFlags
Opciones, ListBox lbox)
I 've also tried :
...
restoreSvc.ServiceOutput += new
FirebirdSql.Data.Services.ServiceOutputEventHandler(ServiceOutput);
FirebirdSql.Data.Services.FbConfiguration fbc = new
FirebirdSql.Data.Services.FbConfiguration();
fbc.ConnectionString = restoreSvc.ConnectionString;
try
{
fbc.DatabaseShutdown(FirebirdSql.Data.Services.FbShutdownMode.Forced, 0);
restoreSvc.Execute();
fbc.DatabaseOnline();
...
but I get the same error
I hope this was helpfull.
Thanks a lot
Marcial
----- Mensaje original ----
De: Jiri Cincura <[EMAIL PROTECTED]>
Para: For users and developers of the Firebird .NET providers
<[email protected]>
Enviado: viernes, 18 de abril, 2008 15:54:34
Asunto: Re: [Firebird-net-provider] Restore database
On 4/18/08, Marcial Gonzalez <[EMAIL PROTECTED]> wrote:
> Is there any way for restoring a database just using the alias? That's for
> an application that don't know about the actual location of the database.
Yes.
> When I try to restore the database, I get an error.
And the error is ...?
--
Jiri {x2} Cincura (CTO x2develop.com)
http://blog.vyvojar.cz/jirka/ | http://www.ID3renamer.com
-------------------------------------------------------------------------
This SF.net email is sponsored by the 2008 JavaOne(SM) Conference
Don't miss this year's exciting event. There's still time to save $100.
Use priority code J8TL2D2.
http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone
_______________________________________________
Firebird-net-provider mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/firebird-net-provider
______________________________________________
Enviado desde Correo Yahoo! La bandeja de entrada más inteligente.-------------------------------------------------------------------------
This SF.net email is sponsored by the 2008 JavaOne(SM) Conference
Don't miss this year's exciting event. There's still time to save $100.
Use priority code J8TL2D2.
http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone
_______________________________________________
Firebird-net-provider mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/firebird-net-provider