Is it possible to get the files for a deployed reports ON SSRS 2005?
On of our developers deployed them to the Reporting Server, but didn't commited his changes to SVN. Now we are in an inconsistent state and we also can't find the files he created.
In Report Manager (usually the URL ends with /Reports or /Reports_instanceName ) You can look at the details of reports. The Edit button will allow you to download the .rdl definition files.
From
http://msdn.microsoft.com/en-us/library/ms156032(v=sql.90).aspx
In the Report Definition section, click Edit to extract a copy of the report definition. Modifications that you make locally to the report definition are not saved on the report server.
(I should have also noted, the interface and the button name change in SSRS 2008, so these instructions are specific to SSRS 2005.)
use ReportServer
go
create view vwReportDataSet_SharedDataSet_Mapping
as
select ds.itemid, ds.name as Report_DataSource,
cat.name as Shared_DataSource
from datasets ds
inner join catalog cat on ds.linkid = cat.itemid
go
create view vwSharedDataset_Usage
as
select cat.path,
cat.name,
cat.type,
ds.Report_DataSource,
ds.Shared_DataSource
from
catalog cat
left join vwReportDataSet_SharedDataSet_Mapping ds
on cat.itemid = ds.itemid
This SQL gives you your report dataset usage.
select * from vwSharedDataset_Usage
where type = 2
and path like '/SIT/%'
and name in ('Report1','Report2')
Related
My team and I are in the process of migrating from Crystal Reports to SQL Server Reporting Services. A handful of our reports involve what my team refer to as "dynamic external images". What this means is that in the report we would have this default blank image object, and then in the Graphic Location setting we would have the following function:
Trim({rpt_StoredProc;1.SignaturePath}) + Trim({rpt_StoredProc;1.SignatureId}) + ".jpg"
This way, we could pass through the directory path and the file name (minus the file extension) via the stored procedure.
I'm now trying to replicate this in SQL Server Reporting Services Report Builder and I'm running into a brick wall.
Your data relating to dynamic external images having been imported in SSRS should be accessible in a table using the data type varbinary(max). This can be accessed and utilised in an SSRS report either as a single field (ie in a header/title) or in matrix a field.
Both usages require you use the toolbox, (view and select toolbox) and left mouse click , drag "image" to your report, image source "database", use the field (select varbinary(max) field) , MIME type try "image/bmp" first, select the size to suit your needs.
and you should be good to go.
Best of luck.
I finally found the answer!
="file://" & First(Fields!SignaturePath.Value, "rpt_StoredProc") & "\" & First(Fields!SignatureId.Value, "rpt_StoredProc") & ".JPG"
I thought I had already tried this and that it didn't work, but I guess not.
I have SQL 2014 professional version 12.0.5000.0 with SSRS runing. eI have created a report in report builder 3.0 which works and runs find.
However when I go to create a subscription and run I get the user a1234 (as a example ) don't exist.
I looked there is no user with that name added to SSRS or in our domain.
my user name is ah1234 (as a example )
I looked in the subscription table and the owner is me ? However, the subscription is showing the owner as a1234?
I checked the report I uploaded it says the owner is a1234.
I'm thinking it might be a active directory issue but not sure.
Has anyone has see this before if so how can I fix the owner name of the subscription?
I don't know how SSRS has corrupted the owner name but here is a trick (written on 2008 R2) to correct owner names (I use this when people leave & their Active Directory user id gets deleted leaving orphaned subs that will not run).
Note that it updates the Microsoft-supplied subscriptions table, you may not wish to do that.
First identify the SSRS owner id for the from-person & also that of the to-person (you may need to get the to-person to create a subscription first):
SELECT distinct [OwnerID], u.username
FROM [<ssrs-database>].[dbo].[Subscriptions] s
join [<ssrs-database>].[dbo].[Users] u on s.ownerid = u.userid
Now make a safe copy of the subscriptions list, e.g.:
SELECT * into temp.subscriptionscpy
FROM [<ssrs-database>].[dbo].[Subscriptions] s
Now make the change, e.g. (this one changes the owner of all relevant subs):
update [<ssrs-database>].[dbo].[Subscriptions]
set ownerid = 'DDD87598-8957-42C8-8DBC-A893E7174CB6'
where ownerid = 'EBF0E483-69E6-4458-B171-BA28FFCCDF3F'
Now check the owner is as you want it.
The problem is that alle the reports for a given project is now looking at a wrong team project.
In the standard reports the following query is used to determine the project:
SELECT TOP 1 p.ProjectNodeGUID, p.ProjectNodeName FROM
(
SELECT ProjectNodeGUID, ProjectNodeName, 1 AS RowRank FROM GetProjectNodeInfoFromReportFolder(#ReportPath)
UNION
SELECT '00000000-0000-0000-0000-000000000000' AS ProjectNodeGUID, 'missing' AS ProjectNodeName, 0 AS RowRank
) p ORDER BY p.RowRank DESC
But it does not return the correct one.
What has happened is that I renamed a project from A to A.Old and created a new project called A.
Looking at the report server, there is no folder called A.Old, only A but that actually points to A.Old.
Any idea of how to fix that?
If you are connecting to the Warehouse for TFS then you will need to run a rebuild of the Warehouse to have this change passed through. This is true for Project Renames, Deletes, and Collection detach/attach.
This should have been displayed in the warning message when you did the rename.
Running a rebuild from the admin console will fix this...
I have hundreds of reports that are deployed in MSSQL reporting server. In which few of the reports has embedded datasource and the rest has shared datasource. Is there is any query or easy method to differentiate the reports that have shared and embedded datasource?
You can use the following query:
WITH XMLNAMESPACES(DEFAULT 'http://schemas.microsoft.com/sqlserver/reporting/2010/01/reportdefinition')
SELECT C.Name,
CONVERT(XML,CONVERT(VARBINARY(MAX),C.Content)).exist('/Report/DataSources/DataSource/ConnectionProperties') AS EmbeddedSourcePresent,
CONVERT(XML,CONVERT(VARBINARY(MAX),C.Content)).exist('/Report/DataSources/DataSource/DataSourceReference') AS SharedSourcePresent
FROM ReportServer.dbo.Catalog C
WHERE C.Content is not null
AND C.Type = 2
You might need to change your namespace according to your ssrs version. I hope this helps.
I have designed a SSRS report having multiple sub-reports. The report is working fine but displaying data for all records.
But my need is to make it context sensitive.
Below is the query for the main report.
SELECT Filterednew_franchisee.new_franchiseeid,
Filterednew_franchisee.new_name,
Filterednew_monthlypayment.new_insurance
FROM Filterednew_franchisee
INNER JOIN Filterednew_monthlypayment
ON Filterednew_franchisee.new_franchiseeid =
Filterednew_monthlypayment.new_franchiseeid
WHERE (Filterednew_monthlypayment.new_yearmonth =
#reportyear + #reportmonth)
AND (Filterednew_franchisee.new_franchiseeid IN
(select new_franchiseeid
from Filterednew_franchisee as CRMAF_Filterednew_franchisee))
Sub-reports are using the fields from the above query as parameter.
Am I missing something ? Is there any other approach that needs to be followed? Is it really possible to design a context sensitive report having multiple sub-reports?
Please help.
Yes, context-sensitive reports are possible. The name Filtered as in Filterednew_franchisee refers to a SQL Server view that is designed for the sake of security roles. To gain access to context-sensitive views, the API takes an arbitrary prefix called CRMAF_ and translates it into a context-sensitive query.
Thankfully, the SDK includes a sample view (which I've copied below).
SELECT
CRMAF_FilteredActivityPointer.activitytypecodename as activitytypecodename,
CRMAF_FilteredActivityPointer.regardingobjectidname as regardingobjectidname,
CRMAF_FilteredActivityPointer.subject as subject,
CRMAF_FilteredAccount.name
FROM FilteredActivityPointer AS CRMAF_FilteredActivityPointer
INNER JOIN FilteredAccount As CRMAF_FilteredAccount on
CRMAF_FilteredAccount.accountid =
CRMAF_FilteredActivityPointer.regardingobjectid