August 15, 2011 at 1:10 am
Is there any limit on the size of text in the t-sql step of agent job?
Currently i am looking at the tsql script of more than 21000 lines (yes its too big) and its been put into agent job as tsql step. Job is failing at this step. When i run the tsql in SSMS, it works fine.
Then it came to my mind may be there is a limit on text/characters that agent job can handle for execution. Can anyone please confirm or advise?
August 15, 2011 at 1:36 am
on researching, i found it is nvarchar(max)
http://msdn.microsoft.com/en-us/library/ms187358(v=SQL.90).aspx
i cant figure it out then why the step is failing? any suggestions??
August 15, 2011 at 5:04 am
Put the TSQL into a stored procedure and call the sproc from the job.
For fast, accurate and documented assistance in answering your questions, please read this article.
Understanding and using APPLY, (I) and (II) Paul White
Hidden RBAR: Triangular Joins / The "Numbers" or "Tally" Table: What it is and how it replaces a loop Jeff Moden
Viewing 3 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply