Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
?
Solved

Subscriptions in SQL Reporting Services

Posted on 2007-07-23
2
Medium Priority
?
649 Views
Last Modified: 2012-08-14
Hello

I am new to SQL Server Reporting Services and i need to accomplish the following:

Email a report via subscription on the 1st of every month that would send the details of last month's report.

Example - Medical records to be sent out on 1st of August that would report on the details on the previous month (July).

Hope you can help.
0
Comment
Question by:SigmundFraud
2 Comments
 
LVL 1

Accepted Solution

by:
jantje_20 earned 200 total points
ID: 19547201
look here how to create a subscription that runs every first day of the month: http://technet.microsoft.com/en-us/library/bb283186.aspx
change the query in your report to something like this:
select *
from table
where date between dateadd(m,-1,getdate()) and dateadd(d,-1,getdate())

this query selects all data where de date-field "date" lies between yesterday and a month earlier
0
 

Author Comment

by:SigmundFraud
ID: 19548359
Works great.

Thanks for the swift reply.
0

Featured Post

Get expert help—faster!

Need expert help—fast? Use the Help Bell for personalized assistance getting answers to your important questions.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When trying to connect from SSMS v17.x to a SQL Server Integration Services 2016 instance or previous version, you get the error “Connecting to the Integration Services service on the computer failed with the following error: 'The specified service …
Microsoft provides a rich set of technologies for High Availability and Disaster Recovery solutions.
This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.
Viewers will learn how to use the SELECT statement in SQL to return specific rows and columns, with various degrees of sorting and limits in place.

571 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question