Hello mairlist gurus !
I’m trying to run an automated DB backup using a script. I got the script from this post : Clone Database (an old post which seems still valid). I just modified the target path to suit my needs.
I’m using the Professional studio version, i.e. with a PostGRE engine.
I’m getting this error message : error running script: [error] (16:4): invalid number of parameters.
Op de volgende manier maak ik een backup van de database in een draaiend systeem.
Uiteraard aanpassen aan jouw behoeften… doe er je voordeel mee…
Verberingen lees ik ook graag terug
@Echo Off
D:
CD
CD “D:\mAirlist DB”
for /f “tokens=2 delims==” %%a in (‘wmic OS Get localdatetime /value’) do set “dt=%%a”
set “YY=%dt:~2,2%” & set “YYYY=%dt:~0,4%” & set “MM=%dt:~4,2%” & set “DD=%dt:~6,2%”
set “HH=%dt:~8,2%” & set “Min=%dt:~10,2%” & set “Sec=%dt:~12,2%”
set “fullstamp=%DD%-%MM%-%YYYY%_%HH%.%Min%”
timeout /t 10 /nobreak
copy “mAirList DB.mldb” “mAirList DB.mldb.%fullstamp%.bu”
del “mAirList DB.mldb”
begin
CloneDatabase(
IDBConnection(Database(0)), // Connection
‘sqlite’, // TargetType
‘’, // Host, empty for sqlite
‘X:\RCM-backup.mldb’, // Database, or Filename for sqlite
‘’, // User, empty for sqlite
‘’, // Password, empty for sqlite
false, // Include icons?
true, // Include playlist?
0, // day from which to include playlists, 0 = all
true, // Include history?,
0, // day from which to include history, 0 = all
‘’, // new database ID, empty = use existing
nil // progress indicator, always use nil in scripts
);
end.