Dynamically Change Image Source in SSRS Report based on Field Value - sql-server

We have images stored in a SQL database that are displayed on a SSRS report - but after 90 days, the images are uploaded to Azure/AWS and deleted from the database itself.
Is there a way to dynamically load the image based on whether or not the image exists in the database? And if it no longer does exist in the database, look to the Azure/AWS site to load the image in the report?
Within Visual Studio / SSDT, I do not see an option to dynamically set the image to load based upon a field that I would be able to create in the dataset.
I am not sure if this is even possible, and if so, I have not been able to figure out how to accomplish this task. Would anyone have any experience in this area they could offer?

Related

Inconsistencies with report layout in SSRS 2016

Using SSRS, I am creating a report that will show some payroll information. The desired layout is to have one page consist of a single employee's information for a single paycheck. It seemed to me that having a List and putting rectangles in it was the best way.
The problem is that I want black borders on each rectangle/text box, and they are appearing inconsistent. In Design/Preview mode in Visual Studio, it looks just how I would like. However, when I deploy to the server, it does not. Thoughts?
This is how it looks in the Design/Preview mode in VS
This is how it looks when deployed to the server. Notice the type and check date fields have space between them as well as the Job Class and Empl. Type fields, and the Printed field has grown vertically a little. NOTE: This is mock data
You need go to the Build-->select your Project and click on deployment the changes which were made by you will reflect in the SSRS Report.

sql data base with pictures

I'm working on a SQL server database and I need to have pictures
its for a catalog and most pictures are 1-4 mbs I don't thing embedding the pictures in SQL will be a good idea
what the best solution
till now I used to use access
I would really like to make a wpf form
but when I make a data source I don't understand exactly how linked images work
my main point is that I need it to run really quick and print out a catalog with inventory info each day for thousands of items
I'm looking for a form to manage it
I have tried an access form but access doesn't handle good the linked pictures
Just store the path to the image in the database.
Or, if using SQL 2008 or higher, there is also a new table called FileTable that stores data in the file system directly.
http://msdn.microsoft.com/es-es/library/ff929144.aspx
"I need it to run really quick" If speed is a must, Access might not be a good choice for this.. You should use a more professional RDBMS, IMHO.
If this is a hobby project I'd suggest using sqlserver express (I assume you have microsoft knowledge) and either storing a link to an image on the file system/web server or storing the object in the db. For small data volumes either way is likely to perform fairly well.
It is all very easy in MS Access 2010, just bind an image control to a table of paths. For example, my table is called Pictures, with the following entries.
PicturePath
Z:\Users\Fionnuala\Pictures\abc.png
Z:\Users\Fionnuala\Pictures\abc.jpg
I now just need an image control on a report bound to the table Pictures with a control source set to PicturePath, the images will be displayed.

How to display RDL report in WPF for user to edit and save

we have a large number of existing reports (.rdl files), the business need is to enable business users to change the text on those report directly, they don't have report designer of any sort.
So requirement is to create a WPF app, that will allow user to browse to one of those reports, display them in readable format (not as xml but formatted similar to what the real report looks like, as if they are opened in the designer), and then allow user to update the text (essentially the contents inside those tags), and save the report. so when it's ran it'll reflect those title, heading, text etc. changes.
Did some research there are something like ReportViewer, Syncfusion reportviewer that can take care of displaying part in WPF, but none of them seems to allow user to edit and save.
Are there any suggestions on what are the options to achieve this? I am thinking creating some mapping/translating between those xml tags and html so the content can be displayed in a readable format, and put those user editable fields in array of values to keep track of changes and replace back to the original .rdl file. but that all seem too complicated and also performance can be a concern...there should be a better way!
your help is greatly appreciated!
Instead of having these values stored inside the report, I would store them in the database. Don't have any static values in the report. Everything shown in the report is loaded as paramters that can be configured.
This way you can create a UI that allows you to change the values of these configurations and a button to load the report viewer with a fresh version of the report using these values. This wouldn't be a full on report editor but if you created some base templates that meet the business needs, they'd be able to make some general modifications to the report such as Titles, alignment, logos, etc.

Auto populating data into an existing Excel template

I was given an Excel template and have to automate filling it.
It is supposed to be uploaded every month into the grand central DB of our company. Grand central accepts nothing other than an Excel file with that template.
I tried reproducing the same using SSRS but it looks like SSRS has no control over rendering the looks and data in Excel (it keeps hiding columns and rows which is not acceptable). I have created a SQL connection on the Excel to get the stored procedure data into Excel.
Now I have to make sure the data goes into the template into appropriate fields. I think it needs groupings and page breaks also.
Please help..
You're on the right track with dumping SSRS as a way to export into the template. I've also found that the Excel rendering extension in SSRS does a lot of hiding and merging cells with certain report designs.
You will probably end up needing to write a script in your language of choice to load the data into appropriate cells on the template.
Here are some Powershell articles on Excel automation:
http://blogs.technet.com/b/heyscriptingguy/archive/2006/09/08/how-can-i-use-windows-powershell-to-automate-microsoft-excel.aspx
http://winpowershell.blogspot.com/2007/03/powershell-and-excel-com-object.html
Also take a look at Perl and the Win32::OLE module:
https://metacpan.org/pod/Win32::OLE
http://www.perlmonks.org/?node_id=153486

How to display image from sql server in ms access

I have an MS sql server database. There is a table with one of the column of the "image" type. Now, the customer wants to read the data from an MS access. He wants to display the images in a form.
I have never used access and have no idea of how to do simple things there. Any help will be greatly appreciate.
Thanks,
Ramjee
Rather than write out the stored images to files in order to display them, it may be possible to use ASP to display the image and a web browser control on the Access form to display the page. I have not tried this.
How To Display Images Stored in a BLOB Field: http://support.microsoft.com/kb/173308
You can put regular Image control on form and state MyPic.PictureData=PicField in Current event.
Or you can use AccessImagine, which is great for pictures in MS Access and requires no scripting. You can download it here - http://access.bukrek.net/download
I think you can do this by using streams. Stream the image from the field to an unbound image control. We use the same process for opening documents and other binary data stored in an SQL Server database.
On the other hand, Access had an Image control that can be linked to a field in a table. That should be a lot easier to user!

Resources