rs.exe to update a shared schedule?
sql version: sql server 2008
Is it possible to create a .rss file to update a shared schedule and then call that .rss from rs.exe? I thought I read all the web services could be called doing this. I have successfully called other methods such as rs.FlushCache(), rs.LoadReport()
and rs.Render doing this with no problem. However, when I try to call rs.SetScheduleProperties I get an error saying this method is not a member of Microsoft.SqlServer.ReportingServices2005.Execution.ReportExecutionService.
Here's my .rss implementation:
Public Sub Main()
rs.Credentials = System.Net.CredentialCache.DefaultCredentials
Dim _scheduleName as String = ScheduleName
Dim _scheduleID as String = ScheduleID
Dim _scheduleDefinition As String = "<ScheduleDefinition><StartDateTime>20011-11-10T09:01:02-08:09</StartDateTime><WeeklyRecurrence><WeeksInterval>1</WeeksInterval><DaysOfWeek><Monday>True</Monday></DaysOfWeek></WeeklyRecurrence></ScheduleDefinition>"
rs.SetScheduleProperties(_scheduleName, _scheduleID, _scheduleDefinition)
End Sub Main
Here's my .bat i'm calling it with:
set serverURL=http://HidingMyIPAddress/ReportServer_CMAPSQL1
set environment=UAT
set scheduleName=EQUITY_PERFORMANCE_REFRESH_UAT
set scheduleID=C94C2F25-9C71-4DC6-A022-93DACF48851E
rs -i UPDATE_SHARED_SCHEDULE.rss -s %serverURL% -e Exec2005 -v ScheduleName="%scheduleName%" -v ScheduleID="%scheduleID%"
I know I can not use rs.exe and instead actually make the webservice call. However, I want to know if I can accomplish it this way. Thank you in advance for any help on this.
November 9th, 2011 6:37pm
The SetScheduleProperties API exists on the Management endpoint, not the Execution endpoint. Try specifying Mgmt2005 on the -e option:
rs -i UPDATE_SHARED_SCHEDULE.rss -s %serverURL% -e
Mgmt2005 -v ScheduleName="%scheduleName%" -v ScheduleID="%scheduleID%"
Free Windows Admin Tool Kit Click here and download it now
November 9th, 2011 8:10pm