Make sure to have your cron-entry in a global startup method and you're all set. Something like this:
http://www.servoymagazine.com/home/2007 ... tho_1.html
Looks like Robert will be attending the ServoyWorld Batchprocessors session ;-)
Isn't that that single, very intense, 1:1 session against that ridicule rateLooks like Robert will be attending the ServoyWorld Batchprocessors session
jaleman wrote:Looks like Robert will be attending the ServoyWorld Batchprocessors session
var jobname = "backup"
var cronTimings = "* 00 22 * * ?"
var startDate = new Date()
var endDate = new Date(startDate.getFullYear()+50,startDate.getMonth(),startDate.getDate())
var args = new Array(directory_postgres,directory_for_backup)
plugins.scheduler.addCronJob(jobname, cronTimings, globals.Backup_DB,startDate,endDate,args)
var directory_postgres = arguments[0]
var directory_for_backup= arguments[1]
//Returns the name of the operating system
var osname = application.getOSName();
if(osname.indexOf("Windows",0)>-1){
var file = plugins.file.convertToJSFile(directory_postgres +"/vacuumdb.exe")
if(file.exists())
application.executeProgram(directory_postgres +"/vacuumdb.exe","-h","localhost","-p","5432","-U","postgres","-d","sopavet")
var file = plugins.file.convertToJSFile(directory_postgres +"/reindexdb.exe")
if(file.exists())
application.executeProgram(directory_postgres +"/reindexdb.exe","-h","localhost","-p","5432","-U","postgres","-d","sopavet"
var file = plugins.file.convertToJSFile(directory_postgres +"/pg_dump.exe")
if(file.exists())
application.executeProgram(directory_postgres +"/pg_dump.exe","-i","-h","localhost","-p","5432","-U","postgres","-F","t","-f","\""directory_for_backup+"/database_save.backup\"","sopavet"
}
But doesn't the cost of one client weight up to the ease of use (as you said yourself)?but I didn't know that batch process use one client license .So I have to find another way to backup my database.
But doesn't the cost of one client weight up to the ease of use (as you said yourself)?
Users browsing this forum: No registered users and 7 guests