Quantcast
Channel: SQL Server Reporting Services, Power View forum
Viewing all 10045 articles
Browse latest View live

Display all 6 months in a half year along the x-axis even though there's data for the first month, only

$
0
0

I have a line chart that shows the number of calls taken during each month in the selected half-year (for performance evaluation). When I have only the first month in our financial half year with data captured then I see just the label Oct and a dot for the number of calls.

When the second month is complete, I get Oct and Nov and a line.

What I'd like to do is also show Dec, Jan, Feb and Mar along the x-axis with the same line as for the current situation.

I saw a description using a LOOKUP but I couldn't figure out how to make it work for me with multiple series including a range chart and a line chart.


Nick Ryan MIS Programmer Analyst, ANZ Bank


#Error using IIF and divide by zero

$
0
0

I am getting an error in a calculated field that could potentially divide by zero, even though I'm using an IIF.  The column displays in the report as "#Error".  My expression looks like this:

= IIF(Fields!Qty.Value = 0,

"None", Fields!Hours.Value / Fields!Qty.Value)

I have successfully used this approach with INT fields, but this time the Hours field is a NUMERIC(9,2).  My workaround is to do this:

 IIF(Fields!Qty.Value = 0, "None", IIF(Fields!Qty.Value = 0, 42, Fields!Hours.Value) / Fields!Qty.Value)

I guess the 42 is cast to an INT inside the second IIF and the calculation works.

What's strange is that the division would even be carried out in the event of Qty = 0 from the first IIF, because the expression should just evaluate to "None" and that would be that.

Has anybody run into this problem?  Is my workaround the recommended approach?

-Larry

 

Tricky Update in the same table

$
0
0

I have a query that yield a result like this

col1ID      col2      Name1      col3ID        col4       Name2      

1             200          A             1               null         null

2             null          null           2              300         A

1             400          B              1              null          null

2             null          null           2              500         B

There is no unique ID for this table, say Extbl, colIDID and col3ID has the same value, either col2 or col3 has null value, also Name1 and Name2 has null value, how can I update Extbl to have result like this?

col1ID      col2      Name1      col3ID        col4       Name2      

1             200          A           1               200         A

2             300          A           2              300         A

1             400          B           1               400         B

2             500          B           2              500         B

Extbl has 6 columns where col col1ID and col col3ID have same value, either col col2 and col Name1 both have null, or col col4 and col Name2 both have null, then the rule is to update col2 = col4 if col2 is null, and col Name1 = col Name2 if col Name1 is null. Similarly, col4 = col2 if col4 is null, col Name2 = col Name1 if col Name2 is null, also col1ID must match col3ID when update. But it is tricky when row 1 and row 3 have same ID = 1. I'm stuck when do normal update. Is there a way to do that? 

Thank you

Kay_D




Management reporter subscription parameter values (for yesterday)?

$
0
0

Hey all,

I'm trying to setup a subscription to a report, but want the data for that report for yesterday(example, all sales from yesterday). I can't get the syntax correct, I've tried today()-1, @today() but none are working. How can I get the parameters to allow this? Screenshot attached for reference.

How to Stop Execution when Parameter Dates are Nullable

$
0
0

I have a report which has two (2) date range parameters. (Start date, End Date)

If the "Allow Null Value" is checked for both dates, then the report will run as soon as you load it.

Is there a way to allow for null values, but not run the report until the user clicks "View Report"?


rsInvalidDataSourceReference

$
0
0

 

I am trying to move a report from one SQL 2008 server to another.  I'm getting the rsInvalidDataSourceReference error but replacing the data source GUID with a guid from another report that does run on the new server is not fixing the problem. 

The data source is named the same thing on both servers - Is there something else I need to fix?

 

Condition for group

$
0
0

Hi everyone.

I have a matrix with column group in my report, where column group is month. 

I need 3 rows in this groups: cost of product 1, cost of product 2 and overall cost.

I have items in my database with property, so I wanted to put condition expression in group column.

I've tried this approach:

=iif(Fields!TYPE.Value="a", sum(Fields!COST.Value), 0)

However, I got 0 in columns.

How I can put condition expression in group?

Regards,

Yerkhan

SSRS AVER

$
0
0

Hi Sir,

I am having 12 individual tables with single row data value. I want to get maximum value among these 12 tables. How I can do this logic.  


DATEADD working days?

$
0
0

Hello, 

I am trying to do a formula to add 2 working days to a date field. 

I don't even know where to start so does anyone have a suggestion of what I can try? 

I did try and look it up on the internet but cannot find anything that makes sense to me. 

Many thanks, 

SSRS Data Sets Identification

$
0
0

Hi,

How can we identify a particular data set in SSRS Report.

We are using Report Builder 3.0

I am having a large amount of data sets.

Is there any search criteria available for searching data sets in the report. 

Please help

Report Viewer DateTime picker exchange MONTH and DAY after selection...

$
0
0

Hi,

I honestly don't know where to look to solve this problem.  when I preview my report, I have a DateTime parameter for which I click the icon to bring the calendar and select the date 2016-03-04

When I hit VIEW REPORT, the Textbox changes for 2016-04-03 making the result invalid






add formatted date to the end of report name when exported as .csv

$
0
0

Hello,
Report is subscribed and exports as .csv to file share.
The report is delivered as the name of the report.csv
Is there a way to place _mm_yyyy at the end of the report name i.e. Name_mm_yyyy.csv

?

Thank you

need to have expression display one field or three concatenated fields based on parameter

$
0
0

So I'm doing a report where in the title in the header it displays an id# then based upon that id# it will then display either the appropriate group name or an individual's name (first middle and last name fields concatenated together.) My dataset is a stored procedure. 

Example of my report title, "ID: 1234  Group or Individual's Name: BlueGroup"
The ID number is a parameter so that textbox expression is simply [@ID_Num] then for the latter part, if my textbox expression reads, =First(Fields!Group_Name.Value, "report_ds") it successfully pulls in the name of the group; however, I'm really banging my head for the proper phrasing to have it be "Group_Name" OR "First_Name" & "Middle_Name" & "Last_Name". I'm thinking this where the IIF comes into play but not sure how to properly put all that in there.

I'm new to doing reporting services and the first couple of reports I did did not have anything like this; so, much thanks in advance to anyone who can help me wrap my head around this.


Change of IP address on ReportServer has caused Subscription emails to show new IP address rather than name of report server

$
0
0

Hi All,

Recently we changed the IP address of our ReportServer.  After doing so, Email subscriptions which are received by many of our users, expose the IP address in the attached URL, rather than the server name as it originally did before the change.

We do not want the IP address displayed.

What should I look for to ensure that the server name is displayed in the link rather than the IP address?

New: (since the IP change)

The report is accessible at the following address:
http://11.222.333.444/ReportServer_xxxxxx

Old: (before the IP change)

The report is accessible at the following address:
http://myhostname/ReportServer_xxxxxx

All other features of ReportServer appear to be working normally.

Thank you!

--Dan

SSRS Remove Duplicates from comma delimited Array using LookupSet Function

$
0
0

I need to pass multi-variet parameters to a sub-report. I'm attempting to use LookupSet to concatenate all the data to go into the sub-report, this is working, however there are too many data points and most are duplicates:

---------------

=Join(LookupSet(Fields!Object_Code.Value, Fields!Object_Code.Value, Fields!Object_Code.Value, "ResultsDataSet"), ",")

---------------

I've attempted to use the code below I found on google searching to remove duplicates, but this code ends up showing just the first result:

---------------

Public Shared Function RemoveDuplicates(m_Array As Object()) As String()

    System.Array.Sort(m_Array)
    Dim k As Integer = 0
    For i As Integer = 0 To m_Array.Length - 1
        If i > 0 AndAlso m_Array(i).Equals(m_Array(i - 1)) Then
            Continue For
        End If
        m_Array(k) = m_Array(i)
        k += 1
    Next

    Dim unique As [String]() = New [String](k - 1) {}

    System.Array.Copy(m_Array, 0, unique, 0, k)

    Return unique

End Function

(I use this statement in the action section of the placeholder to push variables to subreport):

=Join(Code.RemoveDuplicates(LookupSet(Fields!Object_Code.Value, Fields!Object_Code.Value, Fields!Object_Code.Value, "ResultsDataSet")), ",")

---------------

Long and short of it, I have a long list of items getting pushed as parameters to a separate sub-report, but there is a ton of duplicates in that list. How do I get rid of the duplicates?


Calculation in Matrix

$
0
0

Hi

I am using Matrix and created structure like this, here Category, Year_ID is coming from database And I have added row named % Diff, I want to calculate value for that in runtime. Calculation is "2018 value" - "2017 Value". Second snap is showing up the Preview


Aniruddha http://aniruddhathengadi.blogspot.com/

How to Count workflow process for distinct employee

$
0
0

Hi

I have a data which gives me approval step number for an Employee. When for an employee, Iscomplete is 1,1,1 for StepNumber 1,2,3 Than I need to count it  as 1 'Complete process'. If IsComplete is 1,0,0 Than one 'Review' and If IsComplete is 1,1,0 Than one 'FInal' . How can I achieve it ?

CREATE TABLE Test
(
EntityID INT,
EmployeeID INT,
WorkflowID INT,
StepNumber INT,
StepName Varchar(100),
IsComplete Bit
)

INSERT INTO Test VALUES
(43,    38,    5,        1,    'Create',    0),
(45,    40,    5,        1,    'Create',    0),
(46,    41,    5,        1,    'Create',    0),
(47,    42,    5,        1,    'Create',    1),
(48,    42,    5,        2,    'Check',    1),
(49,    42,    5,        3,    'Final'     ,  1),
(50,    43,    5,        1,    'Create',   1),
(51,    43,    5,        2,    'Check',    0),
(52,    43,    5,        3, 'Final'  ,    0)

SELECT * FROM Test
Drop Table Test

According to this data there is 1 'Complete' and 1 'Review'.

Thanks!

Auto Refresh Not Working if Report Called in URL

$
0
0

If I call an SSRS report (2008) using this string:

http://xxxxx-sql01/Reports/Pages/Report.aspx?ItemPath=%2fReport%2fSR+Parts+Requests<o:p></o:p>

it behaves normally, i.e., it auto refreshes the timestamp in the header and the displayed data based on the autorefresh value parameter within the report.

However, if I call the same report using this string:

http://xxxxx-sql01/ReportServer/Pages/ReportViewer.aspx?%2fReport%2fSR+Parts+Requests&rc:Toolbar=false&rc:Parameters=Collapsed&rc:Zoom=120&rs:Command=Render&rs:ClearSession=true&resp=1<o:p></o:p>

The report will initially display correctly, but the auto refresh is only seen in the timestamp - the data itself is not refreshed.

What is there in the second string that causes the auto refresh to fail?

Thanks, Bill

Automated Testing Frameworks that work with SSRS

$
0
0

Hello,

I'm looking to automate testing for reports created by SSRS and I was wondering if anyone knows of any Automated Test Frameworks that work with SSRS. It would benefical if the tool can connect to an enterprise data warehouse as well.

Thanks!

An impersonation error occurred using the security context of the current user. The referenced account is currently locked out and may not be logged on to.

$
0
0

We're using SharePoint integrated Reporting Services.

We have a daily event that triggers eight SSRS subscriptions that write files to various shared folders after our ETL completes.

Randomly, every 5-10 days these subscriptions fail with the message:

"An impersonation error occurred using the security context of the current user. ---> System.Runtime.InteropServices.COMException: The referenced account is currently locked out and may not be logged on to."

This message is misleading as the account is not locked out. The resolution is just to re-trigger the event. The reports run fine and are saved successfully. If it happens to occur on a weekend, nothing is done and the reports just run fine the next day. Nothing is done to change the account.

The eight reports are either all successful or they all fail, there is never a combination of some success and some fails.

Any ideas what would make an account seem locked out when it's not? Is there some way to find out more information on what's going on? 

Here are the relevant logs for one of the reports:

--These are the log entries when the report fails

w3wp!schedule!126!05/05/2016-05:39:29:: i INFO: Handling Event TimedSubscription with data 51740b52-5115-4452-ac2a-bb593a2959c7.
w3wp!schedule!126!05/05/2016-05:39:29:: i INFO: Creating Time based subscription notification for subscription: 51740b52-5115-4452-ac2a-bb593a2959c7
w3wp!schedule!67!05/05/2016-05:39:29:: i INFO: Handling Event DataDrivenSubscription with data 51740B52-5115-4452-AC2A-BB593A2959C7.
w3wp!library!21!05/05/2016-05:39:29:: i INFO: Handling data-driven subscription 51740b52-5115-4452-ac2a-bb593a2959c7 to report https://go.mydomain.com/sites/bi/Reports/My report Name.rdl, owner: mydomain\ownername, delivery extension: Report Server FileShare.
w3wp!library!98!05/05/2016-05:39:29:: i INFO: Initializing EnableExecutionLogging to 'True'  as specified in Server system properties.
w3wp!notification!98!05/05/2016-05:39:46:: i INFO: Handling subscription 51740b52-5115-4452-ac2a-bb593a2959c7 to report My report Name.rdl, owner: mydomain\ownername, delivery extension: Report Server FileShare.
w3wp!library!98!05/05/2016-05:39:46:: i INFO: RenderForNewSession('https://go.mydomain.com/sites/bi/Reports/My report Name.rdl')
w3wp!library!98!05/05/2016-05:39:53:: i INFO: Initializing EnableExecutionLogging to 'True'  as specified in Server system properties.
w3wp!library!98!05/05/2016-05:39:53:: e ERROR: Throwing Microsoft.ReportingServices.FileShareDeliveryProvider.FileShareProvider+NetworkErrorException: An impersonation error occurred using the security context of the current user., Microsoft.ReportingServices.FileShareDeliveryProvider.FileShareProvider+NetworkErrorException: An impersonation error occurred using the security context of the current user. ---> System.Runtime.InteropServices.COMException: The referenced account is currently locked out and may not be logged on to. (Exception from HRESULT: 0x80070775)
   at System.Runtime.InteropServices.Marshal.ThrowExceptionForHRInternal(Int32 errorCode, IntPtr errorInfo)
   at Microsoft.ReportingServices.FileShareDeliveryProvider.FileShareProvider.GetImpersonationToken(String userName, String domain, String userPwd)
   --- End of inner exception stack trace ---;
w3wp!subscription!98!05/05/2016-05:39:53:: e ERROR: Failure writing file \\server\path$\path\path2\My report Name Export.xlsx : Microsoft.ReportingServices.FileShareDeliveryProvider.FileShareProvider+NetworkErrorException: An impersonation error occurred using the security context of the current user. ---> System.Runtime.InteropServices.COMException: The referenced account is currently locked out and may not be logged on to. (Exception from HRESULT: 0x80070775)
w3wp!subscription!98!05/05/2016-05:39:53:: i INFO: Error writing file My report Name Export.xlsx to path \\server\path$\path\path2
w3wp!notification!98!05/05/2016-05:39:53:: e ERROR: Error occurred processing subscription 51740b52-5115-4452-ac2a-bb593a2959c7: Failure writing file \\server\path$\path\path2\My report Name Export.xlsx : An impersonation error occurred using the security context of the current user.


--And Later on when the event is triggered again and the report is successful...

w3wp!schedule!4a!05/05/2016-08:33:04:: i INFO: Handling Event TimedSubscription with data 51740b52-5115-4452-ac2a-bb593a2959c7.
w3wp!schedule!4a!05/05/2016-08:33:04:: i INFO: Creating Time based subscription notification for subscription: 51740b52-5115-4452-ac2a-bb593a2959c7
w3wp!schedule!126!05/05/2016-08:33:04:: i INFO: Handling Event DataDrivenSubscription with data 51740B52-5115-4452-AC2A-BB593A2959C7.
w3wp!library!4d!05/05/2016-08:33:04:: i INFO: Handling data-driven subscription 51740b52-5115-4452-ac2a-bb593a2959c7 to report https://go.mydomain.com/sites/bi/Reports/My report Name.rdl, owner: mydomain\ownername, delivery extension: Report Server FileShare.
w3wp!notification!ca!05/05/2016-08:33:25:: i INFO: Handling subscription 51740b52-5115-4452-ac2a-bb593a2959c7 to report My report Name.rdl, owner: mydomain\ownername, delivery extension: Report Server FileShare.
w3wp!library!ca!05/05/2016-08:33:25:: i INFO: RenderForNewSession('https://go.mydomain.com/sites/bi/Reports/My report Name.rdl')
w3wp!library!ca!05/05/2016-08:33:27:: i INFO: Initializing EnableExecutionLogging to 'True'  as specified in Server system properties.
w3wp!notification!ca!05/05/2016-08:33:27:: i INFO: Notification 3361bf99-a2ce-4013-94eb-f33a4739fee4 completed.  Success: True, Status: The file "My report Name Export.xlsx" has been saved to the "\\server\path$\path\path2" file share., DeliveryExtension: Report Server FileShare, Report: My report Name.rdl, Attempt 0


Viewing all 10045 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>