[NEW in 3.0]
The BACKUP DATABASE statement is used to create backup of a database. This command works for both LOCAL and Server-based databases.
BACKUP DATABASE [TO absolute_path] [WITH DIAGNOSE]
specifies the absolute path to folder where backup should be produced. If it is not specified then backup will be produced in the same folder where the database is located.
Valentina creates at the specified location the folder “Backup” if it not exists, then creates inside a folder with a timestamp name that contains files of backup database. Each backup produces one more folder with a timestamp name.
if specified then before backup will be executed diagnose database.
If diagnose fails then backup is not produced and error is returned. If this command is used in the shedule of Valentina Server then error go into log file.
- This command has the most sense to be used with CREATE EVENT command of Valentina Server.
- Backup can be used for Valentina Server non-stop. It locks database, do flush of cache, then copy disk files of database. This operation is as fast as SizeOfDatabase (Mb) / Speed of HDD read/write (MB).
* If your computer have another HDD and you have specify TO absolute_path point on this second HDD, then you can double speed of backup.
BACKUP DATABASE WITH DIAGNOSE