sql.conditionFetch=select job_config_id, job_params,job_input_pattern,coalesce(last_run_timestamp,now() - interval 10 year) as last_run_timestamp,job_addl_criteria,coalesce(job_min_file_count,0) as job_min_file_count from edbaconfig.aggrjobconfiguration where last_exec_status is null or last_exec_status <> 'RUNNING' sql.jobInputFilesMinTSAndCount = select count(file_url) as file_count,min(last_validated_timestamp) as min_lvt from edbaconfig.ingestedfilestatus where sql.updateJobConfigStatus=update edbaconfig.aggrjobconfiguration set last_exec_stepid=?,last_exec_status='RUNNING',last_run_timestamp=current_timestamp where job_config_id=? sql.updateSubmittedJobsJSON=update ingestedfilestatus set submitted_jobs = case when json_contains(submitted_jobs,json_array('?')) is null then json_array('?') when json_contains(submitted_jobs,json_array('?')) = 0 then json_merge(submitted_jobs,json_array('?')) else submitted_jobs end where sql.updateStepStatus=update edbaconfig.aggrjobconfiguration set last_exec_status=? where job_config_id=? sql.retrieveOpenSteps=select job_config_id, substr(last_exec_stepid,1,locate(':',last_exec_stepid)-1) as cluster_id,substr(last_exec_stepid,locate(':',last_exec_stepid)+1) as step_id from edbaconfig.aggrjobconfiguration where last_exec_stepid is not null and last_exec_status = 'RUNNING' sql.auditValidatedFile=insert into edbaconfig.ingestedfilestatus (file_url, submitted_jobs,last_update_status, last_validated_timestamp) VALUES(?,null,?,current_timestamp) ON DUPLICATE KEY UPDATE last_update_status = ? , submitted_jobs=null,last_validated_timestamp=current_timestamp edba.cluster.tag.key=edba edba.cluster.tag.value=true url=jdbc:mysql://<>:3306/<> user=<> password=<>