.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
Gaurav Pal
Post New Web Links

Is it possible to stop a subscription from mailing if there is no data contained?

Posted By:      Posted Date: September 21, 2010    Points: 0   Category :Sql Server

I have got a report that mails everyday a set of raw data, I only have to mail the report if there is data in the report, is it possible to have a check inside the subscription to only email if the report has data?


I am running a SSRS 2005 Reporting Enviroment.\

Thanks in Advance


View Complete Post

More Related Resource Links

Data Security: Stop SQL Injection Attacks Before They Stop You


To execute a SQL injection attack, a hacker writes a Web page that captures text in a textbox to be used to execute a query against a database. The hacker enters a malformed SQL statement into the textbox that causes the back-end database to perform operations the owners did not intend it to perform, like making unauthorized updates. This article explains how you can protect against the all too common SQL injection attack in your own database. The steps covered include data validation, proper exception handing, and much more.

Paul Litwin

MSDN Magazine September 2004

Multivalued parameter & Data driven subscription for SSRS 2005

I need to create data driven subscription for our reports. Most our reports have multi valued parameters (7-12 parameters with at least 4-5 with multiple values)and need to be send to a users between the range of 25-200. So standard subscription is really not a choice.I have gone through most of the threads before. Question 1:Does any one have a solution for the SSRS 2005 regarding passing mutiple values for a parameter for the Data subscription table. If yes, could you please share the information. Question 2:I found some solutions using the SOAP API. Can any one explain that in detail- how we can do it ?Reference:http://social.msdn.microsoft.com/forums/en-US/sqlreportingservices/thread/8ab615b4-1373-4258-bf49-c2843cfea8e9/http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=516735&SiteID=1 Question 3:Here is the other solution I found in one of the postsApparently passing in values like {A, B, C} only works when you configure the parameter values not to come from a dataset so that SSRS doesnt check for ValidValues.Reference: http://social.msdn.microsoft.com/forums/en-US/sqlreportingservices/thread/b2c50aea-2032-4025-a155-306c00fcb856/Any commends about this solution?Thanks

SSRS Subscription Management: Restart, Stop, View Status, update properties, etc

As SSRS admins, there are times when a user comes to us and ask: I didn't get my reported emailed to me today?or worst, a report subscription going to multiple people doesn't run and now you have lots of people missing their subscription - (suppose server crashed, or something happened).One idea of course would be to have the subscription owner re-schedule it to run now, or create a new -- but - i'm thinking - we should create a subscription adminstration tool.a .net app that queries the ssrs web service, gets a list of subscriptions in the ssrs system (or perhaps by folder) and then is able to 'restart a subscription', "stop a running one", 'view all subscription status, schedule, owner, etc' if I wanted to d this - what is the web service that I could use this for?and most importanly - has anybody dont anything like this that they can share?this is for ssrs 2005 & and I'm hoping 2008 can be called through the same .net app tool

Problem with date values in data-driven subscription reports

Hello together, I have a question in regards of data-driven subscription report. I already have an ad-hoc report in place which can be customized by date etc. I now want to run these reports with a subscription. My challenge is now that I don't know how I can pre-define the date. I basically want the start date of NOW() and the end date 7 days in the past. I was looking around but did not get any clue where and how I have to configure it the way it works. I found this thread but honestly do not understand it well... :( http://social.msdn.microsoft.com/Forums/en-US/sqlreportingservices/thread/fb48fd15-09dd-4f5f-a09f-d92bf304c1a2 Can someone help me out please? M.

For a Data-driven Subscription, If it Processes 20 but 2 error , how do i just run the ones that err

 I'm trying to figure out if there is a way to just run the errored out ones.  Sometimes I have up to 100 being processed and need to only rerun the ones that error out. Is there a way to do this? and how?

how to stop refresing data grid when selection changed

Hi , I have datagrid on my page bounded with linq datasource. I want to stop refresing datagrid when I need to show details of selected row. Could you please help me to do that. Regards Reside 

Data Driven Subscription problem - sub runs slowly, has 40 errors out of 300, but report server trac

I have two report servers and a single separate SQL Server 2008 server hosting the data source database and the report server catalogues. There is a data driven subscription that runs off a sproc that returns 300 rows with email addresses for this report to be emailed to. The report itself contains around 30 subreports each with its own sproc to retrieve data. As the report is executing there are long pauses between the times when emails are actually sent out, and the subscription status will finally end with something like "Done: 300 processed of 300 total; 40 errors." I am not sure how to go about troubleshooting this problem. Details: I kicked it off at (say) 2:00 PM. Within 3 minutes in the report server execution log I saw 300 entries. There were exactly 300 people who should receive reports, so the master report should have executed 300 times and sent out 300 emails. So this looked good in the execution log. But when I checked report manager's status page for the subscription it was listed as processing 50 out of 300... Then all activity stopped, about 15 minutes some more reports started emailing out, and now I see there are around 590 rows in the execution log and maybe 97 emails sent out... Then finally I get a grand total of 846 rows in the execution log and a grand total of 260 of 300 emails sent out with 40 errors so 260+40=300 exactly. The time betw

How to pass multi-value parameters to DDS (data driven subscription)?

Using RS2005, how should multivalue parameters be stored in a database field so that a data driven subscription can properly read and use them?  I have so far had no luck using syntax of: 1)  parm1, parm2 2)  parm1,parm2 Do single qutoes need to explicitly wrap the values?  Can you please provide an example and a SQL INSERT statement using parm1 and parm2 to demonstrate what to store in the database field?  Thanks!!

SSRS data driven subscription with varying schedule


I've created a report hosted on SQL Server Reporting Services 2005. I know how to use the Reporting Services Web Services Class Library to create a timed subscription, so that a user can receive the report automatically every day.

Now I need to extend this to deliver the report to hundreds of users. That seems like an application for data driven subscriptions. I haven't worked with data driven subscriptions before. Here's what I'd like to know:

Within a single data driven subscription, can each recipient receive the report ON A DIFFERENT SCHEDULE? For example, user "A" wants to receive it every Tuesday at 9:00 AM, while user "B" wants it every day at 6:00 PM.

Thanks for your help.

- Steve

Error for delivering a report via email by using the data-driven subscription



I have created a SSRS 2005 report to export in the Excel format as a batch execution. I have made a data-driven subscription, I have specified the from mail address (with my address) and the smtp server in the RS configuration tool, I have set the SQL Server Agent account with my domain user, but I have an error about the from address is refused from the server and the client was not authenticated. I have tried to specify the IP for the smtp server.

Any suggests to me in order to solve this issue, please? Many thanks

The incoming tabular data stream (TDS) protocol stream is incorrect. The MARS TDS header contained e


Below error occured like 100 times today morning , have no clue where to start looking into.

Any ideas?




Exception of type 'System.Web.HttpUnhandledException' was thrown.


The incoming tabular data stream (TDS) protocol stream is incorrect. The MARS TDS header contained errors.


   at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection)

How to not send subscription report if no data

I have a report that may or may not have data. I have a subscription setup for this report. The subscription has a defined To list. I would like to NOT send the report if there is no data on the report. I did this in SQL 2000 by raising an error from the stored procedure if there was no data. However, that approach does not seem to work with 2005. Is there another way to accomplish this?

SSRS 2008 R2 data driven subscription failing



I have a SSRS report connecting to a SSAS cube. i have created a data driven subscription for two of the report parameters.

since its a ssas cube we have to pass the actual parameter value.

For ex: for parameter name PAR_ASM the value passed is &[23563]. This value works when i execute the report from reportserver using url parameter adding the following at the end &PAR_ASM=%26[23563]. But the same doesn't work when i do it from the subscription.

Also strange things is that this subscription was working on 2008, but after upgrading to 2008 R2 it started failing.

has anybody faced a similar issue?



How managing programatically a data-driven subscription



I need to create and edit a SSRS data-driven subscription inside a .NET application. Is it possible? Which objects or classer can I use?

Any helps to me, please? Thanks

About data-driven subscription



I want to execute my SSRS 2005 report as a scheduled batch. I think to create a data-driven subscription and a table to pass the report parameters. In this table could contains more one records. So, when I specify the query or the command in the subscription, the SELECT statement could reads more one records. I want that the behaviour the subrscription it to read all the records from the parameter table and execute the report each time for each record in the table. Is this the behaviour for the data-driven subscription for a parameter table with more one record?

Any helps to me, please? Thanks

Creating a data-driven subscription from a SSIS pkg



I would like to use a SSIS pkg to implement a data-driven subscription for a my SSRS 2005 report, by using the ReportingService2005.CreateSubscription Method. Is it possible? How? Is there a sample about this implementation?

Many thanks for your suggests

About Windows file share delivery for a data-driven subscription



In order to try the data-driven subscription with the windows file share delivery, on my machine I have created a folder and then I have shared it adding my Windows account with full-control. The UNC of my shared folder is like \\mymachine\mysharedfolder.

When the subscription starts I can see in the report server service log an error about the access to the shared folder on account or password isn't valid.

Now, how can I solve this issue, please? Do I change some settings in the config files of the report server? Many thanks

ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend