Subject | Re: [firebird-support] gbak to a non existing directory |
---|---|
Author | Michael Ludwig |
Post date | 2012-06-06T12:25:44Z |
ma_golyo schrieb am 06.06.2012 um 11:45 (-0000):
https://www.google.com/search?q=eierlegende+Wollmilchsau&tbm=isch
Use the command-line processor:
D:\MiLu\RepoHgSvn\comp\win\http :: more restore.bat
@ECHO OFF
IF /I "%~x1" NEQ ".bak" GOTO:USAGE
IF /I "%~x2" NEQ ".gdb" GOTO:USAGE
IF "%3" NEQ "" GOTO:USAGE
IF NOT EXIST "%~dp2" md "%~dp2"
gbak -c "%1" "%~f2"
echo ==== "%~f2"
dir "%~f2"
GOTO:EOF
:USAGE
ECHO Usage: %0 path\to\my.bak path\to\my\restored.gdb >&2
REM -- Michael
> Running "gbak -c" does not create directories when not exists.Forcing won't help - GBAK is not an eierlegende Wollmilchsau.
> How can I force to create directories? I cannot find any gbak swith
> which can help.
https://www.google.com/search?q=eierlegende+Wollmilchsau&tbm=isch
Use the command-line processor:
D:\MiLu\RepoHgSvn\comp\win\http :: more restore.bat
@ECHO OFF
IF /I "%~x1" NEQ ".bak" GOTO:USAGE
IF /I "%~x2" NEQ ".gdb" GOTO:USAGE
IF "%3" NEQ "" GOTO:USAGE
IF NOT EXIST "%~dp2" md "%~dp2"
gbak -c "%1" "%~f2"
echo ==== "%~f2"
dir "%~f2"
GOTO:EOF
:USAGE
ECHO Usage: %0 path\to\my.bak path\to\my\restored.gdb >&2
REM -- Michael