Showing posts with label values. Show all posts
Showing posts with label values. Show all posts

Friday, March 30, 2012

report does not accept null values for its parameters

Hi all
Im using a stored procedure with in params as datasource to a report.
These params are initialized to null by default in the procedure.
When executing this datasource in the report designer's data tab
every thing works fine - i can live these parameters with nulls (or set
other values) and the procedures return appropriate results.
Then in the report parameters tab i allow these params to get null values,
with no default value.
But when executing the report in the 'preview' mode of visual studio i must
enter values for all params or else the report is not displayed at all (not
even with empty result set..).
No error massage is displayed - just the default blank background..
Thanks for your attention
ReaThe report will not execute unless you provide Default values in the Report
Parameters dialog. Without setting a default value on each and every
parameter, RS has no way of knowing what to use. It is unaware that your SP
has default values assigned.
hth
fmi see www.sqlreportingservices.net
____________________________________
William (Bill) Vaughn
Author, Mentor, Consultant
Microsoft MVP
www.betav.com
Please reply only to the newsgroup so that others can benefit.
This posting is provided "AS IS" with no warranties, and confers no rights.
__________________________________
"Rea Peleg" <rea_p@.afek.co.il> wrote in message
news:%23nq$JF3YEHA.2500@.TK2MSFTNGP09.phx.gbl...
> Hi all
> Im using a stored procedure with in params as datasource to a report.
> These params are initialized to null by default in the procedure.
> When executing this datasource in the report designer's data tab
> every thing works fine - i can live these parameters with nulls (or set
> other values) and the procedures return appropriate results.
> Then in the report parameters tab i allow these params to get null values,
> with no default value.
> But when executing the report in the 'preview' mode of visual studio i
must
> enter values for all params or else the report is not displayed at all
(not
> even with empty result set..).
> No error massage is displayed - just the default blank background..
> Thanks for your attention
> Rea
>|||ok then how do i set null values as default values for report's parameters'
i tried : null , =null, =System.DBnull - all were rejected by compilation.
Thanks again
Rea
"William (Bill) Vaughn" <billvaRemoveThis@.nwlink.com> wrote in message
news:uAKFBp3YEHA.1764@.TK2MSFTNGP10.phx.gbl...
> The report will not execute unless you provide Default values in the
Report
> Parameters dialog. Without setting a default value on each and every
> parameter, RS has no way of knowing what to use. It is unaware that your
SP
> has default values assigned.
> hth
> fmi see www.sqlreportingservices.net
>
> --
> ____________________________________
> William (Bill) Vaughn
> Author, Mentor, Consultant
> Microsoft MVP
> www.betav.com
> Please reply only to the newsgroup so that others can benefit.
> This posting is provided "AS IS" with no warranties, and confers no
rights.
> __________________________________
> "Rea Peleg" <rea_p@.afek.co.il> wrote in message
> news:%23nq$JF3YEHA.2500@.TK2MSFTNGP09.phx.gbl...
> > Hi all
> > Im using a stored procedure with in params as datasource to a report.
> > These params are initialized to null by default in the procedure.
> > When executing this datasource in the report designer's data tab
> > every thing works fine - i can live these parameters with nulls (or set
> > other values) and the procedures return appropriate results.
> > Then in the report parameters tab i allow these params to get null
values,
> > with no default value.
> > But when executing the report in the 'preview' mode of visual studio i
> must
> > enter values for all params or else the report is not displayed at all
> (not
> > even with empty result set..).
> > No error massage is displayed - just the default blank background..
> > Thanks for your attention
> > Rea
> >
> >
>|||=Nothing
(according to Peter)
--
____________________________________
William (Bill) Vaughn
Author, Mentor, Consultant
Microsoft MVP
www.betav.com
Please reply only to the newsgroup so that others can benefit.
This posting is provided "AS IS" with no warranties, and confers no rights.
__________________________________
"Rea Peleg" <rea_p@.afek.co.il> wrote in message
news:uip9OnAZEHA.1356@.TK2MSFTNGP09.phx.gbl...
> ok then how do i set null values as default values for report's
parameters'
> i tried : null , =null, =System.DBnull - all were rejected by compilation.
> Thanks again
> Rea
> "William (Bill) Vaughn" <billvaRemoveThis@.nwlink.com> wrote in message
> news:uAKFBp3YEHA.1764@.TK2MSFTNGP10.phx.gbl...
> > The report will not execute unless you provide Default values in the
> Report
> > Parameters dialog. Without setting a default value on each and every
> > parameter, RS has no way of knowing what to use. It is unaware that your
> SP
> > has default values assigned.
> >
> > hth
> > fmi see www.sqlreportingservices.net
> >
> >
> > --
> > ____________________________________
> > William (Bill) Vaughn
> > Author, Mentor, Consultant
> > Microsoft MVP
> > www.betav.com
> > Please reply only to the newsgroup so that others can benefit.
> > This posting is provided "AS IS" with no warranties, and confers no
> rights.
> > __________________________________
> >
> > "Rea Peleg" <rea_p@.afek.co.il> wrote in message
> > news:%23nq$JF3YEHA.2500@.TK2MSFTNGP09.phx.gbl...
> > > Hi all
> > > Im using a stored procedure with in params as datasource to a report.
> > > These params are initialized to null by default in the procedure.
> > > When executing this datasource in the report designer's data tab
> > > every thing works fine - i can live these parameters with nulls (or
set
> > > other values) and the procedures return appropriate results.
> > > Then in the report parameters tab i allow these params to get null
> values,
> > > with no default value.
> > > But when executing the report in the 'preview' mode of visual studio i
> > must
> > > enter values for all params or else the report is not displayed at all
> > (not
> > > even with empty result set..).
> > > No error massage is displayed - just the default blank background..
> > > Thanks for your attention
> > > Rea
> > >
> > >
> >
> >
>|||Thanks i found a way:
Null values should be added to the parameter's result set/data source.
Then you allow null values for it and set for default value - none.
I hope =Nothing does not work because i spent some 2 hours figuring in
out...:))
Rea
"William (Bill) Vaughn" <billvaRemoveThis@.nwlink.com> wrote in message
news:ew$ZIAJZEHA.2016@.TK2MSFTNGP09.phx.gbl...
> =Nothing
> (according to Peter)
> --
> ____________________________________
> William (Bill) Vaughn
> Author, Mentor, Consultant
> Microsoft MVP
> www.betav.com
> Please reply only to the newsgroup so that others can benefit.
> This posting is provided "AS IS" with no warranties, and confers no
rights.
> __________________________________
> "Rea Peleg" <rea_p@.afek.co.il> wrote in message
> news:uip9OnAZEHA.1356@.TK2MSFTNGP09.phx.gbl...
> > ok then how do i set null values as default values for report's
> parameters'
> > i tried : null , =null, =System.DBnull - all were rejected by
compilation.
> > Thanks again
> > Rea
> >
> > "William (Bill) Vaughn" <billvaRemoveThis@.nwlink.com> wrote in message
> > news:uAKFBp3YEHA.1764@.TK2MSFTNGP10.phx.gbl...
> > > The report will not execute unless you provide Default values in the
> > Report
> > > Parameters dialog. Without setting a default value on each and every
> > > parameter, RS has no way of knowing what to use. It is unaware that
your
> > SP
> > > has default values assigned.
> > >
> > > hth
> > > fmi see www.sqlreportingservices.net
> > >
> > >
> > > --
> > > ____________________________________
> > > William (Bill) Vaughn
> > > Author, Mentor, Consultant
> > > Microsoft MVP
> > > www.betav.com
> > > Please reply only to the newsgroup so that others can benefit.
> > > This posting is provided "AS IS" with no warranties, and confers no
> > rights.
> > > __________________________________
> > >
> > > "Rea Peleg" <rea_p@.afek.co.il> wrote in message
> > > news:%23nq$JF3YEHA.2500@.TK2MSFTNGP09.phx.gbl...
> > > > Hi all
> > > > Im using a stored procedure with in params as datasource to a
report.
> > > > These params are initialized to null by default in the procedure.
> > > > When executing this datasource in the report designer's data tab
> > > > every thing works fine - i can live these parameters with nulls (or
> set
> > > > other values) and the procedures return appropriate results.
> > > > Then in the report parameters tab i allow these params to get null
> > values,
> > > > with no default value.
> > > > But when executing the report in the 'preview' mode of visual studio
i
> > > must
> > > > enter values for all params or else the report is not displayed at
all
> > > (not
> > > > even with empty result set..).
> > > > No error massage is displayed - just the default blank background..
> > > > Thanks for your attention
> > > > Rea
> > > >
> > > >
> > >
> > >
> >
> >
>

Report Designer: preview goes into infinite loop

Hello,
Situation:
- a report with cascading parameters [A], [B], [C]
- first parameter [A] loaded via non-queried values
- second parameter [B] loaded via stored procedure, taking [A] and a
constant as input (via dataset dsB)
- third parameter [C] loaded via the same stored procedure, taking [A] and
[B] as input (via dataset dsC)
When I preview this report:
- initial view ok
- modify [A] -> [B] changes accordingly
- modify [B] -> the designer starts flickering and goes into a never ending
loop.
The deployed report works just fine and as expected.
Bug ? Any work arounds ?
Thanks for any input!
TomSounds like a bug. There is another bug I have found with the preview tab
and cascading parameters. It only cascades once. I.e. if you go back a
second time and change A it does not change B. Again, deploy works fine. I
have access to the the internal bug reporting tool and when I report the
previous but I'll do this one too. I am not aware of any workaround. At
least it works in deployed mode.
--
Bruce Loehle-Conger
MVP SQL Server Reporting Services
"Tom VdP" <unick@.hot_mail_.c-o-m> wrote in message
news:1FBF14D5-28E3-4B76-93BF-47F292BC33FE@.microsoft.com...
> Hello,
> Situation:
> - a report with cascading parameters [A], [B], [C]
> - first parameter [A] loaded via non-queried values
> - second parameter [B] loaded via stored procedure, taking [A] and a
> constant as input (via dataset dsB)
> - third parameter [C] loaded via the same stored procedure, taking [A] and
> [B] as input (via dataset dsC)
> When I preview this report:
> - initial view ok
> - modify [A] -> [B] changes accordingly
> - modify [B] -> the designer starts flickering and goes into a never
ending
> loop.
> The deployed report works just fine and as expected.
> Bug ? Any work arounds ?
> Thanks for any input!
> Tom|||Thanks for reporting it.
It is annoying as the first parameter in our reports is the choice of
language. Depending on the selection the contents of the other dropdown
boxes is changed.
So we have cascading parameters in every report.
But we can use the deployed reports luckily.
Regards,
Tom
"Bruce L-C [MVP]" wrote:
> Sounds like a bug. There is another bug I have found with the preview tab
> and cascading parameters. It only cascades once. I.e. if you go back a
> second time and change A it does not change B. Again, deploy works fine. I
> have access to the the internal bug reporting tool and when I report the
> previous but I'll do this one too. I am not aware of any workaround. At
> least it works in deployed mode.
> --
> Bruce Loehle-Conger
> MVP SQL Server Reporting Services
>
> "Tom VdP" <unick@.hot_mail_.c-o-m> wrote in message
> news:1FBF14D5-28E3-4B76-93BF-47F292BC33FE@.microsoft.com...
> >
> > Hello,
> >
> > Situation:
> > - a report with cascading parameters [A], [B], [C]
> > - first parameter [A] loaded via non-queried values
> > - second parameter [B] loaded via stored procedure, taking [A] and a
> > constant as input (via dataset dsB)
> > - third parameter [C] loaded via the same stored procedure, taking [A] and
> > [B] as input (via dataset dsC)
> >
> > When I preview this report:
> > - initial view ok
> > - modify [A] -> [B] changes accordingly
> > - modify [B] -> the designer starts flickering and goes into a never
> ending
> > loop.
> >
> > The deployed report works just fine and as expected.
> >
> > Bug ? Any work arounds ?
> >
> > Thanks for any input!
> > Tom
>
>|||I am not using cascading parameters but I have experieced a similiar problems
with the Report Designer preview (loops) and I sometimes get a Processing
Error 'Specified Cast in not Valid' , If I remove the Page Header OR Footer I
do not get the error, OR if there is labels only (no ReportItems! or Globals!
in the header/footer) it works.
There are no problems when the report is deployed.
"Tom VdP" wrote:
> Thanks for reporting it.
> It is annoying as the first parameter in our reports is the choice of
> language. Depending on the selection the contents of the other dropdown
> boxes is changed.
> So we have cascading parameters in every report.
> But we can use the deployed reports luckily.
> Regards,
> Tom
>
> "Bruce L-C [MVP]" wrote:
> > Sounds like a bug. There is another bug I have found with the preview tab
> > and cascading parameters. It only cascades once. I.e. if you go back a
> > second time and change A it does not change B. Again, deploy works fine. I
> > have access to the the internal bug reporting tool and when I report the
> > previous but I'll do this one too. I am not aware of any workaround. At
> > least it works in deployed mode.
> > --
> > Bruce Loehle-Conger
> > MVP SQL Server Reporting Services
> >
> >
> > "Tom VdP" <unick@.hot_mail_.c-o-m> wrote in message
> > news:1FBF14D5-28E3-4B76-93BF-47F292BC33FE@.microsoft.com...
> > >
> > > Hello,
> > >
> > > Situation:
> > > - a report with cascading parameters [A], [B], [C]
> > > - first parameter [A] loaded via non-queried values
> > > - second parameter [B] loaded via stored procedure, taking [A] and a
> > > constant as input (via dataset dsB)
> > > - third parameter [C] loaded via the same stored procedure, taking [A] and
> > > [B] as input (via dataset dsC)
> > >
> > > When I preview this report:
> > > - initial view ok
> > > - modify [A] -> [B] changes accordingly
> > > - modify [B] -> the designer starts flickering and goes into a never
> > ending
> > > loop.
> > >
> > > The deployed report works just fine and as expected.
> > >
> > > Bug ? Any work arounds ?
> > >
> > > Thanks for any input!
> > > Tom
> >
> >
> >

Friday, March 23, 2012

Report Builder: Is there a way to filter a filter?

Dear Anyone,

We have a report model that connects to a single table. Some of the columns of the table contains blank values which is regarded as a valid value in our reports.

We have a requirement that the filter selection should not contain any blank values. They do not want to include a blank value for the users to choose but if the users decide not to use a filter, those blank values should still be included in the report.

Does anyone have any suggestions on how to do this in RB? We already made this work in RS2k5 but we can't seem to find any way to do this in RB.

Thanks,
Joseph

No, there is no way to control the list of values presented to the user. It is always a list of all existing values in the underlying database.

Wednesday, March 21, 2012

Report Builder, Aggregation Scope and Running Values

Dear Anyone,

I need to create a measure/column that is percent of column (or row, not sure). In Reporting services, we were able to do this because aggregations there had scope.

=Sum(Fields!Open_Demand.Value)/Sum(Fields!Open_Demand.Value,"GSD")

I can't seem to do this in RB because the aggregation there does not seem to have a scope. Nor does it have the function running value.

Does anyone have an idea on how to do this on Report Builder?
Thanks,
Joseph

Report Builder does not expose the scope parameter for aggregation. You can often get the same results, however, by including a separate field that retrieves the total for the set you want.

For example, you can create a (hypothetical) report like this:

Category | Product Name | Total Sales | % of Category

...if Category is an entity in your report model. If it is a lookup entity, you will need to turn on View->Advanced Mode in RB to see it.

Here's how:

Select Product Entity
Add Product Name field to report
Add Category field to left of Product Name
Add Sales->Total Sales to report TWICE
Right-click on the value cell of the second Total Sales field, choose Edit Formula
Type "/" after the Total Sales field in the formula textbox
Add Product->Category->Products->Sales->Total Sales to the formula
- this is the total sales for all products in the same category as this product
Click OK
Change the format on the second field from $ to %
Run the report

This will be notably slower than using RDL scoping, but it should work.

PS: Due to a known issue in RTM, the subtotals you display for the % field above will be incorrect. This will be fixed in SP1. Meanwhile, if you choose "Server Totals" in the Report->Report Properties dialog, you will get the correct subtotals as well.

|||

Hi Bob,

We've tried what you suggested but we seem to be getting a 1 result. We've enabled server totals and the answer still is the same. We are currently using the RTM build.

Thanks,

Joseph

Report Builder, Aggregation Scope and Running Values

Dear Anyone,

I need to create a measure/column that is percent of column (or row, not sure). In Reporting services, we were able to do this because aggregations there had scope.

=Sum(Fields!Open_Demand.Value)/Sum(Fields!Open_Demand.Value,"GSD")

I can't seem to do this in RB because the aggregation there does not seem to have a scope. Nor does it have the function running value.

Does anyone have an idea on how to do this on Report Builder?
Thanks,
Joseph

Report Builder does not expose the scope parameter for aggregation. You can often get the same results, however, by including a separate field that retrieves the total for the set you want.

For example, you can create a (hypothetical) report like this:

Category | Product Name | Total Sales | % of Category

...if Category is an entity in your report model. If it is a lookup entity, you will need to turn on View->Advanced Mode in RB to see it.

Here's how:

Select Product Entity
Add Product Name field to report
Add Category field to left of Product Name
Add Sales->Total Sales to report TWICE
Right-click on the value cell of the second Total Sales field, choose Edit Formula
Type "/" after the Total Sales field in the formula textbox
Add Product->Category->Products->Sales->Total Sales to the formula
- this is the total sales for all products in the same category as this product
Click OK
Change the format on the second field from $ to %
Run the report

This will be notably slower than using RDL scoping, but it should work.

PS: Due to a known issue in RTM, the subtotals you display for the % field above will be incorrect. This will be fixed in SP1. Meanwhile, if you choose "Server Totals" in the Report->Report Properties dialog, you will get the correct subtotals as well.

|||

Hi Bob,

We've tried what you suggested but we seem to be getting a 1 result. We've enabled server totals and the answer still is the same. We are currently using the RTM build.

Thanks,

Joseph

Report Builder Top N functionality

I'm not seeing any built-in functionality for Report Builder to get Top N values. Am I missing something? Is there a way to do this? If not, is there a way to simulate this functionality?

Thanks.

PJJ

This should help:

http://msevents.microsoft.com/cui/WebCastEventDetails.aspx?culture=en-US&EventID=1032306508&CountryCode=US

Tuesday, March 20, 2012

Report Builder Filter drop down list - when the list is more than 500 values

Hi All,

I build a model (either from Cube or from tables) and open it in report builder. When I select a FIELTER on field which has few distinct values like state code, I get a drop down list. But when I select a filter on 'Dept Name', the drop down list on filter disapears. I have to manually key the filter value.

Can any one help me in getting a drop down list on filter, when distinct values in that column are more than few hundred.

Regards

Bobba

This is controlled by a property InstanceSelection, that can be set on each attribute of a dimension (within the dimension Editor).

The cube/dimension wizard initially sets this property, but then it can be changed as required.

Report Builder error.

Hi,

I am facing a peculiar situation where my ad-hoc report is inter-mittently giving me the following error based on the parameter values I am selecting from the dropdown. What could be the possible reasons for this ?


Report execution error
The report might not be valid or the server could not process the data.

An existing connection was forcibly closed by the remote host.
-
Unable to read data from the transport connection:An existing connection was forcibly closed by the remote host.
-
The underlying connection was closed: An unexpected error occured on a receive.


In the same report if I try to add another runtime filter, the application crashes. This filter field has about 50k available values.Is that the reason for such behaviour? What can be the possible solution here ?

Is this error displayed during execution (preview) of the report or during design-time?

If it is being displayed during design-time, try opening the model in Model Designer and change the element's "Value Selection" property to "None". This will tell Report Builder to use a textbox instead of a dropdown menu for this element.

If this error is during execution (preview) of the report, does it occur when the report is published and executed directly from the server?

HTH, Jason Tremper

|||

Hi !

Sorry for the late response !The error is shown during execution of the ad-hoc report . As I said the above error comes only if I select some particular set of values from the parameter dropdowns.
The other question is that of the filter condition.The application crashes during the design time when I try to apply that filter.This filter probably tries to load all the available values which is about 50k!
I cannot make the 'Value Selection' property to 'None'. The user won't have a clue as to what to enter in the text box.

Report Builder error.

Hi,

I am facing a peculiar situation where my ad-hoc report is inter-mittently giving me the following error based on the parameter values I am selecting from the dropdown. What could be the possible reasons for this ?


Report execution error
The report might not be valid or the server could not process the data.

An existing connection was forcibly closed by the remote host.
-
Unable to read data from the transport connection:An existing connection was forcibly closed by the remote host.
-
The underlying connection was closed: An unexpected error occured on a receive.


In the same report if I try to add another runtime filter, the application crashes. This filter field has about 50k available values.Is that the reason for such behaviour? What can be the possible solution here ?

Is this error displayed during execution (preview) of the report or during design-time?

If it is being displayed during design-time, try opening the model in Model Designer and change the element's "Value Selection" property to "None". This will tell Report Builder to use a textbox instead of a dropdown menu for this element.

If this error is during execution (preview) of the report, does it occur when the report is published and executed directly from the server?

HTH, Jason Tremper

|||

Hi !

Sorry for the late response !The error is shown during execution of the ad-hoc report . As I said the above error comes only if I select some particular set of values from the parameter dropdowns.
The other question is that of the filter condition.The application crashes during the design time when I try to apply that filter.This filter probably tries to load all the available values which is about 50k!
I cannot make the 'Value Selection' property to 'None'. The user won't have a clue as to what to enter in the text box.

Monday, March 12, 2012

Report Builder and NULL values

Hi,

I am trying to create a report with Report Builder, using a simple data model residing on SQL2005 reporting server.

The problem that literally drives me crazy is that I can't find any way to handle NULL values in my report. Say, a table has 3 numeric columns, and I need to create a formula to make a sum of those 3 columns. This would be an ordinary sum for the same entity, not an aggregate. So I create a new formula with following body:

Field1 + Field2 + Field3

The problem is, each one of the 3 columns can have NULL values, and if any column actually is NULL, I end up with empty sum value, instead of having sum of those columns that do have values.

What I need is one of the following:

- a way to check for NULL values before summarizing, like ISNOTHING() in Report Designer

- a way to replace NULL values with empty values, like ISNULL() or COALESCE() in TSQL

- a way to tell the report to just convert NULLs to empty values, like in Crystal Reports.

I haven't been able to find any of the above in Report Builder. Please help me!

Denis

This is a nice usability feature request.

Right now you can do it by building the following expression:
if(Field1 = Empty, 0, Field1) + if(Field2 = Empty, 0, Field2) + ...

|||

Thank you Alexander, this worked like a charm.

I think that this Empty keyword should be mentioned in Report Builder help system, or in a KB article.

Best regards,

Denis

P.S. Please also read my another usability request that I will submit very shortly.