November 21, 2011 at 9:31 am
I have a SQL step that I have checked off output to log file, but it doesn't output any of the print commands I have in the step. I just get:
Job 'Copy data from Staging' : Step 1, 'check table counts and date field in Staging tables' : Began Executing 2011-11-21 07:00:00
Msg 18054, Sev 16, State 1, Line 22 : Error 50010, severity 10, state 1 was raised, but no message with that error number was found in sys.messages. If error is larger than 50000, make sure the user-defined message is added using sp_addmessage. [SQLSTATE 42000]
Partial code
DECLARE @cnt int
DECLARE @name varchar(50)
DECLARE @todaysdate datetime
set @todaysdate = convert (varchar(10), getdate(), 101)
SELECT @cnt = COUNT(*) FROM equipdata
print 'equipdata count'
print @cnt
November 21, 2011 at 9:35 am
November 21, 2011 at 9:52 am
Output to file does not work?
November 21, 2011 at 9:53 am
I need way more details than that to help you.
November 21, 2011 at 11:30 am
I'm attaching a screenshot of what I have selected and filled in.
So, basically, I need to log to a table in addition to log to a file to get all the details?
November 21, 2011 at 11:39 am
I've always checked all 3 fields.
It gives me both the .txt document and a way to do a select to do more complexe filtering.
I'm not 100% sure of the "best" way to do this. Sinec this logs 1 mb of data / month, I didn't bother with more research.
November 22, 2011 at 7:34 am
This morning, the job actually did output completely to the file. That job was scripted from an SQL 2005 system. Maybe because I went into the step and hit ok, that "activated" it?
November 22, 2011 at 7:36 am
No idea, glad it's working now ;-).
Viewing 8 posts - 1 through 7 (of 7 total)
You must be logged in to reply to this topic. Login to reply