Sql Server Database Mail To Send RDL Report - tsql

Using Sql Server in my last job we had a stored procedure that passed the a reporting services report address and parameters and sent the report as pdf to an email address via database mail.
I've looked everywhere for instructions on how i can achieve this as i would like to set up an agent job that runs on a Thursday night that runs through a list of invoice numbers and email addresses and sends these reports via email to the address on the same row

The procedure you've been using is probably not part of sql server. AFAIK there is no such procedure that is commonly available.
the way it goes is usually to create a SSRS subscription (using report manager at http://yourserver/reports) where you set destination email and parameters. afterwards you trigger the subscription with the AddEvent procedure in the ReportServer db.
It gets a bit complicated when there are too many recipients to manage manually, and if you need to change the parameters often.
If you have sql server enterprise edition, you can setup and use data driven subscriptions. You will need a table that contains emails and parameter mappings.
If you don't have enterprise edition, then it's a bit complicated. I would suggest that you have a look at https://busyreports.codeplex.com/ or similar solutions.

Related

How to clear the data in a Power BI Report when publishing it to multiple clients via DevOps

We are building a generic Power BI Reporting suite for a product. Every time we commit the PBIX file to Source Control our DevOps project publishes the report to multiple workspaces, clears the SQL Connection, and reattaches it to the SQL database for each particular client. We then trigger a dataset refresh so that the report loads the data from it's own SQL database.
The problem is that the PBIX file committed to GIT contains the imported data from the LAST SQL data source it was connected to (usually our Dev SQL DB). Then when the report and dataset are published to each client the client will see this imported DEV data in their report for a period of 20 minutes or so until the dataset has refreshed, which is a security risk and confusing for the user.
I found this workaround using PowerQuery as an example, however I am really hoping for a more robust solution.
https://community.powerbi.com/t5/Desktop/Another-way-to-clear-fetched-data-from-PBIX-files/m-p/686627
How can we "clear" the imported data in the PBIX file so that when we publish to each client it is completely empty and just reloads that clients data?
Did you try a Powerbi API?
https://learn.microsoft.com/en-us/rest/api/power-bi/pushdatasets/datasets_deleterows
The ideal situation would be to be able to publish pbit instead of pbix (which contains data). Unfortunately, this is not allowed. If you can, vote for this or a similar idea.
https://ideas.powerbi.com/ideas/idea/?ideaid=b8928e24-3a1a-4a21-89d0-29fab9454a3c

TABLEAU FILTERS AND SERVERS

There is an automated report on Tableau server set to run each business day. When we open the report, the filters are still present, but there are no results (no data, no viz). There are also no errors. What are some of the possible explanations for why there would not be data present in the report? How to Describe to check for each possible explanation?
2.Tableau reports that connect to multiple servers. Assume that one of the servers went down, it’s unclear when it will be back online, and that this server is the most widely used data source. What to do immediately to minimize the impact on business customers?
You are lucky that question is not closed normally these type of questions are not entertained in SO
There are no errors and no data
Since filters are present in reports possible reason would be filters are active on the report are not fetching any data to report hence you are getting blank report and no errors. For E.g if you run the report for emp ID 100 and there is no emp id with number 100 then no data is fetched from database and report will be black.
So possible debug way would be check the applied filters and check in database if there is any data for those filters and if database access is not provided then provided different values for the same report and check data.
one of the servers went down, it’s unclear when it will be back online
Normally in a live scenario there will be back up servers when primary server is down you need to connect to the back server and minimize the impact and check for the solution for primary server to back online ASAP

Display and Upload files MS access with SQL Server backend

I'm responsible for an internal ticketing system used to initiate work for our team. I've finished converting the MS Access database into SQL Server 2008 R2 but I'm hung up on the attachment functionality that was previously handled in Access.
Does anyone have any code samples that display a list of files (from SQL Server) where user can click and view? The user should be able to upload new attachments to the varbinary(max) column.
Thanks!
Paul

database delivery option for subscribed ssrs reports

I have a reports which is taking 20 minutes to run .I want to make it as subscribed ssrs report.I have seen that in SSRS the delivery options are email and fileshare but I want the report to be saved in DB directly.Is there a way of inserting the report in DB.
You can schedule a snapshot based on parameters to be rendered. If your report follows a model that allows it to be subscribed to with parameters similar to the snapshot then you can create a batch type process. This works if your users are not expecting real-time data.
For example:
Early in the morning create a snapshot.
Email cached version based on similar parameters.
Hope this helps.

SSRS 2008 R2 - Distribution Slow

We have an SSRS Report with a subscription. The report gets emailed out to 400+ users once a week. We run a query to get the list of emails to send it to.
Originally, we ran this report for each user and then email it out, even though the report was the same for each user. It took over 5 hours to send out all of the reports.
We now changed the report to cache first and then send the report out to all of the emails in the list.
It now distributes the report in just over an 1 hr.. I think this is still slow, but maybe I am wrong. I'm thinking this is something that should take minutes to run, not hours.
The report varies in size from 250 kb to 750 kb.
I have another report that does something similiar, but for only 8 reports, but every report is different for each user. This all happens almost instantly. Not sure what the difference is.
Any suggestions on where to look to figure out why this takes so long. Is there something built into SSRS to slow down the distribution or delay it?
Nothing built into SSRS that should slow this down. I'd take a look at the connection between your SQL server and the SMTP server that SSRS is using. I suspect the problem is the data in the email, usually as an attachment, and simply getting that data to the SMTP server.
Also, you can set this up to send one email to multiple users or send an email to each user individually: Have you considered the one email approach?