Questions tagged [jobs]

A scheduled task managed by the database, for example using SQL Server Agent, Oracle dbms_job, or MySQL Event Scheduler.

Filter by
Sorted by
Tagged with
0
votes
0answers
23 views

Aborting long running query under AG configuration [duplicate]

Currently we have a process where any query running over 2 mins (only select) in primary database participating in db mirroring is killed, running every 5 mins. As we have moved to Availability groups ...
0
votes
1answer
39 views

Schedule suggestion and index rebuild / database integrity progress for Ola Hallengren’s Maintenance Script

I have to configure Ola Hallengren's Maintenance Scripts for my SQL Server 2017. SQL Database size about total 400GB.Total 10 Dbs. But I have some questions. 1- I will use these schedules like below. ...
1
vote
1answer
22 views

Installing SSIS package outside of SSIDB catalog

I'm trying to simplify deployment of SSIS package to a remote server. At the moment, I have Local Visual Studio SSDT and SSIS package that has 4 connection managers - DEV environment Remote server ...
0
votes
1answer
51 views

Index automation job script

Our Production instance is running SQL Server 2014. There needs to be an automated Index defragmentation job that will either reorganize or rebuild the indexes based on the fragmentation level for a ...
0
votes
1answer
36 views

Why a job of dbms_job is BROKEN

I have Oracle job that uses dbms_job package. I see that it becomes BROKEN: Select job,what,BROKEN from dba_jobs; -------- ------------ ----------- 1 statspack.snap; Y I would like to know the ...
1
vote
0answers
27 views

Oracle Scheduler Job - Exporting of CSV File every 16:01

I have already executed the code for scheduler. However, I have a problem whenever I execute my scheduler. Can someone help me with this? I'll appreciate all your response. My procedure code: create ...
0
votes
3answers
67 views

SQL Server Agent & sp_send_dbmail failing on permissions

I have set up a SQL Server Agent job to call sp_send_dbmail with a very simple select on a certain table in a certain database. Within the properties > permissions of the target database, the ...
0
votes
0answers
66 views

How to reset failures count to zero when using dbms_jobs?

Is there some way to reset the failure count column to 0 in dba_jobs view? Sometimes a job fail and after fix it I need to wait the next scheduled execution, during this time I'd like to reset to 0 to ...
0
votes
0answers
30 views

Can't connect Oracle 11g2 Database to Job Scheduler Agent on client/application server

Running 11g2 database on one Linux server and installed Oracle client and job scheduler agent on separate Linux (application) server sitting next to it. The connection betweeen them worked fine for ...
1
vote
1answer
45 views

Target server is not communicating(polling) with master SQL Server

We set up multi-server administration to create a job on the master which are executed on target servers, and we had this issue because the target server was shut down after a virus attack and we set ...
-1
votes
2answers
49 views

Rebuild Indexes [duplicate]

We have a database named WSS_Us_App in our Production SQL Server 2014. In this database all of the indexes need to be rebuilt as most have a fragmentation level greater than 50%. I plan to rebuild ...
2
votes
1answer
118 views

Can't take backup to the shared folder

Need your help. My sql job is not able to take backup to the shared folder although the domain account, under which the sql agent service account is running, has full permission on that shared folder. ...
1
vote
2answers
48 views

SQL SERVER Detailed Backup Report

I need to create a script that gives the report for the following information: Backup Job Name Databases that have been backed up in the last 24 hours Size of each DB backup Start time of backup End ...
4
votes
3answers
210 views

How to prevent parallel running of SQL Agent jobs

What would be good ways to design a group of jobs such that they can never run at the same time? I am looking for a generic concept, like a semaphore, which makes it easier to ensure that some jobs ...
0
votes
0answers
50 views

Oracle 12cR2 / ORA-02800 ORA-06512

When we run database jobs, we get the following error: ORA-02800: Requests timed out ORA-06512: at "SYS.DBMS_ISCHED", line 209 ORA-06512: at "SYS.DBMS_SCHEDULER", line 594 For 12 ...
2
votes
1answer
42 views

Job management: How to get the next running date by querying MSDB

Table sysjobschedules contains 2 columns next_run_date and next_run_time. With the help of sysschedules and column enable it should be easy to determine the next running date/time of a specific job. ...
0
votes
2answers
183 views

Maximum Error Count Reached

I created a maintenance plan to backup all the databases locally on a folder in E Drive. Out of nowhere, the job is failing occasionally. sometimes the job runs successfully and sometimes sends an ...
2
votes
0answers
156 views

PowerShell Script Not Working on SQL Server Job Step

I've some .CSV files generated in a shared folder \\SERVER01\DIR\Current and would like to copy to another folder in same server \\SERVER01\DIR\Archive. The script needs to copy, rename files adding ...
0
votes
1answer
30 views

Report server scheduled job location

I inherited a SQL Server environment. In (database engine) SQL Server Agent are two jobs defined that apparently belong to the report server. First and only step in the first job: exec [ReportServer]....
0
votes
1answer
110 views

sp_update_schedule says @schedule_id does not exist

I wrote a script that reads job schedules from msdb.dbo.sysschedules and runs sp_update_schedule to change the active_start_time for a given subset of jobs. In each case, sp_update_schedule fails with ...
-1
votes
2answers
128 views

Why would a scheduled job fail in SQL Developer?

I am trying to create a scheduled job in Oracle SQL Developer that would run once a month and I am testing the Scheduler/Jobs feature where I have created a simple SQL query to test the ability to do ...
1
vote
2answers
30 views

Schedule Job to Start at Different Steps

I am working on a system that generates a number of recurring emails as parts of various jobs scheduled in SQL Server Agent. The emails contain text-based reports that are loosely associated to the ...
0
votes
0answers
37 views

Syntax error in adding a job step in Azure SQL Job Agent

I am inserting a job step in Azure Elastic job agent. This is my code: EXEC jobs.sp_add_jobstep @job_name='Sample T-SQL', @command=N' declare @columns varchar(max) select @columns = stuff(( select '],[...
1
vote
1answer
149 views

Scheduling a procedure with DBMS_SCHEDULER. PLS-00103: Encountered the symbol “NULL” when expecting one of the following: ;

I can't schedule a job to run. I made a procedure that writes CSV files and it works when I execute it. Then I tried to make a job to schedule it: BEGIN DBMS_SCHEDULER.CREATE_JOB ( job_name =>...
0
votes
0answers
337 views

PLS-00306: wrong number or types of arguments in call to 'CREATE_JOB'

BEGIN DBMS_SCHEDULER.CREATE_JOB( job_name => 'DELETE_TEXT_TEST_LOG', job_type => 'STORED_PROCEDURE', job_action => '"DEV"."DELETE_TEXT_TEST_LOG"...
0
votes
2answers
257 views

Grant an AD Group permission to edit all MSSQL Agent jobs

We have a team of people, we all log in MSSQL Server from SSMS using our Active Directory accounts, by Windows Authentication. Our AD accounts are added to an AD group, which is used to grant all ...
1
vote
1answer
42 views

How to find the sql jobs that have not run for more than two months?

I would like to get a query to ascertain which sql jobs have not run for more than 60 days?
0
votes
1answer
20 views

Oracle 11g - Database Job About User Lock

I have an Oracle database (Oracle 11gR2) and I want to create a job. The job will trigger my procedure. The procedure must comply with the rules I have specified below: If a user's expiry_date value ...
-3
votes
1answer
139 views

SQL Server Integrity Check error

I’ve Implemented Ola's SQL Server Integrity Check on one of my SQL 2012 Servers and created a SQL Agent job to run it. The job fails every time I run it, but when I run the code below manually it ...
0
votes
0answers
38 views

Oracle Enterprise Manager 13c - query used in metric

I got task - "send me the query used in this metric?" It is related to Job with status "FAILED". I find this failed Job but can't find with which query this metric detect this ...
0
votes
1answer
28 views

How to Capture Job Exit Code?

I'm essentially trying to find a better way to determine if my job has completed successfully before moving on to another call of the same job. I have multiple jobs which run through a parsing process ...
0
votes
1answer
66 views

Chaining remote SQL Server Agent Jobs with success/failure feedback

I have 2 Microsoft SQL Server 2014 (SP3-CU4) instances, residing on different servers. ServerA has a linked server, pointing to ServerB\InstanceB. Both instances have a job, and JobA triggers the ...
0
votes
0answers
114 views

gMSA for running a sql agent job

I've had the question if it's possible to add a gMSA-account to the SQL-logins in order to let it perform a certain SQL Agent Job. I know it's possible to add a gMSA as a login but it will probably ...
0
votes
2answers
1k views

ORA-01658: unable to create INITIAL extent for segment in tablespace SYSAUX; JOB_SCHEDULER is biggest occupant

DBMS_SCHEDULER is occupying all of my SYSAUX tablespace. I ran dbms_scheduler.purge_log which deleted 100 million rows from dba_scheduler_job_run_details, however v$sysaux_occupants and the data file ...
-1
votes
1answer
39 views

SQL Job runs without it schedule and renaming or deleting it causes other jobs fail

I recently migrated the SQL 2008 to SQL Server 2016. I started noticing a strange issue where one of the SQL Job is causing the failure of other jobs. This job is disabled and there is no schedule and ...
0
votes
0answers
234 views

CDC capture Job Step-2 is not running when enabling CDC on table in SQL Server and Change table is empty

My Database has CDC enabled and the table i want to track changes using the below T-SQL, EXEC sys.sp_cdc_enable_db; GO EXEC sys.sp_cdc_enable_table @source_schema = N'dbo', @source_name = N'...
1
vote
1answer
23 views

Backup with date to azure blob storage url

Im trying to do backups to an azure blob storage that have the date when the backup is made, that way the job does not fail when the backup is generated with the same name, I am concatenating convert(...
1
vote
2answers
133 views

How to clear SQL Agent Job Scheduler Cache

I have to submit tickets to alter job scheduling, so rather than a walk through of the GUI I try to update msdb..sysschedules via tsql script. I always see the alterations immediately via the GUI. ...
0
votes
1answer
385 views

SQL Server Management Studio Error Access Denied Editing Job Step

I recently changed the owner of a job from my user to sa. After the ownership change I am able to edit the Schedules and Notifications for the job. However all attempts to to create New, Insert, Edit, ...
0
votes
2answers
2k views

Execute sp_update_jobstep to change SQL Agent job step type

As I was going to deploy a change to our Ola Hallengren indexing scripts, I noticed on some SQL Servers we have indexing job running as an "Operating System (CmdExec)" step instead of being called as ...
1
vote
2answers
115 views

Is it better to have one instance of a continuously running agent job or to fire off the job multiple times throughout the day?

I have a SQL query I need to run every second for about 12 hours a day. It's a pretty simple query that logs some data to an isolated table. Right now I've been leaving it running in my local SSMS ...
0
votes
1answer
44 views

Scheduled Job Does not work in oracle SQL*PLUS

I am just a beginner in Oracle and can't seem to get this job running :- I want to delete old rows from my database. And created a job as follows :- CREATE OR REPLACE PROCEDURE delete_trips AS ...
2
votes
1answer
183 views

begin tran instead of use db_name inside a SQL Job for executing Stored Procedure

I was defining a SQL job yesterday for executing stored procedure at a specific time in the morning. It was an ad-hoc and urgent requirement and hence I developed this procedure on the fly and ...
0
votes
1answer
418 views

SQL Agent using domain user for Jobs with TSQL

I have tried every option but i still cant find out why my sql agent is using a domain user when executing job steps with TSQL and keep getting the following error: Executed as user: RESOURCE\...
2
votes
1answer
565 views

Linked Server Timeout - Not Queried

I have a job that runs for multiple regions across the globe. Depending on what region is running and what time zone it's in, the job might not run. It uses GOTO to get to the end and reports that it ...
1
vote
2answers
136 views

Is it possible to query for the job schedule description?

Working on putting together a script to analyze all of the active jobs and I have nearly everything I need, but if possible I would like to be able to query for the schedules description as well. Is ...
1
vote
2answers
84 views

Find jobs that succeeded, but had steps that failed

Is it possible to find jobs that succeeded, but that had steps that failed like the desired output shows? I'm new to this side of development and I'm not sure about all of the system tables, etc. If ...
0
votes
3answers
1k views

Oracle 12c and Jobs running one hour apart after changing time for hourly use

I have an Oracle 12c database in which I have detected that the scheduled jobs are running one hour apart after the change of time on the server, checking in the database I see that the SYSTIMESTAMP ...
1
vote
0answers
97 views

Why is failed job not logged in SQL Server Agent Error Log?

I have a failed job which is logged in SQL Server Logs but not logged in SQL Server Agent Error Logs. The job is executed as user: NT SERVICE\SQLSERVERAGENT. Limit size of job history and Remove agent ...
0
votes
1answer
120 views

Toad for Oracle: Procedures, Packages, Job, and DBMS_SCHEDULER

If I have about 10 queries which contain subqueries, would it be a best practice to contain all of them in one procedure? This script creates a small fraction of the data required for a report. DROP ...

1
2 3 4 5
8