Custom Ordering In MDX For SSRS Report
Feb 27, 2008
Hi guys,
i Have the following code for a SSRS Matrix Report.
SELECT NON EMPTY { [Measures].[Ordered Qty], [Measures].[Line Fill %], [Measures].[Qty Fill %], [Measures].[Delivered Qty], [Measures].[Delivered Lines], [Measures].[Ordered Lines] } ON COLUMNS,
NON EMPTY {[Customer].[Customer Name].[Customer Name].ALLMEMBERS * [Market].[Product Group].[Product Group].ALLMEMBERS * {[Time Calculations].[MTD Pr Mth],[Time Calculations].[MTD]} } DIMENSION PROPERTIES MEMBER_CAPTION, MEMBER_UNIQUE_NAME ON ROWS
FROM ( SELECT ( STRTOSET(@DatePeriod, CONSTRAINED) ) ON COLUMNS FROM ( SELECT ( STRTOSET(@DateYear, CONSTRAINED) ) ON COLUMNS FROM [DIFOT]))
WHERE ( IIF( STRTOSET(@DateYear, CONSTRAINED).Count = 1, STRTOSET(@DateYear, CONSTRAINED), [Date].[Year].currentmember ), IIF( STRTOSET(@DatePeriod, CONSTRAINED).Count = 1, STRTOSET(@DatePeriod, CONSTRAINED), [Date].[Period].currentmember ) )
CELL PROPERTIES VALUE, BACK_COLOR, FORE_COLOR, FORMATTED_VALUE, FORMAT_STRING, FONT_NAME, FONT_SIZE, FONT_FLAGS
Parent is the Customer Name, with Drill Down to Product Group.
Is their a way that i can sort this report so the customers with the highest [Measures].[Ordered Lines] for ],[Time Calculations].[MTD] is on the top.
Ive been trying to work out the ORDER command in MDX, but i cannot seem to get it to work..
Any help would be great
Thanks
Scotty
View 5 Replies
ADVERTISEMENT
Apr 28, 2008
Hi,
I have a set up SSRS which is reporting from a custom list in sharepoint to SQL 2005. I have created a parameter on the SQL report to return data from a field in the sharepoint list, however when it retrieves the data i get 1;# in front of the returned data?
Why would this happen?
Any help would be much appreciated, thanks.
View 5 Replies
View Related
Aug 20, 2015
I have an application that will ask a user about faults in a car. The info is stored in a database.
I want to create a report that will have a 'picture' of a car, as in the below; and will be highlighted depending on which part is faulty.
For example, if the bonnet is faulty, then it must be highlighted in a specific color.
View 5 Replies
View Related
Jun 17, 2015
I am working on SSRS report with project server 2013 and I want to add custom dll in SSRS report.I have create dll first then add into GAC Assembly After that i have add this dll in report project in SSRS.when i have try to deploy and build report...
.An error Occurred during local report processing.
Failed to load expression host assembly.
Details : Cannot Perform CAS Asserts in Security Transparent methods.
View 6 Replies
View Related
Aug 6, 2015
I have a balance sheet report developed and working. What I need to do is add the ability to click (or double-click) on a number and have a separate report (drill-down) open with the detail that makes up that number. I've researched drill-through reports, sub reports, etc. but can't find a way to do what I want.
I'm now thinking that I need to add custom code in the report properties, code window to do this. I'm hoping that there is a VB method I can use to call this report and pass a parameter. Pseudo-code for this function would look something like this: RunReport("DrillDownReport", "Parameter").
This seems like it should be pretty easy but I don't know what the function is in VB for running an SSRS report (if there is one).
Is this possible or am I barking up the wrong code tree?
View 5 Replies
View Related
Jul 11, 2005
Hi guys.
I want to create a top 20 product list from a few thousand products. I want the rest of the products to be grouped into 'others'...
I also want the products to be ordered by the facts in the cube. Thus the product dimension would dynamically change depending on the Time dimension thats being selected.
is this plausible ?
Thanks
Tom
View 1 Replies
View Related
Jul 9, 2013
I am creating a SSRS report which would be executed by User manually through ReportServer URL.User would be generating the SSRS report for different Customer ID based on ad-hoc basis.
I am passing CustomerID as input parameter to the report. Is there any way to get the manually generated SSRS report name as 'Report_CustomerID_TodayDate.xls'.
E.g.If User is generating report for Customer ID 123 today then report name should be 'Report_123_07092013.xls'
View 2 Replies
View Related
Jan 2, 2007
Hi group, i'm having a problem with custom ordering in a SP. My code isthe following:CREATE PROCEDURE [dbo].[PersonasSelectAll_P]@fromRow int,@toRow int,@expresionOrdenamiento int = nullASSET NOCOUNT ONDECLARE @TotalFilas intSelect @TotalFilas = count(*) from [Personas]SELECT * FROM(SELECT ROW_NUMBER() OVER (ORDER BY CASE WHEN @expresionOrdenamiento =1 THEN [Id]--WHEN @expresionOrdenamiento = 2 THEN [Nombre_RazonSocial]WHEN @expresionOrdenamiento = 3 THEN [CUIT_CUIL]ELSE nullEND) AS Row, * , @TotalFilas as TotalRowsFROM [Personas]AS NumberedPersonsWHERE(Row >= isnull(@fromRow, 0)) AND (Row <= isnull(@toRow, row))The line WHEN @expresionOrdenamiento = 2 THEN [Nombre_RazonSocial] iserroring out (the sp compiles, it's a runtime error), i'm getting an'Cannot convert varchar to int'. Maybe it's because Nombre_RazonSocialis varchar? If i comment that line then everything works fine. AnyHelp??Thanks in advance
View 1 Replies
View Related
Dec 11, 2013
I am using the QRCode4CS class [URL] .... to generate QR codes.
I can use the following code to successfully return a bitmap image to a picturebox in a Windows Form Application.
public class CreateQRCodeClass
{
public static Image CreateQRCodeImage(string inputString)
{
QRCode4CS.QRCode qrcode = new QRCode4CS.QRCode(new QRCode4CS.Options(inputString));
qrcode.Make();
[Code] ....
In trying to adapt the same code (below) to display a QR code in an SSRS report I get the error "There is an error on line 1 of custom code: [BC30311] Value of type 'System.Drawing.Image' cannot be converted to '1-dimensional array of Byte.'
Here is the custom code I am using.
Public Function QRCode(ByVal RetailerId As String) as Byte()
Return QRCode4CSCreateQRCode.CreateQRCodeClass.CreateQRCodeImage(RetailerId)
End Function
Here is the revised custom assembly.
public class CreateQRCodeClass
{
public static byte[] CreateQRCodeImage(string inputString)
{
QRCode4CS.QRCode qrcode = new QRCode4CS.QRCode(new QRCode4CS.Options(inputString));
qrcode.Make();
Image canvas = new Bitmap(86, 86);
[Code] ....
What data type can I successfully return to SSRS to display the image?
View 9 Replies
View Related
Jun 3, 2015
I'm trying to add a custom report format to ssrs 2005 as per this [URL] I've added the code snippets in the example to three different ssrs 2005 server RSReportServer.config files but it does not work i.e do not show up in the export drop down when rendering report.
I've tried starting and stopping reporting services and it still does not works.
I've also modified the existing csv extension with different options to see if it works but to no avail.However it works with SSRS2008 R2 . In fact it works right after I saved the config file, no restart needed.For SSRS2005 the file is in C:Program FilesMicrosoft SQL ServerMSSQL.3Reporting ServicesReportServer. I checked the registry setting just to make sure I'm looking at the correct installation 'HKEY_LOCAL_MACHINE', 'SOFTWAREMicrosoftMicrosoft SQL Server90ToolsClientSetup', 'SQLPath' The three ssrs2005 instances are in three different physical servers and the problem is with all of them so it is not an isolated incident. I've dbowner rights to all three servers. The server versions are 9.0.4060, 9.0.4035 and 9.0.4053
View 11 Replies
View Related
Sep 3, 2015
Currently we are using Custom Delivery Extension for SSRS 2008R2 We are planning to move it SSRS2012
My Question is: Whether we can use the same Code used for SSRS2008R2 to SSRS2012?
if not what code changes we should do?
View 3 Replies
View Related
Aug 18, 2007
Hello,
I am trying to format a matrix report so that columns appear in a specified order.
An example of what I mean is, I have 3 columns; New, Additional and Old.
When these columns are dynamically generated by RS they are put in alphebitic order. I want them to appear in the order in which I have them above.
The dataset returns a sequence (int) for each of the columns, so 'New' = 1, 'Additional' = 2 and 'Old' = 3. I am ordering on that sequence, but still can't get it to work. These are actually column groupings.
What am I doing wrong? I don't want the column sorted (i.e. data sorted within a row), but the columns to appear in a specific order.
Many thanks
Shawn
View 2 Replies
View Related
Sep 19, 2007
Hi,
I'm trying to deploy Reporting Services on an Internet-facing web server using a custom security extension (forms authentication). We will be putting Report Manager on the Web Server outside of the firewall, and Report Server on another machine inside the firewall. When testing the solution in a development environment with Report Manager and Report Server on the same box, the solution works fine.
When testing it using the Internet-facing environment described above, it almost works but there seems to be an issue with the authentication cookie that is generated. Here's what happens:
1. User enters credentials on UILogon.aspx and submits form.
2. In the code-behind, LogonUser() is called through a web service proxy and the authentication cookie is returned successfully. The code used here to set the cookie is the same code used in the Forms Authentication sample that ships with RS2005.
3. The user is redirected to Folder.aspx, and the request hangs for a while, and eventually kicks you back out to UILogon.aspx, as if it lost the authentication cookie. When doing a trace on the HTTP header, the cookie is still there.
Is there anything special I need to do to make the Report Server "see" the cookie when I have Report Manager and Report Server on different machines?
Any help would be much appreciated!
Mike
View 2 Replies
View Related
Mar 18, 2008
Hello everyone,
I created a custom assembly using C# to transform some binary data into text, and in this assembly I used one win32 dll developed by our customer to help me to do the tranformation.
The code I used to call the win32 dll is like below:
[DllImport("tdasuie.dll", EntryPoint = "AlrtLogConditionToText",
ExactSpelling = false, CharSet = CharSet.Auto, SetLastError = true)]
private static extern UInt32 AlrtLogConditionToText(Byte[] pbCondition, StringBuilder pszText, UInt32 dwSize);
I defined a C# method to call the above win32 method and return a string. Then in the report, I called this C# method to get the correct string.
In the report designer, the C# method in the custom assembly can return the correct string in the preview window. But after I deployed the report into the report server, the textbox will only display "#error" in the report manager web page.
Can anybody help me on it? Thanks a lot.
Danny
View 4 Replies
View Related
Jun 15, 2007
Is it possible to create a custom SSRS .NET component that can view the report parameters and values contained within?
Thanks!
View 3 Replies
View Related
Nov 29, 2006
I have developed a custom report item that works fine in design and preview mode while in Visual Studio. I cannot get it to show up on my deployed reports. Here's what I have done so far:
1. Deployed the report using Visual Studio
2. updated the rsreportserver.config file with the following entry:
<ReportItems>
<ReportItem Name="PedigreeChart" Type="Uabr.Rap.PedigreeChart.PedigreeChartRenderer, Uabr.Rap.PedigreeChart" />
</ReportItems>
3. Updated the rssrvpolicy.config file with the following entry.
<CodeGroup
class="UnionCodeGroup"
version="1"
PermissionSetName="FullTrust"
Description="This code group grants Uabr.Rap.PedigreeChart.dll FUllTrust permission. ">
<IMembershipCondition
class="UrlMembershipCondition"
version="1"
Url="C:Program FilesMicrosoft SQL ServerMSSQL.3Reporting ServicesReportServerinUabr.Rap.PedigreeChart.dll" />
</CodeGroup>
I've also tried using the StrongNameMembershipCondition with no better results.
4. The dll and its dependencies are copied to the bin directory of the report server.
5. When I load a report with this custom report item on it, the report loads fine with no errors or warnings in the log file (even with verbose tracing). The area where the custom item should be is just white. It's almost like Reporting Services isn't registering the item correctly.
This is particularly frustrating because the report works fine in Visual Studio - apparently I configured that correctly. Any suggestions would be greatly appreciated. I'm stumped.
View 6 Replies
View Related
Mar 28, 2008
i deigned assembly and referced it to my report in preview
when deployed the report , i get #Error
i don't add any cas code.
pls help
View 4 Replies
View Related
Apr 21, 2007
HI all, I am having a problem while trying to create a list item through SSRS.The scenario:I have created a SSRS report which has custom code. the report has some parameters. The code accepts the parameters and tries to create a list item in moss. I have added the required references. This works fine as long as I work in VISUAL STUDIO IDE. When I deploy the report to report server it throws an error in the code.Can anybody help me in this...?Regards...
Girija Shankar
View 1 Replies
View Related
Mar 25, 2008
I have a custom assembly that I'm trying to use with my resport in Reporting Services in SQL Server 2008.
I keep consistently getting a "Request for the permission of type 'System.Data.SqlClient.SqlClientPermission, System.Data,Version=2.0.0.0, Culture=neutral,PublicKeyToken=b77a5c561934e089' failed" error. Even in preview mode.
- I added <Assembly: AllowPartiallyTrustedCallers()> attribute to the assembly
- I'm asserting the permission in the routine that is doing the database call with the follwing lines:
Dim permission As SqlClient.SqlClientPermission = New SqlClient.SqlClientPermission(PermissionState.Unrestricted)
permission.Assert()
- I went in .net 2.0 Framework configuration and made the assembly fully trusted
- I added the approprtiate codegroup to the rssrvpolicy.config file
- I tried the same assembly on another PC running SQL server reporting services 2005, its working just fine.
what is it that I am missing?
View 1 Replies
View Related
Apr 24, 2015
Can we call custom code in parent report, which written in the subreport.
View 5 Replies
View Related
Nov 19, 2007
Exporting a report to Excel has a lot of issues with appearance. As a result, I created an Excel template that I would like to use when the user selects to export the report to Excel, using the reportViewer toolbar. I haven't found any documentation thus far on how to accomplish this. Does anyone know whether this is possible with SSRS and if so can you please provide information as to how it is accomplished. I have created a similar post where my application code can be reviewed: http://forums.asp.net/t/1183977.aspx
Any help is appreciated.
View 1 Replies
View Related
Apr 24, 2007
Hi,
Have compiled and set up a custom security extension for SQL Reporting Services on my local machine and got it working. However, I'm trying to copy the extension across to a different server. So far, I've tried copying the updated dlls straight from my machine to the server and making the relevant changes in Reporting Services .config files (rsWebApplication.config, rssvrpolicy.config, etc)
Initially, the Forms authentication redirects to a login page as expected. However, when we try to submit a login name and password from this login page, it throws this error message:
"Invalid URI: The format of the URI could not be determined."
Is copying the dlls straight across a bad idea?
If anyone has encountered a similar issue, do you know if there are there certain things I should be checking for, or have missed, when trying to replicate a custom security extension on a different machine?
(FYI, the original server where it worked was Windows XP SP2, new server is Windows Server 2003 SP1)
View 1 Replies
View Related
Oct 17, 2007
Hi,
I'm developing an ASP.NET application that creates on-demand reports with Reporting Services 2005 in report server.
I use a custom data set that contains the data that I want to bind to the report, and I use a WebService to pass that DataSet to the reporting services to accomplish my purpose.
The query passed to the reporting services is:
<Query>
<Method Namespace=http://myNameSpace.com Name="GetDataSetForReport"/> <SoapAction>http://myNameSpace.com/WebService/GetDataSetForReport</SoapAction>
<ElementPath IgnoreNamespaces="True">GetDataSetForReportResponse{}/GetDataSetForReportResult{}/diffgram{}/ReportDataSet{}/MyTable{Fields1,Fields2,Fields3,..,FieldsN,Image}</ElementPath>
</Query>
This works well and all the fields are displayed in the report fine except the Image Fields, that are not showing (the red X appears instead of the image).
The issue is that all the data that is bind to the dataset is contained in a SQL Server 2005 database, and the Image column in the table of that database is a VARBINARY(MAX) field (I insert the image into the database table).
Also, when I created the dataset in .NET, the column type of the dataset I declared for the Image field was Byte[], but that didn't work for me. I've also tried to declare as the field type Byte,SqlByte,Image,SqlBinary, etc without succesfull results.
I've also tried creating a XML Schema, declaring the Image field as base64Binary, then do DataSet.ReadXMLSchema(myschema) and then retrievied the data from sql server and filled the dataset, Again, the Images doesn`t display.
For finnishing my unsatisfactory tests, I've also tried to handle the image data with a MemoryStream object:
MemoryStream mem = new MemoryStream();
MemoryStream oStream = new MemoryStream();
mem.Write((Byte[])dr["Image"],0 , ((Byte[])dr["Image"]).Length); //dr is the datareader used to read from the DB
Image image = Image.FromStream(mem);
try
{
image.Save(oStream, ImageFormat.Png);
}
catch{}
newRow["Image"] = oStream.GetBuffer(); //newRow is a row of the custom DataSet.Table passed to the SSRS.
But again, the Image is not showing.
Any suggestions?
Thanks for you time.
View 1 Replies
View Related
Sep 22, 2015
I have a SSRS report that uses a custom library. The custom library returns a string values, and I have tested this with a windows application.In the SSRS report. I have set the expression value for a text box as =CodeReportingLibrary.CodeReportingFunctions.GetImage(1232)
However, when i preview the report the text box value shows as #ERROR. I checked the error list and I get a warning message : Warning 1 [rsRuntime ErrorIn Expression] The Value expression for the textrun ‘Textbox5.Paragraphs[0].TextRuns[0]’ contains an error: Attempt by security transparent method 'CodeReportingLibrary.CodeReportingFunctions.GetReferenceImage(Int32)' to access security critical method 'Microsoft. TeamFoundation. Client. TfsTeamProjectCollection..ctor(System.Uri)' failed. Assembly 'CodeReportingLibrary, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' is partially trusted, which causes the CLR to make it entirely security transparent regardless of any transparency annotations in the assembly itself. In order to access security critical code, this assembly must be fully trusted.
I have updated the rssrvpolicy.config in ReportServer folder, to include my custom dll.
<CodeGroup
class="UnionCodeGroup"
version="1"
PermissionSetName="FullTrust"
Name="CoDeMagSample"
Description="CoDe Magazine Sample. ">
[code]....
View 4 Replies
View Related
Jun 3, 2015
Is it possible to have a custom start date parameter on a report? I would like to have a cumulative daily report for the week, Friday to Thursday. The final daily to run on the Friday, then the next week begins. I have a enddate, which is today()-1 (for previous day); I need a start date to be variable.
In other words,
On a Monday, report pulls data from last Friday to Sunday;
On a Tuseday, report pulls data from last Friday to Monday,
On a Wednesday, report pulls data from Friday to Tuesday, etc,
until on Friday, the report pulls data from last Friday to Thursday.
View 4 Replies
View Related
May 5, 2015
I am using Custom Data Processing Extension to call a stored procedure. Iam getting following error when creating a dataset in report designer using the extension. I wrote the code in c#.
could not update a list of fields for the query. verify that you can connect to the data source and that your query syntax is correct.(Details-Object reference not set to an instance of an object.)
Here is my code
using System;
using System.Collections.Generic;
using System.Text;
using System.IO;
using System.Data;
[Code] .....
View 2 Replies
View Related
Oct 9, 2015
I have done the following and a domain user would not access report created a login to the SQL server to the user (this SQL Server is where data source DB is)went to site setting in Report Manager and made this use a system userright clicked on report folder and made this user in the browser roleeven checked that in the report in question, the user is already in the browser role Still the user would not access the report! "User .......... does not have required permission" is the error message I am getting.
View 6 Replies
View Related
Jul 5, 2012
I have written a report visual studio. The report has 10 multi-value parameters that pull data from their individual data sets within the reports. When running the report from within Visual Studio it renders fine. There are no errors reported, only a warning related to a pathname I have use to retrieve image data and display on the report.Deployment of the report is error free.When I view the report I briefly get the "Loading" splash window, but then nothing. None of the headers or static text is displayed. The results window is blank.
The report defaults all the parameter values. In trying to debug the issue I have found by reducing the number of parameter values the report will render. Once I have all the values added, the report does nothing.Below is the query being used for the report. The where clause in the query shows the parameters being used and the syntax.We are running on Windows Server 2008 R2 and SQL Server 2008 R2.
Ralph
SELECT RTRIM(a.ITEMNMBR) AS Style, RTRIM(a.ITEMDESC) AS Description, a.ITMSHNAM AS UPC, c.LOCNCODE AS Store, d.LISTPRCE AS ListPrice, a.CURRCOST AS Cost,
a.USCATVLS_1 AS [Main Category], a.USCATVLS_2 AS Market, a.USCATVLS_3 AS [Alternate Retail], a.USCATVLS_4 AS Country, b.ITEMXTRAS_1_Type AS Type,
b.ITEMXTRAS_2_Finish AS Finish, b.ITEMXTRAS_3_SubCategory AS SubCategory, b.ITEMXTRAS_4_Department AS Department,
[code]...
View 7 Replies
View Related
Sep 21, 2015
I have a ssrs report having 2 tables in with 4 columns in each. When I go to export option in preview I can see all data coming in one excel sheet, But I am trying to get 2 tables in 2 different pages in Excel when I export.First page of excel comes with first table data with 4 columns and second page of excel comes with second table data with 4 columns .
View 2 Replies
View Related
Nov 18, 2007
Here is a situation in my company:
We have an Office SharePoint 2007 site, we developed a couple of web parts and added them to our site. We used SQL Server Reporting services 2005 as our reporting solution. The reports are hosted on the report center and when we need a report, we open it by sending a URL requesting the report, passing the report parameters in the URL query string. So the report is filtered based on the parameters passed from the web parts.
But since best practices say that you should host reports directly under SharePoint, by configuring the reporting services to run in the SharePoint integrated mode. We followed the steps and installed SharePointRS and we finally succeeded to publish the reports to a SharePoint folder, but we had a limitation: we are unable to pass the report parameters internally to the report hosted in SharePoint. If we passed them in the query string as the report center case, SharePoint neglects them totally.
So the question is: how can I pass parameters internally between a SharePoint web part and a SQL server 2005 reporting services report hosted in SharePoint?
View 1 Replies
View Related
Jun 29, 2015
I'm wondering how to print a SSRS report without bringing up a report viewer. Is there way to print(PDF format) the SSRS report in the web application( .net ) directly from the "print" button without bringing up a report viewer?
View 2 Replies
View Related
Apr 29, 2008
Hi,
I'm encounter lately some weird behaviour of SSRS in BIDS as well as after deploying on Reporting Server.
I'm running basic classical SQL SSRS Reports with Oracle DB connection. My reports have header and footer pagination and well defined report layer configuration. All the reports are simple based on one table and some basic parameters passed to query.
In query builder from BIDS from data tab, the query is running fine without any other execution delays. Also the query is runnign fine in PL/Dev environment.
When I switch in "Preview" mode the report hangs in execution and just showing "Report is being generated" without any resuts. After a while is generating an execution error (after 20 min).
The behaviour is the same after deployment on Report Server .
I now...here it comes...the problem is intermitent...some times the report is working...but most of the times it hangs on execution.
I checked the report from top to bottom and nothing's wrong from design perspective.
On other reports I don't have this problem and I don't understand where to start to investigate.
Any suggestions...I'm stuck here.
Thanks
View 1 Replies
View Related
Sep 16, 2015
I am trying to develop a report from cube,and it has one drill through report.when i click on sales amount field on main report,then it open the drill through report with details.Here i passed the **(category,subcat,product)parameters(Cascaded)** to drill through report in action part of main report.In my main report i have two columns .
columns are **Level** and **Salesamount**.
Values are like
**[-]category** **100**
**[-]subcat** **50**
**product** **30**
when i click on 100, parameters are passed & it open the detail report correctly, but when i click on 50,the values for subcat parameter is not getting values in detail report and same as the product also.
Here i used the expressions in parameter values
**pCategory**----iif(inscope(category),!fields.category.value,split(join(Parameters!category.value,","),","))
**psubcat**----iif(inscope(subcat),!fields.subcat.value,split(join(Parameters!subcat.value,","),","))
**pproduct**----iif(inscope(product),!fields.product.value,split(join(Parameters!product.value,","),","))
View 3 Replies
View Related