declare @cmd as varchar(4000)
set @cmd =
'
select count(ID)FA00100_count from test1
go
select count(ID) IV40400_Count from test3
go
select count(ID)POP10100_count from test4
'
exec master.dbo.spSQLSMTPMail @vcTo = 'test@test.net', @vcSubject = 'Record Count',@vcQuery = @cmd
when i try to do this it gives me error saying that
Server: Msg 105, Level 15, State 1, Line 3
Unclosed quotation mark before the character string ''select count
how can i solve this
set @cmd =
'
select count(ID)FA00100_count from test1
go
select count(ID) IV40400_Count from test3
go
select count(ID)POP10100_count from test4
'
exec master.dbo.spSQLSMTPMail @vcTo = 'test@test.net', @vcSubject = 'Record Count',@vcQuery = @cmd
when i try to do this it gives me error saying that
Server: Msg 105, Level 15, State 1, Line 3
Unclosed quotation mark before the character string ''select count
how can i solve this