Questions tagged [sql-agent-job]

this tag is used to discuss about the issues are occurred when add or modify the job steps, schedules, alerts, and notifications of sql server agent jobs.

SQL Server Agent job can be create in SQL Server by using SQL Server Management Studio, Transact-SQL, or SQL Server Management Objects (SMO).

421 questions
6
votes
1 answer

Query to list the job names and step associated with a particular table

Is there any way to search and find ,what job holds a particular table refresh . There are multiple sql agent jobs with multiple steps.What is the sql query to search all jobs and locate the job name and steps? This is to identify the steps…
user1254579
  • 3,901
  • 21
  • 65
  • 104
6
votes
2 answers

How to Export data to Excel in SQL Server using SQL Jobs

I need to export the data from a particular table in my database to Excel files (.xls/.xlsx) that will be located into a shared folder into my network. Now the situation is like this - I need to use SQL SERVER Agent Jobs. 2.I need to generate a new…
Atanu Roy
  • 1,384
  • 2
  • 17
  • 29
6
votes
3 answers

The job failed. The job was invoked by user. The last step to run was step1

I have created SSIS package which is running successfully and dumping the data to the required place. But the same package results in the error when i run it through job. I googled n got these links but failed to get the way…
Teju MB
  • 1,333
  • 5
  • 20
  • 37
5
votes
1 answer

Error Executing SQL Server Agent Job: JSON text is not properly formatted, Unexpected character '"'

Using Microsoft SQL Server 2016 (RTM) Standard Edition, I am trying load a JSON into a SQL Server table using a SQL Server Agent Job, and get the following error: JSON text is not properly formatted. Unexpected character '"' is found at position…
Prospec007
  • 51
  • 1
  • 3
5
votes
1 answer

Create SQL Server Agent job for stored procedure with input parameter

Could you suggest please how to create SQL Server Agent job for a stored procedure that have 1 input parameter? The procedure is correctly created and i executed it using this code : EXECUTE dbo.MYProcedure N'2016-02-25'; Is there a way to create…
stoner
  • 417
  • 2
  • 12
  • 22
4
votes
1 answer

SQL Jobs Schedule to Not Run on Holidays

I have a SQL Agent Job that has multiple steps which are scheduled to run Monday - Friday at a certain time. I need to be able to implement a stop feature on this job to not run on Holidays that are listed in a table. I don't really know how to…
Taryn
  • 242,637
  • 56
  • 362
  • 405
4
votes
2 answers

SSIS Failed to acquire connection. Connection may not be configured correctly or you may not have the right permissions on this connection

I'm using MS SQL Server 2016. I have a SSIS package, with one execute SQL task. I can execute it fine with Visual Studio. When I deploy to the SSIS Catalog, I receive the below error: Execute SQL Task: Error: Failed to acquire connection.…
Michael
  • 2,507
  • 8
  • 35
  • 71
4
votes
3 answers

SSIS Package error- SSIS Error Code DTS_E_PROCESSINPUTFAILED

SSIS job has failed and posting the below error [Product Sales [749]] Error: An exception has occurred during data insertion, the message returned from the provider is: The given value of type String from the data source cannot be converted to type…
MSM
  • 327
  • 2
  • 6
  • 12
4
votes
5 answers

Error processing tabular model - From SQL Server Agent

We have a tabular cube, processing database (full) in SSMS works fine, but when processing from SQL server agent, throws following error.  
user5863509
  • 255
  • 1
  • 4
  • 16
4
votes
1 answer

Increase TEXT SIZE in SQL Server Agent

SQL Server Agent has a 512 characters limit on texts fields like nvarchar(max). I found this out after seeing my stored procedure is working correctly when I run it in SSMS but not working when is being run by a SQL Server job. To fix this I know I…
Bahman
  • 1,034
  • 12
  • 28
4
votes
1 answer

SSIS 2012 SQL Agent Job ConnectionString vs InitialCatalog

I was not able to find a resource discussing this from the SQL Agent and SSIS Catalog. I'm getting behavior that was unexpected when running a package from SQL Agent. I believe that the issue is that I specified a different InitialCatalog property…
Stephen Lloyd
  • 733
  • 8
  • 21
4
votes
7 answers

Why does my SQL agent job keep failing?

I have a SQL agent job that just runs a basic query on a schedule. It updates info based on the query shown. USE DB DECLARE @startDate AS DATETIME DECLARE @endDate AS DATETIME DECLARE @rcount AS VARCHAR(10) SET @startDate =…
BSanders
  • 295
  • 1
  • 6
  • 29
4
votes
2 answers

SQL Server Agent Jobs Log custom messages in Job History

Is it possible to log custom messages from your SQL Server Agent job in the job history messages? If not what's the best way to go about doing such a thing?
Tsukasa
  • 6,342
  • 16
  • 64
  • 96
4
votes
2 answers

Why is Sql Server Agent Job sending duplicate emails?

I have Sql Server Agent Jobs which send emails once a day, each of them containing one excel file. They are similar to each other in many ways; they complete the steps successfully, and have no problem with sp_send_dbmail procedure. USE msdb …
3
votes
1 answer

Custom dlls not found in SQL Server 2016 agent job

I have an ssis package in SQL Server 2016 which is using a custom dll that I have added in the gac. SSIS package works fine in visual studio but when I deploy it on SQL Server, it can not find the dll frm gac. Can anyone help me where to place that…
Usman
  • 73
  • 7
1
2
3
28 29