Monday, March 26, 2012
Report-Sub Report in Visual Studio 2005
I have a problem on connecting subreports with reports.
I create the sub report, bind data to it, and filter the
data (in the query) with something like Case_Id = @.ParamCaseID.
I create the parameter ParamCaseID in the subreport and then I go
to the primary report and set the property parameters of the subreport
to ParamCaseID and value to (=Fields!PrimaryCaseID.Value).
I run the application to see the report and although the report is
showing I get the error "Subreport could not be shown" in the
place where the subreport was supposed to appear.
What am I doing wrong ?
Any help would be useful .
Thanks in advance.
To answer by e-mail remove the "bog" from the e-mail.I use SQL Server 2005 Reporting Services of course.sql
ReportService2005 and ReportExecution2005
Help!
Can anyone explain the difference between these two web services?
I want to create an ASPX page that develops report parameters and then uses those parameters to render a report which I will display in an image box. Which service do I need?
Is there a place to read about how to use each of them?
Thanks!
Neither :-).
You need the ReportViewer control that comes with Visual Studio 2005 or can be downloaded here:
http://www.microsoft.com/downloads/details.aspx?FamilyID=8a166cac-758d-45c8-b637-dd7726e61367&DisplayLang=en
This will allow you to embed a report directly in your page - no need for picture boxes :-). It will also provide you the APIs for setting parameters.
Using the ReportExecution2005 endpoint you could achieve this, but it would be a lot of work to handle all the possible cases. The ReportViewer controls let you do this very quickly and handle all the interaction with the Report Server for you.
-Lukasz
This posting is provided "AS IS" with no warranties, and confers no rights.
Lukasz,
Thank you for your reply.
I have used the report viewer control when I am willing to have the parameter prompts managed by the report. I don't understand how to use the report viewer's API to render the report when I want it rendered, and how to provide parameters from outside the control. Do you know of an example or a reference?
Ira
|||
You can find samples here: www.gotreportviewer.com There is a sample called "Parameter prompting in local mode" that you should be able to reuse, just in Server mode.
Also, you can ask this question on the Report Viewer forum. It might already be answered there.
http://forums.microsoft.com/msdn/showforum.aspx?forumid=75&siteid=1
-Lukasz
This posting is provided "AS IS" with no warranties, and confers no rights.
Lukasz,
Mission accomplished!
It's amazing how easy things are when you find the right approach. Thanks.
Ira
ReportService Deployment
servers. Based on googling it seems the only way to do this is via script
or direct calls using SOAP and VS.2005 has not direct support for creating
setup programs.
Is this correct or is there a better way?
Regards,
JohnThere is no direct support for creating an MSI to do deployments, but it
would be fairly easy to write one to push the reports yourself.
"John J. Hughes II" <no@.invalid.com> wrote in message
news:up6Lve8iGHA.4776@.TK2MSFTNGP05.phx.gbl...
>I need to create a installation for a group of report on our customer
>servers. Based on googling it seems the only way to do this is via script
>or direct calls using SOAP and VS.2005 has not direct support for creating
>setup programs.
> Is this correct or is there a better way?
> Regards,
> John
>|||Sorry. crappy response.
You can create a setup project and a custom installer that connects to the
report server and, using the web service calls, adds the reports.
I think you can also use RSS to perform installations.
"John J. Hughes II" <no@.invalid.com> wrote in message
news:up6Lve8iGHA.4776@.TK2MSFTNGP05.phx.gbl...
>I need to create a installation for a group of report on our customer
>servers. Based on googling it seems the only way to do this is via script
>or direct calls using SOAP and VS.2005 has not direct support for creating
>setup programs.
> Is this correct or is there a better way?
> Regards,
> John
>|||Thanks, guess MS only supports the product partially still.
Regards,
John
"Tim Dot NoSpam" <Tim.NoSpam@.hughes.net> wrote in message
news:esmwbxajGHA.4508@.TK2MSFTNGP05.phx.gbl...
> Sorry. crappy response.
> You can create a setup project and a custom installer that connects to the
> report server and, using the web service calls, adds the reports.
> I think you can also use RSS to perform installations.
> "John J. Hughes II" <no@.invalid.com> wrote in message
> news:up6Lve8iGHA.4776@.TK2MSFTNGP05.phx.gbl...
>>I need to create a installation for a group of report on our customer
>>servers. Based on googling it seems the only way to do this is via
>>script or direct calls using SOAP and VS.2005 has not direct support for
>>creating setup programs.
>> Is this correct or is there a better way?
>> Regards,
>> John
>
Wednesday, March 21, 2012
ReportServer
I want to create ReportServer which processes crystal report and sybase database using c#. Particulary this report server
get parameters from user and process this report send it back to user additional also send email,print,ftp etc... Also report server should be able to schedule reports as per user request.
Does microsoft gives any classes /services to start programming for this? Any suggestion or Any Idea ?
thanks for looking into this..
Out of the box .NET supports SQL Server and Crystal Reports. I don't know about Sybase. For SQL .NET has builtin support for displaying reports in WinForms or WebForms (Microsoft.Reporting). CR does the same thing (CrystalDecisions.Web) but they are in no way related.
In projects past if my app had to support multiple reporting subsystems then I created a generalized reporting manager with abstract report and parameter classes from which I derived specific types for SQL, CR or whatever. This is a lot of work and you are ultimately tied to the LCM of the reports. For example if Sybase doesn't support scheduling then you can't do it irrelevant of what your interface exposes. Therefore you must either target the LCM or do some sort of "Supports feature X" system to allow the generalized components to play nice together.
Michael Taylor - 9/14/07
http://p3net.mvps.org
|||what is LCM ?|||Least Common Multiple. In the context of this discussion the list of features shared by all reporting types (such as types, parameter options, etc).
Michael Taylor - 9/25/07
http://p3net.mvps.org
|||thanks for your reply.
I am now planning to write my own report manager. Because i tried "Crystal Report Server" , but it has limitation with features what I need
I am planning to write report manager which supports
- View /print/mail/ftp reports
- also schedule a job which containts bunch of reports with predefined parametes
- most important we also want to put user request in queue if other user is has submitted request for this report. this
type of reports take long time and may cause dead lock on database.
again thanks for your time
ReportServer
I want to create ReportServer which processes crystal report and sybase database using c#. Particulary this report server
get parameters from user and process this report send it back to user additional also send email,print,ftp etc... Also report server should be able to schedule reports as per user request.
Does microsoft gives any classes /services to start programming for this? Any suggestion or Any Idea ?
thanks for looking into this..
Out of the box .NET supports SQL Server and Crystal Reports. I don't know about Sybase. For SQL .NET has builtin support for displaying reports in WinForms or WebForms (Microsoft.Reporting). CR does the same thing (CrystalDecisions.Web) but they are in no way related.
In projects past if my app had to support multiple reporting subsystems then I created a generalized reporting manager with abstract report and parameter classes from which I derived specific types for SQL, CR or whatever. This is a lot of work and you are ultimately tied to the LCM of the reports. For example if Sybase doesn't support scheduling then you can't do it irrelevant of what your interface exposes. Therefore you must either target the LCM or do some sort of "Supports feature X" system to allow the generalized components to play nice together.
Michael Taylor - 9/14/07
http://p3net.mvps.org
|||what is LCM ?|||Least Common Multiple. In the context of this discussion the list of features shared by all reporting types (such as types, parameter options, etc).
Michael Taylor - 9/25/07
http://p3net.mvps.org
|||thanks for your reply.
I am now planning to write my own report manager. Because i tried "Crystal Report Server" , but it has limitation with features what I need
I am planning to write report manager which supports
- View /print/mail/ftp reports
- also schedule a job which containts bunch of reports with predefined parametes
- most important we also want to put user request in queue if other user is has submitted request for this report. this
type of reports take long time and may cause dead lock on database.
again thanks for your time
sqlReportServer
I want to create ReportServer which processes crystal report and sybase database using c#. Particulary this report server
get parameters from user and process this report send it back to user additional also send email,print,ftp etc... Also report server should be able to schedule reports as per user request.
Does microsoft gives any classes /services to start programming for this? Any suggestion or Any Idea ?
thanks for looking into this..
Out of the box .NET supports SQL Server and Crystal Reports. I don't know about Sybase. For SQL .NET has builtin support for displaying reports in WinForms or WebForms (Microsoft.Reporting). CR does the same thing (CrystalDecisions.Web) but they are in no way related.
In projects past if my app had to support multiple reporting subsystems then I created a generalized reporting manager with abstract report and parameter classes from which I derived specific types for SQL, CR or whatever. This is a lot of work and you are ultimately tied to the LCM of the reports. For example if Sybase doesn't support scheduling then you can't do it irrelevant of what your interface exposes. Therefore you must either target the LCM or do some sort of "Supports feature X" system to allow the generalized components to play nice together.
Michael Taylor - 9/14/07
http://p3net.mvps.org
|||what is LCM ?|||Least Common Multiple. In the context of this discussion the list of features shared by all reporting types (such as types, parameter options, etc).
Michael Taylor - 9/25/07
http://p3net.mvps.org
|||thanks for your reply.
I am now planning to write my own report manager. Because i tried "Crystal Report Server" , but it has limitation with features what I need
I am planning to write report manager which supports
- View /print/mail/ftp reports
- also schedule a job which containts bunch of reports with predefined parametes
- most important we also want to put user request in queue if other user is has submitted request for this report. this
type of reports take long time and may cause dead lock on database.
again thanks for your time
Reports without Using VS ?
so.. how?
Thanks,
RichYou cannot not avoid having some component of Visual Studio installed if you
want to use Report Designer.
You might want to review what tools are offered by our partners:
http://www.microsoft.com/sql/reporting/partners/default.asp
--
Bruce Johnson [MSFT]
Microsoft SQL Server Reporting Services
This posting is provided "AS IS" with no warranties, and confers no rights.
"Richard Morey" <rwmorey71@.hotmail.com> wrote in message
news:uZIYfN$nEHA.628@.TK2MSFTNGP10.phx.gbl...
> Can I create reports for Report Services without having Visual Studio? If
> so.. how?
> Thanks,
> Rich
>|||Hi,
Is there any kind of freely downloadable thing that I can use? It seems a
little strange to me that Report Services would ship free with SQL Server
2000 but not include something to actually build reports with.. :-(
Rich
"Bruce Johnson [MSFT]" <brucejoh@.online.microsoft.com> wrote in message
news:exwu%23l$nEHA.2300@.TK2MSFTNGP10.phx.gbl...
> You cannot not avoid having some component of Visual Studio installed if
> you
> want to use Report Designer.
> You might want to review what tools are offered by our partners:
> http://www.microsoft.com/sql/reporting/partners/default.asp
> --
> Bruce Johnson [MSFT]
> Microsoft SQL Server Reporting Services
> This posting is provided "AS IS" with no warranties, and confers no
> rights.
>
> "Richard Morey" <rwmorey71@.hotmail.com> wrote in message
> news:uZIYfN$nEHA.628@.TK2MSFTNGP10.phx.gbl...
>> Can I create reports for Report Services without having Visual Studio? If
>> so.. how?
>> Thanks,
>> Rich
>>
>|||That is the intention with Yukon. For now all you need is some sort of
version of VS. The least expensive would be around $100 (VB.Net).
Bruce L-C
"Richard Morey" <rwmorey71@.hotmail.com> wrote in message
news:e3xoyvAoEHA.3224@.tk2msftngp13.phx.gbl...
> Hi,
> Is there any kind of freely downloadable thing that I can use? It seems a
> little strange to me that Report Services would ship free with SQL Server
> 2000 but not include something to actually build reports with.. :-(
> Rich
> "Bruce Johnson [MSFT]" <brucejoh@.online.microsoft.com> wrote in message
> news:exwu%23l$nEHA.2300@.TK2MSFTNGP10.phx.gbl...
> > You cannot not avoid having some component of Visual Studio installed if
> > you
> > want to use Report Designer.
> > You might want to review what tools are offered by our partners:
> > http://www.microsoft.com/sql/reporting/partners/default.asp
> >
> > --
> > Bruce Johnson [MSFT]
> > Microsoft SQL Server Reporting Services
> >
> > This posting is provided "AS IS" with no warranties, and confers no
> > rights.
> >
> >
> > "Richard Morey" <rwmorey71@.hotmail.com> wrote in message
> > news:uZIYfN$nEHA.628@.TK2MSFTNGP10.phx.gbl...
> >> Can I create reports for Report Services without having Visual Studio?
If
> >> so.. how?
> >>
> >> Thanks,
> >>
> >> Rich
> >>
> >>
> >
> >
>|||Would one of the "Express" version of VB, etc.. work?
Also, I would be developing reports on my machine, not on the server running
Report Services. What do I need to install on my machine to get Report
Writer to run?
I also hae Delphi.Net on my computer -- is this enough to install Report
Writer?
Rich
"Bruce Loehle-Conger" <bruce_lcNOSPAM@.hotmail.com> wrote in message
news:uDDLfABoEHA.3464@.TK2MSFTNGP14.phx.gbl...
> That is the intention with Yukon. For now all you need is some sort of
> version of VS. The least expensive would be around $100 (VB.Net).
> Bruce L-C
> "Richard Morey" <rwmorey71@.hotmail.com> wrote in message
> news:e3xoyvAoEHA.3224@.tk2msftngp13.phx.gbl...
>> Hi,
>> Is there any kind of freely downloadable thing that I can use? It seems a
>> little strange to me that Report Services would ship free with SQL Server
>> 2000 but not include something to actually build reports with.. :-(
>> Rich
>> "Bruce Johnson [MSFT]" <brucejoh@.online.microsoft.com> wrote in message
>> news:exwu%23l$nEHA.2300@.TK2MSFTNGP10.phx.gbl...
>> > You cannot not avoid having some component of Visual Studio installed
>> > if
>> > you
>> > want to use Report Designer.
>> > You might want to review what tools are offered by our partners:
>> > http://www.microsoft.com/sql/reporting/partners/default.asp
>> >
>> > --
>> > Bruce Johnson [MSFT]
>> > Microsoft SQL Server Reporting Services
>> >
>> > This posting is provided "AS IS" with no warranties, and confers no
>> > rights.
>> >
>> >
>> > "Richard Morey" <rwmorey71@.hotmail.com> wrote in message
>> > news:uZIYfN$nEHA.628@.TK2MSFTNGP10.phx.gbl...
>> >> Can I create reports for Report Services without having Visual Studio?
> If
>> >> so.. how?
>> >>
>> >> Thanks,
>> >>
>> >> Rich
>> >>
>> >>
>> >
>> >
>>
>|||The express version is a beta of the next release of VB. The report designer
will not work with that version of Visual Studio. The report writer is
separate from the server. You can install both but you do not have to.
Indeed, it will be common to not have the designer on the same machine as
the server. The server install makes it seem like you have both together but
you can just ignore the message about VS when installing the server.
I doubt the Report Writer would install with Delphi.Net. Think of the report
writer as an add-on to VS.
At a minimum you need VS 2003 (any version) and dotnet 1.1, some version of
MDAC 2.6 or higher.If you have a version of VS 2003 the rest of the
requirements will be checked for during the install and installed if they
are not there.
Bruce L-C
"Richard Morey" <rwmorey71@.hotmail.com> wrote in message
news:uC$MIENoEHA.2900@.TK2MSFTNGP09.phx.gbl...
> Would one of the "Express" version of VB, etc.. work?
> Also, I would be developing reports on my machine, not on the server
running
> Report Services. What do I need to install on my machine to get Report
> Writer to run?
> I also hae Delphi.Net on my computer -- is this enough to install Report
> Writer?
> Rich
> "Bruce Loehle-Conger" <bruce_lcNOSPAM@.hotmail.com> wrote in message
> news:uDDLfABoEHA.3464@.TK2MSFTNGP14.phx.gbl...
> > That is the intention with Yukon. For now all you need is some sort of
> > version of VS. The least expensive would be around $100 (VB.Net).
> >
> > Bruce L-C
> >
> > "Richard Morey" <rwmorey71@.hotmail.com> wrote in message
> > news:e3xoyvAoEHA.3224@.tk2msftngp13.phx.gbl...
> >> Hi,
> >>
> >> Is there any kind of freely downloadable thing that I can use? It seems
a
> >> little strange to me that Report Services would ship free with SQL
Server
> >> 2000 but not include something to actually build reports with.. :-(
> >>
> >> Rich
> >>
> >> "Bruce Johnson [MSFT]" <brucejoh@.online.microsoft.com> wrote in message
> >> news:exwu%23l$nEHA.2300@.TK2MSFTNGP10.phx.gbl...
> >> > You cannot not avoid having some component of Visual Studio installed
> >> > if
> >> > you
> >> > want to use Report Designer.
> >> > You might want to review what tools are offered by our partners:
> >> > http://www.microsoft.com/sql/reporting/partners/default.asp
> >> >
> >> > --
> >> > Bruce Johnson [MSFT]
> >> > Microsoft SQL Server Reporting Services
> >> >
> >> > This posting is provided "AS IS" with no warranties, and confers no
> >> > rights.
> >> >
> >> >
> >> > "Richard Morey" <rwmorey71@.hotmail.com> wrote in message
> >> > news:uZIYfN$nEHA.628@.TK2MSFTNGP10.phx.gbl...
> >> >> Can I create reports for Report Services without having Visual
Studio?
> > If
> >> >> so.. how?
> >> >>
> >> >> Thanks,
> >> >>
> >> >> Rich
> >> >>
> >> >>
> >> >
> >> >
> >>
> >>
> >
> >
>
Reports without Dataset ?
Hi,
I want to create SQL reports without using typedDataset.
Here is my scenario..
I am building a 3-tier arch website. On my web layer I want to display few reports and as a datasource I want to use my business objects which lays in buisness layer classes as methods. These methods returns DataTable.
I want to use this methods as datasource for my reports without getting dataset in picture. My problem is that while desinging report, it is taking Dataset as default datasource and its building it in App code. I don't want this, instead, I want to point my reports to Object Data Source and ODS to my business objects.
Is it possible to get rid of DataSet completly while designing reports? If yes than How to do it?
Thanks in advance
Regards,
ND
Hi,
From your description, it seems that you want to use the dataset as the datasource of your report project, right?
Based on my understanding, you can create a webservice which returns the dataset, and then regard the dataset as the datasource of your report. And then, in that webservice, you can call the methods which comes from your business layer to get the data you need.
For detail:
1. Create a webservice project, and create a webmethod, and then add the reference of your business class, and invoke the methods to get the data, create an dataset which is used to contain the data from your business layer. After that, you should deploy the webservice in your IIS.
2. Create a reporting service project, and then crate a new datasource in the SharedDataSource, set the Type to XML, assign the connection String property with the webservice address you created just now.
3. Create a new report, assign the Query String as:
<Query xmlns="http://Eric.org/">
<SoapAction>http://Eric.org/GetDataSource</SoapAction>
</Query>
For more usage about QueryString, seehttp://msdn2.microsoft.com/en-us/library/ms345251.aspx
Thanks.
Thanks for the details..
Actually I don't want to use Dataset for my reports, How to achieve this?
While designing reports, It always creates Dataset and then display all the fields from the connected source. Instead of that, I want something what you mentioned in your reply but, WITHOUT using XML.
My scenario is the same, Its 3-tiers application, Fetching data by using WebService methods.
Regards,
ND
Reports using Dynamic Columns
I am facing a problem with the SQL reporting Service and also am pretty much new to the reporting service…
I need to create a yearly report from a table called say tblData. It has rows like
[items] [Amount] [Date].
Item1 100 05/2005
Item1 110 06/2005
Item2 200 05/2005
Item2 230 06/2005
Now I want the report like
[Items] [First month] [Second month] etc...
The data for the first month, second month etc will be the [amount] for that month.
ie the report rows should be like
[item] [05/2005] [06/2005]
item 1 100 110
item 2 200 230
In the report the month columns will be dynamic according to the data in the tblData table...
Now how should I implement this?
First I though of writing up a Stored Procedure so that the sp returns the formatted data (i.e. a returning a table having the having the dynamic columns). But how can I create the report using these dynamic columns in the reporting service?
Thanks in advance for the replies…
ASMSYou can achieve this with a matrix report item and using a column grouping expression of =Year(Fields!Date.Value)*100 + Month(Fields!Date.Value) to achieve the grouping based on Month/Year.
You may also want to take a look at the sample reports that ship with RS 2000 and RS 2005. Specifically, look at the "Company Sales" report sample.
-- Robert
Tuesday, March 20, 2012
Reports subscription
Hello to everyone!
I have a question. I need to create subscriptions for set of reports. I have a task to send it via e-mail but I need to be able to send not to e-mail but for user name from Global Address List or for whole groups. When I just type user name from that list I got an error that invalid e-mail. Is it possible to do it or I need to use e-mail?
Thanks,
You would need to use e-mail to send to email addresses. SQL RS can't talk to Outlook.
You could probably write a custom wrapper to convert user names / distribution lists to email addresses, and append to the subscription.
Alternatively you should be able to setup the subscriptions using a command line or script.
http://www.sqldbatips.com/showarticle.asp?ID=62 - Try RS Scripter to see examples of subscription scripts.
hope this helps!
Andrew
Reports on Cubes of SQL 2000
We have to create reports based on cubes, which were designed using SQL 2000. We have migrated to SQL 2005. We have the cubes (.cub files). We need to design few sample reports based on these cubes (specifically some charts).
Any idea, how can we use these cubes as data source in the reports RS 2005. Can anyone guide us or point to the right direction, what are the steps to be followed here, like do we need to import these cubes into a 2005 database or can these be just copied in a folder and referred directly. basically where and how to start from.
Any suggestion or help is appreciated.
One good starting point might be this link:
http://www.microsoft.com/downloads/details.aspx?FamilyID=f9b6e945-1f4c-4b7c-9c83-c6801f0576ff&DisplayLang=en
It is a rs 2000 sample that uses cubes. I hope this helps
reports on AD elements
Active Directory as the data source? I need to pull a
report listing two fields: User and e-mail address(from
exchange). Any help is appreciated. Thanks, RonI found the info. it is included in case someone else would like to know how to do it:
Other Data Sources
One exciting aspect of SRS is its ability to query multiple data source types in addition to SQL Server. Any ODBC or OLE-DB provider can be a potential data source for SRS. We will be covering two of these additional providers while covering both developing reports in SRS as well as examining an overall Business Intelligence platform with Analysis Services in a later chapter.
For a simple example of using a data source other than a SQL Server database, let=D5s look at the OLE-DB Provider for Directory Services. By using a direct LDAP query, it is possible to generate field information for use in SRS.
SELECT cn,sn,objectcategory,department
FROM 'LDAP://DirectoryServerName/ OU=3DOuName ,DC=3DCompany,DC=3DCom'
The query uses a standard SQlLdialect that will return the common name, surname, objectcategory (computer or person) and department from the Active Directory. The field names will be automatically created and can be used like any other data field for a report.
There are couple of caveats that must be taken into consideration when querying AD, as well as other data sources that do not support the graphical query designer in SRS.
* Query Parameters are not supported directly in the query, however, Report Parameters can be defined and utilized both in the query, referred to as dynamic query, or used to filter data.
* Because a graphical query designer is not available, the query will need to be developed in the generic query designer by typing the query directly and testing. This requires knowledge of Active Directory objects and names.
Tip: There are several tools available to assist in the development and management of Active Directory, such as ADAM (Active Directory Application Mode) and LDP, an Active Directory tool included in the Windows Support Tools.
>--Original Message--
>Is there a way that RS can create reports using the DC >Active Directory as the data source? I need to pull a >report listing two fields: User and e-mail address(from >exchange). Any help is appreciated. Thanks, Ron
>.
>
Reports in view longer than page
pieces. I have another report that will just create 1 big page. Its
probably about 4 pages long. Anyone know how to toggle this feature. I
don't think I did anything explicitly, but I might have. Thanks
JohnOn Fri, 8 Apr 2005 16:01:13 -0400, "John Alfaro" <john@.nospam.com>
wrote:
>I have 2 reports. When you view one, its breaks the data into page size
>pieces. I have another report that will just create 1 big page. Its
>probably about 4 pages long. Anyone know how to toggle this feature. I
>don't think I did anything explicitly, but I might have. Thanks
>John
In Report Designer, select the Layout tab.
Right click on the small black square at the top left of the Layout
tab's area.
Select Properties. Select the Layout tab on the Properties dialog.
Pay particular attention to the page height setting.
Andrew Watt
MVP - InfoPath|||I have the same problem and the page height is set correctly. But it still
is larger than 8 1/2 x 11.
"Andrew Watt [MVP - InfoPath]" wrote:
> On Fri, 8 Apr 2005 16:01:13 -0400, "John Alfaro" <john@.nospam.com>
> wrote:
> >I have 2 reports. When you view one, its breaks the data into page size
> >pieces. I have another report that will just create 1 big page. Its
> >probably about 4 pages long. Anyone know how to toggle this feature. I
> >don't think I did anything explicitly, but I might have. Thanks
> >
> >John
> In Report Designer, select the Layout tab.
> Right click on the small black square at the top left of the Layout
> tab's area.
> Select Properties. Select the Layout tab on the Properties dialog.
> Pay particular attention to the page height setting.
> Andrew Watt
> MVP - InfoPath
>
Monday, March 12, 2012
Reports in an application
stand alone fashion ie someone just goes to a URL instead of having to use a
reporting server to display the reports.
Does any one know how to do this, thanks for any help
Sammy.You mean just URL from where you will give the URL ? so two ways
1. Just give the URL each and everytime when they want to access.
(e.g. http://servername/reportserver?/SampleReports/Employee Sales
Summary&rs:Command=Render&rs:format=HTML4.0 )
You can go to the help for various options you can give along with URL.
search for "URL access" in the help.
2. Create a report page with "Action" as URL so something like menu of
reports, will be available for the users to select.
Amarnath
"Sammy" wrote:
> I have VS2003, I can create reports but am not sure how to run them in a
> stand alone fashion ie someone just goes to a URL instead of having to use a
> reporting server to display the reports.
> Does any one know how to do this, thanks for any help
> Sammy.|||I think Sammy is thinking the VS2003 is the report server.
Sammy, are you deploying the reports to a webserver, as this will also
give you an URL for users to click. As well as the navigation from
http://servername/reportserver
I'll shut up now.
Amarnath wrote:
> You mean just URL from where you will give the URL ? so two ways
> 1. Just give the URL each and everytime when they want to access.
> (e.g. http://servername/reportserver?/SampleReports/Employee Sales
> Summary&rs:Command=Render&rs:format=HTML4.0 )
> You can go to the help for various options you can give along with URL.
> search for "URL access" in the help.
> 2. Create a report page with "Action" as URL so something like menu of
> reports, will be available for the users to select.
> Amarnath
> "Sammy" wrote:
> > I have VS2003, I can create reports but am not sure how to run them in a
> > stand alone fashion ie someone just goes to a URL instead of having to use a
> > reporting server to display the reports.
> >
> > Does any one know how to do this, thanks for any help
> >
> > Sammy.|||Well I wanted to be able to just copy the files the report uses straight into
the wwwroot$ web app ...but have installed report serverand uploaded the rdl
file there and have now used the report server URL in the app instead
"VB" wrote:
> I think Sammy is thinking the VS2003 is the report server.
> Sammy, are you deploying the reports to a webserver, as this will also
> give you an URL for users to click. As well as the navigation from
> http://servername/reportserver
> I'll shut up now.
>
> Amarnath wrote:
> > You mean just URL from where you will give the URL ? so two ways
> >
> > 1. Just give the URL each and everytime when they want to access.
> > (e.g. http://servername/reportserver?/SampleReports/Employee Sales
> > Summary&rs:Command=Render&rs:format=HTML4.0 )
> >
> > You can go to the help for various options you can give along with URL.
> > search for "URL access" in the help.
> >
> > 2. Create a report page with "Action" as URL so something like menu of
> > reports, will be available for the users to select.
> >
> > Amarnath
> >
> > "Sammy" wrote:
> >
> > > I have VS2003, I can create reports but am not sure how to run them in a
> > > stand alone fashion ie someone just goes to a URL instead of having to use a
> > > reporting server to display the reports.
> > >
> > > Does any one know how to do this, thanks for any help
> > >
> > > Sammy.
>
Reports as asp.net
Hi, i'm new in sql server 2005 technology and i have a lot of questions in my head.
Can i create a screen with the reporting services as i can create it with the asp.net, i mean, can i design a screen with 3 combo boxes that conditioned the results shown in the linked report?.
Thank you
Manuel
There's no control in the Report Designer that is similar to the combobox or dropdownlist controls in ASP.NET. Your best bet would be to create your report and have its data driven by the dropdownlist controls from your ASP.NET app.
Basically pass in what you need from your .NET app to your report.
|||You must create ReportParameters based on the dropdownlist, and then add the ReportParametrs to the ReportServer class of the ReportViewer Control to send it.
Here is a little example.
private void cargarReporte()
{
string usuario = ConfigurationSettings.AppSettings["Usuario"].ToString();
string clave = ConfigurationSettings.AppSettings["Clave"].ToString();
string dominio = ConfigurationSettings.AppSettings["Dominio"].ToString();
string reportserver = ConfigurationSettings.AppSettings["ReportServer"].ToString();
string reportfolder = ConfigurationSettings.AppSettings["ReportFolder"].ToString();
int NmCiclo = Convert.ToInt32(Request.QueryString["NmCiclo"]);
int NmEmpresa = Convert.ToInt32(Request.QueryString["NmEmpresa"]);
int NmCargoEvaluada = Convert.ToInt32(Request.QueryString["NmCargoEvaluada"]);
int NmPersonaEvaluada = Convert.ToInt32(Request.QueryString["NmPersonaEvaluada"]);
rptviewer.ServerReport.ReportServerUrl = new Uri(reportserver);
rptviewer.ServerReport.ReportPath = reportfolder + "RPT_EvaluacionRequisitos";
x.ReportViewerCredentials rvwCreds = new x.ReportViewerCredentials(usuario, clave, dominio);
rptviewer.ServerReport.ReportServerCredentials = rvwCreds;
ReportParameter pNmEmpresa = new ReportParameter("NmEmpresa", NmEmpresa.ToString());
ReportParameter pNmCiclo = new ReportParameter("NmCiclo", NmCiclo.ToString());
ReportParameter pNmCargoEvaluada = new ReportParameter("NmCargo", NmCargoEvaluada.ToString());
ReportParameter pNmPersonaEvaluada = new ReportParameter("NmPersona", NmPersonaEvaluada.ToString());
rptviewer.ServerReport.SetParameters(new ReportParameter[] { pNmEmpresa,pNmCiclo,pNmCargoEvaluada,pNmPersonaEvaluada });
rptviewer.ShowParameterPrompts = false;
}
Reports + Setup
Hi,
I need to create a setup project that will create a new folder in the Reports Server.
The folder should contain all the reports I have developed.
The folder should have a browse permission for a user that I will choose (from the Active Dir.).
Everything must be programaticlly. In other words, I need to create a folder and set the permissions for it using code.
Is there a way? Do you have something in mind?
10x,
Solved it using the followings:
for the folder creation part:
_service = new ReportingService2005();
_service.Credentials = System.Net.CredentialCache.DefaultCredentials;
_service.CreateFolder(directoryName, "/", null);
for the security part:
Role role = new Role();
role.Name = "Browser";
Policy policy = new Policy();
policy.Roles = new Role[] { role };
policy.GroupUserName = domain + @."\user";
_service.SetPolicies("/" + directoryName, new Policy[] { policy });
I hope this will help you guys..
Friday, March 9, 2012
ReportParameter.ValidValues
done everything but prompt the user for values. So there are a bunch
of reports with varied parameters. Some of these parameters are
hard-coded lists and others are DataSetReference. How do I provide the
subscriber with an accurate list of valid values?
I was thinking something like:
ReportParameters[0].reportParameter.ValidValues
but that comes back null.
I tried reportService.GetReportParameters(report, historyID,
forRendering, values, credentials)
Values comes back null.
Please help!
Thank you!
--Larry--"values" in GetReportParameters is used to validate parameter values.
Actual parameters are returned by GetReportParameters.
You can try something like this:
ReportParameter [ ] rp = reportService.GetReportParameters(report,
forRendering, historyID, null, credentials);
rp[0].ValidValues should contain valid values.
This posting is provided "AS IS" with no warranties, and confers no rights.
<lfarrell@.setfocus.com> wrote in message
news:1105590508.069271.235070@.c13g2000cwb.googlegroups.com...
>I have been assigned to create a new report subscription form. I have
> done everything but prompt the user for values. So there are a bunch
> of reports with varied parameters. Some of these parameters are
> hard-coded lists and others are DataSetReference. How do I provide the
> subscriber with an accurate list of valid values?
> I was thinking something like:
> ReportParameters[0].reportParameter.ValidValues
> but that comes back null.
> I tried reportService.GetReportParameters(report, historyID,
> forRendering, values, credentials)
> Values comes back null.
> Please help!
> Thank you!
> --Larry--
>|||Thank you, but that didn't work,
The ValidValues is <undefined value>
I used the following code:
ValidValue[] vv = new ValidValue[0];
parameters = server.GetReportParameters(thisfolder, null, false,
Paramvalues, Paramcredentials);
if (parameters.Length != 0)
{
vv = parameters[0].ValidValues;
}
when I look at parameter[0] (and 1 as well) I have ValidValues
<undefined value>
CalidValuesQueryBased = true
ValidValuesQueryBasedSpecified = true|||Thank you, but that didn't work,
The ValidValues is <undefined value>
I used the following code:
ValidValue[] vv = new ValidValue[0];
parameters = server.GetReportParameters(thisfolder, null, false,
Paramvalues, Paramcredentials);
if (parameters.Length != 0)
{
vv = parameters[0].ValidValues;
}
when I look at parameter[0] (and 1 as well) I have ValidValues
<undefined value>
CalidValuesQueryBased = true
ValidValuesQueryBasedSpecified = true|||Thanks to Daniel Dieb, I fixed my problem. He commented on a similar
post:
If ForRendering has a value of false, the parameter meta data returned
represents the parameter data that is currently associated with the
specified report. If any parameters values are based on a query and you
are
interested in returning the query-based parameters valid values list,
you
need to set ForRendering to true, In addition, for query based
parameters,
you need to ensure that you have passed in all of the credential
information
required to return the query parameters.
I set this parm to true and got my values!!
Reportmodel data incorrect
Hi,
I have a very weird and frustrating problem at a customer. Since two months we are busy developing a report model, so users are able to create their own reports using the reportbuilder.
Suddenly the 1:n relations seem to be screwed! If I have a simple relation between entities, like a customer can have optional multiple invoices and a invoice has always one customer..
When in reportbuilder I select the customername, invoicenumber and #Invoices, then I expect there is only one invoice per invoicenumber. (When I select this in a query myself it is the truth...) But, the reportbuilder gives 2 as a result. This suddenly happens to all my 1:n roles.
It's not only in the #invoices fields, even when i select invoice amount this amount is being multiplied by 2.
I opened a backup of my project from one month ago, with the same relation in it and try to make the same report and it gave me the right results. But ofcourse I don't want to waste a month works, so I need to get this model working!
HELP!!!!
Thanks in advance
Julian
My fault... If i selected the relation entity and tested the results I would have seen each relation is mentioned twice.Wednesday, March 7, 2012
Reporting Svcs - stored procedure
Services. All of which are based on stored procedures, none of which require
any parameters. Most if not all of the report is calculated. I am
struggling badly to get even the most basic of the fields in place w/the
correct expressions. The only one I actually got to accept the expression
was a Date field, this is the calculation:
=SELECT CONVERT(char(10),dateadd(dd,-0,GetDate()),1)
It, too, fails to preview, indicating the value expression for the field
contains an error. Again, all of the other report items are calculated
fields. SUMs, totals, money formats, CASE statements, CASTs, etc. Using the
report designer/report wizard to 'do it for me' only returns Date and a
couple fields that are not even in my resultset. like one of my values in
the report is 'Total Trades'...one of the fields listed as available is
'ID__Total__'
Further, in VS I've got the report open and am on the data tab, i hit the
Run option, I receive this error: An error occurred while retrieving the
parameters in the query. Could not locate entry in sysdatabases for database
'EXEC databasename'. No entry found with that name. Make sure that the name
is entered correctly.'
Clearly I am doing something very wrong with the stored procedure
definition. Like I said, all of these reports are based on procedures, can
anybody give me some suggestion/direction on the right way to call the procs?
They run w/out parameters...EXEC databasename.dbo.proc that's it.
Please advise.
-- LynnPick the command type as stored procedure and then just enter the name of
the stored procedure. When you click on the ! you should get back the data
and the fields. If you do not get the field list populated then click on the
refresh fields button (to the right of the ..., it looks like the refresh
button for IE).
Note that RS only works with the first resultset returned. It cannot handle
mutliple resultsets.
Bruce Loehle-Conger
MVP SQL Server Reporting Services
"Lynn" <Lynn@.discussions.microsoft.com> wrote in message
news:EF6A6CBC-083B-4537-83D9-D763A8ABA056@.microsoft.com...
> Hi. I have a need to create a number of different reports via Reporting
> Services. All of which are based on stored procedures, none of which
> require
> any parameters. Most if not all of the report is calculated. I am
> struggling badly to get even the most basic of the fields in place w/the
> correct expressions. The only one I actually got to accept the expression
> was a Date field, this is the calculation:
> =SELECT CONVERT(char(10),dateadd(dd,-0,GetDate()),1)
> It, too, fails to preview, indicating the value expression for the field
> contains an error. Again, all of the other report items are calculated
> fields. SUMs, totals, money formats, CASE statements, CASTs, etc. Using
> the
> report designer/report wizard to 'do it for me' only returns Date and a
> couple fields that are not even in my resultset. like one of my values in
> the report is 'Total Trades'...one of the fields listed as available is
> 'ID__Total__'
> Further, in VS I've got the report open and am on the data tab, i hit the
> Run option, I receive this error: An error occurred while retrieving the
> parameters in the query. Could not locate entry in sysdatabases for
> database
> 'EXEC databasename'. No entry found with that name. Make sure that the
> name
> is entered correctly.'
> Clearly I am doing something very wrong with the stored procedure
> definition. Like I said, all of these reports are based on procedures,
> can
> anybody give me some suggestion/direction on the right way to call the
> procs?
> They run w/out parameters...EXEC databasename.dbo.proc that's it.
> Please advise.
>
> -- Lynn|||oh, bruce, that is great. I can't believe it was as simple as that. one
remaining problem, though. one of my reports is like this:
Date Total Trades Symbols Traded Total $
-- -- -- --
02/07/2006 333,333 333 33,333,333,333.33
#Stocks Volume Total $
-- -- --
333,333 33,333,333 3,333,333,333.33
EndPoint Liquidity #Trades Volume Total $
-- -- -- -- --
AAAA Add 114,729 21,797,575 583,102,631.33
AAAA Opening 1 27
3,412.53
AAAA Remove 30,836 8,330,843 444,521,928.10
AAAA Route 41 4,543
103,291.31
BBBB Add 26,997 9,940,201 178,600,674.78
BBBB Opening 8,089 1,448,143 44,276,419.41
BBBB Remove 3,406 1,719,403 40,267,318.25
CCCC Add 83,781 22,443,732 746,570,071.43
CCCC Remove 35,756 12,250,359 483,329,796.97
CCCC Route 1,088 244,697 6,655,913.26
DDDD Route 2 62,500 2,539,375.00
DDDD Add 2,354 1,262,589 19,136,233.44
DDDD Remove 258 195,019 6,227,451.69
I only receive the top line in the resultset:
Date Total Trades Symbols Traded Total $
-- -- -- --
02/07/2006 333,333 333 33,333,333,333.33
I assume this is what you mean when you say it will only handle the 1st
resultset. All of my reports have multiple 'chunks' in the body. Do you
have any idea how I can achieve this report via reporting svcs?
Unfortunately, this is very important. Please do advise.
--Lynn
"Bruce L-C [MVP]" wrote:
> Pick the command type as stored procedure and then just enter the name of
> the stored procedure. When you click on the ! you should get back the data
> and the fields. If you do not get the field list populated then click on the
> refresh fields button (to the right of the ..., it looks like the refresh
> button for IE).
> Note that RS only works with the first resultset returned. It cannot handle
> mutliple resultsets.
>
> --
> Bruce Loehle-Conger
> MVP SQL Server Reporting Services
> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> news:EF6A6CBC-083B-4537-83D9-D763A8ABA056@.microsoft.com...
> > Hi. I have a need to create a number of different reports via Reporting
> > Services. All of which are based on stored procedures, none of which
> > require
> > any parameters. Most if not all of the report is calculated. I am
> > struggling badly to get even the most basic of the fields in place w/the
> > correct expressions. The only one I actually got to accept the expression
> > was a Date field, this is the calculation:
> >
> > =SELECT CONVERT(char(10),dateadd(dd,-0,GetDate()),1)
> >
> > It, too, fails to preview, indicating the value expression for the field
> > contains an error. Again, all of the other report items are calculated
> > fields. SUMs, totals, money formats, CASE statements, CASTs, etc. Using
> > the
> > report designer/report wizard to 'do it for me' only returns Date and a
> > couple fields that are not even in my resultset. like one of my values in
> > the report is 'Total Trades'...one of the fields listed as available is
> > 'ID__Total__'
> >
> > Further, in VS I've got the report open and am on the data tab, i hit the
> > Run option, I receive this error: An error occurred while retrieving the
> > parameters in the query. Could not locate entry in sysdatabases for
> > database
> > 'EXEC databasename'. No entry found with that name. Make sure that the
> > name
> > is entered correctly.'
> >
> > Clearly I am doing something very wrong with the stored procedure
> > definition. Like I said, all of these reports are based on procedures,
> > can
> > anybody give me some suggestion/direction on the right way to call the
> > procs?
> > They run w/out parameters...EXEC databasename.dbo.proc that's it.
> > Please advise.
> >
> >
> > -- Lynn
>
>|||This is three resultsets. RS does not have the ability to handle that. There
is no work around from RS side. You could create another stored procedure
that calls this one and have it return just one of the resultsets.
RS can deal with multiple datasets quite well, but each stored procedure
call can only return one.
Bruce Loehle-Conger
MVP SQL Server Reporting Services
"Lynn" <Lynn@.discussions.microsoft.com> wrote in message
news:E1AFA910-1FF4-4DC8-A3F0-FC1EADE8DFD5@.microsoft.com...
> oh, bruce, that is great. I can't believe it was as simple as that. one
> remaining problem, though. one of my reports is like this:
> Date Total Trades Symbols Traded Total $
> -- -- -- --
> 02/07/2006 333,333 333 33,333,333,333.33
> #Stocks Volume Total $
> -- -- --
> 333,333 33,333,333 3,333,333,333.33
> EndPoint Liquidity #Trades Volume Total $
> -- -- -- -- --
> AAAA Add 114,729 21,797,575
> 583,102,631.33
> AAAA Opening 1 27
> 3,412.53
> AAAA Remove 30,836 8,330,843
> 444,521,928.10
> AAAA Route 41 4,543
> 103,291.31
> BBBB Add 26,997 9,940,201
> 178,600,674.78
> BBBB Opening 8,089 1,448,143
> 44,276,419.41
> BBBB Remove 3,406 1,719,403
> 40,267,318.25
> CCCC Add 83,781 22,443,732
> 746,570,071.43
> CCCC Remove 35,756 12,250,359
> 483,329,796.97
> CCCC Route 1,088 244,697
> 6,655,913.26
> DDDD Route 2 62,500
> 2,539,375.00
> DDDD Add 2,354 1,262,589
> 19,136,233.44
> DDDD Remove 258 195,019
> 6,227,451.69
> I only receive the top line in the resultset:
> Date Total Trades Symbols Traded Total $
> -- -- -- --
> 02/07/2006 333,333 333 33,333,333,333.33
> I assume this is what you mean when you say it will only handle the 1st
> resultset. All of my reports have multiple 'chunks' in the body. Do you
> have any idea how I can achieve this report via reporting svcs?
> Unfortunately, this is very important. Please do advise.
> --Lynn
>
> "Bruce L-C [MVP]" wrote:
>> Pick the command type as stored procedure and then just enter the name of
>> the stored procedure. When you click on the ! you should get back the
>> data
>> and the fields. If you do not get the field list populated then click on
>> the
>> refresh fields button (to the right of the ..., it looks like the refresh
>> button for IE).
>> Note that RS only works with the first resultset returned. It cannot
>> handle
>> mutliple resultsets.
>>
>> --
>> Bruce Loehle-Conger
>> MVP SQL Server Reporting Services
>> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> news:EF6A6CBC-083B-4537-83D9-D763A8ABA056@.microsoft.com...
>> > Hi. I have a need to create a number of different reports via
>> > Reporting
>> > Services. All of which are based on stored procedures, none of which
>> > require
>> > any parameters. Most if not all of the report is calculated. I am
>> > struggling badly to get even the most basic of the fields in place
>> > w/the
>> > correct expressions. The only one I actually got to accept the
>> > expression
>> > was a Date field, this is the calculation:
>> >
>> > =SELECT CONVERT(char(10),dateadd(dd,-0,GetDate()),1)
>> >
>> > It, too, fails to preview, indicating the value expression for the
>> > field
>> > contains an error. Again, all of the other report items are calculated
>> > fields. SUMs, totals, money formats, CASE statements, CASTs, etc.
>> > Using
>> > the
>> > report designer/report wizard to 'do it for me' only returns Date and a
>> > couple fields that are not even in my resultset. like one of my values
>> > in
>> > the report is 'Total Trades'...one of the fields listed as available
>> > is
>> > 'ID__Total__'
>> >
>> > Further, in VS I've got the report open and am on the data tab, i hit
>> > the
>> > Run option, I receive this error: An error occurred while retrieving
>> > the
>> > parameters in the query. Could not locate entry in sysdatabases for
>> > database
>> > 'EXEC databasename'. No entry found with that name. Make sure that the
>> > name
>> > is entered correctly.'
>> >
>> > Clearly I am doing something very wrong with the stored procedure
>> > definition. Like I said, all of these reports are based on procedures,
>> > can
>> > anybody give me some suggestion/direction on the right way to call the
>> > procs?
>> > They run w/out parameters...EXEC databasename.dbo.proc that's it.
>> > Please advise.
>> >
>> >
>> > -- Lynn
>>|||Bruce, I'm not sure I follow. Can you elaborate a little more, please, on
the second, possibly third procedure?
-- Lynn
"Bruce L-C [MVP]" wrote:
> This is three resultsets. RS does not have the ability to handle that. There
> is no work around from RS side. You could create another stored procedure
> that calls this one and have it return just one of the resultsets.
> RS can deal with multiple datasets quite well, but each stored procedure
> call can only return one.
>
> --
> Bruce Loehle-Conger
> MVP SQL Server Reporting Services
> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> news:E1AFA910-1FF4-4DC8-A3F0-FC1EADE8DFD5@.microsoft.com...
> > oh, bruce, that is great. I can't believe it was as simple as that. one
> > remaining problem, though. one of my reports is like this:
> >
> > Date Total Trades Symbols Traded Total $
> > -- -- -- --
> > 02/07/2006 333,333 333 33,333,333,333.33
> >
> > #Stocks Volume Total $
> > -- -- --
> > 333,333 33,333,333 3,333,333,333.33
> >
> > EndPoint Liquidity #Trades Volume Total $
> > -- -- -- -- --
> > AAAA Add 114,729 21,797,575
> > 583,102,631.33
> > AAAA Opening 1 27
> > 3,412.53
> > AAAA Remove 30,836 8,330,843
> > 444,521,928.10
> > AAAA Route 41 4,543
> > 103,291.31
> > BBBB Add 26,997 9,940,201
> > 178,600,674.78
> > BBBB Opening 8,089 1,448,143
> > 44,276,419.41
> > BBBB Remove 3,406 1,719,403
> > 40,267,318.25
> > CCCC Add 83,781 22,443,732
> > 746,570,071.43
> > CCCC Remove 35,756 12,250,359
> > 483,329,796.97
> > CCCC Route 1,088 244,697
> > 6,655,913.26
> > DDDD Route 2 62,500
> > 2,539,375.00
> > DDDD Add 2,354 1,262,589
> > 19,136,233.44
> > DDDD Remove 258 195,019
> > 6,227,451.69
> >
> > I only receive the top line in the resultset:
> >
> > Date Total Trades Symbols Traded Total $
> > -- -- -- --
> > 02/07/2006 333,333 333 33,333,333,333.33
> >
> > I assume this is what you mean when you say it will only handle the 1st
> > resultset. All of my reports have multiple 'chunks' in the body. Do you
> > have any idea how I can achieve this report via reporting svcs?
> > Unfortunately, this is very important. Please do advise.
> >
> > --Lynn
> >
> >
> > "Bruce L-C [MVP]" wrote:
> >
> >> Pick the command type as stored procedure and then just enter the name of
> >> the stored procedure. When you click on the ! you should get back the
> >> data
> >> and the fields. If you do not get the field list populated then click on
> >> the
> >> refresh fields button (to the right of the ..., it looks like the refresh
> >> button for IE).
> >>
> >> Note that RS only works with the first resultset returned. It cannot
> >> handle
> >> mutliple resultsets.
> >>
> >>
> >> --
> >> Bruce Loehle-Conger
> >> MVP SQL Server Reporting Services
> >>
> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> news:EF6A6CBC-083B-4537-83D9-D763A8ABA056@.microsoft.com...
> >> > Hi. I have a need to create a number of different reports via
> >> > Reporting
> >> > Services. All of which are based on stored procedures, none of which
> >> > require
> >> > any parameters. Most if not all of the report is calculated. I am
> >> > struggling badly to get even the most basic of the fields in place
> >> > w/the
> >> > correct expressions. The only one I actually got to accept the
> >> > expression
> >> > was a Date field, this is the calculation:
> >> >
> >> > =SELECT CONVERT(char(10),dateadd(dd,-0,GetDate()),1)
> >> >
> >> > It, too, fails to preview, indicating the value expression for the
> >> > field
> >> > contains an error. Again, all of the other report items are calculated
> >> > fields. SUMs, totals, money formats, CASE statements, CASTs, etc.
> >> > Using
> >> > the
> >> > report designer/report wizard to 'do it for me' only returns Date and a
> >> > couple fields that are not even in my resultset. like one of my values
> >> > in
> >> > the report is 'Total Trades'...one of the fields listed as available
> >> > is
> >> > 'ID__Total__'
> >> >
> >> > Further, in VS I've got the report open and am on the data tab, i hit
> >> > the
> >> > Run option, I receive this error: An error occurred while retrieving
> >> > the
> >> > parameters in the query. Could not locate entry in sysdatabases for
> >> > database
> >> > 'EXEC databasename'. No entry found with that name. Make sure that the
> >> > name
> >> > is entered correctly.'
> >> >
> >> > Clearly I am doing something very wrong with the stored procedure
> >> > definition. Like I said, all of these reports are based on procedures,
> >> > can
> >> > anybody give me some suggestion/direction on the right way to call the
> >> > procs?
> >> > They run w/out parameters...EXEC databasename.dbo.proc that's it.
> >> > Please advise.
> >> >
> >> >
> >> > -- Lynn
> >>
> >>
> >>
>
>|||Configure your existing stored procedure to accept a parameter (you can make
it optional so that it doesn't break existing code).
Then call it three times in RS with a static value and create three
datasets.
For instance dataset1
yourproc 1
Dataset2
yourproc 2
etc.
Then in your stored procedure return the appropriate resultset based on the
parameter.
Downside is that your sp is being run three times.
Bruce Loehle-Conger
MVP SQL Server Reporting Services
"Lynn" <Lynn@.discussions.microsoft.com> wrote in message
news:E8E34B6C-A36A-4576-BE8C-AB61866EEC80@.microsoft.com...
> Bruce, I'm not sure I follow. Can you elaborate a little more, please, on
> the second, possibly third procedure?
> -- Lynn
>
> "Bruce L-C [MVP]" wrote:
>> This is three resultsets. RS does not have the ability to handle that.
>> There
>> is no work around from RS side. You could create another stored procedure
>> that calls this one and have it return just one of the resultsets.
>> RS can deal with multiple datasets quite well, but each stored procedure
>> call can only return one.
>>
>> --
>> Bruce Loehle-Conger
>> MVP SQL Server Reporting Services
>> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> news:E1AFA910-1FF4-4DC8-A3F0-FC1EADE8DFD5@.microsoft.com...
>> > oh, bruce, that is great. I can't believe it was as simple as that.
>> > one
>> > remaining problem, though. one of my reports is like this:
>> >
>> > Date Total Trades Symbols Traded Total $
>> > -- -- -- --
>> > 02/07/2006 333,333 333 33,333,333,333.33
>> >
>> > #Stocks Volume Total $
>> > -- -- --
>> > 333,333 33,333,333 3,333,333,333.33
>> >
>> > EndPoint Liquidity #Trades Volume Total $
>> > -- -- -- -- --
>> > AAAA Add 114,729 21,797,575
>> > 583,102,631.33
>> > AAAA Opening 1 27
>> > 3,412.53
>> > AAAA Remove 30,836 8,330,843
>> > 444,521,928.10
>> > AAAA Route 41 4,543
>> > 103,291.31
>> > BBBB Add 26,997 9,940,201
>> > 178,600,674.78
>> > BBBB Opening 8,089 1,448,143
>> > 44,276,419.41
>> > BBBB Remove 3,406 1,719,403
>> > 40,267,318.25
>> > CCCC Add 83,781 22,443,732
>> > 746,570,071.43
>> > CCCC Remove 35,756 12,250,359
>> > 483,329,796.97
>> > CCCC Route 1,088 244,697
>> > 6,655,913.26
>> > DDDD Route 2 62,500
>> > 2,539,375.00
>> > DDDD Add 2,354 1,262,589
>> > 19,136,233.44
>> > DDDD Remove 258 195,019
>> > 6,227,451.69
>> >
>> > I only receive the top line in the resultset:
>> >
>> > Date Total Trades Symbols Traded Total $
>> > -- -- -- --
>> > 02/07/2006 333,333 333 33,333,333,333.33
>> >
>> > I assume this is what you mean when you say it will only handle the 1st
>> > resultset. All of my reports have multiple 'chunks' in the body. Do
>> > you
>> > have any idea how I can achieve this report via reporting svcs?
>> > Unfortunately, this is very important. Please do advise.
>> >
>> > --Lynn
>> >
>> >
>> > "Bruce L-C [MVP]" wrote:
>> >
>> >> Pick the command type as stored procedure and then just enter the name
>> >> of
>> >> the stored procedure. When you click on the ! you should get back the
>> >> data
>> >> and the fields. If you do not get the field list populated then click
>> >> on
>> >> the
>> >> refresh fields button (to the right of the ..., it looks like the
>> >> refresh
>> >> button for IE).
>> >>
>> >> Note that RS only works with the first resultset returned. It cannot
>> >> handle
>> >> mutliple resultsets.
>> >>
>> >>
>> >> --
>> >> Bruce Loehle-Conger
>> >> MVP SQL Server Reporting Services
>> >>
>> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> >> news:EF6A6CBC-083B-4537-83D9-D763A8ABA056@.microsoft.com...
>> >> > Hi. I have a need to create a number of different reports via
>> >> > Reporting
>> >> > Services. All of which are based on stored procedures, none of
>> >> > which
>> >> > require
>> >> > any parameters. Most if not all of the report is calculated. I am
>> >> > struggling badly to get even the most basic of the fields in place
>> >> > w/the
>> >> > correct expressions. The only one I actually got to accept the
>> >> > expression
>> >> > was a Date field, this is the calculation:
>> >> >
>> >> > =SELECT CONVERT(char(10),dateadd(dd,-0,GetDate()),1)
>> >> >
>> >> > It, too, fails to preview, indicating the value expression for the
>> >> > field
>> >> > contains an error. Again, all of the other report items are
>> >> > calculated
>> >> > fields. SUMs, totals, money formats, CASE statements, CASTs, etc.
>> >> > Using
>> >> > the
>> >> > report designer/report wizard to 'do it for me' only returns Date
>> >> > and a
>> >> > couple fields that are not even in my resultset. like one of my
>> >> > values
>> >> > in
>> >> > the report is 'Total Trades'...one of the fields listed as
>> >> > available
>> >> > is
>> >> > 'ID__Total__'
>> >> >
>> >> > Further, in VS I've got the report open and am on the data tab, i
>> >> > hit
>> >> > the
>> >> > Run option, I receive this error: An error occurred while
>> >> > retrieving
>> >> > the
>> >> > parameters in the query. Could not locate entry in sysdatabases for
>> >> > database
>> >> > 'EXEC databasename'. No entry found with that name. Make sure that
>> >> > the
>> >> > name
>> >> > is entered correctly.'
>> >> >
>> >> > Clearly I am doing something very wrong with the stored procedure
>> >> > definition. Like I said, all of these reports are based on
>> >> > procedures,
>> >> > can
>> >> > anybody give me some suggestion/direction on the right way to call
>> >> > the
>> >> > procs?
>> >> > They run w/out parameters...EXEC databasename.dbo.proc that's
>> >> > it.
>> >> > Please advise.
>> >> >
>> >> >
>> >> > -- Lynn
>> >>
>> >>
>> >>
>>|||well, bruce, i'm still not sure i know what to do w/these parameters...how
will i get one parameter to do one resultset and get the other resultsets
w/parameters 2 and 3? but, i will see if i can walk through this.
-- Lynn
"Bruce L-C [MVP]" wrote:
> Configure your existing stored procedure to accept a parameter (you can make
> it optional so that it doesn't break existing code).
> Then call it three times in RS with a static value and create three
> datasets.
> For instance dataset1
> yourproc 1
> Dataset2
> yourproc 2
> etc.
> Then in your stored procedure return the appropriate resultset based on the
> parameter.
> Downside is that your sp is being run three times.
>
> --
> Bruce Loehle-Conger
> MVP SQL Server Reporting Services
> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> news:E8E34B6C-A36A-4576-BE8C-AB61866EEC80@.microsoft.com...
> > Bruce, I'm not sure I follow. Can you elaborate a little more, please, on
> > the second, possibly third procedure?
> > -- Lynn
> >
> >
> > "Bruce L-C [MVP]" wrote:
> >
> >> This is three resultsets. RS does not have the ability to handle that.
> >> There
> >> is no work around from RS side. You could create another stored procedure
> >> that calls this one and have it return just one of the resultsets.
> >>
> >> RS can deal with multiple datasets quite well, but each stored procedure
> >> call can only return one.
> >>
> >>
> >> --
> >> Bruce Loehle-Conger
> >> MVP SQL Server Reporting Services
> >>
> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> news:E1AFA910-1FF4-4DC8-A3F0-FC1EADE8DFD5@.microsoft.com...
> >> > oh, bruce, that is great. I can't believe it was as simple as that.
> >> > one
> >> > remaining problem, though. one of my reports is like this:
> >> >
> >> > Date Total Trades Symbols Traded Total $
> >> > -- -- -- --
> >> > 02/07/2006 333,333 333 33,333,333,333.33
> >> >
> >> > #Stocks Volume Total $
> >> > -- -- --
> >> > 333,333 33,333,333 3,333,333,333.33
> >> >
> >> > EndPoint Liquidity #Trades Volume Total $
> >> > -- -- -- -- --
> >> > AAAA Add 114,729 21,797,575
> >> > 583,102,631.33
> >> > AAAA Opening 1 27
> >> > 3,412.53
> >> > AAAA Remove 30,836 8,330,843
> >> > 444,521,928.10
> >> > AAAA Route 41 4,543
> >> > 103,291.31
> >> > BBBB Add 26,997 9,940,201
> >> > 178,600,674.78
> >> > BBBB Opening 8,089 1,448,143
> >> > 44,276,419.41
> >> > BBBB Remove 3,406 1,719,403
> >> > 40,267,318.25
> >> > CCCC Add 83,781 22,443,732
> >> > 746,570,071.43
> >> > CCCC Remove 35,756 12,250,359
> >> > 483,329,796.97
> >> > CCCC Route 1,088 244,697
> >> > 6,655,913.26
> >> > DDDD Route 2 62,500
> >> > 2,539,375.00
> >> > DDDD Add 2,354 1,262,589
> >> > 19,136,233.44
> >> > DDDD Remove 258 195,019
> >> > 6,227,451.69
> >> >
> >> > I only receive the top line in the resultset:
> >> >
> >> > Date Total Trades Symbols Traded Total $
> >> > -- -- -- --
> >> > 02/07/2006 333,333 333 33,333,333,333.33
> >> >
> >> > I assume this is what you mean when you say it will only handle the 1st
> >> > resultset. All of my reports have multiple 'chunks' in the body. Do
> >> > you
> >> > have any idea how I can achieve this report via reporting svcs?
> >> > Unfortunately, this is very important. Please do advise.
> >> >
> >> > --Lynn
> >> >
> >> >
> >> > "Bruce L-C [MVP]" wrote:
> >> >
> >> >> Pick the command type as stored procedure and then just enter the name
> >> >> of
> >> >> the stored procedure. When you click on the ! you should get back the
> >> >> data
> >> >> and the fields. If you do not get the field list populated then click
> >> >> on
> >> >> the
> >> >> refresh fields button (to the right of the ..., it looks like the
> >> >> refresh
> >> >> button for IE).
> >> >>
> >> >> Note that RS only works with the first resultset returned. It cannot
> >> >> handle
> >> >> mutliple resultsets.
> >> >>
> >> >>
> >> >> --
> >> >> Bruce Loehle-Conger
> >> >> MVP SQL Server Reporting Services
> >> >>
> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> news:EF6A6CBC-083B-4537-83D9-D763A8ABA056@.microsoft.com...
> >> >> > Hi. I have a need to create a number of different reports via
> >> >> > Reporting
> >> >> > Services. All of which are based on stored procedures, none of
> >> >> > which
> >> >> > require
> >> >> > any parameters. Most if not all of the report is calculated. I am
> >> >> > struggling badly to get even the most basic of the fields in place
> >> >> > w/the
> >> >> > correct expressions. The only one I actually got to accept the
> >> >> > expression
> >> >> > was a Date field, this is the calculation:
> >> >> >
> >> >> > =SELECT CONVERT(char(10),dateadd(dd,-0,GetDate()),1)
> >> >> >
> >> >> > It, too, fails to preview, indicating the value expression for the
> >> >> > field
> >> >> > contains an error. Again, all of the other report items are
> >> >> > calculated
> >> >> > fields. SUMs, totals, money formats, CASE statements, CASTs, etc.
> >> >> > Using
> >> >> > the
> >> >> > report designer/report wizard to 'do it for me' only returns Date
> >> >> > and a
> >> >> > couple fields that are not even in my resultset. like one of my
> >> >> > values
> >> >> > in
> >> >> > the report is 'Total Trades'...one of the fields listed as
> >> >> > available
> >> >> > is
> >> >> > 'ID__Total__'
> >> >> >
> >> >> > Further, in VS I've got the report open and am on the data tab, i
> >> >> > hit
> >> >> > the
> >> >> > Run option, I receive this error: An error occurred while
> >> >> > retrieving
> >> >> > the
> >> >> > parameters in the query. Could not locate entry in sysdatabases for
> >> >> > database
> >> >> > 'EXEC databasename'. No entry found with that name. Make sure that
> >> >> > the
> >> >> > name
> >> >> > is entered correctly.'
> >> >> >
> >> >> > Clearly I am doing something very wrong with the stored procedure
> >> >> > definition. Like I said, all of these reports are based on
> >> >> > procedures,
> >> >> > can
> >> >> > anybody give me some suggestion/direction on the right way to call
> >> >> > the
> >> >> > procs?
> >> >> > They run w/out parameters...EXEC databasename.dbo.proc that's
> >> >> > it.
> >> >> > Please advise.
> >> >> >
> >> >> >
> >> >> > -- Lynn
> >> >>
> >> >>
> >> >>
> >>
> >>
> >>
>
>|||Hi again, Bruce. Is there any way you can give me an example of how to
change my proc to accept the 3 parameters? I know how to pass parameters to
a procedure, I just don't understand how I can do it to make my procedure gen
three different resultsets.
-- Lynn
"Bruce L-C [MVP]" wrote:
> Configure your existing stored procedure to accept a parameter (you can make
> it optional so that it doesn't break existing code).
> Then call it three times in RS with a static value and create three
> datasets.
> For instance dataset1
> yourproc 1
> Dataset2
> yourproc 2
> etc.
> Then in your stored procedure return the appropriate resultset based on the
> parameter.
> Downside is that your sp is being run three times.
>
> --
> Bruce Loehle-Conger
> MVP SQL Server Reporting Services
> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> news:E8E34B6C-A36A-4576-BE8C-AB61866EEC80@.microsoft.com...
> > Bruce, I'm not sure I follow. Can you elaborate a little more, please, on
> > the second, possibly third procedure?
> > -- Lynn
> >
> >
> > "Bruce L-C [MVP]" wrote:
> >
> >> This is three resultsets. RS does not have the ability to handle that.
> >> There
> >> is no work around from RS side. You could create another stored procedure
> >> that calls this one and have it return just one of the resultsets.
> >>
> >> RS can deal with multiple datasets quite well, but each stored procedure
> >> call can only return one.
> >>
> >>
> >> --
> >> Bruce Loehle-Conger
> >> MVP SQL Server Reporting Services
> >>
> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> news:E1AFA910-1FF4-4DC8-A3F0-FC1EADE8DFD5@.microsoft.com...
> >> > oh, bruce, that is great. I can't believe it was as simple as that.
> >> > one
> >> > remaining problem, though. one of my reports is like this:
> >> >
> >> > Date Total Trades Symbols Traded Total $
> >> > -- -- -- --
> >> > 02/07/2006 333,333 333 33,333,333,333.33
> >> >
> >> > #Stocks Volume Total $
> >> > -- -- --
> >> > 333,333 33,333,333 3,333,333,333.33
> >> >
> >> > EndPoint Liquidity #Trades Volume Total $
> >> > -- -- -- -- --
> >> > AAAA Add 114,729 21,797,575
> >> > 583,102,631.33
> >> > AAAA Opening 1 27
> >> > 3,412.53
> >> > AAAA Remove 30,836 8,330,843
> >> > 444,521,928.10
> >> > AAAA Route 41 4,543
> >> > 103,291.31
> >> > BBBB Add 26,997 9,940,201
> >> > 178,600,674.78
> >> > BBBB Opening 8,089 1,448,143
> >> > 44,276,419.41
> >> > BBBB Remove 3,406 1,719,403
> >> > 40,267,318.25
> >> > CCCC Add 83,781 22,443,732
> >> > 746,570,071.43
> >> > CCCC Remove 35,756 12,250,359
> >> > 483,329,796.97
> >> > CCCC Route 1,088 244,697
> >> > 6,655,913.26
> >> > DDDD Route 2 62,500
> >> > 2,539,375.00
> >> > DDDD Add 2,354 1,262,589
> >> > 19,136,233.44
> >> > DDDD Remove 258 195,019
> >> > 6,227,451.69
> >> >
> >> > I only receive the top line in the resultset:
> >> >
> >> > Date Total Trades Symbols Traded Total $
> >> > -- -- -- --
> >> > 02/07/2006 333,333 333 33,333,333,333.33
> >> >
> >> > I assume this is what you mean when you say it will only handle the 1st
> >> > resultset. All of my reports have multiple 'chunks' in the body. Do
> >> > you
> >> > have any idea how I can achieve this report via reporting svcs?
> >> > Unfortunately, this is very important. Please do advise.
> >> >
> >> > --Lynn
> >> >
> >> >
> >> > "Bruce L-C [MVP]" wrote:
> >> >
> >> >> Pick the command type as stored procedure and then just enter the name
> >> >> of
> >> >> the stored procedure. When you click on the ! you should get back the
> >> >> data
> >> >> and the fields. If you do not get the field list populated then click
> >> >> on
> >> >> the
> >> >> refresh fields button (to the right of the ..., it looks like the
> >> >> refresh
> >> >> button for IE).
> >> >>
> >> >> Note that RS only works with the first resultset returned. It cannot
> >> >> handle
> >> >> mutliple resultsets.
> >> >>
> >> >>
> >> >> --
> >> >> Bruce Loehle-Conger
> >> >> MVP SQL Server Reporting Services
> >> >>
> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> news:EF6A6CBC-083B-4537-83D9-D763A8ABA056@.microsoft.com...
> >> >> > Hi. I have a need to create a number of different reports via
> >> >> > Reporting
> >> >> > Services. All of which are based on stored procedures, none of
> >> >> > which
> >> >> > require
> >> >> > any parameters. Most if not all of the report is calculated. I am
> >> >> > struggling badly to get even the most basic of the fields in place
> >> >> > w/the
> >> >> > correct expressions. The only one I actually got to accept the
> >> >> > expression
> >> >> > was a Date field, this is the calculation:
> >> >> >
> >> >> > =SELECT CONVERT(char(10),dateadd(dd,-0,GetDate()),1)
> >> >> >
> >> >> > It, too, fails to preview, indicating the value expression for the
> >> >> > field
> >> >> > contains an error. Again, all of the other report items are
> >> >> > calculated
> >> >> > fields. SUMs, totals, money formats, CASE statements, CASTs, etc.
> >> >> > Using
> >> >> > the
> >> >> > report designer/report wizard to 'do it for me' only returns Date
> >> >> > and a
> >> >> > couple fields that are not even in my resultset. like one of my
> >> >> > values
> >> >> > in
> >> >> > the report is 'Total Trades'...one of the fields listed as
> >> >> > available
> >> >> > is
> >> >> > 'ID__Total__'
> >> >> >
> >> >> > Further, in VS I've got the report open and am on the data tab, i
> >> >> > hit
> >> >> > the
> >> >> > Run option, I receive this error: An error occurred while
> >> >> > retrieving
> >> >> > the
> >> >> > parameters in the query. Could not locate entry in sysdatabases for
> >> >> > database
> >> >> > 'EXEC databasename'. No entry found with that name. Make sure that
> >> >> > the
> >> >> > name
> >> >> > is entered correctly.'
> >> >> >
> >> >> > Clearly I am doing something very wrong with the stored procedure
> >> >> > definition. Like I said, all of these reports are based on
> >> >> > procedures,
> >> >> > can
> >> >> > anybody give me some suggestion/direction on the right way to call
> >> >> > the
> >> >> > procs?
> >> >> > They run w/out parameters...EXEC databasename.dbo.proc that's
> >> >> > it.
> >> >> > Please advise.
> >> >> >
> >> >> >
> >> >> > -- Lynn
> >> >>
> >> >>
> >> >>
> >>
> >>
> >>
>
>|||Bruce, or somebody else, might you give me an example of how to give the proc
3 parameters, producing three resultsets in a way that RS will display them?
Or, am I giving it three parameters and calling it three times? If so, how
would i call the 3 procs in RS?
-- Lynn
"Bruce L-C [MVP]" wrote:
> Configure your existing stored procedure to accept a parameter (you can make
> it optional so that it doesn't break existing code).
> Then call it three times in RS with a static value and create three
> datasets.
> For instance dataset1
> yourproc 1
> Dataset2
> yourproc 2
> etc.
> Then in your stored procedure return the appropriate resultset based on the
> parameter.
> Downside is that your sp is being run three times.
>
> --
> Bruce Loehle-Conger
> MVP SQL Server Reporting Services
> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> news:E8E34B6C-A36A-4576-BE8C-AB61866EEC80@.microsoft.com...
> > Bruce, I'm not sure I follow. Can you elaborate a little more, please, on
> > the second, possibly third procedure?
> > -- Lynn
> >
> >
> > "Bruce L-C [MVP]" wrote:
> >
> >> This is three resultsets. RS does not have the ability to handle that.
> >> There
> >> is no work around from RS side. You could create another stored procedure
> >> that calls this one and have it return just one of the resultsets.
> >>
> >> RS can deal with multiple datasets quite well, but each stored procedure
> >> call can only return one.
> >>
> >>
> >> --
> >> Bruce Loehle-Conger
> >> MVP SQL Server Reporting Services
> >>
> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> news:E1AFA910-1FF4-4DC8-A3F0-FC1EADE8DFD5@.microsoft.com...
> >> > oh, bruce, that is great. I can't believe it was as simple as that.
> >> > one
> >> > remaining problem, though. one of my reports is like this:
> >> >
> >> > Date Total Trades Symbols Traded Total $
> >> > -- -- -- --
> >> > 02/07/2006 333,333 333 33,333,333,333.33
> >> >
> >> > #Stocks Volume Total $
> >> > -- -- --
> >> > 333,333 33,333,333 3,333,333,333.33
> >> >
> >> > EndPoint Liquidity #Trades Volume Total $
> >> > -- -- -- -- --
> >> > AAAA Add 114,729 21,797,575
> >> > 583,102,631.33
> >> > AAAA Opening 1 27
> >> > 3,412.53
> >> > AAAA Remove 30,836 8,330,843
> >> > 444,521,928.10
> >> > AAAA Route 41 4,543
> >> > 103,291.31
> >> > BBBB Add 26,997 9,940,201
> >> > 178,600,674.78
> >> > BBBB Opening 8,089 1,448,143
> >> > 44,276,419.41
> >> > BBBB Remove 3,406 1,719,403
> >> > 40,267,318.25
> >> > CCCC Add 83,781 22,443,732
> >> > 746,570,071.43
> >> > CCCC Remove 35,756 12,250,359
> >> > 483,329,796.97
> >> > CCCC Route 1,088 244,697
> >> > 6,655,913.26
> >> > DDDD Route 2 62,500
> >> > 2,539,375.00
> >> > DDDD Add 2,354 1,262,589
> >> > 19,136,233.44
> >> > DDDD Remove 258 195,019
> >> > 6,227,451.69
> >> >
> >> > I only receive the top line in the resultset:
> >> >
> >> > Date Total Trades Symbols Traded Total $
> >> > -- -- -- --
> >> > 02/07/2006 333,333 333 33,333,333,333.33
> >> >
> >> > I assume this is what you mean when you say it will only handle the 1st
> >> > resultset. All of my reports have multiple 'chunks' in the body. Do
> >> > you
> >> > have any idea how I can achieve this report via reporting svcs?
> >> > Unfortunately, this is very important. Please do advise.
> >> >
> >> > --Lynn
> >> >
> >> >
> >> > "Bruce L-C [MVP]" wrote:
> >> >
> >> >> Pick the command type as stored procedure and then just enter the name
> >> >> of
> >> >> the stored procedure. When you click on the ! you should get back the
> >> >> data
> >> >> and the fields. If you do not get the field list populated then click
> >> >> on
> >> >> the
> >> >> refresh fields button (to the right of the ..., it looks like the
> >> >> refresh
> >> >> button for IE).
> >> >>
> >> >> Note that RS only works with the first resultset returned. It cannot
> >> >> handle
> >> >> mutliple resultsets.
> >> >>
> >> >>
> >> >> --
> >> >> Bruce Loehle-Conger
> >> >> MVP SQL Server Reporting Services
> >> >>
> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> news:EF6A6CBC-083B-4537-83D9-D763A8ABA056@.microsoft.com...
> >> >> > Hi. I have a need to create a number of different reports via
> >> >> > Reporting
> >> >> > Services. All of which are based on stored procedures, none of
> >> >> > which
> >> >> > require
> >> >> > any parameters. Most if not all of the report is calculated. I am
> >> >> > struggling badly to get even the most basic of the fields in place
> >> >> > w/the
> >> >> > correct expressions. The only one I actually got to accept the
> >> >> > expression
> >> >> > was a Date field, this is the calculation:
> >> >> >
> >> >> > =SELECT CONVERT(char(10),dateadd(dd,-0,GetDate()),1)
> >> >> >
> >> >> > It, too, fails to preview, indicating the value expression for the
> >> >> > field
> >> >> > contains an error. Again, all of the other report items are
> >> >> > calculated
> >> >> > fields. SUMs, totals, money formats, CASE statements, CASTs, etc.
> >> >> > Using
> >> >> > the
> >> >> > report designer/report wizard to 'do it for me' only returns Date
> >> >> > and a
> >> >> > couple fields that are not even in my resultset. like one of my
> >> >> > values
> >> >> > in
> >> >> > the report is 'Total Trades'...one of the fields listed as
> >> >> > available
> >> >> > is
> >> >> > 'ID__Total__'
> >> >> >
> >> >> > Further, in VS I've got the report open and am on the data tab, i
> >> >> > hit
> >> >> > the
> >> >> > Run option, I receive this error: An error occurred while
> >> >> > retrieving
> >> >> > the
> >> >> > parameters in the query. Could not locate entry in sysdatabases for
> >> >> > database
> >> >> > 'EXEC databasename'. No entry found with that name. Make sure that
> >> >> > the
> >> >> > name
> >> >> > is entered correctly.'
> >> >> >
> >> >> > Clearly I am doing something very wrong with the stored procedure
> >> >> > definition. Like I said, all of these reports are based on
> >> >> > procedures,
> >> >> > can
> >> >> > anybody give me some suggestion/direction on the right way to call
> >> >> > the
> >> >> > procs?
> >> >> > They run w/out parameters...EXEC databasename.dbo.proc that's
> >> >> > it.
> >> >> > Please advise.
> >> >> >
> >> >> >
> >> >> > -- Lynn
> >> >>
> >> >>
> >> >>
> >>
> >>
> >>
>
>|||Yes, you are calling it three times. In RS you create three datasets. Go to
the dataset tab and there is a combo box with the name of the dataset, you
can click on that and there is a an option for a new.
In your stored procedure
if @.WHICHRESULTSET = 1
begin
--return the first resultset here
end
etc
Bruce Loehle-Conger
MVP SQL Server Reporting Services
"Lynn" <Lynn@.discussions.microsoft.com> wrote in message
news:81E3A442-6694-442D-B151-F083E4750ADB@.microsoft.com...
> Bruce, or somebody else, might you give me an example of how to give the
> proc
> 3 parameters, producing three resultsets in a way that RS will display
> them?
> Or, am I giving it three parameters and calling it three times? If so,
> how
> would i call the 3 procs in RS?
> -- Lynn
>
> "Bruce L-C [MVP]" wrote:
>> Configure your existing stored procedure to accept a parameter (you can
>> make
>> it optional so that it doesn't break existing code).
>> Then call it three times in RS with a static value and create three
>> datasets.
>> For instance dataset1
>> yourproc 1
>> Dataset2
>> yourproc 2
>> etc.
>> Then in your stored procedure return the appropriate resultset based on
>> the
>> parameter.
>> Downside is that your sp is being run three times.
>>
>> --
>> Bruce Loehle-Conger
>> MVP SQL Server Reporting Services
>> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> news:E8E34B6C-A36A-4576-BE8C-AB61866EEC80@.microsoft.com...
>> > Bruce, I'm not sure I follow. Can you elaborate a little more, please,
>> > on
>> > the second, possibly third procedure?
>> > -- Lynn
>> >
>> >
>> > "Bruce L-C [MVP]" wrote:
>> >
>> >> This is three resultsets. RS does not have the ability to handle that.
>> >> There
>> >> is no work around from RS side. You could create another stored
>> >> procedure
>> >> that calls this one and have it return just one of the resultsets.
>> >>
>> >> RS can deal with multiple datasets quite well, but each stored
>> >> procedure
>> >> call can only return one.
>> >>
>> >>
>> >> --
>> >> Bruce Loehle-Conger
>> >> MVP SQL Server Reporting Services
>> >>
>> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> >> news:E1AFA910-1FF4-4DC8-A3F0-FC1EADE8DFD5@.microsoft.com...
>> >> > oh, bruce, that is great. I can't believe it was as simple as that.
>> >> > one
>> >> > remaining problem, though. one of my reports is like this:
>> >> >
>> >> > Date Total Trades Symbols Traded Total $
>> >> > -- -- -- --
>> >> > 02/07/2006 333,333 333 33,333,333,333.33
>> >> >
>> >> > #Stocks Volume Total $
>> >> > -- -- --
>> >> > 333,333 33,333,333 3,333,333,333.33
>> >> >
>> >> > EndPoint Liquidity #Trades Volume Total $
>> >> > -- -- -- -- --
>> >> > AAAA Add 114,729 21,797,575
>> >> > 583,102,631.33
>> >> > AAAA Opening 1 27
>> >> > 3,412.53
>> >> > AAAA Remove 30,836 8,330,843
>> >> > 444,521,928.10
>> >> > AAAA Route 41 4,543
>> >> > 103,291.31
>> >> > BBBB Add 26,997 9,940,201
>> >> > 178,600,674.78
>> >> > BBBB Opening 8,089 1,448,143
>> >> > 44,276,419.41
>> >> > BBBB Remove 3,406 1,719,403
>> >> > 40,267,318.25
>> >> > CCCC Add 83,781 22,443,732
>> >> > 746,570,071.43
>> >> > CCCC Remove 35,756 12,250,359
>> >> > 483,329,796.97
>> >> > CCCC Route 1,088 244,697
>> >> > 6,655,913.26
>> >> > DDDD Route 2 62,500
>> >> > 2,539,375.00
>> >> > DDDD Add 2,354 1,262,589
>> >> > 19,136,233.44
>> >> > DDDD Remove 258 195,019
>> >> > 6,227,451.69
>> >> >
>> >> > I only receive the top line in the resultset:
>> >> >
>> >> > Date Total Trades Symbols Traded Total $
>> >> > -- -- -- --
>> >> > 02/07/2006 333,333 333 33,333,333,333.33
>> >> >
>> >> > I assume this is what you mean when you say it will only handle the
>> >> > 1st
>> >> > resultset. All of my reports have multiple 'chunks' in the body.
>> >> > Do
>> >> > you
>> >> > have any idea how I can achieve this report via reporting svcs?
>> >> > Unfortunately, this is very important. Please do advise.
>> >> >
>> >> > --Lynn
>> >> >
>> >> >
>> >> > "Bruce L-C [MVP]" wrote:
>> >> >
>> >> >> Pick the command type as stored procedure and then just enter the
>> >> >> name
>> >> >> of
>> >> >> the stored procedure. When you click on the ! you should get back
>> >> >> the
>> >> >> data
>> >> >> and the fields. If you do not get the field list populated then
>> >> >> click
>> >> >> on
>> >> >> the
>> >> >> refresh fields button (to the right of the ..., it looks like the
>> >> >> refresh
>> >> >> button for IE).
>> >> >>
>> >> >> Note that RS only works with the first resultset returned. It
>> >> >> cannot
>> >> >> handle
>> >> >> mutliple resultsets.
>> >> >>
>> >> >>
>> >> >> --
>> >> >> Bruce Loehle-Conger
>> >> >> MVP SQL Server Reporting Services
>> >> >>
>> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> >> >> news:EF6A6CBC-083B-4537-83D9-D763A8ABA056@.microsoft.com...
>> >> >> > Hi. I have a need to create a number of different reports via
>> >> >> > Reporting
>> >> >> > Services. All of which are based on stored procedures, none of
>> >> >> > which
>> >> >> > require
>> >> >> > any parameters. Most if not all of the report is calculated. I
>> >> >> > am
>> >> >> > struggling badly to get even the most basic of the fields in
>> >> >> > place
>> >> >> > w/the
>> >> >> > correct expressions. The only one I actually got to accept the
>> >> >> > expression
>> >> >> > was a Date field, this is the calculation:
>> >> >> >
>> >> >> > =SELECT CONVERT(char(10),dateadd(dd,-0,GetDate()),1)
>> >> >> >
>> >> >> > It, too, fails to preview, indicating the value expression for
>> >> >> > the
>> >> >> > field
>> >> >> > contains an error. Again, all of the other report items are
>> >> >> > calculated
>> >> >> > fields. SUMs, totals, money formats, CASE statements, CASTs,
>> >> >> > etc.
>> >> >> > Using
>> >> >> > the
>> >> >> > report designer/report wizard to 'do it for me' only returns Date
>> >> >> > and a
>> >> >> > couple fields that are not even in my resultset. like one of my
>> >> >> > values
>> >> >> > in
>> >> >> > the report is 'Total Trades'...one of the fields listed as
>> >> >> > available
>> >> >> > is
>> >> >> > 'ID__Total__'
>> >> >> >
>> >> >> > Further, in VS I've got the report open and am on the data tab, i
>> >> >> > hit
>> >> >> > the
>> >> >> > Run option, I receive this error: An error occurred while
>> >> >> > retrieving
>> >> >> > the
>> >> >> > parameters in the query. Could not locate entry in sysdatabases
>> >> >> > for
>> >> >> > database
>> >> >> > 'EXEC databasename'. No entry found with that name. Make sure
>> >> >> > that
>> >> >> > the
>> >> >> > name
>> >> >> > is entered correctly.'
>> >> >> >
>> >> >> > Clearly I am doing something very wrong with the stored procedure
>> >> >> > definition. Like I said, all of these reports are based on
>> >> >> > procedures,
>> >> >> > can
>> >> >> > anybody give me some suggestion/direction on the right way to
>> >> >> > call
>> >> >> > the
>> >> >> > procs?
>> >> >> > They run w/out parameters...EXEC databasename.dbo.proc that's
>> >> >> > it.
>> >> >> > Please advise.
>> >> >> >
>> >> >> >
>> >> >> > -- Lynn
>> >> >>
>> >> >>
>> >> >>
>> >>
>> >>
>> >>
>>|||bruce, i've added the parameters to the proc, now if you fire procname 1,
procname 2, procname 3 or procname 4, it returns each of the resultsets to me
in query analyzer.
in Rs i've got one dataset running this successfully:
EXEC db.dbo.procname 1
results are given, everthing looks good.
but, i go add dataset 2, it seems to do so successfully, but now the data is
not shown. not even the data from the first dataset. it just gives my
header, no results. i don't know how to fix this. should i be using
subreports, should i be using one proce multiple times w/multiple datasets,
i'm just not sure.
-- Lynn
"Bruce L-C [MVP]" wrote:
> Yes, you are calling it three times. In RS you create three datasets. Go to
> the dataset tab and there is a combo box with the name of the dataset, you
> can click on that and there is a an option for a new.
> In your stored procedure
> if @.WHICHRESULTSET = 1
> begin
> --return the first resultset here
> end
> etc
>
> --
> Bruce Loehle-Conger
> MVP SQL Server Reporting Services
> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> news:81E3A442-6694-442D-B151-F083E4750ADB@.microsoft.com...
> > Bruce, or somebody else, might you give me an example of how to give the
> > proc
> > 3 parameters, producing three resultsets in a way that RS will display
> > them?
> > Or, am I giving it three parameters and calling it three times? If so,
> > how
> > would i call the 3 procs in RS?
> > -- Lynn
> >
> >
> > "Bruce L-C [MVP]" wrote:
> >
> >> Configure your existing stored procedure to accept a parameter (you can
> >> make
> >> it optional so that it doesn't break existing code).
> >>
> >> Then call it three times in RS with a static value and create three
> >> datasets.
> >> For instance dataset1
> >> yourproc 1
> >>
> >> Dataset2
> >> yourproc 2
> >>
> >> etc.
> >>
> >> Then in your stored procedure return the appropriate resultset based on
> >> the
> >> parameter.
> >>
> >> Downside is that your sp is being run three times.
> >>
> >>
> >> --
> >> Bruce Loehle-Conger
> >> MVP SQL Server Reporting Services
> >>
> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> news:E8E34B6C-A36A-4576-BE8C-AB61866EEC80@.microsoft.com...
> >> > Bruce, I'm not sure I follow. Can you elaborate a little more, please,
> >> > on
> >> > the second, possibly third procedure?
> >> > -- Lynn
> >> >
> >> >
> >> > "Bruce L-C [MVP]" wrote:
> >> >
> >> >> This is three resultsets. RS does not have the ability to handle that.
> >> >> There
> >> >> is no work around from RS side. You could create another stored
> >> >> procedure
> >> >> that calls this one and have it return just one of the resultsets.
> >> >>
> >> >> RS can deal with multiple datasets quite well, but each stored
> >> >> procedure
> >> >> call can only return one.
> >> >>
> >> >>
> >> >> --
> >> >> Bruce Loehle-Conger
> >> >> MVP SQL Server Reporting Services
> >> >>
> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> news:E1AFA910-1FF4-4DC8-A3F0-FC1EADE8DFD5@.microsoft.com...
> >> >> > oh, bruce, that is great. I can't believe it was as simple as that.
> >> >> > one
> >> >> > remaining problem, though. one of my reports is like this:
> >> >> >
> >> >> > Date Total Trades Symbols Traded Total $
> >> >> > -- -- -- --
> >> >> > 02/07/2006 333,333 333 33,333,333,333.33
> >> >> >
> >> >> > #Stocks Volume Total $
> >> >> > -- -- --
> >> >> > 333,333 33,333,333 3,333,333,333.33
> >> >> >
> >> >> > EndPoint Liquidity #Trades Volume Total $
> >> >> > -- -- -- -- --
> >> >> > AAAA Add 114,729 21,797,575
> >> >> > 583,102,631.33
> >> >> > AAAA Opening 1 27
> >> >> > 3,412.53
> >> >> > AAAA Remove 30,836 8,330,843
> >> >> > 444,521,928.10
> >> >> > AAAA Route 41 4,543
> >> >> > 103,291.31
> >> >> > BBBB Add 26,997 9,940,201
> >> >> > 178,600,674.78
> >> >> > BBBB Opening 8,089 1,448,143
> >> >> > 44,276,419.41
> >> >> > BBBB Remove 3,406 1,719,403
> >> >> > 40,267,318.25
> >> >> > CCCC Add 83,781 22,443,732
> >> >> > 746,570,071.43
> >> >> > CCCC Remove 35,756 12,250,359
> >> >> > 483,329,796.97
> >> >> > CCCC Route 1,088 244,697
> >> >> > 6,655,913.26
> >> >> > DDDD Route 2 62,500
> >> >> > 2,539,375.00
> >> >> > DDDD Add 2,354 1,262,589
> >> >> > 19,136,233.44
> >> >> > DDDD Remove 258 195,019
> >> >> > 6,227,451.69
> >> >> >
> >> >> > I only receive the top line in the resultset:
> >> >> >
> >> >> > Date Total Trades Symbols Traded Total $
> >> >> > -- -- -- --
> >> >> > 02/07/2006 333,333 333 33,333,333,333.33
> >> >> >
> >> >> > I assume this is what you mean when you say it will only handle the
> >> >> > 1st
> >> >> > resultset. All of my reports have multiple 'chunks' in the body.
> >> >> > Do
> >> >> > you
> >> >> > have any idea how I can achieve this report via reporting svcs?
> >> >> > Unfortunately, this is very important. Please do advise.
> >> >> >
> >> >> > --Lynn
> >> >> >
> >> >> >
> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >
> >> >> >> Pick the command type as stored procedure and then just enter the
> >> >> >> name
> >> >> >> of
> >> >> >> the stored procedure. When you click on the ! you should get back
> >> >> >> the
> >> >> >> data
> >> >> >> and the fields. If you do not get the field list populated then
> >> >> >> click
> >> >> >> on
> >> >> >> the
> >> >> >> refresh fields button (to the right of the ..., it looks like the
> >> >> >> refresh
> >> >> >> button for IE).
> >> >> >>
> >> >> >> Note that RS only works with the first resultset returned. It
> >> >> >> cannot
> >> >> >> handle
> >> >> >> mutliple resultsets.
> >> >> >>
> >> >> >>
> >> >> >> --
> >> >> >> Bruce Loehle-Conger
> >> >> >> MVP SQL Server Reporting Services
> >> >> >>
> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> news:EF6A6CBC-083B-4537-83D9-D763A8ABA056@.microsoft.com...
> >> >> >> > Hi. I have a need to create a number of different reports via
> >> >> >> > Reporting
> >> >> >> > Services. All of which are based on stored procedures, none of
> >> >> >> > which
> >> >> >> > require
> >> >> >> > any parameters. Most if not all of the report is calculated. I
> >> >> >> > am
> >> >> >> > struggling badly to get even the most basic of the fields in
> >> >> >> > place
> >> >> >> > w/the
> >> >> >> > correct expressions. The only one I actually got to accept the
> >> >> >> > expression
> >> >> >> > was a Date field, this is the calculation:
> >> >> >> >
> >> >> >> > =SELECT CONVERT(char(10),dateadd(dd,-0,GetDate()),1)
> >> >> >> >
> >> >> >> > It, too, fails to preview, indicating the value expression for
> >> >> >> > the
> >> >> >> > field
> >> >> >> > contains an error. Again, all of the other report items are
> >> >> >> > calculated
> >> >> >> > fields. SUMs, totals, money formats, CASE statements, CASTs,
> >> >> >> > etc.
> >> >> >> > Using
> >> >> >> > the
> >> >> >> > report designer/report wizard to 'do it for me' only returns Date
> >> >> >> > and a
> >> >> >> > couple fields that are not even in my resultset. like one of my
> >> >> >> > values
> >> >> >> > in
> >> >> >> > the report is 'Total Trades'...one of the fields listed as
> >> >> >> > available
> >> >> >> > is
> >> >> >> > 'ID__Total__'
> >> >> >> >
> >> >> >> > Further, in VS I've got the report open and am on the data tab, i
> >> >> >> > hit
> >> >> >> > the
> >> >> >> > Run option, I receive this error: An error occurred while
> >> >> >> > retrieving
> >> >> >> > the
> >> >> >> > parameters in the query. Could not locate entry in sysdatabases
> >> >> >> > for
> >> >> >> > database
> >> >> >> > 'EXEC databasename'. No entry found with that name. Make sure
> >> >> >> > that
> >> >> >> > the
> >> >> >> > name
> >> >> >> > is entered correctly.'
> >> >> >> >
> >> >> >> > Clearly I am doing something very wrong with the stored procedure
> >> >> >> > definition. Like I said, all of these reports are based on
> >> >> >> > procedures,
> >> >> >> > can
> >> >> >> > anybody give me some suggestion/direction on the right way to
> >> >> >> > call
> >> >> >> > the
> >> >> >> > procs?
> >> >> >> > They run w/out parameters...EXEC databasename.dbo.proc that's
> >> >> >> > it.
> >> >> >> > Please advise.
> >> >> >> >
> >> >> >> >
> >> >> >> > -- Lynn
> >> >> >>
> >> >> >>
> >> >> >>
> >> >>
> >> >>
> >> >>
> >>
> >>
> >>
>
>|||And, if I blow away the 2nd dataset and just give my 1st one parameters, it
almost works. EXEC db.dbo.procname 1 for chunk one of the results, works
just fine. if i change the parameter to 2, 3 or 4, when I hit RUN in Data
tab it returns an error: SQL Syntax Errors Encountered...The designer does
not graphically support the EXEC SQL Construct' but, i hit 'OK' and my
results are still returned to me. On 'Preview' tab, however, I get no
data/results at all.
-- Lynn
"Bruce L-C [MVP]" wrote:
> Yes, you are calling it three times. In RS you create three datasets. Go to
> the dataset tab and there is a combo box with the name of the dataset, you
> can click on that and there is a an option for a new.
> In your stored procedure
> if @.WHICHRESULTSET = 1
> begin
> --return the first resultset here
> end
> etc
>
> --
> Bruce Loehle-Conger
> MVP SQL Server Reporting Services
> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> news:81E3A442-6694-442D-B151-F083E4750ADB@.microsoft.com...
> > Bruce, or somebody else, might you give me an example of how to give the
> > proc
> > 3 parameters, producing three resultsets in a way that RS will display
> > them?
> > Or, am I giving it three parameters and calling it three times? If so,
> > how
> > would i call the 3 procs in RS?
> > -- Lynn
> >
> >
> > "Bruce L-C [MVP]" wrote:
> >
> >> Configure your existing stored procedure to accept a parameter (you can
> >> make
> >> it optional so that it doesn't break existing code).
> >>
> >> Then call it three times in RS with a static value and create three
> >> datasets.
> >> For instance dataset1
> >> yourproc 1
> >>
> >> Dataset2
> >> yourproc 2
> >>
> >> etc.
> >>
> >> Then in your stored procedure return the appropriate resultset based on
> >> the
> >> parameter.
> >>
> >> Downside is that your sp is being run three times.
> >>
> >>
> >> --
> >> Bruce Loehle-Conger
> >> MVP SQL Server Reporting Services
> >>
> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> news:E8E34B6C-A36A-4576-BE8C-AB61866EEC80@.microsoft.com...
> >> > Bruce, I'm not sure I follow. Can you elaborate a little more, please,
> >> > on
> >> > the second, possibly third procedure?
> >> > -- Lynn
> >> >
> >> >
> >> > "Bruce L-C [MVP]" wrote:
> >> >
> >> >> This is three resultsets. RS does not have the ability to handle that.
> >> >> There
> >> >> is no work around from RS side. You could create another stored
> >> >> procedure
> >> >> that calls this one and have it return just one of the resultsets.
> >> >>
> >> >> RS can deal with multiple datasets quite well, but each stored
> >> >> procedure
> >> >> call can only return one.
> >> >>
> >> >>
> >> >> --
> >> >> Bruce Loehle-Conger
> >> >> MVP SQL Server Reporting Services
> >> >>
> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> news:E1AFA910-1FF4-4DC8-A3F0-FC1EADE8DFD5@.microsoft.com...
> >> >> > oh, bruce, that is great. I can't believe it was as simple as that.
> >> >> > one
> >> >> > remaining problem, though. one of my reports is like this:
> >> >> >
> >> >> > Date Total Trades Symbols Traded Total $
> >> >> > -- -- -- --
> >> >> > 02/07/2006 333,333 333 33,333,333,333.33
> >> >> >
> >> >> > #Stocks Volume Total $
> >> >> > -- -- --
> >> >> > 333,333 33,333,333 3,333,333,333.33
> >> >> >
> >> >> > EndPoint Liquidity #Trades Volume Total $
> >> >> > -- -- -- -- --
> >> >> > AAAA Add 114,729 21,797,575
> >> >> > 583,102,631.33
> >> >> > AAAA Opening 1 27
> >> >> > 3,412.53
> >> >> > AAAA Remove 30,836 8,330,843
> >> >> > 444,521,928.10
> >> >> > AAAA Route 41 4,543
> >> >> > 103,291.31
> >> >> > BBBB Add 26,997 9,940,201
> >> >> > 178,600,674.78
> >> >> > BBBB Opening 8,089 1,448,143
> >> >> > 44,276,419.41
> >> >> > BBBB Remove 3,406 1,719,403
> >> >> > 40,267,318.25
> >> >> > CCCC Add 83,781 22,443,732
> >> >> > 746,570,071.43
> >> >> > CCCC Remove 35,756 12,250,359
> >> >> > 483,329,796.97
> >> >> > CCCC Route 1,088 244,697
> >> >> > 6,655,913.26
> >> >> > DDDD Route 2 62,500
> >> >> > 2,539,375.00
> >> >> > DDDD Add 2,354 1,262,589
> >> >> > 19,136,233.44
> >> >> > DDDD Remove 258 195,019
> >> >> > 6,227,451.69
> >> >> >
> >> >> > I only receive the top line in the resultset:
> >> >> >
> >> >> > Date Total Trades Symbols Traded Total $
> >> >> > -- -- -- --
> >> >> > 02/07/2006 333,333 333 33,333,333,333.33
> >> >> >
> >> >> > I assume this is what you mean when you say it will only handle the
> >> >> > 1st
> >> >> > resultset. All of my reports have multiple 'chunks' in the body.
> >> >> > Do
> >> >> > you
> >> >> > have any idea how I can achieve this report via reporting svcs?
> >> >> > Unfortunately, this is very important. Please do advise.
> >> >> >
> >> >> > --Lynn
> >> >> >
> >> >> >
> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >
> >> >> >> Pick the command type as stored procedure and then just enter the
> >> >> >> name
> >> >> >> of
> >> >> >> the stored procedure. When you click on the ! you should get back
> >> >> >> the
> >> >> >> data
> >> >> >> and the fields. If you do not get the field list populated then
> >> >> >> click
> >> >> >> on
> >> >> >> the
> >> >> >> refresh fields button (to the right of the ..., it looks like the
> >> >> >> refresh
> >> >> >> button for IE).
> >> >> >>
> >> >> >> Note that RS only works with the first resultset returned. It
> >> >> >> cannot
> >> >> >> handle
> >> >> >> mutliple resultsets.
> >> >> >>
> >> >> >>
> >> >> >> --
> >> >> >> Bruce Loehle-Conger
> >> >> >> MVP SQL Server Reporting Services
> >> >> >>
> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> news:EF6A6CBC-083B-4537-83D9-D763A8ABA056@.microsoft.com...
> >> >> >> > Hi. I have a need to create a number of different reports via
> >> >> >> > Reporting
> >> >> >> > Services. All of which are based on stored procedures, none of
> >> >> >> > which
> >> >> >> > require
> >> >> >> > any parameters. Most if not all of the report is calculated. I
> >> >> >> > am
> >> >> >> > struggling badly to get even the most basic of the fields in
> >> >> >> > place
> >> >> >> > w/the
> >> >> >> > correct expressions. The only one I actually got to accept the
> >> >> >> > expression
> >> >> >> > was a Date field, this is the calculation:
> >> >> >> >
> >> >> >> > =SELECT CONVERT(char(10),dateadd(dd,-0,GetDate()),1)
> >> >> >> >
> >> >> >> > It, too, fails to preview, indicating the value expression for
> >> >> >> > the
> >> >> >> > field
> >> >> >> > contains an error. Again, all of the other report items are
> >> >> >> > calculated
> >> >> >> > fields. SUMs, totals, money formats, CASE statements, CASTs,
> >> >> >> > etc.
> >> >> >> > Using
> >> >> >> > the
> >> >> >> > report designer/report wizard to 'do it for me' only returns Date
> >> >> >> > and a
> >> >> >> > couple fields that are not even in my resultset. like one of my
> >> >> >> > values
> >> >> >> > in
> >> >> >> > the report is 'Total Trades'...one of the fields listed as
> >> >> >> > available
> >> >> >> > is
> >> >> >> > 'ID__Total__'
> >> >> >> >
> >> >> >> > Further, in VS I've got the report open and am on the data tab, i
> >> >> >> > hit
> >> >> >> > the
> >> >> >> > Run option, I receive this error: An error occurred while
> >> >> >> > retrieving
> >> >> >> > the
> >> >> >> > parameters in the query. Could not locate entry in sysdatabases
> >> >> >> > for
> >> >> >> > database
> >> >> >> > 'EXEC databasename'. No entry found with that name. Make sure
> >> >> >> > that
> >> >> >> > the
> >> >> >> > name
> >> >> >> > is entered correctly.'
> >> >> >> >
> >> >> >> > Clearly I am doing something very wrong with the stored procedure
> >> >> >> > definition. Like I said, all of these reports are based on
> >> >> >> > procedures,
> >> >> >> > can
> >> >> >> > anybody give me some suggestion/direction on the right way to
> >> >> >> > call
> >> >> >> > the
> >> >> >> > procs?
> >> >> >> > They run w/out parameters...EXEC databasename.dbo.proc that's
> >> >> >> > it.
> >> >> >> > Please advise.
> >> >> >> >
> >> >> >> >
> >> >> >> > -- Lynn
> >> >> >>
> >> >> >>
> >> >> >>
> >> >>
> >> >>
> >> >>
> >>
> >>
> >>
>
>|||If you are going against SQL Server do not run your stored procedure this
way. Pick command type of stored procedure. RS will detect the parameters.
If going against ODBC or OLEDB driver (which uses ? format for parameters)
then pick text as the command type and do this:
myproc ?
Create multiple datasets and for each one you should call the stored
procedure for each one.
Bruce Loehle-Conger
"Lynn" <Lynn@.discussions.microsoft.com> wrote in message
news:79CA374D-729B-4181-8F45-5D61FCF30F28@.microsoft.com...
> And, if I blow away the 2nd dataset and just give my 1st one parameters,
> it
> almost works. EXEC db.dbo.procname 1 for chunk one of the results,
> works
> just fine. if i change the parameter to 2, 3 or 4, when I hit RUN in Data
> tab it returns an error: SQL Syntax Errors Encountered...The designer
> does
> not graphically support the EXEC SQL Construct' but, i hit 'OK' and my
> results are still returned to me. On 'Preview' tab, however, I get no
> data/results at all.
> -- Lynn
>
> "Bruce L-C [MVP]" wrote:
>> Yes, you are calling it three times. In RS you create three datasets. Go
>> to
>> the dataset tab and there is a combo box with the name of the dataset,
>> you
>> can click on that and there is a an option for a new.
>> In your stored procedure
>> if @.WHICHRESULTSET = 1
>> begin
>> --return the first resultset here
>> end
>> etc
>>
>> --
>> Bruce Loehle-Conger
>> MVP SQL Server Reporting Services
>> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> news:81E3A442-6694-442D-B151-F083E4750ADB@.microsoft.com...
>> > Bruce, or somebody else, might you give me an example of how to give
>> > the
>> > proc
>> > 3 parameters, producing three resultsets in a way that RS will display
>> > them?
>> > Or, am I giving it three parameters and calling it three times? If so,
>> > how
>> > would i call the 3 procs in RS?
>> > -- Lynn
>> >
>> >
>> > "Bruce L-C [MVP]" wrote:
>> >
>> >> Configure your existing stored procedure to accept a parameter (you
>> >> can
>> >> make
>> >> it optional so that it doesn't break existing code).
>> >>
>> >> Then call it three times in RS with a static value and create three
>> >> datasets.
>> >> For instance dataset1
>> >> yourproc 1
>> >>
>> >> Dataset2
>> >> yourproc 2
>> >>
>> >> etc.
>> >>
>> >> Then in your stored procedure return the appropriate resultset based
>> >> on
>> >> the
>> >> parameter.
>> >>
>> >> Downside is that your sp is being run three times.
>> >>
>> >>
>> >> --
>> >> Bruce Loehle-Conger
>> >> MVP SQL Server Reporting Services
>> >>
>> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> >> news:E8E34B6C-A36A-4576-BE8C-AB61866EEC80@.microsoft.com...
>> >> > Bruce, I'm not sure I follow. Can you elaborate a little more,
>> >> > please,
>> >> > on
>> >> > the second, possibly third procedure?
>> >> > -- Lynn
>> >> >
>> >> >
>> >> > "Bruce L-C [MVP]" wrote:
>> >> >
>> >> >> This is three resultsets. RS does not have the ability to handle
>> >> >> that.
>> >> >> There
>> >> >> is no work around from RS side. You could create another stored
>> >> >> procedure
>> >> >> that calls this one and have it return just one of the resultsets.
>> >> >>
>> >> >> RS can deal with multiple datasets quite well, but each stored
>> >> >> procedure
>> >> >> call can only return one.
>> >> >>
>> >> >>
>> >> >> --
>> >> >> Bruce Loehle-Conger
>> >> >> MVP SQL Server Reporting Services
>> >> >>
>> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> >> >> news:E1AFA910-1FF4-4DC8-A3F0-FC1EADE8DFD5@.microsoft.com...
>> >> >> > oh, bruce, that is great. I can't believe it was as simple as
>> >> >> > that.
>> >> >> > one
>> >> >> > remaining problem, though. one of my reports is like this:
>> >> >> >
>> >> >> > Date Total Trades Symbols Traded Total $
>> >> >> > -- -- -- --
>> >> >> > 02/07/2006 333,333 333
>> >> >> > 33,333,333,333.33
>> >> >> >
>> >> >> > #Stocks Volume Total $
>> >> >> > -- -- --
>> >> >> > 333,333 33,333,333 3,333,333,333.33
>> >> >> >
>> >> >> > EndPoint Liquidity #Trades Volume Total $
>> >> >> > -- -- -- -- --
>> >> >> > AAAA Add 114,729 21,797,575
>> >> >> > 583,102,631.33
>> >> >> > AAAA Opening 1 27
>> >> >> > 3,412.53
>> >> >> > AAAA Remove 30,836 8,330,843
>> >> >> > 444,521,928.10
>> >> >> > AAAA Route 41 4,543
>> >> >> > 103,291.31
>> >> >> > BBBB Add 26,997 9,940,201
>> >> >> > 178,600,674.78
>> >> >> > BBBB Opening 8,089 1,448,143
>> >> >> > 44,276,419.41
>> >> >> > BBBB Remove 3,406 1,719,403
>> >> >> > 40,267,318.25
>> >> >> > CCCC Add 83,781 22,443,732
>> >> >> > 746,570,071.43
>> >> >> > CCCC Remove 35,756 12,250,359
>> >> >> > 483,329,796.97
>> >> >> > CCCC Route 1,088 244,697
>> >> >> > 6,655,913.26
>> >> >> > DDDD Route 2 62,500
>> >> >> > 2,539,375.00
>> >> >> > DDDD Add 2,354 1,262,589
>> >> >> > 19,136,233.44
>> >> >> > DDDD Remove 258 195,019
>> >> >> > 6,227,451.69
>> >> >> >
>> >> >> > I only receive the top line in the resultset:
>> >> >> >
>> >> >> > Date Total Trades Symbols Traded Total $
>> >> >> > -- -- -- --
>> >> >> > 02/07/2006 333,333 333
>> >> >> > 33,333,333,333.33
>> >> >> >
>> >> >> > I assume this is what you mean when you say it will only handle
>> >> >> > the
>> >> >> > 1st
>> >> >> > resultset. All of my reports have multiple 'chunks' in the
>> >> >> > body.
>> >> >> > Do
>> >> >> > you
>> >> >> > have any idea how I can achieve this report via reporting svcs?
>> >> >> > Unfortunately, this is very important. Please do advise.
>> >> >> >
>> >> >> > --Lynn
>> >> >> >
>> >> >> >
>> >> >> > "Bruce L-C [MVP]" wrote:
>> >> >> >
>> >> >> >> Pick the command type as stored procedure and then just enter
>> >> >> >> the
>> >> >> >> name
>> >> >> >> of
>> >> >> >> the stored procedure. When you click on the ! you should get
>> >> >> >> back
>> >> >> >> the
>> >> >> >> data
>> >> >> >> and the fields. If you do not get the field list populated then
>> >> >> >> click
>> >> >> >> on
>> >> >> >> the
>> >> >> >> refresh fields button (to the right of the ..., it looks like
>> >> >> >> the
>> >> >> >> refresh
>> >> >> >> button for IE).
>> >> >> >>
>> >> >> >> Note that RS only works with the first resultset returned. It
>> >> >> >> cannot
>> >> >> >> handle
>> >> >> >> mutliple resultsets.
>> >> >> >>
>> >> >> >>
>> >> >> >> --
>> >> >> >> Bruce Loehle-Conger
>> >> >> >> MVP SQL Server Reporting Services
>> >> >> >>
>> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> >> >> >> news:EF6A6CBC-083B-4537-83D9-D763A8ABA056@.microsoft.com...
>> >> >> >> > Hi. I have a need to create a number of different reports via
>> >> >> >> > Reporting
>> >> >> >> > Services. All of which are based on stored procedures, none
>> >> >> >> > of
>> >> >> >> > which
>> >> >> >> > require
>> >> >> >> > any parameters. Most if not all of the report is calculated.
>> >> >> >> > I
>> >> >> >> > am
>> >> >> >> > struggling badly to get even the most basic of the fields in
>> >> >> >> > place
>> >> >> >> > w/the
>> >> >> >> > correct expressions. The only one I actually got to accept
>> >> >> >> > the
>> >> >> >> > expression
>> >> >> >> > was a Date field, this is the calculation:
>> >> >> >> >
>> >> >> >> > =SELECT CONVERT(char(10),dateadd(dd,-0,GetDate()),1)
>> >> >> >> >
>> >> >> >> > It, too, fails to preview, indicating the value expression for
>> >> >> >> > the
>> >> >> >> > field
>> >> >> >> > contains an error. Again, all of the other report items are
>> >> >> >> > calculated
>> >> >> >> > fields. SUMs, totals, money formats, CASE statements, CASTs,
>> >> >> >> > etc.
>> >> >> >> > Using
>> >> >> >> > the
>> >> >> >> > report designer/report wizard to 'do it for me' only returns
>> >> >> >> > Date
>> >> >> >> > and a
>> >> >> >> > couple fields that are not even in my resultset. like one of
>> >> >> >> > my
>> >> >> >> > values
>> >> >> >> > in
>> >> >> >> > the report is 'Total Trades'...one of the fields listed as
>> >> >> >> > available
>> >> >> >> > is
>> >> >> >> > 'ID__Total__'
>> >> >> >> >
>> >> >> >> > Further, in VS I've got the report open and am on the data
>> >> >> >> > tab, i
>> >> >> >> > hit
>> >> >> >> > the
>> >> >> >> > Run option, I receive this error: An error occurred while
>> >> >> >> > retrieving
>> >> >> >> > the
>> >> >> >> > parameters in the query. Could not locate entry in
>> >> >> >> > sysdatabases
>> >> >> >> > for
>> >> >> >> > database
>> >> >> >> > 'EXEC databasename'. No entry found with that name. Make sure
>> >> >> >> > that
>> >> >> >> > the
>> >> >> >> > name
>> >> >> >> > is entered correctly.'
>> >> >> >> >
>> >> >> >> > Clearly I am doing something very wrong with the stored
>> >> >> >> > procedure
>> >> >> >> > definition. Like I said, all of these reports are based on
>> >> >> >> > procedures,
>> >> >> >> > can
>> >> >> >> > anybody give me some suggestion/direction on the right way to
>> >> >> >> > call
>> >> >> >> > the
>> >> >> >> > procs?
>> >> >> >> > They run w/out parameters...EXEC databasename.dbo.proc
>> >> >> >> > that's
>> >> >> >> > it.
>> >> >> >> > Please advise.
>> >> >> >> >
>> >> >> >> >
>> >> >> >> > -- Lynn
>> >> >> >>
>> >> >> >>
>> >> >> >>
>> >> >>
>> >> >>
>> >> >>
>> >>
>> >>
>> >>
>>|||i'm sorry, bruce, but where do i define the parameters? rs is not detecting
them. in my 1st dataset i've got cmd type stored procedure and the proc name
is in the query string. i assumed i would put the 1st parameter in on the
parameters tab and then do the same for 2, 3 and 4 on 3 other datasets, so i
gave it @.ch and the value of 1, but when i attempted to run it, it threw me a
'define query parameters box asking me to put the '1' in it.
-- Lynn
"Bruce L-C [MVP]" wrote:
> If you are going against SQL Server do not run your stored procedure this
> way. Pick command type of stored procedure. RS will detect the parameters.
> If going against ODBC or OLEDB driver (which uses ? format for parameters)
> then pick text as the command type and do this:
> myproc ?
> Create multiple datasets and for each one you should call the stored
> procedure for each one.
> Bruce Loehle-Conger
> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> news:79CA374D-729B-4181-8F45-5D61FCF30F28@.microsoft.com...
> > And, if I blow away the 2nd dataset and just give my 1st one parameters,
> > it
> > almost works. EXEC db.dbo.procname 1 for chunk one of the results,
> > works
> > just fine. if i change the parameter to 2, 3 or 4, when I hit RUN in Data
> > tab it returns an error: SQL Syntax Errors Encountered...The designer
> > does
> > not graphically support the EXEC SQL Construct' but, i hit 'OK' and my
> > results are still returned to me. On 'Preview' tab, however, I get no
> > data/results at all.
> > -- Lynn
> >
> >
> > "Bruce L-C [MVP]" wrote:
> >
> >> Yes, you are calling it three times. In RS you create three datasets. Go
> >> to
> >> the dataset tab and there is a combo box with the name of the dataset,
> >> you
> >> can click on that and there is a an option for a new.
> >>
> >> In your stored procedure
> >>
> >> if @.WHICHRESULTSET = 1
> >> begin
> >> --return the first resultset here
> >> end
> >> etc
> >>
> >>
> >> --
> >> Bruce Loehle-Conger
> >> MVP SQL Server Reporting Services
> >>
> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> news:81E3A442-6694-442D-B151-F083E4750ADB@.microsoft.com...
> >> > Bruce, or somebody else, might you give me an example of how to give
> >> > the
> >> > proc
> >> > 3 parameters, producing three resultsets in a way that RS will display
> >> > them?
> >> > Or, am I giving it three parameters and calling it three times? If so,
> >> > how
> >> > would i call the 3 procs in RS?
> >> > -- Lynn
> >> >
> >> >
> >> > "Bruce L-C [MVP]" wrote:
> >> >
> >> >> Configure your existing stored procedure to accept a parameter (you
> >> >> can
> >> >> make
> >> >> it optional so that it doesn't break existing code).
> >> >>
> >> >> Then call it three times in RS with a static value and create three
> >> >> datasets.
> >> >> For instance dataset1
> >> >> yourproc 1
> >> >>
> >> >> Dataset2
> >> >> yourproc 2
> >> >>
> >> >> etc.
> >> >>
> >> >> Then in your stored procedure return the appropriate resultset based
> >> >> on
> >> >> the
> >> >> parameter.
> >> >>
> >> >> Downside is that your sp is being run three times.
> >> >>
> >> >>
> >> >> --
> >> >> Bruce Loehle-Conger
> >> >> MVP SQL Server Reporting Services
> >> >>
> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> news:E8E34B6C-A36A-4576-BE8C-AB61866EEC80@.microsoft.com...
> >> >> > Bruce, I'm not sure I follow. Can you elaborate a little more,
> >> >> > please,
> >> >> > on
> >> >> > the second, possibly third procedure?
> >> >> > -- Lynn
> >> >> >
> >> >> >
> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >
> >> >> >> This is three resultsets. RS does not have the ability to handle
> >> >> >> that.
> >> >> >> There
> >> >> >> is no work around from RS side. You could create another stored
> >> >> >> procedure
> >> >> >> that calls this one and have it return just one of the resultsets.
> >> >> >>
> >> >> >> RS can deal with multiple datasets quite well, but each stored
> >> >> >> procedure
> >> >> >> call can only return one.
> >> >> >>
> >> >> >>
> >> >> >> --
> >> >> >> Bruce Loehle-Conger
> >> >> >> MVP SQL Server Reporting Services
> >> >> >>
> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> news:E1AFA910-1FF4-4DC8-A3F0-FC1EADE8DFD5@.microsoft.com...
> >> >> >> > oh, bruce, that is great. I can't believe it was as simple as
> >> >> >> > that.
> >> >> >> > one
> >> >> >> > remaining problem, though. one of my reports is like this:
> >> >> >> >
> >> >> >> > Date Total Trades Symbols Traded Total $
> >> >> >> > -- -- -- --
> >> >> >> > 02/07/2006 333,333 333
> >> >> >> > 33,333,333,333.33
> >> >> >> >
> >> >> >> > #Stocks Volume Total $
> >> >> >> > -- -- --
> >> >> >> > 333,333 33,333,333 3,333,333,333.33
> >> >> >> >
> >> >> >> > EndPoint Liquidity #Trades Volume Total $
> >> >> >> > -- -- -- -- --
> >> >> >> > AAAA Add 114,729 21,797,575
> >> >> >> > 583,102,631.33
> >> >> >> > AAAA Opening 1 27
> >> >> >> > 3,412.53
> >> >> >> > AAAA Remove 30,836 8,330,843
> >> >> >> > 444,521,928.10
> >> >> >> > AAAA Route 41 4,543
> >> >> >> > 103,291.31
> >> >> >> > BBBB Add 26,997 9,940,201
> >> >> >> > 178,600,674.78
> >> >> >> > BBBB Opening 8,089 1,448,143
> >> >> >> > 44,276,419.41
> >> >> >> > BBBB Remove 3,406 1,719,403
> >> >> >> > 40,267,318.25
> >> >> >> > CCCC Add 83,781 22,443,732
> >> >> >> > 746,570,071.43
> >> >> >> > CCCC Remove 35,756 12,250,359
> >> >> >> > 483,329,796.97
> >> >> >> > CCCC Route 1,088 244,697
> >> >> >> > 6,655,913.26
> >> >> >> > DDDD Route 2 62,500
> >> >> >> > 2,539,375.00
> >> >> >> > DDDD Add 2,354 1,262,589
> >> >> >> > 19,136,233.44
> >> >> >> > DDDD Remove 258 195,019
> >> >> >> > 6,227,451.69
> >> >> >> >
> >> >> >> > I only receive the top line in the resultset:
> >> >> >> >
> >> >> >> > Date Total Trades Symbols Traded Total $
> >> >> >> > -- -- -- --
> >> >> >> > 02/07/2006 333,333 333
> >> >> >> > 33,333,333,333.33
> >> >> >> >
> >> >> >> > I assume this is what you mean when you say it will only handle
> >> >> >> > the
> >> >> >> > 1st
> >> >> >> > resultset. All of my reports have multiple 'chunks' in the
> >> >> >> > body.
> >> >> >> > Do
> >> >> >> > you
> >> >> >> > have any idea how I can achieve this report via reporting svcs?
> >> >> >> > Unfortunately, this is very important. Please do advise.
> >> >> >> >
> >> >> >> > --Lynn
> >> >> >> >
> >> >> >> >
> >> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >> >
> >> >> >> >> Pick the command type as stored procedure and then just enter
> >> >> >> >> the
> >> >> >> >> name
> >> >> >> >> of
> >> >> >> >> the stored procedure. When you click on the ! you should get
> >> >> >> >> back
> >> >> >> >> the
> >> >> >> >> data
> >> >> >> >> and the fields. If you do not get the field list populated then
> >> >> >> >> click
> >> >> >> >> on
> >> >> >> >> the
> >> >> >> >> refresh fields button (to the right of the ..., it looks like
> >> >> >> >> the
> >> >> >> >> refresh
> >> >> >> >> button for IE).
> >> >> >> >>
> >> >> >> >> Note that RS only works with the first resultset returned. It
> >> >> >> >> cannot
> >> >> >> >> handle
> >> >> >> >> mutliple resultsets.
> >> >> >> >>
> >> >> >> >>
> >> >> >> >> --
> >> >> >> >> Bruce Loehle-Conger
> >> >> >> >> MVP SQL Server Reporting Services
> >> >> >> >>
> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> >> news:EF6A6CBC-083B-4537-83D9-D763A8ABA056@.microsoft.com...
> >> >> >> >> > Hi. I have a need to create a number of different reports via
> >> >> >> >> > Reporting
> >> >> >> >> > Services. All of which are based on stored procedures, none
> >> >> >> >> > of
> >> >> >> >> > which
> >> >> >> >> > require
> >> >> >> >> > any parameters. Most if not all of the report is calculated.
> >> >> >> >> > I
> >> >> >> >> > am
> >> >> >> >> > struggling badly to get even the most basic of the fields in
> >> >> >> >> > place
> >> >> >> >> > w/the
> >> >> >> >> > correct expressions. The only one I actually got to accept
> >> >> >> >> > the
> >> >> >> >> > expression
> >> >> >> >> > was a Date field, this is the calculation:
> >> >> >> >> >
> >> >> >> >> > =SELECT CONVERT(char(10),dateadd(dd,-0,GetDate()),1)
> >> >> >> >> >
> >> >> >> >> > It, too, fails to preview, indicating the value expression for
> >> >> >> >> > the
> >> >> >> >> > field
> >> >> >> >> > contains an error. Again, all of the other report items are
> >> >> >> >> > calculated
> >> >> >> >> > fields. SUMs, totals, money formats, CASE statements, CASTs,
> >> >> >> >> > etc.
> >> >> >> >> > Using
> >> >> >> >> > the
> >> >> >> >> > report designer/report wizard to 'do it for me' only returns
> >> >> >> >> > Date
> >> >> >> >> > and a
> >> >> >> >> > couple fields that are not even in my resultset. like one of
> >> >> >> >> > my
> >> >> >> >> > values
> >> >> >> >> > in
> >> >> >> >> > the report is 'Total Trades'...one of the fields listed as
> >> >> >> >> > available
> >> >> >> >> > is
> >> >> >> >> > 'ID__Total__'
> >> >> >> >> >
> >> >> >> >> > Further, in VS I've got the report open and am on the data
> >> >> >> >> > tab, i
> >> >> >> >> > hit
> >> >> >> >> > the
> >> >> >> >> > Run option, I receive this error: An error occurred while
> >> >> >> >> > retrieving
> >> >> >> >> > the
> >> >> >> >> > parameters in the query. Could not locate entry in
> >> >> >> >> > sysdatabases
> >> >> >> >> > for
> >> >> >> >> > database
> >> >> >> >> > 'EXEC databasename'. No entry found with that name. Make sure
> >> >> >> >> > that
> >> >> >> >> > the
> >> >> >> >> > name
> >> >> >> >> > is entered correctly.'
> >> >> >> >> >
> >> >> >> >> > Clearly I am doing something very wrong with the stored
> >> >> >> >> > procedure
> >> >> >> >> > definition. Like I said, all of these reports are based on
> >> >> >> >> > procedures,
> >> >> >> >> > can
> >> >> >> >> > anybody give me some suggestion/direction on the right way to
> >> >> >> >> > call
> >> >> >> >> > the
> >> >> >> >> > procs?
> >> >> >> >> > They run w/out parameters...EXEC databasename.dbo.proc
> >> >> >> >> > that's
> >> >> >> >> > it.
> >> >> >> >> > Please advise.
> >> >> >> >> >
> >> >> >> >> >
> >> >> >> >> > -- Lynn
> >> >> >> >>
> >> >> >> >>
> >> >> >> >>
> >> >> >>
> >> >> >>
> >> >> >>
> >> >>
> >> >>
> >> >>
> >>
> >>
> >>
>
>|||Are you going against SQL Server?
If so, then just select tored procedure for the command type and just put in
the name of the stored procedure. Do not put exec in from of it or anything
else. It should detect the parameter and prompt you for it. It should also
create a report parameter as well for you.
Try creating a new dataset and do this from the start. If you continue to
have problems create a new stored procedure just for testing .
create procedure dbo.testproc
@.PARAM1 int
as
select 'Parameter passed in = ' + @.PARAM1 as Message
return
Get the above procedure to work for you so you know how to call a stored
procedure they way I am telling you (do not use exec).
Bruce Loehle-Conger
MVP SQL Server Reporting Services
--
Bruce Loehle-Conger
MVP SQL Server Reporting Services
"Lynn" <Lynn@.discussions.microsoft.com> wrote in message
news:9B089D7B-1F23-465B-B443-08BD09469A3E@.microsoft.com...
> i'm sorry, bruce, but where do i define the parameters? rs is not
> detecting
> them. in my 1st dataset i've got cmd type stored procedure and the proc
> name
> is in the query string. i assumed i would put the 1st parameter in on the
> parameters tab and then do the same for 2, 3 and 4 on 3 other datasets, so
> i
> gave it @.ch and the value of 1, but when i attempted to run it, it threw
> me a
> 'define query parameters box asking me to put the '1' in it.
> -- Lynn
>
> "Bruce L-C [MVP]" wrote:
>> If you are going against SQL Server do not run your stored procedure this
>> way. Pick command type of stored procedure. RS will detect the
>> parameters.
>> If going against ODBC or OLEDB driver (which uses ? format for
>> parameters)
>> then pick text as the command type and do this:
>> myproc ?
>> Create multiple datasets and for each one you should call the stored
>> procedure for each one.
>> Bruce Loehle-Conger
>> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> news:79CA374D-729B-4181-8F45-5D61FCF30F28@.microsoft.com...
>> > And, if I blow away the 2nd dataset and just give my 1st one
>> > parameters,
>> > it
>> > almost works. EXEC db.dbo.procname 1 for chunk one of the results,
>> > works
>> > just fine. if i change the parameter to 2, 3 or 4, when I hit RUN in
>> > Data
>> > tab it returns an error: SQL Syntax Errors Encountered...The designer
>> > does
>> > not graphically support the EXEC SQL Construct' but, i hit 'OK' and
>> > my
>> > results are still returned to me. On 'Preview' tab, however, I get no
>> > data/results at all.
>> > -- Lynn
>> >
>> >
>> > "Bruce L-C [MVP]" wrote:
>> >
>> >> Yes, you are calling it three times. In RS you create three datasets.
>> >> Go
>> >> to
>> >> the dataset tab and there is a combo box with the name of the dataset,
>> >> you
>> >> can click on that and there is a an option for a new.
>> >>
>> >> In your stored procedure
>> >>
>> >> if @.WHICHRESULTSET = 1
>> >> begin
>> >> --return the first resultset here
>> >> end
>> >> etc
>> >>
>> >>
>> >> --
>> >> Bruce Loehle-Conger
>> >> MVP SQL Server Reporting Services
>> >>
>> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> >> news:81E3A442-6694-442D-B151-F083E4750ADB@.microsoft.com...
>> >> > Bruce, or somebody else, might you give me an example of how to give
>> >> > the
>> >> > proc
>> >> > 3 parameters, producing three resultsets in a way that RS will
>> >> > display
>> >> > them?
>> >> > Or, am I giving it three parameters and calling it three times? If
>> >> > so,
>> >> > how
>> >> > would i call the 3 procs in RS?
>> >> > -- Lynn
>> >> >
>> >> >
>> >> > "Bruce L-C [MVP]" wrote:
>> >> >
>> >> >> Configure your existing stored procedure to accept a parameter (you
>> >> >> can
>> >> >> make
>> >> >> it optional so that it doesn't break existing code).
>> >> >>
>> >> >> Then call it three times in RS with a static value and create three
>> >> >> datasets.
>> >> >> For instance dataset1
>> >> >> yourproc 1
>> >> >>
>> >> >> Dataset2
>> >> >> yourproc 2
>> >> >>
>> >> >> etc.
>> >> >>
>> >> >> Then in your stored procedure return the appropriate resultset
>> >> >> based
>> >> >> on
>> >> >> the
>> >> >> parameter.
>> >> >>
>> >> >> Downside is that your sp is being run three times.
>> >> >>
>> >> >>
>> >> >> --
>> >> >> Bruce Loehle-Conger
>> >> >> MVP SQL Server Reporting Services
>> >> >>
>> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> >> >> news:E8E34B6C-A36A-4576-BE8C-AB61866EEC80@.microsoft.com...
>> >> >> > Bruce, I'm not sure I follow. Can you elaborate a little more,
>> >> >> > please,
>> >> >> > on
>> >> >> > the second, possibly third procedure?
>> >> >> > -- Lynn
>> >> >> >
>> >> >> >
>> >> >> > "Bruce L-C [MVP]" wrote:
>> >> >> >
>> >> >> >> This is three resultsets. RS does not have the ability to handle
>> >> >> >> that.
>> >> >> >> There
>> >> >> >> is no work around from RS side. You could create another stored
>> >> >> >> procedure
>> >> >> >> that calls this one and have it return just one of the
>> >> >> >> resultsets.
>> >> >> >>
>> >> >> >> RS can deal with multiple datasets quite well, but each stored
>> >> >> >> procedure
>> >> >> >> call can only return one.
>> >> >> >>
>> >> >> >>
>> >> >> >> --
>> >> >> >> Bruce Loehle-Conger
>> >> >> >> MVP SQL Server Reporting Services
>> >> >> >>
>> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> >> >> >> news:E1AFA910-1FF4-4DC8-A3F0-FC1EADE8DFD5@.microsoft.com...
>> >> >> >> > oh, bruce, that is great. I can't believe it was as simple as
>> >> >> >> > that.
>> >> >> >> > one
>> >> >> >> > remaining problem, though. one of my reports is like this:
>> >> >> >> >
>> >> >> >> > Date Total Trades Symbols Traded Total $
>> >> >> >> > -- -- -- --
>> >> >> >> > 02/07/2006 333,333 333
>> >> >> >> > 33,333,333,333.33
>> >> >> >> >
>> >> >> >> > #Stocks Volume Total $
>> >> >> >> > -- -- --
>> >> >> >> > 333,333 33,333,333 3,333,333,333.33
>> >> >> >> >
>> >> >> >> > EndPoint Liquidity #Trades Volume Total $
>> >> >> >> > -- -- -- -- --
>> >> >> >> > AAAA Add 114,729 21,797,575
>> >> >> >> > 583,102,631.33
>> >> >> >> > AAAA Opening 1 27
>> >> >> >> > 3,412.53
>> >> >> >> > AAAA Remove 30,836 8,330,843
>> >> >> >> > 444,521,928.10
>> >> >> >> > AAAA Route 41 4,543
>> >> >> >> > 103,291.31
>> >> >> >> > BBBB Add 26,997 9,940,201
>> >> >> >> > 178,600,674.78
>> >> >> >> > BBBB Opening 8,089 1,448,143
>> >> >> >> > 44,276,419.41
>> >> >> >> > BBBB Remove 3,406 1,719,403
>> >> >> >> > 40,267,318.25
>> >> >> >> > CCCC Add 83,781 22,443,732
>> >> >> >> > 746,570,071.43
>> >> >> >> > CCCC Remove 35,756 12,250,359
>> >> >> >> > 483,329,796.97
>> >> >> >> > CCCC Route 1,088 244,697
>> >> >> >> > 6,655,913.26
>> >> >> >> > DDDD Route 2 62,500
>> >> >> >> > 2,539,375.00
>> >> >> >> > DDDD Add 2,354 1,262,589
>> >> >> >> > 19,136,233.44
>> >> >> >> > DDDD Remove 258 195,019
>> >> >> >> > 6,227,451.69
>> >> >> >> >
>> >> >> >> > I only receive the top line in the resultset:
>> >> >> >> >
>> >> >> >> > Date Total Trades Symbols Traded Total $
>> >> >> >> > -- -- -- --
>> >> >> >> > 02/07/2006 333,333 333
>> >> >> >> > 33,333,333,333.33
>> >> >> >> >
>> >> >> >> > I assume this is what you mean when you say it will only
>> >> >> >> > handle
>> >> >> >> > the
>> >> >> >> > 1st
>> >> >> >> > resultset. All of my reports have multiple 'chunks' in the
>> >> >> >> > body.
>> >> >> >> > Do
>> >> >> >> > you
>> >> >> >> > have any idea how I can achieve this report via reporting
>> >> >> >> > svcs?
>> >> >> >> > Unfortunately, this is very important. Please do advise.
>> >> >> >> >
>> >> >> >> > --Lynn
>> >> >> >> >
>> >> >> >> >
>> >> >> >> > "Bruce L-C [MVP]" wrote:
>> >> >> >> >
>> >> >> >> >> Pick the command type as stored procedure and then just enter
>> >> >> >> >> the
>> >> >> >> >> name
>> >> >> >> >> of
>> >> >> >> >> the stored procedure. When you click on the ! you should get
>> >> >> >> >> back
>> >> >> >> >> the
>> >> >> >> >> data
>> >> >> >> >> and the fields. If you do not get the field list populated
>> >> >> >> >> then
>> >> >> >> >> click
>> >> >> >> >> on
>> >> >> >> >> the
>> >> >> >> >> refresh fields button (to the right of the ..., it looks like
>> >> >> >> >> the
>> >> >> >> >> refresh
>> >> >> >> >> button for IE).
>> >> >> >> >>
>> >> >> >> >> Note that RS only works with the first resultset returned. It
>> >> >> >> >> cannot
>> >> >> >> >> handle
>> >> >> >> >> mutliple resultsets.
>> >> >> >> >>
>> >> >> >> >>
>> >> >> >> >> --
>> >> >> >> >> Bruce Loehle-Conger
>> >> >> >> >> MVP SQL Server Reporting Services
>> >> >> >> >>
>> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> >> >> >> >> news:EF6A6CBC-083B-4537-83D9-D763A8ABA056@.microsoft.com...
>> >> >> >> >> > Hi. I have a need to create a number of different reports
>> >> >> >> >> > via
>> >> >> >> >> > Reporting
>> >> >> >> >> > Services. All of which are based on stored procedures,
>> >> >> >> >> > none
>> >> >> >> >> > of
>> >> >> >> >> > which
>> >> >> >> >> > require
>> >> >> >> >> > any parameters. Most if not all of the report is
>> >> >> >> >> > calculated.
>> >> >> >> >> > I
>> >> >> >> >> > am
>> >> >> >> >> > struggling badly to get even the most basic of the fields
>> >> >> >> >> > in
>> >> >> >> >> > place
>> >> >> >> >> > w/the
>> >> >> >> >> > correct expressions. The only one I actually got to accept
>> >> >> >> >> > the
>> >> >> >> >> > expression
>> >> >> >> >> > was a Date field, this is the calculation:
>> >> >> >> >> >
>> >> >> >> >> > =SELECT CONVERT(char(10),dateadd(dd,-0,GetDate()),1)
>> >> >> >> >> >
>> >> >> >> >> > It, too, fails to preview, indicating the value expression
>> >> >> >> >> > for
>> >> >> >> >> > the
>> >> >> >> >> > field
>> >> >> >> >> > contains an error. Again, all of the other report items
>> >> >> >> >> > are
>> >> >> >> >> > calculated
>> >> >> >> >> > fields. SUMs, totals, money formats, CASE statements,
>> >> >> >> >> > CASTs,
>> >> >> >> >> > etc.
>> >> >> >> >> > Using
>> >> >> >> >> > the
>> >> >> >> >> > report designer/report wizard to 'do it for me' only
>> >> >> >> >> > returns
>> >> >> >> >> > Date
>> >> >> >> >> > and a
>> >> >> >> >> > couple fields that are not even in my resultset. like one
>> >> >> >> >> > of
>> >> >> >> >> > my
>> >> >> >> >> > values
>> >> >> >> >> > in
>> >> >> >> >> > the report is 'Total Trades'...one of the fields listed as
>> >> >> >> >> > available
>> >> >> >> >> > is
>> >> >> >> >> > 'ID__Total__'
>> >> >> >> >> >
>> >> >> >> >> > Further, in VS I've got the report open and am on the data
>> >> >> >> >> > tab, i
>> >> >> >> >> > hit
>> >> >> >> >> > the
>> >> >> >> >> > Run option, I receive this error: An error occurred while
>> >> >> >> >> > retrieving
>> >> >> >> >> > the
>> >> >> >> >> > parameters in the query. Could not locate entry in
>> >> >> >> >> > sysdatabases
>> >> >> >> >> > for
>> >> >> >> >> > database
>> >> >> >> >> > 'EXEC databasename'. No entry found with that name. Make
>> >> >> >> >> > sure
>> >> >> >> >> > that
>> >> >> >> >> > the
>> >> >> >> >> > name
>> >> >> >> >> > is entered correctly.'
>> >> >> >> >> >
>> >> >> >> >> > Clearly I am doing something very wrong with the stored
>> >> >> >> >> > procedure
>> >> >> >> >> > definition. Like I said, all of these reports are based on
>> >> >> >> >> > procedures,
>> >> >> >> >> > can
>> >> >> >> >> > anybody give me some suggestion/direction on the right way
>> >> >> >> >> > to
>> >> >> >> >> > call
>> >> >> >> >> > the
>> >> >> >> >> > procs?
>> >> >> >> >> > They run w/out parameters...EXEC databasename.dbo.proc
>> >> >> >> >> > that's
>> >> >> >> >> > it.
>> >> >> >> >> > Please advise.
>> >> >> >> >> >
>> >> >> >> >> >
>> >> >> >> >> > -- Lynn
>> >> >> >> >>
>> >> >> >> >>
>> >> >> >> >>
>> >> >> >>
>> >> >> >>
>> >> >> >>
>> >> >>
>> >> >>
>> >> >>
>> >>
>> >>
>> >>
>>|||yes, it's sql2k, i am somewhat of a RS newbie, but I spent last week setting
reports up for all my sql jobs, just to kind of practice in the RS arena.
everything went flawlessly. i even set up one of the company reports just
fine, but it was a proc with only a single resultset. everything else is
multiple resultsets, i'm just having a very difficult time. but, i will give
this a shot, bruce. thank you, bruce
-- Lynn
"Bruce L-C [MVP]" wrote:
> Are you going against SQL Server?
> If so, then just select tored procedure for the command type and just put in
> the name of the stored procedure. Do not put exec in from of it or anything
> else. It should detect the parameter and prompt you for it. It should also
> create a report parameter as well for you.
> Try creating a new dataset and do this from the start. If you continue to
> have problems create a new stored procedure just for testing .
> create procedure dbo.testproc
> @.PARAM1 int
> as
> select 'Parameter passed in = ' + @.PARAM1 as Message
> return
> Get the above procedure to work for you so you know how to call a stored
> procedure they way I am telling you (do not use exec).
>
> --
> Bruce Loehle-Conger
> MVP SQL Server Reporting Services
> --
> Bruce Loehle-Conger
> MVP SQL Server Reporting Services
> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> news:9B089D7B-1F23-465B-B443-08BD09469A3E@.microsoft.com...
> > i'm sorry, bruce, but where do i define the parameters? rs is not
> > detecting
> > them. in my 1st dataset i've got cmd type stored procedure and the proc
> > name
> > is in the query string. i assumed i would put the 1st parameter in on the
> > parameters tab and then do the same for 2, 3 and 4 on 3 other datasets, so
> > i
> > gave it @.ch and the value of 1, but when i attempted to run it, it threw
> > me a
> > 'define query parameters box asking me to put the '1' in it.
> > -- Lynn
> >
> >
> > "Bruce L-C [MVP]" wrote:
> >
> >> If you are going against SQL Server do not run your stored procedure this
> >> way. Pick command type of stored procedure. RS will detect the
> >> parameters.
> >> If going against ODBC or OLEDB driver (which uses ? format for
> >> parameters)
> >> then pick text as the command type and do this:
> >> myproc ?
> >>
> >> Create multiple datasets and for each one you should call the stored
> >> procedure for each one.
> >>
> >> Bruce Loehle-Conger
> >>
> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> news:79CA374D-729B-4181-8F45-5D61FCF30F28@.microsoft.com...
> >> > And, if I blow away the 2nd dataset and just give my 1st one
> >> > parameters,
> >> > it
> >> > almost works. EXEC db.dbo.procname 1 for chunk one of the results,
> >> > works
> >> > just fine. if i change the parameter to 2, 3 or 4, when I hit RUN in
> >> > Data
> >> > tab it returns an error: SQL Syntax Errors Encountered...The designer
> >> > does
> >> > not graphically support the EXEC SQL Construct' but, i hit 'OK' and
> >> > my
> >> > results are still returned to me. On 'Preview' tab, however, I get no
> >> > data/results at all.
> >> > -- Lynn
> >> >
> >> >
> >> > "Bruce L-C [MVP]" wrote:
> >> >
> >> >> Yes, you are calling it three times. In RS you create three datasets.
> >> >> Go
> >> >> to
> >> >> the dataset tab and there is a combo box with the name of the dataset,
> >> >> you
> >> >> can click on that and there is a an option for a new.
> >> >>
> >> >> In your stored procedure
> >> >>
> >> >> if @.WHICHRESULTSET = 1
> >> >> begin
> >> >> --return the first resultset here
> >> >> end
> >> >> etc
> >> >>
> >> >>
> >> >> --
> >> >> Bruce Loehle-Conger
> >> >> MVP SQL Server Reporting Services
> >> >>
> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> news:81E3A442-6694-442D-B151-F083E4750ADB@.microsoft.com...
> >> >> > Bruce, or somebody else, might you give me an example of how to give
> >> >> > the
> >> >> > proc
> >> >> > 3 parameters, producing three resultsets in a way that RS will
> >> >> > display
> >> >> > them?
> >> >> > Or, am I giving it three parameters and calling it three times? If
> >> >> > so,
> >> >> > how
> >> >> > would i call the 3 procs in RS?
> >> >> > -- Lynn
> >> >> >
> >> >> >
> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >
> >> >> >> Configure your existing stored procedure to accept a parameter (you
> >> >> >> can
> >> >> >> make
> >> >> >> it optional so that it doesn't break existing code).
> >> >> >>
> >> >> >> Then call it three times in RS with a static value and create three
> >> >> >> datasets.
> >> >> >> For instance dataset1
> >> >> >> yourproc 1
> >> >> >>
> >> >> >> Dataset2
> >> >> >> yourproc 2
> >> >> >>
> >> >> >> etc.
> >> >> >>
> >> >> >> Then in your stored procedure return the appropriate resultset
> >> >> >> based
> >> >> >> on
> >> >> >> the
> >> >> >> parameter.
> >> >> >>
> >> >> >> Downside is that your sp is being run three times.
> >> >> >>
> >> >> >>
> >> >> >> --
> >> >> >> Bruce Loehle-Conger
> >> >> >> MVP SQL Server Reporting Services
> >> >> >>
> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> news:E8E34B6C-A36A-4576-BE8C-AB61866EEC80@.microsoft.com...
> >> >> >> > Bruce, I'm not sure I follow. Can you elaborate a little more,
> >> >> >> > please,
> >> >> >> > on
> >> >> >> > the second, possibly third procedure?
> >> >> >> > -- Lynn
> >> >> >> >
> >> >> >> >
> >> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >> >
> >> >> >> >> This is three resultsets. RS does not have the ability to handle
> >> >> >> >> that.
> >> >> >> >> There
> >> >> >> >> is no work around from RS side. You could create another stored
> >> >> >> >> procedure
> >> >> >> >> that calls this one and have it return just one of the
> >> >> >> >> resultsets.
> >> >> >> >>
> >> >> >> >> RS can deal with multiple datasets quite well, but each stored
> >> >> >> >> procedure
> >> >> >> >> call can only return one.
> >> >> >> >>
> >> >> >> >>
> >> >> >> >> --
> >> >> >> >> Bruce Loehle-Conger
> >> >> >> >> MVP SQL Server Reporting Services
> >> >> >> >>
> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> >> news:E1AFA910-1FF4-4DC8-A3F0-FC1EADE8DFD5@.microsoft.com...
> >> >> >> >> > oh, bruce, that is great. I can't believe it was as simple as
> >> >> >> >> > that.
> >> >> >> >> > one
> >> >> >> >> > remaining problem, though. one of my reports is like this:
> >> >> >> >> >
> >> >> >> >> > Date Total Trades Symbols Traded Total $
> >> >> >> >> > -- -- -- --
> >> >> >> >> > 02/07/2006 333,333 333
> >> >> >> >> > 33,333,333,333.33
> >> >> >> >> >
> >> >> >> >> > #Stocks Volume Total $
> >> >> >> >> > -- -- --
> >> >> >> >> > 333,333 33,333,333 3,333,333,333.33
> >> >> >> >> >
> >> >> >> >> > EndPoint Liquidity #Trades Volume Total $
> >> >> >> >> > -- -- -- -- --
> >> >> >> >> > AAAA Add 114,729 21,797,575
> >> >> >> >> > 583,102,631.33
> >> >> >> >> > AAAA Opening 1 27
> >> >> >> >> > 3,412.53
> >> >> >> >> > AAAA Remove 30,836 8,330,843
> >> >> >> >> > 444,521,928.10
> >> >> >> >> > AAAA Route 41 4,543
> >> >> >> >> > 103,291.31
> >> >> >> >> > BBBB Add 26,997 9,940,201
> >> >> >> >> > 178,600,674.78
> >> >> >> >> > BBBB Opening 8,089 1,448,143
> >> >> >> >> > 44,276,419.41
> >> >> >> >> > BBBB Remove 3,406 1,719,403
> >> >> >> >> > 40,267,318.25
> >> >> >> >> > CCCC Add 83,781 22,443,732
> >> >> >> >> > 746,570,071.43
> >> >> >> >> > CCCC Remove 35,756 12,250,359
> >> >> >> >> > 483,329,796.97
> >> >> >> >> > CCCC Route 1,088 244,697
> >> >> >> >> > 6,655,913.26
> >> >> >> >> > DDDD Route 2 62,500
> >> >> >> >> > 2,539,375.00
> >> >> >> >> > DDDD Add 2,354 1,262,589
> >> >> >> >> > 19,136,233.44
> >> >> >> >> > DDDD Remove 258 195,019
> >> >> >> >> > 6,227,451.69
> >> >> >> >> >
> >> >> >> >> > I only receive the top line in the resultset:
> >> >> >> >> >
> >> >> >> >> > Date Total Trades Symbols Traded Total $
> >> >> >> >> > -- -- -- --
> >> >> >> >> > 02/07/2006 333,333 333
> >> >> >> >> > 33,333,333,333.33
> >> >> >> >> >
> >> >> >> >> > I assume this is what you mean when you say it will only
> >> >> >> >> > handle
> >> >> >> >> > the
> >> >> >> >> > 1st
> >> >> >> >> > resultset. All of my reports have multiple 'chunks' in the
> >> >> >> >> > body.
> >> >> >> >> > Do
> >> >> >> >> > you
> >> >> >> >> > have any idea how I can achieve this report via reporting
> >> >> >> >> > svcs?
> >> >> >> >> > Unfortunately, this is very important. Please do advise.
> >> >> >> >> >
> >> >> >> >> > --Lynn
> >> >> >> >> >
> >> >> >> >> >
> >> >> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >> >> >
> >> >> >> >> >> Pick the command type as stored procedure and then just enter
> >> >> >> >> >> the
> >> >> >> >> >> name
> >> >> >> >> >> of
> >> >> >> >> >> the stored procedure. When you click on the ! you should get
> >> >> >> >> >> back
> >> >> >> >> >> the
> >> >> >> >> >> data
> >> >> >> >> >> and the fields. If you do not get the field list populated
> >> >> >> >> >> then
> >> >> >> >> >> click
> >> >> >> >> >> on
> >> >> >> >> >> the
> >> >> >> >> >> refresh fields button (to the right of the ..., it looks like
> >> >> >> >> >> the
> >> >> >> >> >> refresh
> >> >> >> >> >> button for IE).
> >> >> >> >> >>
> >> >> >> >> >> Note that RS only works with the first resultset returned. It
> >> >> >> >> >> cannot
> >> >> >> >> >> handle
> >> >> >> >> >> mutliple resultsets.
> >> >> >> >> >>
> >> >> >> >> >>
> >> >> >> >> >> --
> >> >> >> >> >> Bruce Loehle-Conger
> >> >> >> >> >> MVP SQL Server Reporting Services
> >> >> >> >> >>
> >> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> >> >> news:EF6A6CBC-083B-4537-83D9-D763A8ABA056@.microsoft.com...
> >> >> >> >> >> > Hi. I have a need to create a number of different reports
> >> >> >> >> >> > via
> >> >> >> >> >> > Reporting
> >> >> >> >> >> > Services. All of which are based on stored procedures,
> >> >> >> >> >> > none
> >> >> >> >> >> > of
> >> >> >> >> >> > which
> >> >> >> >> >> > require
> >> >> >> >> >> > any parameters. Most if not all of the report is
> >> >> >> >> >> > calculated.
> >> >> >> >> >> > I
> >> >> >> >> >> > am
> >> >> >> >> >> > struggling badly to get even the most basic of the fields
> >> >> >> >> >> > in
> >> >> >> >> >> > place
> >> >> >> >> >> > w/the
> >> >> >> >> >> > correct expressions. The only one I actually got to accept
> >> >> >> >> >> > the
> >> >> >> >> >> > expression
> >> >> >> >> >> > was a Date field, this is the calculation:
> >> >> >> >> >> >
> >> >> >> >> >> > =SELECT CONVERT(char(10),dateadd(dd,-0,GetDate()),1)
> >> >> >> >> >> >
> >> >> >> >> >> > It, too, fails to preview, indicating the value expression
> >> >> >> >> >> > for
> >> >> >> >> >> > the
> >> >> >> >> >> > field
> >> >> >> >> >> > contains an error. Again, all of the other report items
> >> >> >> >> >> > are
> >> >> >> >> >> > calculated
> >> >> >> >> >> > fields. SUMs, totals, money formats, CASE statements,|||i am not sure how to display each resultset/dataset in the same report
-- Lynn
"Bruce L-C [MVP]" wrote:
> Are you going against SQL Server?
> If so, then just select tored procedure for the command type and just put in
> the name of the stored procedure. Do not put exec in from of it or anything
> else. It should detect the parameter and prompt you for it. It should also
> create a report parameter as well for you.
> Try creating a new dataset and do this from the start. If you continue to
> have problems create a new stored procedure just for testing .
> create procedure dbo.testproc
> @.PARAM1 int
> as
> select 'Parameter passed in = ' + @.PARAM1 as Message
> return
> Get the above procedure to work for you so you know how to call a stored
> procedure they way I am telling you (do not use exec).
>
> --
> Bruce Loehle-Conger
> MVP SQL Server Reporting Services
> --
> Bruce Loehle-Conger
> MVP SQL Server Reporting Services
> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> news:9B089D7B-1F23-465B-B443-08BD09469A3E@.microsoft.com...
> > i'm sorry, bruce, but where do i define the parameters? rs is not
> > detecting
> > them. in my 1st dataset i've got cmd type stored procedure and the proc
> > name
> > is in the query string. i assumed i would put the 1st parameter in on the
> > parameters tab and then do the same for 2, 3 and 4 on 3 other datasets, so
> > i
> > gave it @.ch and the value of 1, but when i attempted to run it, it threw
> > me a
> > 'define query parameters box asking me to put the '1' in it.
> > -- Lynn
> >
> >
> > "Bruce L-C [MVP]" wrote:
> >
> >> If you are going against SQL Server do not run your stored procedure this
> >> way. Pick command type of stored procedure. RS will detect the
> >> parameters.
> >> If going against ODBC or OLEDB driver (which uses ? format for
> >> parameters)
> >> then pick text as the command type and do this:
> >> myproc ?
> >>
> >> Create multiple datasets and for each one you should call the stored
> >> procedure for each one.
> >>
> >> Bruce Loehle-Conger
> >>
> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> news:79CA374D-729B-4181-8F45-5D61FCF30F28@.microsoft.com...
> >> > And, if I blow away the 2nd dataset and just give my 1st one
> >> > parameters,
> >> > it
> >> > almost works. EXEC db.dbo.procname 1 for chunk one of the results,
> >> > works
> >> > just fine. if i change the parameter to 2, 3 or 4, when I hit RUN in
> >> > Data
> >> > tab it returns an error: SQL Syntax Errors Encountered...The designer
> >> > does
> >> > not graphically support the EXEC SQL Construct' but, i hit 'OK' and
> >> > my
> >> > results are still returned to me. On 'Preview' tab, however, I get no
> >> > data/results at all.
> >> > -- Lynn
> >> >
> >> >
> >> > "Bruce L-C [MVP]" wrote:
> >> >
> >> >> Yes, you are calling it three times. In RS you create three datasets.
> >> >> Go
> >> >> to
> >> >> the dataset tab and there is a combo box with the name of the dataset,
> >> >> you
> >> >> can click on that and there is a an option for a new.
> >> >>
> >> >> In your stored procedure
> >> >>
> >> >> if @.WHICHRESULTSET = 1
> >> >> begin
> >> >> --return the first resultset here
> >> >> end
> >> >> etc
> >> >>
> >> >>
> >> >> --
> >> >> Bruce Loehle-Conger
> >> >> MVP SQL Server Reporting Services
> >> >>
> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> news:81E3A442-6694-442D-B151-F083E4750ADB@.microsoft.com...
> >> >> > Bruce, or somebody else, might you give me an example of how to give
> >> >> > the
> >> >> > proc
> >> >> > 3 parameters, producing three resultsets in a way that RS will
> >> >> > display
> >> >> > them?
> >> >> > Or, am I giving it three parameters and calling it three times? If
> >> >> > so,
> >> >> > how
> >> >> > would i call the 3 procs in RS?
> >> >> > -- Lynn
> >> >> >
> >> >> >
> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >
> >> >> >> Configure your existing stored procedure to accept a parameter (you
> >> >> >> can
> >> >> >> make
> >> >> >> it optional so that it doesn't break existing code).
> >> >> >>
> >> >> >> Then call it three times in RS with a static value and create three
> >> >> >> datasets.
> >> >> >> For instance dataset1
> >> >> >> yourproc 1
> >> >> >>
> >> >> >> Dataset2
> >> >> >> yourproc 2
> >> >> >>
> >> >> >> etc.
> >> >> >>
> >> >> >> Then in your stored procedure return the appropriate resultset
> >> >> >> based
> >> >> >> on
> >> >> >> the
> >> >> >> parameter.
> >> >> >>
> >> >> >> Downside is that your sp is being run three times.
> >> >> >>
> >> >> >>
> >> >> >> --
> >> >> >> Bruce Loehle-Conger
> >> >> >> MVP SQL Server Reporting Services
> >> >> >>
> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> news:E8E34B6C-A36A-4576-BE8C-AB61866EEC80@.microsoft.com...
> >> >> >> > Bruce, I'm not sure I follow. Can you elaborate a little more,
> >> >> >> > please,
> >> >> >> > on
> >> >> >> > the second, possibly third procedure?
> >> >> >> > -- Lynn
> >> >> >> >
> >> >> >> >
> >> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >> >
> >> >> >> >> This is three resultsets. RS does not have the ability to handle
> >> >> >> >> that.
> >> >> >> >> There
> >> >> >> >> is no work around from RS side. You could create another stored
> >> >> >> >> procedure
> >> >> >> >> that calls this one and have it return just one of the
> >> >> >> >> resultsets.
> >> >> >> >>
> >> >> >> >> RS can deal with multiple datasets quite well, but each stored
> >> >> >> >> procedure
> >> >> >> >> call can only return one.
> >> >> >> >>
> >> >> >> >>
> >> >> >> >> --
> >> >> >> >> Bruce Loehle-Conger
> >> >> >> >> MVP SQL Server Reporting Services
> >> >> >> >>
> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> >> news:E1AFA910-1FF4-4DC8-A3F0-FC1EADE8DFD5@.microsoft.com...
> >> >> >> >> > oh, bruce, that is great. I can't believe it was as simple as
> >> >> >> >> > that.
> >> >> >> >> > one
> >> >> >> >> > remaining problem, though. one of my reports is like this:
> >> >> >> >> >
> >> >> >> >> > Date Total Trades Symbols Traded Total $
> >> >> >> >> > -- -- -- --
> >> >> >> >> > 02/07/2006 333,333 333
> >> >> >> >> > 33,333,333,333.33
> >> >> >> >> >
> >> >> >> >> > #Stocks Volume Total $
> >> >> >> >> > -- -- --
> >> >> >> >> > 333,333 33,333,333 3,333,333,333.33
> >> >> >> >> >
> >> >> >> >> > EndPoint Liquidity #Trades Volume Total $
> >> >> >> >> > -- -- -- -- --
> >> >> >> >> > AAAA Add 114,729 21,797,575
> >> >> >> >> > 583,102,631.33
> >> >> >> >> > AAAA Opening 1 27
> >> >> >> >> > 3,412.53
> >> >> >> >> > AAAA Remove 30,836 8,330,843
> >> >> >> >> > 444,521,928.10
> >> >> >> >> > AAAA Route 41 4,543
> >> >> >> >> > 103,291.31
> >> >> >> >> > BBBB Add 26,997 9,940,201
> >> >> >> >> > 178,600,674.78
> >> >> >> >> > BBBB Opening 8,089 1,448,143
> >> >> >> >> > 44,276,419.41
> >> >> >> >> > BBBB Remove 3,406 1,719,403
> >> >> >> >> > 40,267,318.25
> >> >> >> >> > CCCC Add 83,781 22,443,732
> >> >> >> >> > 746,570,071.43
> >> >> >> >> > CCCC Remove 35,756 12,250,359
> >> >> >> >> > 483,329,796.97
> >> >> >> >> > CCCC Route 1,088 244,697
> >> >> >> >> > 6,655,913.26
> >> >> >> >> > DDDD Route 2 62,500
> >> >> >> >> > 2,539,375.00
> >> >> >> >> > DDDD Add 2,354 1,262,589
> >> >> >> >> > 19,136,233.44
> >> >> >> >> > DDDD Remove 258 195,019
> >> >> >> >> > 6,227,451.69
> >> >> >> >> >
> >> >> >> >> > I only receive the top line in the resultset:
> >> >> >> >> >
> >> >> >> >> > Date Total Trades Symbols Traded Total $
> >> >> >> >> > -- -- -- --
> >> >> >> >> > 02/07/2006 333,333 333
> >> >> >> >> > 33,333,333,333.33
> >> >> >> >> >
> >> >> >> >> > I assume this is what you mean when you say it will only
> >> >> >> >> > handle
> >> >> >> >> > the
> >> >> >> >> > 1st
> >> >> >> >> > resultset. All of my reports have multiple 'chunks' in the
> >> >> >> >> > body.
> >> >> >> >> > Do
> >> >> >> >> > you
> >> >> >> >> > have any idea how I can achieve this report via reporting
> >> >> >> >> > svcs?
> >> >> >> >> > Unfortunately, this is very important. Please do advise.
> >> >> >> >> >
> >> >> >> >> > --Lynn
> >> >> >> >> >
> >> >> >> >> >
> >> >> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >> >> >
> >> >> >> >> >> Pick the command type as stored procedure and then just enter
> >> >> >> >> >> the
> >> >> >> >> >> name
> >> >> >> >> >> of
> >> >> >> >> >> the stored procedure. When you click on the ! you should get
> >> >> >> >> >> back
> >> >> >> >> >> the
> >> >> >> >> >> data
> >> >> >> >> >> and the fields. If you do not get the field list populated
> >> >> >> >> >> then
> >> >> >> >> >> click
> >> >> >> >> >> on
> >> >> >> >> >> the
> >> >> >> >> >> refresh fields button (to the right of the ..., it looks like
> >> >> >> >> >> the
> >> >> >> >> >> refresh
> >> >> >> >> >> button for IE).
> >> >> >> >> >>
> >> >> >> >> >> Note that RS only works with the first resultset returned. It
> >> >> >> >> >> cannot
> >> >> >> >> >> handle
> >> >> >> >> >> mutliple resultsets.
> >> >> >> >> >>
> >> >> >> >> >>
> >> >> >> >> >> --
> >> >> >> >> >> Bruce Loehle-Conger
> >> >> >> >> >> MVP SQL Server Reporting Services
> >> >> >> >> >>
> >> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> >> >> news:EF6A6CBC-083B-4537-83D9-D763A8ABA056@.microsoft.com...
> >> >> >> >> >> > Hi. I have a need to create a number of different reports
> >> >> >> >> >> > via
> >> >> >> >> >> > Reporting
> >> >> >> >> >> > Services. All of which are based on stored procedures,
> >> >> >> >> >> > none
> >> >> >> >> >> > of
> >> >> >> >> >> > which
> >> >> >> >> >> > require
> >> >> >> >> >> > any parameters. Most if not all of the report is
> >> >> >> >> >> > calculated.
> >> >> >> >> >> > I
> >> >> >> >> >> > am
> >> >> >> >> >> > struggling badly to get even the most basic of the fields
> >> >> >> >> >> > in
> >> >> >> >> >> > place
> >> >> >> >> >> > w/the
> >> >> >> >> >> > correct expressions. The only one I actually got to accept
> >> >> >> >> >> > the
> >> >> >> >> >> > expression
> >> >> >> >> >> > was a Date field, this is the calculation:
> >> >> >> >> >> >
> >> >> >> >> >> > =SELECT CONVERT(char(10),dateadd(dd,-0,GetDate()),1)
> >> >> >> >> >> >
> >> >> >> >> >> > It, too, fails to preview, indicating the value expression
> >> >> >> >> >> > for
> >> >> >> >> >> > the
> >> >> >> >> >> > field
> >> >> >> >> >> > contains an error. Again, all of the other report items
> >> >> >> >> >> > are
> >> >> >> >> >> > calculated
> >> >> >> >> >> > fields. SUMs, totals, money formats, CASE statements,|||removing everything but the proc name in the query string in dataset fails
w/this:
Could not generate a list of fields for the query.
Check the query syntax or click Refresh Fields on the query toolbar.
Line 1: Incorrect syntax near 'usp_procname'.
-- Lynn
"Bruce L-C [MVP]" wrote:
> Are you going against SQL Server?
> If so, then just select tored procedure for the command type and just put in
> the name of the stored procedure. Do not put exec in from of it or anything
> else. It should detect the parameter and prompt you for it. It should also
> create a report parameter as well for you.
> Try creating a new dataset and do this from the start. If you continue to
> have problems create a new stored procedure just for testing .
> create procedure dbo.testproc
> @.PARAM1 int
> as
> select 'Parameter passed in = ' + @.PARAM1 as Message
> return
> Get the above procedure to work for you so you know how to call a stored
> procedure they way I am telling you (do not use exec).
>
> --
> Bruce Loehle-Conger
> MVP SQL Server Reporting Services
> --
> Bruce Loehle-Conger
> MVP SQL Server Reporting Services
> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> news:9B089D7B-1F23-465B-B443-08BD09469A3E@.microsoft.com...
> > i'm sorry, bruce, but where do i define the parameters? rs is not
> > detecting
> > them. in my 1st dataset i've got cmd type stored procedure and the proc
> > name
> > is in the query string. i assumed i would put the 1st parameter in on the
> > parameters tab and then do the same for 2, 3 and 4 on 3 other datasets, so
> > i
> > gave it @.ch and the value of 1, but when i attempted to run it, it threw
> > me a
> > 'define query parameters box asking me to put the '1' in it.
> > -- Lynn
> >
> >
> > "Bruce L-C [MVP]" wrote:
> >
> >> If you are going against SQL Server do not run your stored procedure this
> >> way. Pick command type of stored procedure. RS will detect the
> >> parameters.
> >> If going against ODBC or OLEDB driver (which uses ? format for
> >> parameters)
> >> then pick text as the command type and do this:
> >> myproc ?
> >>
> >> Create multiple datasets and for each one you should call the stored
> >> procedure for each one.
> >>
> >> Bruce Loehle-Conger
> >>
> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> news:79CA374D-729B-4181-8F45-5D61FCF30F28@.microsoft.com...
> >> > And, if I blow away the 2nd dataset and just give my 1st one
> >> > parameters,
> >> > it
> >> > almost works. EXEC db.dbo.procname 1 for chunk one of the results,
> >> > works
> >> > just fine. if i change the parameter to 2, 3 or 4, when I hit RUN in
> >> > Data
> >> > tab it returns an error: SQL Syntax Errors Encountered...The designer
> >> > does
> >> > not graphically support the EXEC SQL Construct' but, i hit 'OK' and
> >> > my
> >> > results are still returned to me. On 'Preview' tab, however, I get no
> >> > data/results at all.
> >> > -- Lynn
> >> >
> >> >
> >> > "Bruce L-C [MVP]" wrote:
> >> >
> >> >> Yes, you are calling it three times. In RS you create three datasets.
> >> >> Go
> >> >> to
> >> >> the dataset tab and there is a combo box with the name of the dataset,
> >> >> you
> >> >> can click on that and there is a an option for a new.
> >> >>
> >> >> In your stored procedure
> >> >>
> >> >> if @.WHICHRESULTSET = 1
> >> >> begin
> >> >> --return the first resultset here
> >> >> end
> >> >> etc
> >> >>
> >> >>
> >> >> --
> >> >> Bruce Loehle-Conger
> >> >> MVP SQL Server Reporting Services
> >> >>
> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> news:81E3A442-6694-442D-B151-F083E4750ADB@.microsoft.com...
> >> >> > Bruce, or somebody else, might you give me an example of how to give
> >> >> > the
> >> >> > proc
> >> >> > 3 parameters, producing three resultsets in a way that RS will
> >> >> > display
> >> >> > them?
> >> >> > Or, am I giving it three parameters and calling it three times? If
> >> >> > so,
> >> >> > how
> >> >> > would i call the 3 procs in RS?
> >> >> > -- Lynn
> >> >> >
> >> >> >
> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >
> >> >> >> Configure your existing stored procedure to accept a parameter (you
> >> >> >> can
> >> >> >> make
> >> >> >> it optional so that it doesn't break existing code).
> >> >> >>
> >> >> >> Then call it three times in RS with a static value and create three
> >> >> >> datasets.
> >> >> >> For instance dataset1
> >> >> >> yourproc 1
> >> >> >>
> >> >> >> Dataset2
> >> >> >> yourproc 2
> >> >> >>
> >> >> >> etc.
> >> >> >>
> >> >> >> Then in your stored procedure return the appropriate resultset
> >> >> >> based
> >> >> >> on
> >> >> >> the
> >> >> >> parameter.
> >> >> >>
> >> >> >> Downside is that your sp is being run three times.
> >> >> >>
> >> >> >>
> >> >> >> --
> >> >> >> Bruce Loehle-Conger
> >> >> >> MVP SQL Server Reporting Services
> >> >> >>
> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> news:E8E34B6C-A36A-4576-BE8C-AB61866EEC80@.microsoft.com...
> >> >> >> > Bruce, I'm not sure I follow. Can you elaborate a little more,
> >> >> >> > please,
> >> >> >> > on
> >> >> >> > the second, possibly third procedure?
> >> >> >> > -- Lynn
> >> >> >> >
> >> >> >> >
> >> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >> >
> >> >> >> >> This is three resultsets. RS does not have the ability to handle
> >> >> >> >> that.
> >> >> >> >> There
> >> >> >> >> is no work around from RS side. You could create another stored
> >> >> >> >> procedure
> >> >> >> >> that calls this one and have it return just one of the
> >> >> >> >> resultsets.
> >> >> >> >>
> >> >> >> >> RS can deal with multiple datasets quite well, but each stored
> >> >> >> >> procedure
> >> >> >> >> call can only return one.
> >> >> >> >>
> >> >> >> >>
> >> >> >> >> --
> >> >> >> >> Bruce Loehle-Conger
> >> >> >> >> MVP SQL Server Reporting Services
> >> >> >> >>
> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> >> news:E1AFA910-1FF4-4DC8-A3F0-FC1EADE8DFD5@.microsoft.com...
> >> >> >> >> > oh, bruce, that is great. I can't believe it was as simple as
> >> >> >> >> > that.
> >> >> >> >> > one
> >> >> >> >> > remaining problem, though. one of my reports is like this:
> >> >> >> >> >
> >> >> >> >> > Date Total Trades Symbols Traded Total $
> >> >> >> >> > -- -- -- --
> >> >> >> >> > 02/07/2006 333,333 333
> >> >> >> >> > 33,333,333,333.33
> >> >> >> >> >
> >> >> >> >> > #Stocks Volume Total $
> >> >> >> >> > -- -- --
> >> >> >> >> > 333,333 33,333,333 3,333,333,333.33
> >> >> >> >> >
> >> >> >> >> > EndPoint Liquidity #Trades Volume Total $
> >> >> >> >> > -- -- -- -- --
> >> >> >> >> > AAAA Add 114,729 21,797,575
> >> >> >> >> > 583,102,631.33
> >> >> >> >> > AAAA Opening 1 27
> >> >> >> >> > 3,412.53
> >> >> >> >> > AAAA Remove 30,836 8,330,843
> >> >> >> >> > 444,521,928.10
> >> >> >> >> > AAAA Route 41 4,543
> >> >> >> >> > 103,291.31
> >> >> >> >> > BBBB Add 26,997 9,940,201
> >> >> >> >> > 178,600,674.78
> >> >> >> >> > BBBB Opening 8,089 1,448,143
> >> >> >> >> > 44,276,419.41
> >> >> >> >> > BBBB Remove 3,406 1,719,403
> >> >> >> >> > 40,267,318.25
> >> >> >> >> > CCCC Add 83,781 22,443,732
> >> >> >> >> > 746,570,071.43
> >> >> >> >> > CCCC Remove 35,756 12,250,359
> >> >> >> >> > 483,329,796.97
> >> >> >> >> > CCCC Route 1,088 244,697
> >> >> >> >> > 6,655,913.26
> >> >> >> >> > DDDD Route 2 62,500
> >> >> >> >> > 2,539,375.00
> >> >> >> >> > DDDD Add 2,354 1,262,589
> >> >> >> >> > 19,136,233.44
> >> >> >> >> > DDDD Remove 258 195,019
> >> >> >> >> > 6,227,451.69
> >> >> >> >> >
> >> >> >> >> > I only receive the top line in the resultset:
> >> >> >> >> >
> >> >> >> >> > Date Total Trades Symbols Traded Total $
> >> >> >> >> > -- -- -- --
> >> >> >> >> > 02/07/2006 333,333 333
> >> >> >> >> > 33,333,333,333.33
> >> >> >> >> >
> >> >> >> >> > I assume this is what you mean when you say it will only
> >> >> >> >> > handle
> >> >> >> >> > the
> >> >> >> >> > 1st
> >> >> >> >> > resultset. All of my reports have multiple 'chunks' in the
> >> >> >> >> > body.
> >> >> >> >> > Do
> >> >> >> >> > you
> >> >> >> >> > have any idea how I can achieve this report via reporting
> >> >> >> >> > svcs?
> >> >> >> >> > Unfortunately, this is very important. Please do advise.
> >> >> >> >> >
> >> >> >> >> > --Lynn
> >> >> >> >> >
> >> >> >> >> >
> >> >> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >> >> >
> >> >> >> >> >> Pick the command type as stored procedure and then just enter
> >> >> >> >> >> the
> >> >> >> >> >> name
> >> >> >> >> >> of
> >> >> >> >> >> the stored procedure. When you click on the ! you should get
> >> >> >> >> >> back
> >> >> >> >> >> the
> >> >> >> >> >> data
> >> >> >> >> >> and the fields. If you do not get the field list populated
> >> >> >> >> >> then
> >> >> >> >> >> click
> >> >> >> >> >> on
> >> >> >> >> >> the
> >> >> >> >> >> refresh fields button (to the right of the ..., it looks like
> >> >> >> >> >> the
> >> >> >> >> >> refresh
> >> >> >> >> >> button for IE).
> >> >> >> >> >>
> >> >> >> >> >> Note that RS only works with the first resultset returned. It
> >> >> >> >> >> cannot
> >> >> >> >> >> handle
> >> >> >> >> >> mutliple resultsets.
> >> >> >> >> >>
> >> >> >> >> >>
> >> >> >> >> >> --
> >> >> >> >> >> Bruce Loehle-Conger
> >> >> >> >> >> MVP SQL Server Reporting Services
> >> >> >> >> >>
> >> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> >> >> news:EF6A6CBC-083B-4537-83D9-D763A8ABA056@.microsoft.com...
> >> >> >> >> >> > Hi. I have a need to create a number of different reports
> >> >> >> >> >> > via
> >> >> >> >> >> > Reporting
> >> >> >> >> >> > Services. All of which are based on stored procedures,
> >> >> >> >> >> > none
> >> >> >> >> >> > of
> >> >> >> >> >> > which
> >> >> >> >> >> > require
> >> >> >> >> >> > any parameters. Most if not all of the report is
> >> >> >> >> >> > calculated.
> >> >> >> >> >> > I
> >> >> >> >> >> > am
> >> >> >> >> >> > struggling badly to get even the most basic of the fields
> >> >> >> >> >> > in
> >> >> >> >> >> > place
> >> >> >> >> >> > w/the
> >> >> >> >> >> > correct expressions. The only one I actually got to accept
> >> >> >> >> >> > the
> >> >> >> >> >> > expression
> >> >> >> >> >> > was a Date field, this is the calculation:
> >> >> >> >> >> >
> >> >> >> >> >> > =SELECT CONVERT(char(10),dateadd(dd,-0,GetDate()),1)
> >> >> >> >> >> >
> >> >> >> >> >> > It, too, fails to preview, indicating the value expression
> >> >> >> >> >> > for
> >> >> >> >> >> > the
> >> >> >> >> >> > field
> >> >> >> >> >> > contains an error. Again, all of the other report items
> >> >> >> >> >> > are
> >> >> >> >> >> > calculated
> >> >> >> >> >> > fields. SUMs, totals, money formats, CASE statements,|||my bad, bruce, that was because i had text in cmd type. having changed it to
stored procedure, it pops up the 'define query parameters' box, asking me to
put something in. how do i pass those in dynamically?
-- Lynn
"Bruce L-C [MVP]" wrote:
> Are you going against SQL Server?
> If so, then just select tored procedure for the command type and just put in
> the name of the stored procedure. Do not put exec in from of it or anything
> else. It should detect the parameter and prompt you for it. It should also
> create a report parameter as well for you.
> Try creating a new dataset and do this from the start. If you continue to
> have problems create a new stored procedure just for testing .
> create procedure dbo.testproc
> @.PARAM1 int
> as
> select 'Parameter passed in = ' + @.PARAM1 as Message
> return
> Get the above procedure to work for you so you know how to call a stored
> procedure they way I am telling you (do not use exec).
>
> --
> Bruce Loehle-Conger
> MVP SQL Server Reporting Services
> --
> Bruce Loehle-Conger
> MVP SQL Server Reporting Services
> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> news:9B089D7B-1F23-465B-B443-08BD09469A3E@.microsoft.com...
> > i'm sorry, bruce, but where do i define the parameters? rs is not
> > detecting
> > them. in my 1st dataset i've got cmd type stored procedure and the proc
> > name
> > is in the query string. i assumed i would put the 1st parameter in on the
> > parameters tab and then do the same for 2, 3 and 4 on 3 other datasets, so
> > i
> > gave it @.ch and the value of 1, but when i attempted to run it, it threw
> > me a
> > 'define query parameters box asking me to put the '1' in it.
> > -- Lynn
> >
> >
> > "Bruce L-C [MVP]" wrote:
> >
> >> If you are going against SQL Server do not run your stored procedure this
> >> way. Pick command type of stored procedure. RS will detect the
> >> parameters.
> >> If going against ODBC or OLEDB driver (which uses ? format for
> >> parameters)
> >> then pick text as the command type and do this:
> >> myproc ?
> >>
> >> Create multiple datasets and for each one you should call the stored
> >> procedure for each one.
> >>
> >> Bruce Loehle-Conger
> >>
> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> news:79CA374D-729B-4181-8F45-5D61FCF30F28@.microsoft.com...
> >> > And, if I blow away the 2nd dataset and just give my 1st one
> >> > parameters,
> >> > it
> >> > almost works. EXEC db.dbo.procname 1 for chunk one of the results,
> >> > works
> >> > just fine. if i change the parameter to 2, 3 or 4, when I hit RUN in
> >> > Data
> >> > tab it returns an error: SQL Syntax Errors Encountered...The designer
> >> > does
> >> > not graphically support the EXEC SQL Construct' but, i hit 'OK' and
> >> > my
> >> > results are still returned to me. On 'Preview' tab, however, I get no
> >> > data/results at all.
> >> > -- Lynn
> >> >
> >> >
> >> > "Bruce L-C [MVP]" wrote:
> >> >
> >> >> Yes, you are calling it three times. In RS you create three datasets.
> >> >> Go
> >> >> to
> >> >> the dataset tab and there is a combo box with the name of the dataset,
> >> >> you
> >> >> can click on that and there is a an option for a new.
> >> >>
> >> >> In your stored procedure
> >> >>
> >> >> if @.WHICHRESULTSET = 1
> >> >> begin
> >> >> --return the first resultset here
> >> >> end
> >> >> etc
> >> >>
> >> >>
> >> >> --
> >> >> Bruce Loehle-Conger
> >> >> MVP SQL Server Reporting Services
> >> >>
> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> news:81E3A442-6694-442D-B151-F083E4750ADB@.microsoft.com...
> >> >> > Bruce, or somebody else, might you give me an example of how to give
> >> >> > the
> >> >> > proc
> >> >> > 3 parameters, producing three resultsets in a way that RS will
> >> >> > display
> >> >> > them?
> >> >> > Or, am I giving it three parameters and calling it three times? If
> >> >> > so,
> >> >> > how
> >> >> > would i call the 3 procs in RS?
> >> >> > -- Lynn
> >> >> >
> >> >> >
> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >
> >> >> >> Configure your existing stored procedure to accept a parameter (you
> >> >> >> can
> >> >> >> make
> >> >> >> it optional so that it doesn't break existing code).
> >> >> >>
> >> >> >> Then call it three times in RS with a static value and create three
> >> >> >> datasets.
> >> >> >> For instance dataset1
> >> >> >> yourproc 1
> >> >> >>
> >> >> >> Dataset2
> >> >> >> yourproc 2
> >> >> >>
> >> >> >> etc.
> >> >> >>
> >> >> >> Then in your stored procedure return the appropriate resultset
> >> >> >> based
> >> >> >> on
> >> >> >> the
> >> >> >> parameter.
> >> >> >>
> >> >> >> Downside is that your sp is being run three times.
> >> >> >>
> >> >> >>
> >> >> >> --
> >> >> >> Bruce Loehle-Conger
> >> >> >> MVP SQL Server Reporting Services
> >> >> >>
> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> news:E8E34B6C-A36A-4576-BE8C-AB61866EEC80@.microsoft.com...
> >> >> >> > Bruce, I'm not sure I follow. Can you elaborate a little more,
> >> >> >> > please,
> >> >> >> > on
> >> >> >> > the second, possibly third procedure?
> >> >> >> > -- Lynn
> >> >> >> >
> >> >> >> >
> >> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >> >
> >> >> >> >> This is three resultsets. RS does not have the ability to handle
> >> >> >> >> that.
> >> >> >> >> There
> >> >> >> >> is no work around from RS side. You could create another stored
> >> >> >> >> procedure
> >> >> >> >> that calls this one and have it return just one of the
> >> >> >> >> resultsets.
> >> >> >> >>
> >> >> >> >> RS can deal with multiple datasets quite well, but each stored
> >> >> >> >> procedure
> >> >> >> >> call can only return one.
> >> >> >> >>
> >> >> >> >>
> >> >> >> >> --
> >> >> >> >> Bruce Loehle-Conger
> >> >> >> >> MVP SQL Server Reporting Services
> >> >> >> >>
> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> >> news:E1AFA910-1FF4-4DC8-A3F0-FC1EADE8DFD5@.microsoft.com...
> >> >> >> >> > oh, bruce, that is great. I can't believe it was as simple as
> >> >> >> >> > that.
> >> >> >> >> > one
> >> >> >> >> > remaining problem, though. one of my reports is like this:
> >> >> >> >> >
> >> >> >> >> > Date Total Trades Symbols Traded Total $
> >> >> >> >> > -- -- -- --
> >> >> >> >> > 02/07/2006 333,333 333
> >> >> >> >> > 33,333,333,333.33
> >> >> >> >> >
> >> >> >> >> > #Stocks Volume Total $
> >> >> >> >> > -- -- --
> >> >> >> >> > 333,333 33,333,333 3,333,333,333.33
> >> >> >> >> >
> >> >> >> >> > EndPoint Liquidity #Trades Volume Total $
> >> >> >> >> > -- -- -- -- --
> >> >> >> >> > AAAA Add 114,729 21,797,575
> >> >> >> >> > 583,102,631.33
> >> >> >> >> > AAAA Opening 1 27
> >> >> >> >> > 3,412.53
> >> >> >> >> > AAAA Remove 30,836 8,330,843
> >> >> >> >> > 444,521,928.10
> >> >> >> >> > AAAA Route 41 4,543
> >> >> >> >> > 103,291.31
> >> >> >> >> > BBBB Add 26,997 9,940,201
> >> >> >> >> > 178,600,674.78
> >> >> >> >> > BBBB Opening 8,089 1,448,143
> >> >> >> >> > 44,276,419.41
> >> >> >> >> > BBBB Remove 3,406 1,719,403
> >> >> >> >> > 40,267,318.25
> >> >> >> >> > CCCC Add 83,781 22,443,732
> >> >> >> >> > 746,570,071.43
> >> >> >> >> > CCCC Remove 35,756 12,250,359
> >> >> >> >> > 483,329,796.97
> >> >> >> >> > CCCC Route 1,088 244,697
> >> >> >> >> > 6,655,913.26
> >> >> >> >> > DDDD Route 2 62,500
> >> >> >> >> > 2,539,375.00
> >> >> >> >> > DDDD Add 2,354 1,262,589
> >> >> >> >> > 19,136,233.44
> >> >> >> >> > DDDD Remove 258 195,019
> >> >> >> >> > 6,227,451.69
> >> >> >> >> >
> >> >> >> >> > I only receive the top line in the resultset:
> >> >> >> >> >
> >> >> >> >> > Date Total Trades Symbols Traded Total $
> >> >> >> >> > -- -- -- --
> >> >> >> >> > 02/07/2006 333,333 333
> >> >> >> >> > 33,333,333,333.33
> >> >> >> >> >
> >> >> >> >> > I assume this is what you mean when you say it will only
> >> >> >> >> > handle
> >> >> >> >> > the
> >> >> >> >> > 1st
> >> >> >> >> > resultset. All of my reports have multiple 'chunks' in the
> >> >> >> >> > body.
> >> >> >> >> > Do
> >> >> >> >> > you
> >> >> >> >> > have any idea how I can achieve this report via reporting
> >> >> >> >> > svcs?
> >> >> >> >> > Unfortunately, this is very important. Please do advise.
> >> >> >> >> >
> >> >> >> >> > --Lynn
> >> >> >> >> >
> >> >> >> >> >
> >> >> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >> >> >
> >> >> >> >> >> Pick the command type as stored procedure and then just enter
> >> >> >> >> >> the
> >> >> >> >> >> name
> >> >> >> >> >> of
> >> >> >> >> >> the stored procedure. When you click on the ! you should get
> >> >> >> >> >> back
> >> >> >> >> >> the
> >> >> >> >> >> data
> >> >> >> >> >> and the fields. If you do not get the field list populated
> >> >> >> >> >> then
> >> >> >> >> >> click
> >> >> >> >> >> on
> >> >> >> >> >> the
> >> >> >> >> >> refresh fields button (to the right of the ..., it looks like
> >> >> >> >> >> the
> >> >> >> >> >> refresh
> >> >> >> >> >> button for IE).
> >> >> >> >> >>
> >> >> >> >> >> Note that RS only works with the first resultset returned. It
> >> >> >> >> >> cannot
> >> >> >> >> >> handle
> >> >> >> >> >> mutliple resultsets.
> >> >> >> >> >>
> >> >> >> >> >>
> >> >> >> >> >> --
> >> >> >> >> >> Bruce Loehle-Conger
> >> >> >> >> >> MVP SQL Server Reporting Services
> >> >> >> >> >>
> >> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> >> >> news:EF6A6CBC-083B-4537-83D9-D763A8ABA056@.microsoft.com...
> >> >> >> >> >> > Hi. I have a need to create a number of different reports
> >> >> >> >> >> > via
> >> >> >> >> >> > Reporting
> >> >> >> >> >> > Services. All of which are based on stored procedures,
> >> >> >> >> >> > none
> >> >> >> >> >> > of
> >> >> >> >> >> > which
> >> >> >> >> >> > require
> >> >> >> >> >> > any parameters. Most if not all of the report is
> >> >> >> >> >> > calculated.
> >> >> >> >> >> > I
> >> >> >> >> >> > am
> >> >> >> >> >> > struggling badly to get even the most basic of the fields
> >> >> >> >> >> > in
> >> >> >> >> >> > place
> >> >> >> >> >> > w/the
> >> >> >> >> >> > correct expressions. The only one I actually got to accept
> >> >> >> >> >> > the
> >> >> >> >> >> > expression
> >> >> >> >> >> > was a Date field, this is the calculation:
> >> >> >> >> >> >
> >> >> >> >> >> > =SELECT CONVERT(char(10),dateadd(dd,-0,GetDate()),1)
> >> >> >> >> >> >
> >> >> >> >> >> > It, too, fails to preview, indicating the value expression
> >> >> >> >> >> > for
> >> >> >> >> >> > the
> >> >> >> >> >> > field
> >> >> >> >> >> > contains an error. Again, all of the other report items
> >> >> >> >> >> > are
> >> >> >> >> >> > calculated
> >> >> >> >> >> > fields. SUMs, totals, money formats, CASE statements,|||last one for a while, bruce, i promise. i've got all 4 datasets in there,
each asks me for a parameter, i put 1,2,3 and 4 into each, getting my 'whole
report' in four small subsets of data. how do i get this to happen on the
report page automatically without needing user input?
-- Lynn
"Bruce L-C [MVP]" wrote:
> Are you going against SQL Server?
> If so, then just select tored procedure for the command type and just put in
> the name of the stored procedure. Do not put exec in from of it or anything
> else. It should detect the parameter and prompt you for it. It should also
> create a report parameter as well for you.
> Try creating a new dataset and do this from the start. If you continue to
> have problems create a new stored procedure just for testing .
> create procedure dbo.testproc
> @.PARAM1 int
> as
> select 'Parameter passed in = ' + @.PARAM1 as Message
> return
> Get the above procedure to work for you so you know how to call a stored
> procedure they way I am telling you (do not use exec).
>
> --
> Bruce Loehle-Conger
> MVP SQL Server Reporting Services
> --
> Bruce Loehle-Conger
> MVP SQL Server Reporting Services
> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> news:9B089D7B-1F23-465B-B443-08BD09469A3E@.microsoft.com...
> > i'm sorry, bruce, but where do i define the parameters? rs is not
> > detecting
> > them. in my 1st dataset i've got cmd type stored procedure and the proc
> > name
> > is in the query string. i assumed i would put the 1st parameter in on the
> > parameters tab and then do the same for 2, 3 and 4 on 3 other datasets, so
> > i
> > gave it @.ch and the value of 1, but when i attempted to run it, it threw
> > me a
> > 'define query parameters box asking me to put the '1' in it.
> > -- Lynn
> >
> >
> > "Bruce L-C [MVP]" wrote:
> >
> >> If you are going against SQL Server do not run your stored procedure this
> >> way. Pick command type of stored procedure. RS will detect the
> >> parameters.
> >> If going against ODBC or OLEDB driver (which uses ? format for
> >> parameters)
> >> then pick text as the command type and do this:
> >> myproc ?
> >>
> >> Create multiple datasets and for each one you should call the stored
> >> procedure for each one.
> >>
> >> Bruce Loehle-Conger
> >>
> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> news:79CA374D-729B-4181-8F45-5D61FCF30F28@.microsoft.com...
> >> > And, if I blow away the 2nd dataset and just give my 1st one
> >> > parameters,
> >> > it
> >> > almost works. EXEC db.dbo.procname 1 for chunk one of the results,
> >> > works
> >> > just fine. if i change the parameter to 2, 3 or 4, when I hit RUN in
> >> > Data
> >> > tab it returns an error: SQL Syntax Errors Encountered...The designer
> >> > does
> >> > not graphically support the EXEC SQL Construct' but, i hit 'OK' and
> >> > my
> >> > results are still returned to me. On 'Preview' tab, however, I get no
> >> > data/results at all.
> >> > -- Lynn
> >> >
> >> >
> >> > "Bruce L-C [MVP]" wrote:
> >> >
> >> >> Yes, you are calling it three times. In RS you create three datasets.
> >> >> Go
> >> >> to
> >> >> the dataset tab and there is a combo box with the name of the dataset,
> >> >> you
> >> >> can click on that and there is a an option for a new.
> >> >>
> >> >> In your stored procedure
> >> >>
> >> >> if @.WHICHRESULTSET = 1
> >> >> begin
> >> >> --return the first resultset here
> >> >> end
> >> >> etc
> >> >>
> >> >>
> >> >> --
> >> >> Bruce Loehle-Conger
> >> >> MVP SQL Server Reporting Services
> >> >>
> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> news:81E3A442-6694-442D-B151-F083E4750ADB@.microsoft.com...
> >> >> > Bruce, or somebody else, might you give me an example of how to give
> >> >> > the
> >> >> > proc
> >> >> > 3 parameters, producing three resultsets in a way that RS will
> >> >> > display
> >> >> > them?
> >> >> > Or, am I giving it three parameters and calling it three times? If
> >> >> > so,
> >> >> > how
> >> >> > would i call the 3 procs in RS?
> >> >> > -- Lynn
> >> >> >
> >> >> >
> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >
> >> >> >> Configure your existing stored procedure to accept a parameter (you
> >> >> >> can
> >> >> >> make
> >> >> >> it optional so that it doesn't break existing code).
> >> >> >>
> >> >> >> Then call it three times in RS with a static value and create three
> >> >> >> datasets.
> >> >> >> For instance dataset1
> >> >> >> yourproc 1
> >> >> >>
> >> >> >> Dataset2
> >> >> >> yourproc 2
> >> >> >>
> >> >> >> etc.
> >> >> >>
> >> >> >> Then in your stored procedure return the appropriate resultset
> >> >> >> based
> >> >> >> on
> >> >> >> the
> >> >> >> parameter.
> >> >> >>
> >> >> >> Downside is that your sp is being run three times.
> >> >> >>
> >> >> >>
> >> >> >> --
> >> >> >> Bruce Loehle-Conger
> >> >> >> MVP SQL Server Reporting Services
> >> >> >>
> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> news:E8E34B6C-A36A-4576-BE8C-AB61866EEC80@.microsoft.com...
> >> >> >> > Bruce, I'm not sure I follow. Can you elaborate a little more,
> >> >> >> > please,
> >> >> >> > on
> >> >> >> > the second, possibly third procedure?
> >> >> >> > -- Lynn
> >> >> >> >
> >> >> >> >
> >> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >> >
> >> >> >> >> This is three resultsets. RS does not have the ability to handle
> >> >> >> >> that.
> >> >> >> >> There
> >> >> >> >> is no work around from RS side. You could create another stored
> >> >> >> >> procedure
> >> >> >> >> that calls this one and have it return just one of the
> >> >> >> >> resultsets.
> >> >> >> >>
> >> >> >> >> RS can deal with multiple datasets quite well, but each stored
> >> >> >> >> procedure
> >> >> >> >> call can only return one.
> >> >> >> >>
> >> >> >> >>
> >> >> >> >> --
> >> >> >> >> Bruce Loehle-Conger
> >> >> >> >> MVP SQL Server Reporting Services
> >> >> >> >>
> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> >> news:E1AFA910-1FF4-4DC8-A3F0-FC1EADE8DFD5@.microsoft.com...
> >> >> >> >> > oh, bruce, that is great. I can't believe it was as simple as
> >> >> >> >> > that.
> >> >> >> >> > one
> >> >> >> >> > remaining problem, though. one of my reports is like this:
> >> >> >> >> >
> >> >> >> >> > Date Total Trades Symbols Traded Total $
> >> >> >> >> > -- -- -- --
> >> >> >> >> > 02/07/2006 333,333 333
> >> >> >> >> > 33,333,333,333.33
> >> >> >> >> >
> >> >> >> >> > #Stocks Volume Total $
> >> >> >> >> > -- -- --
> >> >> >> >> > 333,333 33,333,333 3,333,333,333.33
> >> >> >> >> >
> >> >> >> >> > EndPoint Liquidity #Trades Volume Total $
> >> >> >> >> > -- -- -- -- --
> >> >> >> >> > AAAA Add 114,729 21,797,575
> >> >> >> >> > 583,102,631.33
> >> >> >> >> > AAAA Opening 1 27
> >> >> >> >> > 3,412.53
> >> >> >> >> > AAAA Remove 30,836 8,330,843
> >> >> >> >> > 444,521,928.10
> >> >> >> >> > AAAA Route 41 4,543
> >> >> >> >> > 103,291.31
> >> >> >> >> > BBBB Add 26,997 9,940,201
> >> >> >> >> > 178,600,674.78
> >> >> >> >> > BBBB Opening 8,089 1,448,143
> >> >> >> >> > 44,276,419.41
> >> >> >> >> > BBBB Remove 3,406 1,719,403
> >> >> >> >> > 40,267,318.25
> >> >> >> >> > CCCC Add 83,781 22,443,732
> >> >> >> >> > 746,570,071.43
> >> >> >> >> > CCCC Remove 35,756 12,250,359
> >> >> >> >> > 483,329,796.97
> >> >> >> >> > CCCC Route 1,088 244,697
> >> >> >> >> > 6,655,913.26
> >> >> >> >> > DDDD Route 2 62,500
> >> >> >> >> > 2,539,375.00
> >> >> >> >> > DDDD Add 2,354 1,262,589
> >> >> >> >> > 19,136,233.44
> >> >> >> >> > DDDD Remove 258 195,019
> >> >> >> >> > 6,227,451.69
> >> >> >> >> >
> >> >> >> >> > I only receive the top line in the resultset:
> >> >> >> >> >
> >> >> >> >> > Date Total Trades Symbols Traded Total $
> >> >> >> >> > -- -- -- --
> >> >> >> >> > 02/07/2006 333,333 333
> >> >> >> >> > 33,333,333,333.33
> >> >> >> >> >
> >> >> >> >> > I assume this is what you mean when you say it will only
> >> >> >> >> > handle
> >> >> >> >> > the
> >> >> >> >> > 1st
> >> >> >> >> > resultset. All of my reports have multiple 'chunks' in the
> >> >> >> >> > body.
> >> >> >> >> > Do
> >> >> >> >> > you
> >> >> >> >> > have any idea how I can achieve this report via reporting
> >> >> >> >> > svcs?
> >> >> >> >> > Unfortunately, this is very important. Please do advise.
> >> >> >> >> >
> >> >> >> >> > --Lynn
> >> >> >> >> >
> >> >> >> >> >
> >> >> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >> >> >
> >> >> >> >> >> Pick the command type as stored procedure and then just enter
> >> >> >> >> >> the
> >> >> >> >> >> name
> >> >> >> >> >> of
> >> >> >> >> >> the stored procedure. When you click on the ! you should get
> >> >> >> >> >> back
> >> >> >> >> >> the
> >> >> >> >> >> data
> >> >> >> >> >> and the fields. If you do not get the field list populated
> >> >> >> >> >> then
> >> >> >> >> >> click
> >> >> >> >> >> on
> >> >> >> >> >> the
> >> >> >> >> >> refresh fields button (to the right of the ..., it looks like
> >> >> >> >> >> the
> >> >> >> >> >> refresh
> >> >> >> >> >> button for IE).
> >> >> >> >> >>
> >> >> >> >> >> Note that RS only works with the first resultset returned. It
> >> >> >> >> >> cannot
> >> >> >> >> >> handle
> >> >> >> >> >> mutliple resultsets.
> >> >> >> >> >>
> >> >> >> >> >>
> >> >> >> >> >> --
> >> >> >> >> >> Bruce Loehle-Conger
> >> >> >> >> >> MVP SQL Server Reporting Services
> >> >> >> >> >>
> >> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> >> >> news:EF6A6CBC-083B-4537-83D9-D763A8ABA056@.microsoft.com...
> >> >> >> >> >> > Hi. I have a need to create a number of different reports
> >> >> >> >> >> > via
> >> >> >> >> >> > Reporting
> >> >> >> >> >> > Services. All of which are based on stored procedures,
> >> >> >> >> >> > none
> >> >> >> >> >> > of
> >> >> >> >> >> > which
> >> >> >> >> >> > require
> >> >> >> >> >> > any parameters. Most if not all of the report is
> >> >> >> >> >> > calculated.
> >> >> >> >> >> > I
> >> >> >> >> >> > am
> >> >> >> >> >> > struggling badly to get even the most basic of the fields
> >> >> >> >> >> > in
> >> >> >> >> >> > place
> >> >> >> >> >> > w/the
> >> >> >> >> >> > correct expressions. The only one I actually got to accept
> >> >> >> >> >> > the
> >> >> >> >> >> > expression
> >> >> >> >> >> > was a Date field, this is the calculation:
> >> >> >> >> >> >
> >> >> >> >> >> > =SELECT CONVERT(char(10),dateadd(dd,-0,GetDate()),1)
> >> >> >> >> >> >
> >> >> >> >> >> > It, too, fails to preview, indicating the value expression
> >> >> >> >> >> > for
> >> >> >> >> >> > the
> >> >> >> >> >> > field
> >> >> >> >> >> > contains an error. Again, all of the other report items
> >> >> >> >> >> > are
> >> >> >> >> >> > calculated
> >> >> >> >> >> > fields. SUMs, totals, money formats, CASE statements,|||Query parameters and report parameters seem to be the same thing but they
are not. RS automatically creates a report parameter for each query
parameter but instead you can map the query parameter to a constant. Click
on the ... for the dataset, go to the parameters tab. On the right you will
see it mapping to the report parameter, click on that and select expression.
In expression put = 1 (assuming it is an integert expression) for the first
dataset, =2 etc. Then go to report layout, report menu-> report parameters
and then delete the report parameters created for you.
You are very very close to the solution.
--
Bruce Loehle-Conger
MVP SQL Server Reporting Services
"Lynn" <Lynn@.discussions.microsoft.com> wrote in message
news:61E1ED5C-B204-4024-9DC4-82635AEBD912@.microsoft.com...
> last one for a while, bruce, i promise. i've got all 4 datasets in there,
> each asks me for a parameter, i put 1,2,3 and 4 into each, getting my
> 'whole
> report' in four small subsets of data. how do i get this to happen on the
> report page automatically without needing user input?
> -- Lynn
>
> "Bruce L-C [MVP]" wrote:
>> Are you going against SQL Server?
>> If so, then just select tored procedure for the command type and just put
>> in
>> the name of the stored procedure. Do not put exec in from of it or
>> anything
>> else. It should detect the parameter and prompt you for it. It should
>> also
>> create a report parameter as well for you.
>> Try creating a new dataset and do this from the start. If you continue to
>> have problems create a new stored procedure just for testing .
>> create procedure dbo.testproc
>> @.PARAM1 int
>> as
>> select 'Parameter passed in = ' + @.PARAM1 as Message
>> return
>> Get the above procedure to work for you so you know how to call a stored
>> procedure they way I am telling you (do not use exec).
>>
>> --
>> Bruce Loehle-Conger
>> MVP SQL Server Reporting Services
>> --
>> Bruce Loehle-Conger
>> MVP SQL Server Reporting Services
>> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> news:9B089D7B-1F23-465B-B443-08BD09469A3E@.microsoft.com...
>> > i'm sorry, bruce, but where do i define the parameters? rs is not
>> > detecting
>> > them. in my 1st dataset i've got cmd type stored procedure and the
>> > proc
>> > name
>> > is in the query string. i assumed i would put the 1st parameter in on
>> > the
>> > parameters tab and then do the same for 2, 3 and 4 on 3 other datasets,
>> > so
>> > i
>> > gave it @.ch and the value of 1, but when i attempted to run it, it
>> > threw
>> > me a
>> > 'define query parameters box asking me to put the '1' in it.
>> > -- Lynn
>> >
>> >
>> > "Bruce L-C [MVP]" wrote:
>> >
>> >> If you are going against SQL Server do not run your stored procedure
>> >> this
>> >> way. Pick command type of stored procedure. RS will detect the
>> >> parameters.
>> >> If going against ODBC or OLEDB driver (which uses ? format for
>> >> parameters)
>> >> then pick text as the command type and do this:
>> >> myproc ?
>> >>
>> >> Create multiple datasets and for each one you should call the stored
>> >> procedure for each one.
>> >>
>> >> Bruce Loehle-Conger
>> >>
>> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> >> news:79CA374D-729B-4181-8F45-5D61FCF30F28@.microsoft.com...
>> >> > And, if I blow away the 2nd dataset and just give my 1st one
>> >> > parameters,
>> >> > it
>> >> > almost works. EXEC db.dbo.procname 1 for chunk one of the
>> >> > results,
>> >> > works
>> >> > just fine. if i change the parameter to 2, 3 or 4, when I hit RUN
>> >> > in
>> >> > Data
>> >> > tab it returns an error: SQL Syntax Errors Encountered...The
>> >> > designer
>> >> > does
>> >> > not graphically support the EXEC SQL Construct' but, i hit 'OK'
>> >> > and
>> >> > my
>> >> > results are still returned to me. On 'Preview' tab, however, I get
>> >> > no
>> >> > data/results at all.
>> >> > -- Lynn
>> >> >
>> >> >
>> >> > "Bruce L-C [MVP]" wrote:
>> >> >
>> >> >> Yes, you are calling it three times. In RS you create three
>> >> >> datasets.
>> >> >> Go
>> >> >> to
>> >> >> the dataset tab and there is a combo box with the name of the
>> >> >> dataset,
>> >> >> you
>> >> >> can click on that and there is a an option for a new.
>> >> >>
>> >> >> In your stored procedure
>> >> >>
>> >> >> if @.WHICHRESULTSET = 1
>> >> >> begin
>> >> >> --return the first resultset here
>> >> >> end
>> >> >> etc
>> >> >>
>> >> >>
>> >> >> --
>> >> >> Bruce Loehle-Conger
>> >> >> MVP SQL Server Reporting Services
>> >> >>
>> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> >> >> news:81E3A442-6694-442D-B151-F083E4750ADB@.microsoft.com...
>> >> >> > Bruce, or somebody else, might you give me an example of how to
>> >> >> > give
>> >> >> > the
>> >> >> > proc
>> >> >> > 3 parameters, producing three resultsets in a way that RS will
>> >> >> > display
>> >> >> > them?
>> >> >> > Or, am I giving it three parameters and calling it three times?
>> >> >> > If
>> >> >> > so,
>> >> >> > how
>> >> >> > would i call the 3 procs in RS?
>> >> >> > -- Lynn
>> >> >> >
>> >> >> >
>> >> >> > "Bruce L-C [MVP]" wrote:
>> >> >> >
>> >> >> >> Configure your existing stored procedure to accept a parameter
>> >> >> >> (you
>> >> >> >> can
>> >> >> >> make
>> >> >> >> it optional so that it doesn't break existing code).
>> >> >> >>
>> >> >> >> Then call it three times in RS with a static value and create
>> >> >> >> three
>> >> >> >> datasets.
>> >> >> >> For instance dataset1
>> >> >> >> yourproc 1
>> >> >> >>
>> >> >> >> Dataset2
>> >> >> >> yourproc 2
>> >> >> >>
>> >> >> >> etc.
>> >> >> >>
>> >> >> >> Then in your stored procedure return the appropriate resultset
>> >> >> >> based
>> >> >> >> on
>> >> >> >> the
>> >> >> >> parameter.
>> >> >> >>
>> >> >> >> Downside is that your sp is being run three times.
>> >> >> >>
>> >> >> >>
>> >> >> >> --
>> >> >> >> Bruce Loehle-Conger
>> >> >> >> MVP SQL Server Reporting Services
>> >> >> >>
>> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> >> >> >> news:E8E34B6C-A36A-4576-BE8C-AB61866EEC80@.microsoft.com...
>> >> >> >> > Bruce, I'm not sure I follow. Can you elaborate a little
>> >> >> >> > more,
>> >> >> >> > please,
>> >> >> >> > on
>> >> >> >> > the second, possibly third procedure?
>> >> >> >> > -- Lynn
>> >> >> >> >
>> >> >> >> >
>> >> >> >> > "Bruce L-C [MVP]" wrote:
>> >> >> >> >
>> >> >> >> >> This is three resultsets. RS does not have the ability to
>> >> >> >> >> handle
>> >> >> >> >> that.
>> >> >> >> >> There
>> >> >> >> >> is no work around from RS side. You could create another
>> >> >> >> >> stored
>> >> >> >> >> procedure
>> >> >> >> >> that calls this one and have it return just one of the
>> >> >> >> >> resultsets.
>> >> >> >> >>
>> >> >> >> >> RS can deal with multiple datasets quite well, but each
>> >> >> >> >> stored
>> >> >> >> >> procedure
>> >> >> >> >> call can only return one.
>> >> >> >> >>
>> >> >> >> >>
>> >> >> >> >> --
>> >> >> >> >> Bruce Loehle-Conger
>> >> >> >> >> MVP SQL Server Reporting Services
>> >> >> >> >>
>> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> >> >> >> >> news:E1AFA910-1FF4-4DC8-A3F0-FC1EADE8DFD5@.microsoft.com...
>> >> >> >> >> > oh, bruce, that is great. I can't believe it was as simple
>> >> >> >> >> > as
>> >> >> >> >> > that.
>> >> >> >> >> > one
>> >> >> >> >> > remaining problem, though. one of my reports is like this:
>> >> >> >> >> >
>> >> >> >> >> > Date Total Trades Symbols Traded Total $
>> >> >> >> >> > -- -- -- --
>> >> >> >> >> > 02/07/2006 333,333 333
>> >> >> >> >> > 33,333,333,333.33
>> >> >> >> >> >
>> >> >> >> >> > #Stocks Volume Total $
>> >> >> >> >> > -- -- --
>> >> >> >> >> > 333,333 33,333,333 3,333,333,333.33
>> >> >> >> >> >
>> >> >> >> >> > EndPoint Liquidity #Trades Volume
>> >> >> >> >> > Total $
>> >> >> >> >> > -- -- -- -- --
>> >> >> >> >> > AAAA Add 114,729 21,797,575
>> >> >> >> >> > 583,102,631.33
>> >> >> >> >> > AAAA Opening 1 27
>> >> >> >> >> > 3,412.53
>> >> >> >> >> > AAAA Remove 30,836 8,330,843
>> >> >> >> >> > 444,521,928.10
>> >> >> >> >> > AAAA Route 41 4,543
>> >> >> >> >> > 103,291.31
>> >> >> >> >> > BBBB Add 26,997 9,940,201
>> >> >> >> >> > 178,600,674.78
>> >> >> >> >> > BBBB Opening 8,089 1,448,143
>> >> >> >> >> > 44,276,419.41
>> >> >> >> >> > BBBB Remove 3,406 1,719,403
>> >> >> >> >> > 40,267,318.25
>> >> >> >> >> > CCCC Add 83,781 22,443,732
>> >> >> >> >> > 746,570,071.43
>> >> >> >> >> > CCCC Remove 35,756 12,250,359
>> >> >> >> >> > 483,329,796.97
>> >> >> >> >> > CCCC Route 1,088 244,697
>> >> >> >> >> > 6,655,913.26
>> >> >> >> >> > DDDD Route 2 62,500
>> >> >> >> >> > 2,539,375.00
>> >> >> >> >> > DDDD Add 2,354 1,262,589
>> >> >> >> >> > 19,136,233.44
>> >> >> >> >> > DDDD Remove 258 195,019
>> >> >> >> >> > 6,227,451.69
>> >> >> >> >> >
>> >> >> >> >> > I only receive the top line in the resultset:
>> >> >> >> >> >
>> >> >> >> >> > Date Total Trades Symbols Traded Total $
>> >> >> >> >> > -- -- -- --
>> >> >> >> >> > 02/07/2006 333,333 333
>> >> >> >> >> > 33,333,333,333.33
>> >> >> >> >> >
>> >> >> >> >> > I assume this is what you mean when you say it will only
>> >> >> >> >> > handle
>> >> >> >> >> > the
>> >> >> >> >> > 1st
>> >> >> >> >> > resultset. All of my reports have multiple 'chunks' in
>> >> >> >> >> > the
>> >> >> >> >> > body.
>> >> >> >> >> > Do
>> >> >> >> >> > you
>> >> >> >> >> > have any idea how I can achieve this report via reporting
>> >> >> >> >> > svcs?
>> >> >> >> >> > Unfortunately, this is very important. Please do advise.
>> >> >> >> >> >
>> >> >> >> >> > --Lynn
>> >> >> >> >> >
>> >> >> >> >> >
>> >> >> >> >> > "Bruce L-C [MVP]" wrote:
>> >> >> >> >> >
>> >> >> >> >> >> Pick the command type as stored procedure and then just
>> >> >> >> >> >> enter
>> >> >> >> >> >> the
>> >> >> >> >> >> name
>> >> >> >> >> >> of
>> >> >> >> >> >> the stored procedure. When you click on the ! you should
>> >> >> >> >> >> get
>> >> >> >> >> >> back
>> >> >> >> >> >> the
>> >> >> >> >> >> data
>> >> >> >> >> >> and the fields. If you do not get the field list populated
>> >> >> >> >> >> then
>> >> >> >> >> >> click
>> >> >> >> >> >> on
>> >> >> >> >> >> the
>> >> >> >> >> >> refresh fields button (to the right of the ..., it looks
>> >> >> >> >> >> like
>> >> >> >> >> >> the
>> >> >> >> >> >> refresh
>> >> >> >> >> >> button for IE).
>> >> >> >> >> >>
>> >> >> >> >> >> Note that RS only works with the first resultset returned.
>> >> >> >> >> >> It
>> >> >> >> >> >> cannot
>> >> >> >> >> >> handle
>> >> >> >> >> >> mutliple resultsets.
>> >> >> >> >> >>
>> >> >> >> >> >>
>> >> >> >> >> >> --
>> >> >> >> >> >> Bruce Loehle-Conger
>> >> >> >> >> >> MVP SQL Server Reporting Services
>> >> >> >> >> >>
>> >> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> >> >> >> >> >> news:EF6A6CBC-083B-4537-83D9-D763A8ABA056@.microsoft.com...
>> >> >> >> >> >> > Hi. I have a need to create a number of different
>> >> >> >> >> >> > reports
>> >> >> >> >> >> > via
>> >> >> >> >> >> > Reporting
>> >> >> >> >> >> > Services. All of which are based on stored procedures,
>> >> >> >> >> >> > none
>> >> >> >> >> >> > of
>> >> >> >> >> >> > which
>> >> >> >> >> >> > require
>> >> >> >> >> >> > any parameters. Most if not all of the report is
>> >> >> >> >> >> > calculated.
>> >> >> >> >> >> > I
>> >> >> >> >> >> > am
>> >> >> >> >> >> > struggling badly to get even the most basic of the
>> >> >> >> >> >> > fields
>> >> >> >> >> >> > in
>> >> >> >> >> >> > place
>> >> >> >> >> >> > w/the
>> >> >> >> >> >> > correct expressions. The only one I actually got to
>> >> >> >> >> >> > accept
>> >> >> >> >> >> > the
>> >> >> >> >> >> > expression
>> >> >> >> >> >> > was a Date field, this is the calculation:
>> >> >> >> >> >> >
>> >> >> >> >> >> > =SELECT CONVERT(char(10),dateadd(dd,-0,GetDate()),1)
>> >> >> >> >> >> >
>> >> >> >> >> >> > It, too, fails to preview, indicating the value
>> >> >> >> >> >> > expression
>> >> >> >> >> >> > for
>> >> >> >> >> >> > the
>> >> >> >> >> >> > field
>> >> >> >> >> >> > contains an error. Again, all of the other report items
>> >> >> >> >> >> > are
>> >> >> >> >> >> > calculated
>> >> >> >> >> >> > fields. SUMs, totals, money formats, CASE statements,|||oh my goodness this is frustrating me....i did what you said, bruce, and it
almost worked. the preview report shows me three values which correspond, i
believe, to the only three fields in my report. see, they're all calculated
fields. the output of the rpt is this:
Build complete -- 0 errors, 0 warnings
The data set â'DataSet3â' contains a definition for the field
â'Futures_Volumeâ'. This field is missing from the returned result set from the
data source.
The data set â'DataSet4â' contains a definition for the field
â'Futures_Volumeâ'. This field is missing from the returned result set from the
data source.
The data set â'DataSet2â' contains a definition for the field
â'Futures_Volumeâ'. This field is missing from the returned result set from the
data source.
Preview complete -- 0 errors, 3 warnings
Now, I created the4 datasets, the parameter for each is simply 1, 2, 3 and
4. The report, or the query, is not auto-generating my other fields as it
did for three that I do see. The 'Futures_Volume' is one of the fields that
was auto-generated for me, and it is in the 1st dataset. Is it that I just
need to manually add in the other fields? Please do let me know what you
think.
and thank you, bruce, for helping me through this. i truly do appreciate
it. i know i am close...and i got the other reports for my server jobs and
one of the other company reports to work. it's just these multi-resultset
reports are fighting me.
-- Lynn
"Bruce L-C [MVP]" wrote:
> Query parameters and report parameters seem to be the same thing but they
> are not. RS automatically creates a report parameter for each query
> parameter but instead you can map the query parameter to a constant. Click
> on the ... for the dataset, go to the parameters tab. On the right you will
> see it mapping to the report parameter, click on that and select expression.
> In expression put = 1 (assuming it is an integert expression) for the first
> dataset, =2 etc. Then go to report layout, report menu-> report parameters
> and then delete the report parameters created for you.
> You are very very close to the solution.
> --
> Bruce Loehle-Conger
> MVP SQL Server Reporting Services
> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> news:61E1ED5C-B204-4024-9DC4-82635AEBD912@.microsoft.com...
> > last one for a while, bruce, i promise. i've got all 4 datasets in there,
> > each asks me for a parameter, i put 1,2,3 and 4 into each, getting my
> > 'whole
> > report' in four small subsets of data. how do i get this to happen on the
> > report page automatically without needing user input?
> > -- Lynn
> >
> >
> > "Bruce L-C [MVP]" wrote:
> >
> >> Are you going against SQL Server?
> >>
> >> If so, then just select tored procedure for the command type and just put
> >> in
> >> the name of the stored procedure. Do not put exec in from of it or
> >> anything
> >> else. It should detect the parameter and prompt you for it. It should
> >> also
> >> create a report parameter as well for you.
> >>
> >> Try creating a new dataset and do this from the start. If you continue to
> >> have problems create a new stored procedure just for testing .
> >>
> >> create procedure dbo.testproc
> >> @.PARAM1 int
> >> as
> >> select 'Parameter passed in = ' + @.PARAM1 as Message
> >> return
> >>
> >> Get the above procedure to work for you so you know how to call a stored
> >> procedure they way I am telling you (do not use exec).
> >>
> >>
> >> --
> >> Bruce Loehle-Conger
> >> MVP SQL Server Reporting Services
> >> --
> >> Bruce Loehle-Conger
> >> MVP SQL Server Reporting Services
> >>
> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> news:9B089D7B-1F23-465B-B443-08BD09469A3E@.microsoft.com...
> >> > i'm sorry, bruce, but where do i define the parameters? rs is not
> >> > detecting
> >> > them. in my 1st dataset i've got cmd type stored procedure and the
> >> > proc
> >> > name
> >> > is in the query string. i assumed i would put the 1st parameter in on
> >> > the
> >> > parameters tab and then do the same for 2, 3 and 4 on 3 other datasets,
> >> > so
> >> > i
> >> > gave it @.ch and the value of 1, but when i attempted to run it, it
> >> > threw
> >> > me a
> >> > 'define query parameters box asking me to put the '1' in it.
> >> > -- Lynn
> >> >
> >> >
> >> > "Bruce L-C [MVP]" wrote:
> >> >
> >> >> If you are going against SQL Server do not run your stored procedure
> >> >> this
> >> >> way. Pick command type of stored procedure. RS will detect the
> >> >> parameters.
> >> >> If going against ODBC or OLEDB driver (which uses ? format for
> >> >> parameters)
> >> >> then pick text as the command type and do this:
> >> >> myproc ?
> >> >>
> >> >> Create multiple datasets and for each one you should call the stored
> >> >> procedure for each one.
> >> >>
> >> >> Bruce Loehle-Conger
> >> >>
> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> news:79CA374D-729B-4181-8F45-5D61FCF30F28@.microsoft.com...
> >> >> > And, if I blow away the 2nd dataset and just give my 1st one
> >> >> > parameters,
> >> >> > it
> >> >> > almost works. EXEC db.dbo.procname 1 for chunk one of the
> >> >> > results,
> >> >> > works
> >> >> > just fine. if i change the parameter to 2, 3 or 4, when I hit RUN
> >> >> > in
> >> >> > Data
> >> >> > tab it returns an error: SQL Syntax Errors Encountered...The
> >> >> > designer
> >> >> > does
> >> >> > not graphically support the EXEC SQL Construct' but, i hit 'OK'
> >> >> > and
> >> >> > my
> >> >> > results are still returned to me. On 'Preview' tab, however, I get
> >> >> > no
> >> >> > data/results at all.
> >> >> > -- Lynn
> >> >> >
> >> >> >
> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >
> >> >> >> Yes, you are calling it three times. In RS you create three
> >> >> >> datasets.
> >> >> >> Go
> >> >> >> to
> >> >> >> the dataset tab and there is a combo box with the name of the
> >> >> >> dataset,
> >> >> >> you
> >> >> >> can click on that and there is a an option for a new.
> >> >> >>
> >> >> >> In your stored procedure
> >> >> >>
> >> >> >> if @.WHICHRESULTSET = 1
> >> >> >> begin
> >> >> >> --return the first resultset here
> >> >> >> end
> >> >> >> etc
> >> >> >>
> >> >> >>
> >> >> >> --
> >> >> >> Bruce Loehle-Conger
> >> >> >> MVP SQL Server Reporting Services
> >> >> >>
> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> news:81E3A442-6694-442D-B151-F083E4750ADB@.microsoft.com...
> >> >> >> > Bruce, or somebody else, might you give me an example of how to
> >> >> >> > give
> >> >> >> > the
> >> >> >> > proc
> >> >> >> > 3 parameters, producing three resultsets in a way that RS will
> >> >> >> > display
> >> >> >> > them?
> >> >> >> > Or, am I giving it three parameters and calling it three times?
> >> >> >> > If
> >> >> >> > so,
> >> >> >> > how
> >> >> >> > would i call the 3 procs in RS?
> >> >> >> > -- Lynn
> >> >> >> >
> >> >> >> >
> >> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >> >
> >> >> >> >> Configure your existing stored procedure to accept a parameter
> >> >> >> >> (you
> >> >> >> >> can
> >> >> >> >> make
> >> >> >> >> it optional so that it doesn't break existing code).
> >> >> >> >>
> >> >> >> >> Then call it three times in RS with a static value and create
> >> >> >> >> three
> >> >> >> >> datasets.
> >> >> >> >> For instance dataset1
> >> >> >> >> yourproc 1
> >> >> >> >>
> >> >> >> >> Dataset2
> >> >> >> >> yourproc 2
> >> >> >> >>
> >> >> >> >> etc.
> >> >> >> >>
> >> >> >> >> Then in your stored procedure return the appropriate resultset
> >> >> >> >> based
> >> >> >> >> on
> >> >> >> >> the
> >> >> >> >> parameter.
> >> >> >> >>
> >> >> >> >> Downside is that your sp is being run three times.
> >> >> >> >>
> >> >> >> >>
> >> >> >> >> --
> >> >> >> >> Bruce Loehle-Conger
> >> >> >> >> MVP SQL Server Reporting Services
> >> >> >> >>
> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> >> news:E8E34B6C-A36A-4576-BE8C-AB61866EEC80@.microsoft.com...
> >> >> >> >> > Bruce, I'm not sure I follow. Can you elaborate a little
> >> >> >> >> > more,
> >> >> >> >> > please,
> >> >> >> >> > on
> >> >> >> >> > the second, possibly third procedure?
> >> >> >> >> > -- Lynn
> >> >> >> >> >
> >> >> >> >> >
> >> >> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >> >> >
> >> >> >> >> >> This is three resultsets. RS does not have the ability to
> >> >> >> >> >> handle
> >> >> >> >> >> that.
> >> >> >> >> >> There
> >> >> >> >> >> is no work around from RS side. You could create another
> >> >> >> >> >> stored
> >> >> >> >> >> procedure
> >> >> >> >> >> that calls this one and have it return just one of the
> >> >> >> >> >> resultsets.
> >> >> >> >> >>
> >> >> >> >> >> RS can deal with multiple datasets quite well, but each
> >> >> >> >> >> stored
> >> >> >> >> >> procedure
> >> >> >> >> >> call can only return one.
> >> >> >> >> >>
> >> >> >> >> >>
> >> >> >> >> >> --
> >> >> >> >> >> Bruce Loehle-Conger
> >> >> >> >> >> MVP SQL Server Reporting Services
> >> >> >> >> >>
> >> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> >> >> news:E1AFA910-1FF4-4DC8-A3F0-FC1EADE8DFD5@.microsoft.com...
> >> >> >> >> >> > oh, bruce, that is great. I can't believe it was as simple
> >> >> >> >> >> > as
> >> >> >> >> >> > that.
> >> >> >> >> >> > one
> >> >> >> >> >> > remaining problem, though. one of my reports is like this:
> >> >> >> >> >> >
> >> >> >> >> >> > Date Total Trades Symbols Traded Total $
> >> >> >> >> >> > -- -- -- --
> >> >> >> >> >> > 02/07/2006 333,333 333
> >> >> >> >> >> > 33,333,333,333.33
> >> >> >> >> >> >
> >> >> >> >> >> > #Stocks Volume Total $
> >> >> >> >> >> > -- -- --
> >> >> >> >> >> > 333,333 33,333,333 3,333,333,333.33
> >> >> >> >> >> >
> >> >> >> >> >> > EndPoint Liquidity #Trades Volume
> >> >> >> >> >> > Total $
> >> >> >> >> >> > -- -- -- -- --
> >> >> >> >> >> > AAAA Add 114,729 21,797,575
> >> >> >> >> >> > 583,102,631.33
> >> >> >> >> >> > AAAA Opening 1 27
> >> >> >> >> >> > 3,412.53
> >> >> >> >> >> > AAAA Remove 30,836 8,330,843
> >> >> >> >> >> > 444,521,928.10
> >> >> >> >> >> > AAAA Route 41 4,543
> >> >> >> >> >> > 103,291.31
> >> >> >> >> >> > BBBB Add 26,997 9,940,201
> >> >> >> >> >> > 178,600,674.78
> >> >> >> >> >> > BBBB Opening 8,089 1,448,143
> >> >> >> >> >> > 44,276,419.41
> >> >> >> >> >> > BBBB Remove 3,406 1,719,403
> >> >> >> >> >> > 40,267,318.25
> >> >> >> >> >> > CCCC Add 83,781 22,443,732
> >> >> >> >> >> > 746,570,071.43
> >> >> >> >> >> > CCCC Remove 35,756 12,250,359
> >> >> >> >> >> > 483,329,796.97
> >> >> >> >> >> > CCCC Route 1,088 244,697
> >> >> >> >> >> > 6,655,913.26
> >> >> >> >> >> > DDDD Route 2 62,500
> >> >> >> >> >> > 2,539,375.00
> >> >> >> >> >> > DDDD Add 2,354 1,262,589
> >> >> >> >> >> > 19,136,233.44
> >> >> >> >> >> > DDDD Remove 258 195,019
> >> >> >> >> >> > 6,227,451.69
> >> >> >> >> >> >
> >> >> >> >> >> > I only receive the top line in the resultset:
> >> >> >> >> >> >
> >> >> >> >> >> > Date Total Trades Symbols Traded Total $
> >> >> >> >> >> > -- -- -- --
> >> >> >> >> >> > 02/07/2006 333,333 333
> >> >> >> >> >> > 33,333,333,333.33
> >> >> >> >> >> >
> >> >> >> >> >> > I assume this is what you mean when you say it will only
> >> >> >> >> >> > handle
> >> >> >> >> >> > the
> >> >> >> >> >> > 1st
> >> >> >> >> >> > resultset. All of my reports have multiple 'chunks' in
> >> >> >> >> >> > the
> >> >> >> >> >> > body.
> >> >> >> >> >> > Do
> >> >> >> >> >> > you
> >> >> >> >> >> > have any idea how I can achieve this report via reporting
> >> >> >> >> >> > svcs?
> >> >> >> >> >> > Unfortunately, this is very important. Please do advise.
> >> >> >> >> >> >
> >> >> >> >> >> > --Lynn
> >> >> >> >> >> >
> >> >> >> >> >> >
> >> >> >> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >> >> >> >
> >> >> >> >> >> >> Pick the command type as stored procedure and then just
> >> >> >> >> >> >> enter
> >> >> >> >> >> >> the
> >> >> >> >> >> >> name
> >> >> >> >> >> >> of
> >> >> >> >> >> >> the stored procedure. When you click on the ! you should
> >> >> >> >> >> >> get
> >> >> >> >> >> >> back|||For each of your datasets make sure there is a field list. Sometimes you
have to click on the refresh fields button (to the right of the ...).
--
Bruce Loehle-Conger
MVP SQL Server Reporting Services
"Lynn" <Lynn@.discussions.microsoft.com> wrote in message
news:17C0ED6F-0E4A-4033-A1A2-A841AA7BBECF@.microsoft.com...
> oh my goodness this is frustrating me....i did what you said, bruce, and
> it
> almost worked. the preview report shows me three values which correspond,
> i
> believe, to the only three fields in my report. see, they're all
> calculated
> fields. the output of the rpt is this:
> Build complete -- 0 errors, 0 warnings
> The data set 'DataSet3' contains a definition for the field
> 'Futures_Volume'. This field is missing from the returned result set from
> the
> data source.
> The data set 'DataSet4' contains a definition for the field
> 'Futures_Volume'. This field is missing from the returned result set from
> the
> data source.
> The data set 'DataSet2' contains a definition for the field
> 'Futures_Volume'. This field is missing from the returned result set from
> the
> data source.
> Preview complete -- 0 errors, 3 warnings
> Now, I created the4 datasets, the parameter for each is simply 1, 2, 3 and
> 4. The report, or the query, is not auto-generating my other fields as it
> did for three that I do see. The 'Futures_Volume' is one of the fields
> that
> was auto-generated for me, and it is in the 1st dataset. Is it that I
> just
> need to manually add in the other fields? Please do let me know what you
> think.
> and thank you, bruce, for helping me through this. i truly do appreciate
> it. i know i am close...and i got the other reports for my server jobs
> and
> one of the other company reports to work. it's just these multi-resultset
> reports are fighting me.
> -- Lynn
>
> "Bruce L-C [MVP]" wrote:
>> Query parameters and report parameters seem to be the same thing but they
>> are not. RS automatically creates a report parameter for each query
>> parameter but instead you can map the query parameter to a constant.
>> Click
>> on the ... for the dataset, go to the parameters tab. On the right you
>> will
>> see it mapping to the report parameter, click on that and select
>> expression.
>> In expression put = 1 (assuming it is an integert expression) for the
>> first
>> dataset, =2 etc. Then go to report layout, report menu-> report
>> parameters
>> and then delete the report parameters created for you.
>> You are very very close to the solution.
>> --
>> Bruce Loehle-Conger
>> MVP SQL Server Reporting Services
>> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> news:61E1ED5C-B204-4024-9DC4-82635AEBD912@.microsoft.com...
>> > last one for a while, bruce, i promise. i've got all 4 datasets in
>> > there,
>> > each asks me for a parameter, i put 1,2,3 and 4 into each, getting my
>> > 'whole
>> > report' in four small subsets of data. how do i get this to happen on
>> > the
>> > report page automatically without needing user input?
>> > -- Lynn
>> >
>> >
>> > "Bruce L-C [MVP]" wrote:
>> >
>> >> Are you going against SQL Server?
>> >>
>> >> If so, then just select tored procedure for the command type and just
>> >> put
>> >> in
>> >> the name of the stored procedure. Do not put exec in from of it or
>> >> anything
>> >> else. It should detect the parameter and prompt you for it. It should
>> >> also
>> >> create a report parameter as well for you.
>> >>
>> >> Try creating a new dataset and do this from the start. If you continue
>> >> to
>> >> have problems create a new stored procedure just for testing .
>> >>
>> >> create procedure dbo.testproc
>> >> @.PARAM1 int
>> >> as
>> >> select 'Parameter passed in = ' + @.PARAM1 as Message
>> >> return
>> >>
>> >> Get the above procedure to work for you so you know how to call a
>> >> stored
>> >> procedure they way I am telling you (do not use exec).
>> >>
>> >>
>> >> --
>> >> Bruce Loehle-Conger
>> >> MVP SQL Server Reporting Services
>> >> --
>> >> Bruce Loehle-Conger
>> >> MVP SQL Server Reporting Services
>> >>
>> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> >> news:9B089D7B-1F23-465B-B443-08BD09469A3E@.microsoft.com...
>> >> > i'm sorry, bruce, but where do i define the parameters? rs is not
>> >> > detecting
>> >> > them. in my 1st dataset i've got cmd type stored procedure and the
>> >> > proc
>> >> > name
>> >> > is in the query string. i assumed i would put the 1st parameter in
>> >> > on
>> >> > the
>> >> > parameters tab and then do the same for 2, 3 and 4 on 3 other
>> >> > datasets,
>> >> > so
>> >> > i
>> >> > gave it @.ch and the value of 1, but when i attempted to run it, it
>> >> > threw
>> >> > me a
>> >> > 'define query parameters box asking me to put the '1' in it.
>> >> > -- Lynn
>> >> >
>> >> >
>> >> > "Bruce L-C [MVP]" wrote:
>> >> >
>> >> >> If you are going against SQL Server do not run your stored
>> >> >> procedure
>> >> >> this
>> >> >> way. Pick command type of stored procedure. RS will detect the
>> >> >> parameters.
>> >> >> If going against ODBC or OLEDB driver (which uses ? format for
>> >> >> parameters)
>> >> >> then pick text as the command type and do this:
>> >> >> myproc ?
>> >> >>
>> >> >> Create multiple datasets and for each one you should call the
>> >> >> stored
>> >> >> procedure for each one.
>> >> >>
>> >> >> Bruce Loehle-Conger
>> >> >>
>> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> >> >> news:79CA374D-729B-4181-8F45-5D61FCF30F28@.microsoft.com...
>> >> >> > And, if I blow away the 2nd dataset and just give my 1st one
>> >> >> > parameters,
>> >> >> > it
>> >> >> > almost works. EXEC db.dbo.procname 1 for chunk one of the
>> >> >> > results,
>> >> >> > works
>> >> >> > just fine. if i change the parameter to 2, 3 or 4, when I hit
>> >> >> > RUN
>> >> >> > in
>> >> >> > Data
>> >> >> > tab it returns an error: SQL Syntax Errors Encountered...The
>> >> >> > designer
>> >> >> > does
>> >> >> > not graphically support the EXEC SQL Construct' but, i hit
>> >> >> > 'OK'
>> >> >> > and
>> >> >> > my
>> >> >> > results are still returned to me. On 'Preview' tab, however, I
>> >> >> > get
>> >> >> > no
>> >> >> > data/results at all.
>> >> >> > -- Lynn
>> >> >> >
>> >> >> >
>> >> >> > "Bruce L-C [MVP]" wrote:
>> >> >> >
>> >> >> >> Yes, you are calling it three times. In RS you create three
>> >> >> >> datasets.
>> >> >> >> Go
>> >> >> >> to
>> >> >> >> the dataset tab and there is a combo box with the name of the
>> >> >> >> dataset,
>> >> >> >> you
>> >> >> >> can click on that and there is a an option for a new.
>> >> >> >>
>> >> >> >> In your stored procedure
>> >> >> >>
>> >> >> >> if @.WHICHRESULTSET = 1
>> >> >> >> begin
>> >> >> >> --return the first resultset here
>> >> >> >> end
>> >> >> >> etc
>> >> >> >>
>> >> >> >>
>> >> >> >> --
>> >> >> >> Bruce Loehle-Conger
>> >> >> >> MVP SQL Server Reporting Services
>> >> >> >>
>> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> >> >> >> news:81E3A442-6694-442D-B151-F083E4750ADB@.microsoft.com...
>> >> >> >> > Bruce, or somebody else, might you give me an example of how
>> >> >> >> > to
>> >> >> >> > give
>> >> >> >> > the
>> >> >> >> > proc
>> >> >> >> > 3 parameters, producing three resultsets in a way that RS will
>> >> >> >> > display
>> >> >> >> > them?
>> >> >> >> > Or, am I giving it three parameters and calling it three
>> >> >> >> > times?
>> >> >> >> > If
>> >> >> >> > so,
>> >> >> >> > how
>> >> >> >> > would i call the 3 procs in RS?
>> >> >> >> > -- Lynn
>> >> >> >> >
>> >> >> >> >
>> >> >> >> > "Bruce L-C [MVP]" wrote:
>> >> >> >> >
>> >> >> >> >> Configure your existing stored procedure to accept a
>> >> >> >> >> parameter
>> >> >> >> >> (you
>> >> >> >> >> can
>> >> >> >> >> make
>> >> >> >> >> it optional so that it doesn't break existing code).
>> >> >> >> >>
>> >> >> >> >> Then call it three times in RS with a static value and create
>> >> >> >> >> three
>> >> >> >> >> datasets.
>> >> >> >> >> For instance dataset1
>> >> >> >> >> yourproc 1
>> >> >> >> >>
>> >> >> >> >> Dataset2
>> >> >> >> >> yourproc 2
>> >> >> >> >>
>> >> >> >> >> etc.
>> >> >> >> >>
>> >> >> >> >> Then in your stored procedure return the appropriate
>> >> >> >> >> resultset
>> >> >> >> >> based
>> >> >> >> >> on
>> >> >> >> >> the
>> >> >> >> >> parameter.
>> >> >> >> >>
>> >> >> >> >> Downside is that your sp is being run three times.
>> >> >> >> >>
>> >> >> >> >>
>> >> >> >> >> --
>> >> >> >> >> Bruce Loehle-Conger
>> >> >> >> >> MVP SQL Server Reporting Services
>> >> >> >> >>
>> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> >> >> >> >> news:E8E34B6C-A36A-4576-BE8C-AB61866EEC80@.microsoft.com...
>> >> >> >> >> > Bruce, I'm not sure I follow. Can you elaborate a little
>> >> >> >> >> > more,
>> >> >> >> >> > please,
>> >> >> >> >> > on
>> >> >> >> >> > the second, possibly third procedure?
>> >> >> >> >> > -- Lynn
>> >> >> >> >> >
>> >> >> >> >> >
>> >> >> >> >> > "Bruce L-C [MVP]" wrote:
>> >> >> >> >> >
>> >> >> >> >> >> This is three resultsets. RS does not have the ability to
>> >> >> >> >> >> handle
>> >> >> >> >> >> that.
>> >> >> >> >> >> There
>> >> >> >> >> >> is no work around from RS side. You could create another
>> >> >> >> >> >> stored
>> >> >> >> >> >> procedure
>> >> >> >> >> >> that calls this one and have it return just one of the
>> >> >> >> >> >> resultsets.
>> >> >> >> >> >>
>> >> >> >> >> >> RS can deal with multiple datasets quite well, but each
>> >> >> >> >> >> stored
>> >> >> >> >> >> procedure
>> >> >> >> >> >> call can only return one.
>> >> >> >> >> >>
>> >> >> >> >> >>
>> >> >> >> >> >> --
>> >> >> >> >> >> Bruce Loehle-Conger
>> >> >> >> >> >> MVP SQL Server Reporting Services
>> >> >> >> >> >>
>> >> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> >> >> >> >> >> news:E1AFA910-1FF4-4DC8-A3F0-FC1EADE8DFD5@.microsoft.com...
>> >> >> >> >> >> > oh, bruce, that is great. I can't believe it was as
>> >> >> >> >> >> > simple
>> >> >> >> >> >> > as
>> >> >> >> >> >> > that.
>> >> >> >> >> >> > one
>> >> >> >> >> >> > remaining problem, though. one of my reports is like
>> >> >> >> >> >> > this:
>> >> >> >> >> >> >
>> >> >> >> >> >> > Date Total Trades Symbols Traded Total $
>> >> >> >> >> >> > -- -- -- --
>> >> >> >> >> >> > 02/07/2006 333,333 333
>> >> >> >> >> >> > 33,333,333,333.33
>> >> >> >> >> >> >
>> >> >> >> >> >> > #Stocks Volume Total $
>> >> >> >> >> >> > -- -- --
>> >> >> >> >> >> > 333,333 33,333,333 3,333,333,333.33
>> >> >> >> >> >> >
>> >> >> >> >> >> > EndPoint Liquidity #Trades Volume
>> >> >> >> >> >> > Total $
>> >> >> >> >> >> > -- -- -- -- --
>> >> >> >> >> >> > AAAA Add 114,729 21,797,575
>> >> >> >> >> >> > 583,102,631.33
>> >> >> >> >> >> > AAAA Opening 1 27
>> >> >> >> >> >> > 3,412.53
>> >> >> >> >> >> > AAAA Remove 30,836 8,330,843
>> >> >> >> >> >> > 444,521,928.10
>> >> >> >> >> >> > AAAA Route 41 4,543
>> >> >> >> >> >> > 103,291.31
>> >> >> >> >> >> > BBBB Add 26,997 9,940,201
>> >> >> >> >> >> > 178,600,674.78
>> >> >> >> >> >> > BBBB Opening 8,089 1,448,143
>> >> >> >> >> >> > 44,276,419.41
>> >> >> >> >> >> > BBBB Remove 3,406 1,719,403
>> >> >> >> >> >> > 40,267,318.25
>> >> >> >> >> >> > CCCC Add 83,781 22,443,732
>> >> >> >> >> >> > 746,570,071.43
>> >> >> >> >> >> > CCCC Remove 35,756 12,250,359
>> >> >> >> >> >> > 483,329,796.97
>> >> >> >> >> >> > CCCC Route 1,088 244,697
>> >> >> >> >> >> > 6,655,913.26
>> >> >> >> >> >> > DDDD Route 2 62,500
>> >> >> >> >> >> > 2,539,375.00
>> >> >> >> >> >> > DDDD Add 2,354 1,262,589
>> >> >> >> >> >> > 19,136,233.44
>> >> >> >> >> >> > DDDD Remove 258 195,019
>> >> >> >> >> >> > 6,227,451.69
>> >> >> >> >> >> >
>> >> >> >> >> >> > I only receive the top line in the resultset:
>> >> >> >> >> >> >
>> >> >> >> >> >> > Date Total Trades Symbols Traded Total $
>> >> >> >> >> >> > -- -- -- --
>> >> >> >> >> >> > 02/07/2006 333,333 333
>> >> >> >> >> >> > 33,333,333,333.33
>> >> >> >> >> >> >
>> >> >> >> >> >> > I assume this is what you mean when you say it will only
>> >> >> >> >> >> > handle
>> >> >> >> >> >> > the
>> >> >> >> >> >> > 1st
>> >> >> >> >> >> > resultset. All of my reports have multiple 'chunks' in
>> >> >> >> >> >> > the
>> >> >> >> >> >> > body.
>> >> >> >> >> >> > Do
>> >> >> >> >> >> > you
>> >> >> >> >> >> > have any idea how I can achieve this report via
>> >> >> >> >> >> > reporting
>> >> >> >> >> >> > svcs?
>> >> >> >> >> >> > Unfortunately, this is very important. Please do
>> >> >> >> >> >> > advise.
>> >> >> >> >> >> >
>> >> >> >> >> >> > --Lynn
>> >> >> >> >> >> >
>> >> >> >> >> >> >
>> >> >> >> >> >> > "Bruce L-C [MVP]" wrote:
>> >> >> >> >> >> >
>> >> >> >> >> >> >> Pick the command type as stored procedure and then just
>> >> >> >> >> >> >> enter
>> >> >> >> >> >> >> the
>> >> >> >> >> >> >> name
>> >> >> >> >> >> >> of
>> >> >> >> >> >> >> the stored procedure. When you click on the ! you
>> >> >> >> >> >> >> should
>> >> >> >> >> >> >> get
>> >> >> >> >> >> >> back|||Bruce, every time I refresh the fields, it pops the 1st three back in the
list. They're the first three in the report, and i guess they're the only
ones in that first resultset. So, I go into dataset 2, 3 and 4, all the same
3 fields are listed. i remove them per dataset, hit refresh, and the same 3
come back.
-- Lynn
"Bruce L-C [MVP]" wrote:
> For each of your datasets make sure there is a field list. Sometimes you
> have to click on the refresh fields button (to the right of the ...).
> --
> Bruce Loehle-Conger
> MVP SQL Server Reporting Services
> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> news:17C0ED6F-0E4A-4033-A1A2-A841AA7BBECF@.microsoft.com...
> > oh my goodness this is frustrating me....i did what you said, bruce, and
> > it
> > almost worked. the preview report shows me three values which correspond,
> > i
> > believe, to the only three fields in my report. see, they're all
> > calculated
> > fields. the output of the rpt is this:
> >
> > Build complete -- 0 errors, 0 warnings
> > The data set 'DataSet3' contains a definition for the field
> > 'Futures_Volume'. This field is missing from the returned result set from
> > the
> > data source.
> > The data set 'DataSet4' contains a definition for the field
> > 'Futures_Volume'. This field is missing from the returned result set from
> > the
> > data source.
> > The data set 'DataSet2' contains a definition for the field
> > 'Futures_Volume'. This field is missing from the returned result set from
> > the
> > data source.
> > Preview complete -- 0 errors, 3 warnings
> >
> > Now, I created the4 datasets, the parameter for each is simply 1, 2, 3 and
> > 4. The report, or the query, is not auto-generating my other fields as it
> > did for three that I do see. The 'Futures_Volume' is one of the fields
> > that
> > was auto-generated for me, and it is in the 1st dataset. Is it that I
> > just
> > need to manually add in the other fields? Please do let me know what you
> > think.
> >
> > and thank you, bruce, for helping me through this. i truly do appreciate
> > it. i know i am close...and i got the other reports for my server jobs
> > and
> > one of the other company reports to work. it's just these multi-resultset
> > reports are fighting me.
> > -- Lynn
> >
> >
> > "Bruce L-C [MVP]" wrote:
> >
> >> Query parameters and report parameters seem to be the same thing but they
> >> are not. RS automatically creates a report parameter for each query
> >> parameter but instead you can map the query parameter to a constant.
> >> Click
> >> on the ... for the dataset, go to the parameters tab. On the right you
> >> will
> >> see it mapping to the report parameter, click on that and select
> >> expression.
> >> In expression put = 1 (assuming it is an integert expression) for the
> >> first
> >> dataset, =2 etc. Then go to report layout, report menu-> report
> >> parameters
> >> and then delete the report parameters created for you.
> >>
> >> You are very very close to the solution.
> >>
> >> --
> >> Bruce Loehle-Conger
> >> MVP SQL Server Reporting Services
> >>
> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> news:61E1ED5C-B204-4024-9DC4-82635AEBD912@.microsoft.com...
> >> > last one for a while, bruce, i promise. i've got all 4 datasets in
> >> > there,
> >> > each asks me for a parameter, i put 1,2,3 and 4 into each, getting my
> >> > 'whole
> >> > report' in four small subsets of data. how do i get this to happen on
> >> > the
> >> > report page automatically without needing user input?
> >> > -- Lynn
> >> >
> >> >
> >> > "Bruce L-C [MVP]" wrote:
> >> >
> >> >> Are you going against SQL Server?
> >> >>
> >> >> If so, then just select tored procedure for the command type and just
> >> >> put
> >> >> in
> >> >> the name of the stored procedure. Do not put exec in from of it or
> >> >> anything
> >> >> else. It should detect the parameter and prompt you for it. It should
> >> >> also
> >> >> create a report parameter as well for you.
> >> >>
> >> >> Try creating a new dataset and do this from the start. If you continue
> >> >> to
> >> >> have problems create a new stored procedure just for testing .
> >> >>
> >> >> create procedure dbo.testproc
> >> >> @.PARAM1 int
> >> >> as
> >> >> select 'Parameter passed in = ' + @.PARAM1 as Message
> >> >> return
> >> >>
> >> >> Get the above procedure to work for you so you know how to call a
> >> >> stored
> >> >> procedure they way I am telling you (do not use exec).
> >> >>
> >> >>
> >> >> --
> >> >> Bruce Loehle-Conger
> >> >> MVP SQL Server Reporting Services
> >> >> --
> >> >> Bruce Loehle-Conger
> >> >> MVP SQL Server Reporting Services
> >> >>
> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> news:9B089D7B-1F23-465B-B443-08BD09469A3E@.microsoft.com...
> >> >> > i'm sorry, bruce, but where do i define the parameters? rs is not
> >> >> > detecting
> >> >> > them. in my 1st dataset i've got cmd type stored procedure and the
> >> >> > proc
> >> >> > name
> >> >> > is in the query string. i assumed i would put the 1st parameter in
> >> >> > on
> >> >> > the
> >> >> > parameters tab and then do the same for 2, 3 and 4 on 3 other
> >> >> > datasets,
> >> >> > so
> >> >> > i
> >> >> > gave it @.ch and the value of 1, but when i attempted to run it, it
> >> >> > threw
> >> >> > me a
> >> >> > 'define query parameters box asking me to put the '1' in it.
> >> >> > -- Lynn
> >> >> >
> >> >> >
> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >
> >> >> >> If you are going against SQL Server do not run your stored
> >> >> >> procedure
> >> >> >> this
> >> >> >> way. Pick command type of stored procedure. RS will detect the
> >> >> >> parameters.
> >> >> >> If going against ODBC or OLEDB driver (which uses ? format for
> >> >> >> parameters)
> >> >> >> then pick text as the command type and do this:
> >> >> >> myproc ?
> >> >> >>
> >> >> >> Create multiple datasets and for each one you should call the
> >> >> >> stored
> >> >> >> procedure for each one.
> >> >> >>
> >> >> >> Bruce Loehle-Conger
> >> >> >>
> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> news:79CA374D-729B-4181-8F45-5D61FCF30F28@.microsoft.com...
> >> >> >> > And, if I blow away the 2nd dataset and just give my 1st one
> >> >> >> > parameters,
> >> >> >> > it
> >> >> >> > almost works. EXEC db.dbo.procname 1 for chunk one of the
> >> >> >> > results,
> >> >> >> > works
> >> >> >> > just fine. if i change the parameter to 2, 3 or 4, when I hit
> >> >> >> > RUN
> >> >> >> > in
> >> >> >> > Data
> >> >> >> > tab it returns an error: SQL Syntax Errors Encountered...The
> >> >> >> > designer
> >> >> >> > does
> >> >> >> > not graphically support the EXEC SQL Construct' but, i hit
> >> >> >> > 'OK'
> >> >> >> > and
> >> >> >> > my
> >> >> >> > results are still returned to me. On 'Preview' tab, however, I
> >> >> >> > get
> >> >> >> > no
> >> >> >> > data/results at all.
> >> >> >> > -- Lynn
> >> >> >> >
> >> >> >> >
> >> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >> >
> >> >> >> >> Yes, you are calling it three times. In RS you create three
> >> >> >> >> datasets.
> >> >> >> >> Go
> >> >> >> >> to
> >> >> >> >> the dataset tab and there is a combo box with the name of the
> >> >> >> >> dataset,
> >> >> >> >> you
> >> >> >> >> can click on that and there is a an option for a new.
> >> >> >> >>
> >> >> >> >> In your stored procedure
> >> >> >> >>
> >> >> >> >> if @.WHICHRESULTSET = 1
> >> >> >> >> begin
> >> >> >> >> --return the first resultset here
> >> >> >> >> end
> >> >> >> >> etc
> >> >> >> >>
> >> >> >> >>
> >> >> >> >> --
> >> >> >> >> Bruce Loehle-Conger
> >> >> >> >> MVP SQL Server Reporting Services
> >> >> >> >>
> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> >> news:81E3A442-6694-442D-B151-F083E4750ADB@.microsoft.com...
> >> >> >> >> > Bruce, or somebody else, might you give me an example of how
> >> >> >> >> > to
> >> >> >> >> > give
> >> >> >> >> > the
> >> >> >> >> > proc
> >> >> >> >> > 3 parameters, producing three resultsets in a way that RS will
> >> >> >> >> > display
> >> >> >> >> > them?
> >> >> >> >> > Or, am I giving it three parameters and calling it three
> >> >> >> >> > times?
> >> >> >> >> > If
> >> >> >> >> > so,
> >> >> >> >> > how
> >> >> >> >> > would i call the 3 procs in RS?
> >> >> >> >> > -- Lynn
> >> >> >> >> >
> >> >> >> >> >
> >> >> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >> >> >
> >> >> >> >> >> Configure your existing stored procedure to accept a
> >> >> >> >> >> parameter
> >> >> >> >> >> (you
> >> >> >> >> >> can
> >> >> >> >> >> make
> >> >> >> >> >> it optional so that it doesn't break existing code).
> >> >> >> >> >>
> >> >> >> >> >> Then call it three times in RS with a static value and create
> >> >> >> >> >> three
> >> >> >> >> >> datasets.
> >> >> >> >> >> For instance dataset1
> >> >> >> >> >> yourproc 1
> >> >> >> >> >>
> >> >> >> >> >> Dataset2
> >> >> >> >> >> yourproc 2
> >> >> >> >> >>
> >> >> >> >> >> etc.
> >> >> >> >> >>
> >> >> >> >> >> Then in your stored procedure return the appropriate
> >> >> >> >> >> resultset
> >> >> >> >> >> based
> >> >> >> >> >> on
> >> >> >> >> >> the
> >> >> >> >> >> parameter.
> >> >> >> >> >>
> >> >> >> >> >> Downside is that your sp is being run three times.
> >> >> >> >> >>
> >> >> >> >> >>
> >> >> >> >> >> --
> >> >> >> >> >> Bruce Loehle-Conger
> >> >> >> >> >> MVP SQL Server Reporting Services
> >> >> >> >> >>
> >> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> >> >> news:E8E34B6C-A36A-4576-BE8C-AB61866EEC80@.microsoft.com...
> >> >> >> >> >> > Bruce, I'm not sure I follow. Can you elaborate a little
> >> >> >> >> >> > more,
> >> >> >> >> >> > please,
> >> >> >> >> >> > on
> >> >> >> >> >> > the second, possibly third procedure?
> >> >> >> >> >> > -- Lynn
> >> >> >> >> >> >
> >> >> >> >> >> >
> >> >> >> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >> >> >> >
> >> >> >> >> >> >> This is three resultsets. RS does not have the ability to
> >> >> >> >> >> >> handle
> >> >> >> >> >> >> that.
> >> >> >> >> >> >> There
> >> >> >> >> >> >> is no work around from RS side. You could create another
> >> >> >> >> >> >> stored
> >> >> >> >> >> >> procedure
> >> >> >> >> >> >> that calls this one and have it return just one of the
> >> >> >> >> >> >> resultsets.
> >> >> >> >> >> >>
> >> >> >> >> >> >> RS can deal with multiple datasets quite well, but each
> >> >> >> >> >> >> stored
> >> >> >> >> >> >> procedure
> >> >> >> >> >> >> call can only return one.
> >> >> >> >> >> >>
> >> >> >> >> >> >>
> >> >> >> >> >> >> --
> >> >> >> >> >> >> Bruce Loehle-Conger
> >> >> >> >> >> >> MVP SQL Server Reporting Services
> >> >> >> >> >> >>
> >> >> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> >> >> >> news:E1AFA910-1FF4-4DC8-A3F0-FC1EADE8DFD5@.microsoft.com...
> >> >> >> >> >> >> > oh, bruce, that is great. I can't believe it was as
> >> >> >> >> >> >> > simple
> >> >> >> >> >> >> > as
> >> >> >> >> >> >> > that.
> >> >> >> >> >> >> > one
> >> >> >> >> >> >> > remaining problem, though. one of my reports is like|||Ok, what is happening is that it is detecting the first resultset. What you
can do it is add the fields manually. In the field list add a new field and
name it correctly for what will be coming back. (Right mouse click in the
field list).
Bruce Loehle-Conger
MVP SQL Server Reporting Services
"Lynn" <Lynn@.discussions.microsoft.com> wrote in message
news:D5EEA5C8-DB3A-4DB3-ADE6-D8092373DC46@.microsoft.com...
> Bruce, every time I refresh the fields, it pops the 1st three back in the
> list. They're the first three in the report, and i guess they're the only
> ones in that first resultset. So, I go into dataset 2, 3 and 4, all the
> same
> 3 fields are listed. i remove them per dataset, hit refresh, and the same
> 3
> come back.
> -- Lynn
>
> "Bruce L-C [MVP]" wrote:
>> For each of your datasets make sure there is a field list. Sometimes you
>> have to click on the refresh fields button (to the right of the ...).
>> --
>> Bruce Loehle-Conger
>> MVP SQL Server Reporting Services
>> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> news:17C0ED6F-0E4A-4033-A1A2-A841AA7BBECF@.microsoft.com...
>> > oh my goodness this is frustrating me....i did what you said, bruce,
>> > and
>> > it
>> > almost worked. the preview report shows me three values which
>> > correspond,
>> > i
>> > believe, to the only three fields in my report. see, they're all
>> > calculated
>> > fields. the output of the rpt is this:
>> >
>> > Build complete -- 0 errors, 0 warnings
>> > The data set 'DataSet3' contains a definition for the field
>> > 'Futures_Volume'. This field is missing from the returned result set
>> > from
>> > the
>> > data source.
>> > The data set 'DataSet4' contains a definition for the field
>> > 'Futures_Volume'. This field is missing from the returned result set
>> > from
>> > the
>> > data source.
>> > The data set 'DataSet2' contains a definition for the field
>> > 'Futures_Volume'. This field is missing from the returned result set
>> > from
>> > the
>> > data source.
>> > Preview complete -- 0 errors, 3 warnings
>> >
>> > Now, I created the4 datasets, the parameter for each is simply 1, 2, 3
>> > and
>> > 4. The report, or the query, is not auto-generating my other fields as
>> > it
>> > did for three that I do see. The 'Futures_Volume' is one of the fields
>> > that
>> > was auto-generated for me, and it is in the 1st dataset. Is it that I
>> > just
>> > need to manually add in the other fields? Please do let me know what
>> > you
>> > think.
>> >
>> > and thank you, bruce, for helping me through this. i truly do
>> > appreciate
>> > it. i know i am close...and i got the other reports for my server jobs
>> > and
>> > one of the other company reports to work. it's just these
>> > multi-resultset
>> > reports are fighting me.
>> > -- Lynn
>> >
>> >
>> > "Bruce L-C [MVP]" wrote:
>> >
>> >> Query parameters and report parameters seem to be the same thing but
>> >> they
>> >> are not. RS automatically creates a report parameter for each query
>> >> parameter but instead you can map the query parameter to a constant.
>> >> Click
>> >> on the ... for the dataset, go to the parameters tab. On the right you
>> >> will
>> >> see it mapping to the report parameter, click on that and select
>> >> expression.
>> >> In expression put = 1 (assuming it is an integert expression) for the
>> >> first
>> >> dataset, =2 etc. Then go to report layout, report menu-> report
>> >> parameters
>> >> and then delete the report parameters created for you.
>> >>
>> >> You are very very close to the solution.
>> >>
>> >> --
>> >> Bruce Loehle-Conger
>> >> MVP SQL Server Reporting Services
>> >>
>> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> >> news:61E1ED5C-B204-4024-9DC4-82635AEBD912@.microsoft.com...
>> >> > last one for a while, bruce, i promise. i've got all 4 datasets in
>> >> > there,
>> >> > each asks me for a parameter, i put 1,2,3 and 4 into each, getting
>> >> > my
>> >> > 'whole
>> >> > report' in four small subsets of data. how do i get this to happen
>> >> > on
>> >> > the
>> >> > report page automatically without needing user input?
>> >> > -- Lynn
>> >> >
>> >> >
>> >> > "Bruce L-C [MVP]" wrote:
>> >> >
>> >> >> Are you going against SQL Server?
>> >> >>
>> >> >> If so, then just select tored procedure for the command type and
>> >> >> just
>> >> >> put
>> >> >> in
>> >> >> the name of the stored procedure. Do not put exec in from of it or
>> >> >> anything
>> >> >> else. It should detect the parameter and prompt you for it. It
>> >> >> should
>> >> >> also
>> >> >> create a report parameter as well for you.
>> >> >>
>> >> >> Try creating a new dataset and do this from the start. If you
>> >> >> continue
>> >> >> to
>> >> >> have problems create a new stored procedure just for testing .
>> >> >>
>> >> >> create procedure dbo.testproc
>> >> >> @.PARAM1 int
>> >> >> as
>> >> >> select 'Parameter passed in = ' + @.PARAM1 as Message
>> >> >> return
>> >> >>
>> >> >> Get the above procedure to work for you so you know how to call a
>> >> >> stored
>> >> >> procedure they way I am telling you (do not use exec).
>> >> >>
>> >> >>
>> >> >> --
>> >> >> Bruce Loehle-Conger
>> >> >> MVP SQL Server Reporting Services
>> >> >> --
>> >> >> Bruce Loehle-Conger
>> >> >> MVP SQL Server Reporting Services
>> >> >>
>> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> >> >> news:9B089D7B-1F23-465B-B443-08BD09469A3E@.microsoft.com...
>> >> >> > i'm sorry, bruce, but where do i define the parameters? rs is
>> >> >> > not
>> >> >> > detecting
>> >> >> > them. in my 1st dataset i've got cmd type stored procedure and
>> >> >> > the
>> >> >> > proc
>> >> >> > name
>> >> >> > is in the query string. i assumed i would put the 1st parameter
>> >> >> > in
>> >> >> > on
>> >> >> > the
>> >> >> > parameters tab and then do the same for 2, 3 and 4 on 3 other
>> >> >> > datasets,
>> >> >> > so
>> >> >> > i
>> >> >> > gave it @.ch and the value of 1, but when i attempted to run it,
>> >> >> > it
>> >> >> > threw
>> >> >> > me a
>> >> >> > 'define query parameters box asking me to put the '1' in it.
>> >> >> > -- Lynn
>> >> >> >
>> >> >> >
>> >> >> > "Bruce L-C [MVP]" wrote:
>> >> >> >
>> >> >> >> If you are going against SQL Server do not run your stored
>> >> >> >> procedure
>> >> >> >> this
>> >> >> >> way. Pick command type of stored procedure. RS will detect the
>> >> >> >> parameters.
>> >> >> >> If going against ODBC or OLEDB driver (which uses ? format for
>> >> >> >> parameters)
>> >> >> >> then pick text as the command type and do this:
>> >> >> >> myproc ?
>> >> >> >>
>> >> >> >> Create multiple datasets and for each one you should call the
>> >> >> >> stored
>> >> >> >> procedure for each one.
>> >> >> >>
>> >> >> >> Bruce Loehle-Conger
>> >> >> >>
>> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> >> >> >> news:79CA374D-729B-4181-8F45-5D61FCF30F28@.microsoft.com...
>> >> >> >> > And, if I blow away the 2nd dataset and just give my 1st one
>> >> >> >> > parameters,
>> >> >> >> > it
>> >> >> >> > almost works. EXEC db.dbo.procname 1 for chunk one of the
>> >> >> >> > results,
>> >> >> >> > works
>> >> >> >> > just fine. if i change the parameter to 2, 3 or 4, when I hit
>> >> >> >> > RUN
>> >> >> >> > in
>> >> >> >> > Data
>> >> >> >> > tab it returns an error: SQL Syntax Errors Encountered...The
>> >> >> >> > designer
>> >> >> >> > does
>> >> >> >> > not graphically support the EXEC SQL Construct' but, i hit
>> >> >> >> > 'OK'
>> >> >> >> > and
>> >> >> >> > my
>> >> >> >> > results are still returned to me. On 'Preview' tab, however,
>> >> >> >> > I
>> >> >> >> > get
>> >> >> >> > no
>> >> >> >> > data/results at all.
>> >> >> >> > -- Lynn
>> >> >> >> >
>> >> >> >> >
>> >> >> >> > "Bruce L-C [MVP]" wrote:
>> >> >> >> >
>> >> >> >> >> Yes, you are calling it three times. In RS you create three
>> >> >> >> >> datasets.
>> >> >> >> >> Go
>> >> >> >> >> to
>> >> >> >> >> the dataset tab and there is a combo box with the name of the
>> >> >> >> >> dataset,
>> >> >> >> >> you
>> >> >> >> >> can click on that and there is a an option for a new.
>> >> >> >> >>
>> >> >> >> >> In your stored procedure
>> >> >> >> >>
>> >> >> >> >> if @.WHICHRESULTSET = 1
>> >> >> >> >> begin
>> >> >> >> >> --return the first resultset here
>> >> >> >> >> end
>> >> >> >> >> etc
>> >> >> >> >>
>> >> >> >> >>
>> >> >> >> >> --
>> >> >> >> >> Bruce Loehle-Conger
>> >> >> >> >> MVP SQL Server Reporting Services
>> >> >> >> >>
>> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> >> >> >> >> news:81E3A442-6694-442D-B151-F083E4750ADB@.microsoft.com...
>> >> >> >> >> > Bruce, or somebody else, might you give me an example of
>> >> >> >> >> > how
>> >> >> >> >> > to
>> >> >> >> >> > give
>> >> >> >> >> > the
>> >> >> >> >> > proc
>> >> >> >> >> > 3 parameters, producing three resultsets in a way that RS
>> >> >> >> >> > will
>> >> >> >> >> > display
>> >> >> >> >> > them?
>> >> >> >> >> > Or, am I giving it three parameters and calling it three
>> >> >> >> >> > times?
>> >> >> >> >> > If
>> >> >> >> >> > so,
>> >> >> >> >> > how
>> >> >> >> >> > would i call the 3 procs in RS?
>> >> >> >> >> > -- Lynn
>> >> >> >> >> >
>> >> >> >> >> >
>> >> >> >> >> > "Bruce L-C [MVP]" wrote:
>> >> >> >> >> >
>> >> >> >> >> >> Configure your existing stored procedure to accept a
>> >> >> >> >> >> parameter
>> >> >> >> >> >> (you
>> >> >> >> >> >> can
>> >> >> >> >> >> make
>> >> >> >> >> >> it optional so that it doesn't break existing code).
>> >> >> >> >> >>
>> >> >> >> >> >> Then call it three times in RS with a static value and
>> >> >> >> >> >> create
>> >> >> >> >> >> three
>> >> >> >> >> >> datasets.
>> >> >> >> >> >> For instance dataset1
>> >> >> >> >> >> yourproc 1
>> >> >> >> >> >>
>> >> >> >> >> >> Dataset2
>> >> >> >> >> >> yourproc 2
>> >> >> >> >> >>
>> >> >> >> >> >> etc.
>> >> >> >> >> >>
>> >> >> >> >> >> Then in your stored procedure return the appropriate
>> >> >> >> >> >> resultset
>> >> >> >> >> >> based
>> >> >> >> >> >> on
>> >> >> >> >> >> the
>> >> >> >> >> >> parameter.
>> >> >> >> >> >>
>> >> >> >> >> >> Downside is that your sp is being run three times.
>> >> >> >> >> >>
>> >> >> >> >> >>
>> >> >> >> >> >> --
>> >> >> >> >> >> Bruce Loehle-Conger
>> >> >> >> >> >> MVP SQL Server Reporting Services
>> >> >> >> >> >>
>> >> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> >> >> >> >> >> news:E8E34B6C-A36A-4576-BE8C-AB61866EEC80@.microsoft.com...
>> >> >> >> >> >> > Bruce, I'm not sure I follow. Can you elaborate a
>> >> >> >> >> >> > little
>> >> >> >> >> >> > more,
>> >> >> >> >> >> > please,
>> >> >> >> >> >> > on
>> >> >> >> >> >> > the second, possibly third procedure?
>> >> >> >> >> >> > -- Lynn
>> >> >> >> >> >> >
>> >> >> >> >> >> >
>> >> >> >> >> >> > "Bruce L-C [MVP]" wrote:
>> >> >> >> >> >> >
>> >> >> >> >> >> >> This is three resultsets. RS does not have the ability
>> >> >> >> >> >> >> to
>> >> >> >> >> >> >> handle
>> >> >> >> >> >> >> that.
>> >> >> >> >> >> >> There
>> >> >> >> >> >> >> is no work around from RS side. You could create
>> >> >> >> >> >> >> another
>> >> >> >> >> >> >> stored
>> >> >> >> >> >> >> procedure
>> >> >> >> >> >> >> that calls this one and have it return just one of the
>> >> >> >> >> >> >> resultsets.
>> >> >> >> >> >> >>
>> >> >> >> >> >> >> RS can deal with multiple datasets quite well, but each
>> >> >> >> >> >> >> stored
>> >> >> >> >> >> >> procedure
>> >> >> >> >> >> >> call can only return one.
>> >> >> >> >> >> >>
>> >> >> >> >> >> >>
>> >> >> >> >> >> >> --
>> >> >> >> >> >> >> Bruce Loehle-Conger
>> >> >> >> >> >> >> MVP SQL Server Reporting Services
>> >> >> >> >> >> >>
>> >> >> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in
>> >> >> >> >> >> >> message
>> >> >> >> >> >> >> news:E1AFA910-1FF4-4DC8-A3F0-FC1EADE8DFD5@.microsoft.com...
>> >> >> >> >> >> >> > oh, bruce, that is great. I can't believe it was as
>> >> >> >> >> >> >> > simple
>> >> >> >> >> >> >> > as
>> >> >> >> >> >> >> > that.
>> >> >> >> >> >> >> > one
>> >> >> >> >> >> >> > remaining problem, though. one of my reports is like|||yep, i had tried this last week, but it failed w/ a cpl different errors. i
will try it again right now.
-- Lynn
"Bruce L-C [MVP]" wrote:
> Ok, what is happening is that it is detecting the first resultset. What you
> can do it is add the fields manually. In the field list add a new field and
> name it correctly for what will be coming back. (Right mouse click in the
> field list).
>
> --
> Bruce Loehle-Conger
> MVP SQL Server Reporting Services
> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> news:D5EEA5C8-DB3A-4DB3-ADE6-D8092373DC46@.microsoft.com...
> > Bruce, every time I refresh the fields, it pops the 1st three back in the
> > list. They're the first three in the report, and i guess they're the only
> > ones in that first resultset. So, I go into dataset 2, 3 and 4, all the
> > same
> > 3 fields are listed. i remove them per dataset, hit refresh, and the same
> > 3
> > come back.
> > -- Lynn
> >
> >
> > "Bruce L-C [MVP]" wrote:
> >
> >> For each of your datasets make sure there is a field list. Sometimes you
> >> have to click on the refresh fields button (to the right of the ...).
> >>
> >> --
> >> Bruce Loehle-Conger
> >> MVP SQL Server Reporting Services
> >>
> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> news:17C0ED6F-0E4A-4033-A1A2-A841AA7BBECF@.microsoft.com...
> >> > oh my goodness this is frustrating me....i did what you said, bruce,
> >> > and
> >> > it
> >> > almost worked. the preview report shows me three values which
> >> > correspond,
> >> > i
> >> > believe, to the only three fields in my report. see, they're all
> >> > calculated
> >> > fields. the output of the rpt is this:
> >> >
> >> > Build complete -- 0 errors, 0 warnings
> >> > The data set 'DataSet3' contains a definition for the field
> >> > 'Futures_Volume'. This field is missing from the returned result set
> >> > from
> >> > the
> >> > data source.
> >> > The data set 'DataSet4' contains a definition for the field
> >> > 'Futures_Volume'. This field is missing from the returned result set
> >> > from
> >> > the
> >> > data source.
> >> > The data set 'DataSet2' contains a definition for the field
> >> > 'Futures_Volume'. This field is missing from the returned result set
> >> > from
> >> > the
> >> > data source.
> >> > Preview complete -- 0 errors, 3 warnings
> >> >
> >> > Now, I created the4 datasets, the parameter for each is simply 1, 2, 3
> >> > and
> >> > 4. The report, or the query, is not auto-generating my other fields as
> >> > it
> >> > did for three that I do see. The 'Futures_Volume' is one of the fields
> >> > that
> >> > was auto-generated for me, and it is in the 1st dataset. Is it that I
> >> > just
> >> > need to manually add in the other fields? Please do let me know what
> >> > you
> >> > think.
> >> >
> >> > and thank you, bruce, for helping me through this. i truly do
> >> > appreciate
> >> > it. i know i am close...and i got the other reports for my server jobs
> >> > and
> >> > one of the other company reports to work. it's just these
> >> > multi-resultset
> >> > reports are fighting me.
> >> > -- Lynn
> >> >
> >> >
> >> > "Bruce L-C [MVP]" wrote:
> >> >
> >> >> Query parameters and report parameters seem to be the same thing but
> >> >> they
> >> >> are not. RS automatically creates a report parameter for each query
> >> >> parameter but instead you can map the query parameter to a constant.
> >> >> Click
> >> >> on the ... for the dataset, go to the parameters tab. On the right you
> >> >> will
> >> >> see it mapping to the report parameter, click on that and select
> >> >> expression.
> >> >> In expression put = 1 (assuming it is an integert expression) for the
> >> >> first
> >> >> dataset, =2 etc. Then go to report layout, report menu-> report
> >> >> parameters
> >> >> and then delete the report parameters created for you.
> >> >>
> >> >> You are very very close to the solution.
> >> >>
> >> >> --
> >> >> Bruce Loehle-Conger
> >> >> MVP SQL Server Reporting Services
> >> >>
> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> news:61E1ED5C-B204-4024-9DC4-82635AEBD912@.microsoft.com...
> >> >> > last one for a while, bruce, i promise. i've got all 4 datasets in
> >> >> > there,
> >> >> > each asks me for a parameter, i put 1,2,3 and 4 into each, getting
> >> >> > my
> >> >> > 'whole
> >> >> > report' in four small subsets of data. how do i get this to happen
> >> >> > on
> >> >> > the
> >> >> > report page automatically without needing user input?
> >> >> > -- Lynn
> >> >> >
> >> >> >
> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >
> >> >> >> Are you going against SQL Server?
> >> >> >>
> >> >> >> If so, then just select tored procedure for the command type and
> >> >> >> just
> >> >> >> put
> >> >> >> in
> >> >> >> the name of the stored procedure. Do not put exec in from of it or
> >> >> >> anything
> >> >> >> else. It should detect the parameter and prompt you for it. It
> >> >> >> should
> >> >> >> also
> >> >> >> create a report parameter as well for you.
> >> >> >>
> >> >> >> Try creating a new dataset and do this from the start. If you
> >> >> >> continue
> >> >> >> to
> >> >> >> have problems create a new stored procedure just for testing .
> >> >> >>
> >> >> >> create procedure dbo.testproc
> >> >> >> @.PARAM1 int
> >> >> >> as
> >> >> >> select 'Parameter passed in = ' + @.PARAM1 as Message
> >> >> >> return
> >> >> >>
> >> >> >> Get the above procedure to work for you so you know how to call a
> >> >> >> stored
> >> >> >> procedure they way I am telling you (do not use exec).
> >> >> >>
> >> >> >>
> >> >> >> --
> >> >> >> Bruce Loehle-Conger
> >> >> >> MVP SQL Server Reporting Services
> >> >> >> --
> >> >> >> Bruce Loehle-Conger
> >> >> >> MVP SQL Server Reporting Services
> >> >> >>
> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> news:9B089D7B-1F23-465B-B443-08BD09469A3E@.microsoft.com...
> >> >> >> > i'm sorry, bruce, but where do i define the parameters? rs is
> >> >> >> > not
> >> >> >> > detecting
> >> >> >> > them. in my 1st dataset i've got cmd type stored procedure and
> >> >> >> > the
> >> >> >> > proc
> >> >> >> > name
> >> >> >> > is in the query string. i assumed i would put the 1st parameter
> >> >> >> > in
> >> >> >> > on
> >> >> >> > the
> >> >> >> > parameters tab and then do the same for 2, 3 and 4 on 3 other
> >> >> >> > datasets,
> >> >> >> > so
> >> >> >> > i
> >> >> >> > gave it @.ch and the value of 1, but when i attempted to run it,
> >> >> >> > it
> >> >> >> > threw
> >> >> >> > me a
> >> >> >> > 'define query parameters box asking me to put the '1' in it.
> >> >> >> > -- Lynn
> >> >> >> >
> >> >> >> >
> >> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >> >
> >> >> >> >> If you are going against SQL Server do not run your stored
> >> >> >> >> procedure
> >> >> >> >> this
> >> >> >> >> way. Pick command type of stored procedure. RS will detect the
> >> >> >> >> parameters.
> >> >> >> >> If going against ODBC or OLEDB driver (which uses ? format for
> >> >> >> >> parameters)
> >> >> >> >> then pick text as the command type and do this:
> >> >> >> >> myproc ?
> >> >> >> >>
> >> >> >> >> Create multiple datasets and for each one you should call the
> >> >> >> >> stored
> >> >> >> >> procedure for each one.
> >> >> >> >>
> >> >> >> >> Bruce Loehle-Conger
> >> >> >> >>
> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> >> news:79CA374D-729B-4181-8F45-5D61FCF30F28@.microsoft.com...
> >> >> >> >> > And, if I blow away the 2nd dataset and just give my 1st one
> >> >> >> >> > parameters,
> >> >> >> >> > it
> >> >> >> >> > almost works. EXEC db.dbo.procname 1 for chunk one of the
> >> >> >> >> > results,
> >> >> >> >> > works
> >> >> >> >> > just fine. if i change the parameter to 2, 3 or 4, when I hit
> >> >> >> >> > RUN
> >> >> >> >> > in
> >> >> >> >> > Data
> >> >> >> >> > tab it returns an error: SQL Syntax Errors Encountered...The
> >> >> >> >> > designer
> >> >> >> >> > does
> >> >> >> >> > not graphically support the EXEC SQL Construct' but, i hit
> >> >> >> >> > 'OK'
> >> >> >> >> > and
> >> >> >> >> > my
> >> >> >> >> > results are still returned to me. On 'Preview' tab, however,
> >> >> >> >> > I
> >> >> >> >> > get
> >> >> >> >> > no
> >> >> >> >> > data/results at all.
> >> >> >> >> > -- Lynn
> >> >> >> >> >
> >> >> >> >> >
> >> >> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >> >> >
> >> >> >> >> >> Yes, you are calling it three times. In RS you create three
> >> >> >> >> >> datasets.
> >> >> >> >> >> Go
> >> >> >> >> >> to
> >> >> >> >> >> the dataset tab and there is a combo box with the name of the
> >> >> >> >> >> dataset,
> >> >> >> >> >> you
> >> >> >> >> >> can click on that and there is a an option for a new.
> >> >> >> >> >>
> >> >> >> >> >> In your stored procedure
> >> >> >> >> >>
> >> >> >> >> >> if @.WHICHRESULTSET = 1
> >> >> >> >> >> begin
> >> >> >> >> >> --return the first resultset here
> >> >> >> >> >> end
> >> >> >> >> >> etc
> >> >> >> >> >>
> >> >> >> >> >>
> >> >> >> >> >> --
> >> >> >> >> >> Bruce Loehle-Conger
> >> >> >> >> >> MVP SQL Server Reporting Services
> >> >> >> >> >>
> >> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> >> >> news:81E3A442-6694-442D-B151-F083E4750ADB@.microsoft.com...
> >> >> >> >> >> > Bruce, or somebody else, might you give me an example of
> >> >> >> >> >> > how
> >> >> >> >> >> > to
> >> >> >> >> >> > give
> >> >> >> >> >> > the
> >> >> >> >> >> > proc
> >> >> >> >> >> > 3 parameters, producing three resultsets in a way that RS
> >> >> >> >> >> > will
> >> >> >> >> >> > display
> >> >> >> >> >> > them?
> >> >> >> >> >> > Or, am I giving it three parameters and calling it three
> >> >> >> >> >> > times?
> >> >> >> >> >> > If
> >> >> >> >> >> > so,
> >> >> >> >> >> > how
> >> >> >> >> >> > would i call the 3 procs in RS?
> >> >> >> >> >> > -- Lynn
> >> >> >> >> >> >
> >> >> >> >> >> >
> >> >> >> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >> >> >> >
> >> >> >> >> >> >> Configure your existing stored procedure to accept a
> >> >> >> >> >> >> parameter
> >> >> >> >> >> >> (you
> >> >> >> >> >> >> can
> >> >> >> >> >> >> make
> >> >> >> >> >> >> it optional so that it doesn't break existing code).
> >> >> >> >> >> >>
> >> >> >> >> >> >> Then call it three times in RS with a static value and
> >> >> >> >> >> >> create
> >> >> >> >> >> >> three
> >> >> >> >> >> >> datasets.
> >> >> >> >> >> >> For instance dataset1
> >> >> >> >> >> >> yourproc 1
> >> >> >> >> >> >>
> >> >> >> >> >> >> Dataset2
> >> >> >> >> >> >> yourproc 2
> >> >> >> >> >> >>
> >> >> >> >> >> >> etc.
> >> >> >> >> >> >>
> >> >> >> >> >> >> Then in your stored procedure return the appropriate
> >> >> >> >> >> >> resultset
> >> >> >> >> >> >> based
> >> >> >> >> >> >> on
> >> >> >> >> >> >> the
> >> >> >> >> >> >> parameter.|||Bruce, i apologize, this is going on and on. I attempt to add the fields
in...just as they are in dataset1, except with new values, and it fails with
this:
'The properties for the currently selected item are not valid. Please
correct all errors before continuing.'
Now, all of these values are calculated...Volume (sum of another value), #
of Trades (count of another value), etc...but the same thing applies to
dataset 1, and those fields are listed as database fields, not calculated
fields. please can you tell me what the right way to do this is?
-- Lynn
"Bruce L-C [MVP]" wrote:
> Ok, what is happening is that it is detecting the first resultset. What you
> can do it is add the fields manually. In the field list add a new field and
> name it correctly for what will be coming back. (Right mouse click in the
> field list).
>
> --
> Bruce Loehle-Conger
> MVP SQL Server Reporting Services
> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> news:D5EEA5C8-DB3A-4DB3-ADE6-D8092373DC46@.microsoft.com...
> > Bruce, every time I refresh the fields, it pops the 1st three back in the
> > list. They're the first three in the report, and i guess they're the only
> > ones in that first resultset. So, I go into dataset 2, 3 and 4, all the
> > same
> > 3 fields are listed. i remove them per dataset, hit refresh, and the same
> > 3
> > come back.
> > -- Lynn
> >
> >
> > "Bruce L-C [MVP]" wrote:
> >
> >> For each of your datasets make sure there is a field list. Sometimes you
> >> have to click on the refresh fields button (to the right of the ...).
> >>
> >> --
> >> Bruce Loehle-Conger
> >> MVP SQL Server Reporting Services
> >>
> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> news:17C0ED6F-0E4A-4033-A1A2-A841AA7BBECF@.microsoft.com...
> >> > oh my goodness this is frustrating me....i did what you said, bruce,
> >> > and
> >> > it
> >> > almost worked. the preview report shows me three values which
> >> > correspond,
> >> > i
> >> > believe, to the only three fields in my report. see, they're all
> >> > calculated
> >> > fields. the output of the rpt is this:
> >> >
> >> > Build complete -- 0 errors, 0 warnings
> >> > The data set 'DataSet3' contains a definition for the field
> >> > 'Futures_Volume'. This field is missing from the returned result set
> >> > from
> >> > the
> >> > data source.
> >> > The data set 'DataSet4' contains a definition for the field
> >> > 'Futures_Volume'. This field is missing from the returned result set
> >> > from
> >> > the
> >> > data source.
> >> > The data set 'DataSet2' contains a definition for the field
> >> > 'Futures_Volume'. This field is missing from the returned result set
> >> > from
> >> > the
> >> > data source.
> >> > Preview complete -- 0 errors, 3 warnings
> >> >
> >> > Now, I created the4 datasets, the parameter for each is simply 1, 2, 3
> >> > and
> >> > 4. The report, or the query, is not auto-generating my other fields as
> >> > it
> >> > did for three that I do see. The 'Futures_Volume' is one of the fields
> >> > that
> >> > was auto-generated for me, and it is in the 1st dataset. Is it that I
> >> > just
> >> > need to manually add in the other fields? Please do let me know what
> >> > you
> >> > think.
> >> >
> >> > and thank you, bruce, for helping me through this. i truly do
> >> > appreciate
> >> > it. i know i am close...and i got the other reports for my server jobs
> >> > and
> >> > one of the other company reports to work. it's just these
> >> > multi-resultset
> >> > reports are fighting me.
> >> > -- Lynn
> >> >
> >> >
> >> > "Bruce L-C [MVP]" wrote:
> >> >
> >> >> Query parameters and report parameters seem to be the same thing but
> >> >> they
> >> >> are not. RS automatically creates a report parameter for each query
> >> >> parameter but instead you can map the query parameter to a constant.
> >> >> Click
> >> >> on the ... for the dataset, go to the parameters tab. On the right you
> >> >> will
> >> >> see it mapping to the report parameter, click on that and select
> >> >> expression.
> >> >> In expression put = 1 (assuming it is an integert expression) for the
> >> >> first
> >> >> dataset, =2 etc. Then go to report layout, report menu-> report
> >> >> parameters
> >> >> and then delete the report parameters created for you.
> >> >>
> >> >> You are very very close to the solution.
> >> >>
> >> >> --
> >> >> Bruce Loehle-Conger
> >> >> MVP SQL Server Reporting Services
> >> >>
> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> news:61E1ED5C-B204-4024-9DC4-82635AEBD912@.microsoft.com...
> >> >> > last one for a while, bruce, i promise. i've got all 4 datasets in
> >> >> > there,
> >> >> > each asks me for a parameter, i put 1,2,3 and 4 into each, getting
> >> >> > my
> >> >> > 'whole
> >> >> > report' in four small subsets of data. how do i get this to happen
> >> >> > on
> >> >> > the
> >> >> > report page automatically without needing user input?
> >> >> > -- Lynn
> >> >> >
> >> >> >
> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >
> >> >> >> Are you going against SQL Server?
> >> >> >>
> >> >> >> If so, then just select tored procedure for the command type and
> >> >> >> just
> >> >> >> put
> >> >> >> in
> >> >> >> the name of the stored procedure. Do not put exec in from of it or
> >> >> >> anything
> >> >> >> else. It should detect the parameter and prompt you for it. It
> >> >> >> should
> >> >> >> also
> >> >> >> create a report parameter as well for you.
> >> >> >>
> >> >> >> Try creating a new dataset and do this from the start. If you
> >> >> >> continue
> >> >> >> to
> >> >> >> have problems create a new stored procedure just for testing .
> >> >> >>
> >> >> >> create procedure dbo.testproc
> >> >> >> @.PARAM1 int
> >> >> >> as
> >> >> >> select 'Parameter passed in = ' + @.PARAM1 as Message
> >> >> >> return
> >> >> >>
> >> >> >> Get the above procedure to work for you so you know how to call a
> >> >> >> stored
> >> >> >> procedure they way I am telling you (do not use exec).
> >> >> >>
> >> >> >>
> >> >> >> --
> >> >> >> Bruce Loehle-Conger
> >> >> >> MVP SQL Server Reporting Services
> >> >> >> --
> >> >> >> Bruce Loehle-Conger
> >> >> >> MVP SQL Server Reporting Services
> >> >> >>
> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> news:9B089D7B-1F23-465B-B443-08BD09469A3E@.microsoft.com...
> >> >> >> > i'm sorry, bruce, but where do i define the parameters? rs is
> >> >> >> > not
> >> >> >> > detecting
> >> >> >> > them. in my 1st dataset i've got cmd type stored procedure and
> >> >> >> > the
> >> >> >> > proc
> >> >> >> > name
> >> >> >> > is in the query string. i assumed i would put the 1st parameter
> >> >> >> > in
> >> >> >> > on
> >> >> >> > the
> >> >> >> > parameters tab and then do the same for 2, 3 and 4 on 3 other
> >> >> >> > datasets,
> >> >> >> > so
> >> >> >> > i
> >> >> >> > gave it @.ch and the value of 1, but when i attempted to run it,
> >> >> >> > it
> >> >> >> > threw
> >> >> >> > me a
> >> >> >> > 'define query parameters box asking me to put the '1' in it.
> >> >> >> > -- Lynn
> >> >> >> >
> >> >> >> >
> >> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >> >
> >> >> >> >> If you are going against SQL Server do not run your stored
> >> >> >> >> procedure
> >> >> >> >> this
> >> >> >> >> way. Pick command type of stored procedure. RS will detect the
> >> >> >> >> parameters.
> >> >> >> >> If going against ODBC or OLEDB driver (which uses ? format for
> >> >> >> >> parameters)
> >> >> >> >> then pick text as the command type and do this:
> >> >> >> >> myproc ?
> >> >> >> >>
> >> >> >> >> Create multiple datasets and for each one you should call the
> >> >> >> >> stored
> >> >> >> >> procedure for each one.
> >> >> >> >>
> >> >> >> >> Bruce Loehle-Conger
> >> >> >> >>
> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> >> news:79CA374D-729B-4181-8F45-5D61FCF30F28@.microsoft.com...
> >> >> >> >> > And, if I blow away the 2nd dataset and just give my 1st one
> >> >> >> >> > parameters,
> >> >> >> >> > it
> >> >> >> >> > almost works. EXEC db.dbo.procname 1 for chunk one of the
> >> >> >> >> > results,
> >> >> >> >> > works
> >> >> >> >> > just fine. if i change the parameter to 2, 3 or 4, when I hit
> >> >> >> >> > RUN
> >> >> >> >> > in
> >> >> >> >> > Data
> >> >> >> >> > tab it returns an error: SQL Syntax Errors Encountered...The
> >> >> >> >> > designer
> >> >> >> >> > does
> >> >> >> >> > not graphically support the EXEC SQL Construct' but, i hit
> >> >> >> >> > 'OK'
> >> >> >> >> > and
> >> >> >> >> > my
> >> >> >> >> > results are still returned to me. On 'Preview' tab, however,
> >> >> >> >> > I
> >> >> >> >> > get
> >> >> >> >> > no
> >> >> >> >> > data/results at all.
> >> >> >> >> > -- Lynn
> >> >> >> >> >
> >> >> >> >> >
> >> >> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >> >> >
> >> >> >> >> >> Yes, you are calling it three times. In RS you create three
> >> >> >> >> >> datasets.
> >> >> >> >> >> Go
> >> >> >> >> >> to
> >> >> >> >> >> the dataset tab and there is a combo box with the name of the
> >> >> >> >> >> dataset,
> >> >> >> >> >> you
> >> >> >> >> >> can click on that and there is a an option for a new.
> >> >> >> >> >>
> >> >> >> >> >> In your stored procedure
> >> >> >> >> >>
> >> >> >> >> >> if @.WHICHRESULTSET = 1
> >> >> >> >> >> begin
> >> >> >> >> >> --return the first resultset here
> >> >> >> >> >> end
> >> >> >> >> >> etc
> >> >> >> >> >>
> >> >> >> >> >>
> >> >> >> >> >> --
> >> >> >> >> >> Bruce Loehle-Conger
> >> >> >> >> >> MVP SQL Server Reporting Services
> >> >> >> >> >>
> >> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> >> >> news:81E3A442-6694-442D-B151-F083E4750ADB@.microsoft.com...
> >> >> >> >> >> > Bruce, or somebody else, might you give me an example of
> >> >> >> >> >> > how
> >> >> >> >> >> > to
> >> >> >> >> >> > give
> >> >> >> >> >> > the
> >> >> >> >> >> > proc
> >> >> >> >> >> > 3 parameters, producing three resultsets in a way that RS
> >> >> >> >> >> > will
> >> >> >> >> >> > display
> >> >> >> >> >> > them?
> >> >> >> >> >> > Or, am I giving it three parameters and calling it three
> >> >> >> >> >> > times?
> >> >> >> >> >> > If
> >> >> >> >> >> > so,
> >> >> >> >> >> > how
> >> >> >> >> >> > would i call the 3 procs in RS?
> >> >> >> >> >> > -- Lynn
> >> >> >> >> >> >
> >> >> >> >> >> >
> >> >> >> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >> >> >> >
> >> >> >> >> >> >> Configure your existing stored procedure to accept a
> >> >> >> >> >> >> parameter
> >> >> >> >> >> >> (you
> >> >> >> >> >> >> can
> >> >> >> >> >> >> make
> >> >> >> >> >> >> it optional so that it doesn't break existing code).
> >> >> >> >> >> >>
> >> >> >> >> >> >> Then call it three times in RS with a static value and
> >> >> >> >> >> >> create
> >> >> >> >> >> >> three
> >> >> >> >> >> >> datasets.
> >> >> >> >> >> >> For instance dataset1
> >> >> >> >> >> >> yourproc 1
> >> >> >> >> >> >>
> >> >> >> >> >> >> Dataset2
> >> >> >> >> >> >> yourproc 2
> >> >> >> >> >> >>
> >> >> >> >> >> >> etc.
> >> >> >> >> >> >>
> >> >> >> >> >> >> Then in your stored procedure return the appropriate
> >> >> >> >> >> >> resultset
> >> >> >> >> >> >> based
> >> >> >> >> >> >> on
> >> >> >> >> >> >> the
> >> >> >> >> >> >> parameter.|||Just because they are calculated in the stored procedure does not mean they
are calculated when you manually add them to the field list. You put the
name same as the name of the field being returned and mark them as database
field. If you name them appropriately and say they are are database fields
it will work.
So, let's say you are in dataset2 which is called the stored procedure with
a parameter value of 2. When you click the execute the data comes back. Plus
you can see the name of the fields in the dataset (but not in the field
list). Add then appropriate field names to the field list.
Bruce Loehle-Conger
MVP SQL Server Reporting Services
"Lynn" <Lynn@.discussions.microsoft.com> wrote in message
news:56F8F3F3-94C0-4E6F-9385-423CB80090EF@.microsoft.com...
> Bruce, i apologize, this is going on and on. I attempt to add the fields
> in...just as they are in dataset1, except with new values, and it fails
> with
> this:
> 'The properties for the currently selected item are not valid. Please
> correct all errors before continuing.'
> Now, all of these values are calculated...Volume (sum of another value), #
> of Trades (count of another value), etc...but the same thing applies to
> dataset 1, and those fields are listed as database fields, not calculated
> fields. please can you tell me what the right way to do this is?
> -- Lynn
>
> "Bruce L-C [MVP]" wrote:
>> Ok, what is happening is that it is detecting the first resultset. What
>> you
>> can do it is add the fields manually. In the field list add a new field
>> and
>> name it correctly for what will be coming back. (Right mouse click in the
>> field list).
>>
>> --
>> Bruce Loehle-Conger
>> MVP SQL Server Reporting Services
>> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> news:D5EEA5C8-DB3A-4DB3-ADE6-D8092373DC46@.microsoft.com...
>> > Bruce, every time I refresh the fields, it pops the 1st three back in
>> > the
>> > list. They're the first three in the report, and i guess they're the
>> > only
>> > ones in that first resultset. So, I go into dataset 2, 3 and 4, all
>> > the
>> > same
>> > 3 fields are listed. i remove them per dataset, hit refresh, and the
>> > same
>> > 3
>> > come back.
>> > -- Lynn
>> >
>> >
>> > "Bruce L-C [MVP]" wrote:
>> >
>> >> For each of your datasets make sure there is a field list. Sometimes
>> >> you
>> >> have to click on the refresh fields button (to the right of the ...).
>> >>
>> >> --
>> >> Bruce Loehle-Conger
>> >> MVP SQL Server Reporting Services
>> >>
>> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> >> news:17C0ED6F-0E4A-4033-A1A2-A841AA7BBECF@.microsoft.com...
>> >> > oh my goodness this is frustrating me....i did what you said,
>> >> > bruce,
>> >> > and
>> >> > it
>> >> > almost worked. the preview report shows me three values which
>> >> > correspond,
>> >> > i
>> >> > believe, to the only three fields in my report. see, they're all
>> >> > calculated
>> >> > fields. the output of the rpt is this:
>> >> >
>> >> > Build complete -- 0 errors, 0 warnings
>> >> > The data set 'DataSet3' contains a definition for the field
>> >> > 'Futures_Volume'. This field is missing from the returned result set
>> >> > from
>> >> > the
>> >> > data source.
>> >> > The data set 'DataSet4' contains a definition for the field
>> >> > 'Futures_Volume'. This field is missing from the returned result set
>> >> > from
>> >> > the
>> >> > data source.
>> >> > The data set 'DataSet2' contains a definition for the field
>> >> > 'Futures_Volume'. This field is missing from the returned result set
>> >> > from
>> >> > the
>> >> > data source.
>> >> > Preview complete -- 0 errors, 3 warnings
>> >> >
>> >> > Now, I created the4 datasets, the parameter for each is simply 1, 2,
>> >> > 3
>> >> > and
>> >> > 4. The report, or the query, is not auto-generating my other fields
>> >> > as
>> >> > it
>> >> > did for three that I do see. The 'Futures_Volume' is one of the
>> >> > fields
>> >> > that
>> >> > was auto-generated for me, and it is in the 1st dataset. Is it that
>> >> > I
>> >> > just
>> >> > need to manually add in the other fields? Please do let me know
>> >> > what
>> >> > you
>> >> > think.
>> >> >
>> >> > and thank you, bruce, for helping me through this. i truly do
>> >> > appreciate
>> >> > it. i know i am close...and i got the other reports for my server
>> >> > jobs
>> >> > and
>> >> > one of the other company reports to work. it's just these
>> >> > multi-resultset
>> >> > reports are fighting me.
>> >> > -- Lynn
>> >> >
>> >> >
>> >> > "Bruce L-C [MVP]" wrote:
>> >> >
>> >> >> Query parameters and report parameters seem to be the same thing
>> >> >> but
>> >> >> they
>> >> >> are not. RS automatically creates a report parameter for each query
>> >> >> parameter but instead you can map the query parameter to a
>> >> >> constant.
>> >> >> Click
>> >> >> on the ... for the dataset, go to the parameters tab. On the right
>> >> >> you
>> >> >> will
>> >> >> see it mapping to the report parameter, click on that and select
>> >> >> expression.
>> >> >> In expression put = 1 (assuming it is an integert expression) for
>> >> >> the
>> >> >> first
>> >> >> dataset, =2 etc. Then go to report layout, report menu-> report
>> >> >> parameters
>> >> >> and then delete the report parameters created for you.
>> >> >>
>> >> >> You are very very close to the solution.
>> >> >>
>> >> >> --
>> >> >> Bruce Loehle-Conger
>> >> >> MVP SQL Server Reporting Services
>> >> >>
>> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> >> >> news:61E1ED5C-B204-4024-9DC4-82635AEBD912@.microsoft.com...
>> >> >> > last one for a while, bruce, i promise. i've got all 4 datasets
>> >> >> > in
>> >> >> > there,
>> >> >> > each asks me for a parameter, i put 1,2,3 and 4 into each,
>> >> >> > getting
>> >> >> > my
>> >> >> > 'whole
>> >> >> > report' in four small subsets of data. how do i get this to
>> >> >> > happen
>> >> >> > on
>> >> >> > the
>> >> >> > report page automatically without needing user input?
>> >> >> > -- Lynn
>> >> >> >
>> >> >> >
>> >> >> > "Bruce L-C [MVP]" wrote:
>> >> >> >
>> >> >> >> Are you going against SQL Server?
>> >> >> >>
>> >> >> >> If so, then just select tored procedure for the command type and
>> >> >> >> just
>> >> >> >> put
>> >> >> >> in
>> >> >> >> the name of the stored procedure. Do not put exec in from of it
>> >> >> >> or
>> >> >> >> anything
>> >> >> >> else. It should detect the parameter and prompt you for it. It
>> >> >> >> should
>> >> >> >> also
>> >> >> >> create a report parameter as well for you.
>> >> >> >>
>> >> >> >> Try creating a new dataset and do this from the start. If you
>> >> >> >> continue
>> >> >> >> to
>> >> >> >> have problems create a new stored procedure just for testing .
>> >> >> >>
>> >> >> >> create procedure dbo.testproc
>> >> >> >> @.PARAM1 int
>> >> >> >> as
>> >> >> >> select 'Parameter passed in = ' + @.PARAM1 as Message
>> >> >> >> return
>> >> >> >>
>> >> >> >> Get the above procedure to work for you so you know how to call
>> >> >> >> a
>> >> >> >> stored
>> >> >> >> procedure they way I am telling you (do not use exec).
>> >> >> >>
>> >> >> >>
>> >> >> >> --
>> >> >> >> Bruce Loehle-Conger
>> >> >> >> MVP SQL Server Reporting Services
>> >> >> >> --
>> >> >> >> Bruce Loehle-Conger
>> >> >> >> MVP SQL Server Reporting Services
>> >> >> >>
>> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> >> >> >> news:9B089D7B-1F23-465B-B443-08BD09469A3E@.microsoft.com...
>> >> >> >> > i'm sorry, bruce, but where do i define the parameters? rs is
>> >> >> >> > not
>> >> >> >> > detecting
>> >> >> >> > them. in my 1st dataset i've got cmd type stored procedure
>> >> >> >> > and
>> >> >> >> > the
>> >> >> >> > proc
>> >> >> >> > name
>> >> >> >> > is in the query string. i assumed i would put the 1st
>> >> >> >> > parameter
>> >> >> >> > in
>> >> >> >> > on
>> >> >> >> > the
>> >> >> >> > parameters tab and then do the same for 2, 3 and 4 on 3 other
>> >> >> >> > datasets,
>> >> >> >> > so
>> >> >> >> > i
>> >> >> >> > gave it @.ch and the value of 1, but when i attempted to run
>> >> >> >> > it,
>> >> >> >> > it
>> >> >> >> > threw
>> >> >> >> > me a
>> >> >> >> > 'define query parameters box asking me to put the '1' in it.
>> >> >> >> > -- Lynn
>> >> >> >> >
>> >> >> >> >
>> >> >> >> > "Bruce L-C [MVP]" wrote:
>> >> >> >> >
>> >> >> >> >> If you are going against SQL Server do not run your stored
>> >> >> >> >> procedure
>> >> >> >> >> this
>> >> >> >> >> way. Pick command type of stored procedure. RS will detect
>> >> >> >> >> the
>> >> >> >> >> parameters.
>> >> >> >> >> If going against ODBC or OLEDB driver (which uses ? format
>> >> >> >> >> for
>> >> >> >> >> parameters)
>> >> >> >> >> then pick text as the command type and do this:
>> >> >> >> >> myproc ?
>> >> >> >> >>
>> >> >> >> >> Create multiple datasets and for each one you should call the
>> >> >> >> >> stored
>> >> >> >> >> procedure for each one.
>> >> >> >> >>
>> >> >> >> >> Bruce Loehle-Conger
>> >> >> >> >>
>> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> >> >> >> >> news:79CA374D-729B-4181-8F45-5D61FCF30F28@.microsoft.com...
>> >> >> >> >> > And, if I blow away the 2nd dataset and just give my 1st
>> >> >> >> >> > one
>> >> >> >> >> > parameters,
>> >> >> >> >> > it
>> >> >> >> >> > almost works. EXEC db.dbo.procname 1 for chunk one of
>> >> >> >> >> > the
>> >> >> >> >> > results,
>> >> >> >> >> > works
>> >> >> >> >> > just fine. if i change the parameter to 2, 3 or 4, when I
>> >> >> >> >> > hit
>> >> >> >> >> > RUN
>> >> >> >> >> > in
>> >> >> >> >> > Data
>> >> >> >> >> > tab it returns an error: SQL Syntax Errors
>> >> >> >> >> > Encountered...The
>> >> >> >> >> > designer
>> >> >> >> >> > does
>> >> >> >> >> > not graphically support the EXEC SQL Construct' but, i
>> >> >> >> >> > hit
>> >> >> >> >> > 'OK'
>> >> >> >> >> > and
>> >> >> >> >> > my
>> >> >> >> >> > results are still returned to me. On 'Preview' tab,
>> >> >> >> >> > however,
>> >> >> >> >> > I
>> >> >> >> >> > get
>> >> >> >> >> > no
>> >> >> >> >> > data/results at all.
>> >> >> >> >> > -- Lynn
>> >> >> >> >> >
>> >> >> >> >> >
>> >> >> >> >> > "Bruce L-C [MVP]" wrote:
>> >> >> >> >> >
>> >> >> >> >> >> Yes, you are calling it three times. In RS you create
>> >> >> >> >> >> three
>> >> >> >> >> >> datasets.
>> >> >> >> >> >> Go
>> >> >> >> >> >> to
>> >> >> >> >> >> the dataset tab and there is a combo box with the name of
>> >> >> >> >> >> the
>> >> >> >> >> >> dataset,
>> >> >> >> >> >> you
>> >> >> >> >> >> can click on that and there is a an option for a new.
>> >> >> >> >> >>
>> >> >> >> >> >> In your stored procedure
>> >> >> >> >> >>
>> >> >> >> >> >> if @.WHICHRESULTSET = 1
>> >> >> >> >> >> begin
>> >> >> >> >> >> --return the first resultset here
>> >> >> >> >> >> end
>> >> >> >> >> >> etc
>> >> >> >> >> >>
>> >> >> >> >> >>
>> >> >> >> >> >> --
>> >> >> >> >> >> Bruce Loehle-Conger
>> >> >> >> >> >> MVP SQL Server Reporting Services
>> >> >> >> >> >>
>> >> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> >> >> >> >> >> news:81E3A442-6694-442D-B151-F083E4750ADB@.microsoft.com...
>> >> >> >> >> >> > Bruce, or somebody else, might you give me an example of
>> >> >> >> >> >> > how
>> >> >> >> >> >> > to
>> >> >> >> >> >> > give
>> >> >> >> >> >> > the
>> >> >> >> >> >> > proc
>> >> >> >> >> >> > 3 parameters, producing three resultsets in a way that
>> >> >> >> >> >> > RS
>> >> >> >> >> >> > will
>> >> >> >> >> >> > display
>> >> >> >> >> >> > them?
>> >> >> >> >> >> > Or, am I giving it three parameters and calling it three
>> >> >> >> >> >> > times?
>> >> >> >> >> >> > If
>> >> >> >> >> >> > so,
>> >> >> >> >> >> > how
>> >> >> >> >> >> > would i call the 3 procs in RS?
>> >> >> >> >> >> > -- Lynn
>> >> >> >> >> >> >
>> >> >> >> >> >> >
>> >> >> >> >> >> > "Bruce L-C [MVP]" wrote:
>> >> >> >> >> >> >
>> >> >> >> >> >> >> Configure your existing stored procedure to accept a
>> >> >> >> >> >> >> parameter
>> >> >> >> >> >> >> (you
>> >> >> >> >> >> >> can
>> >> >> >> >> >> >> make
>> >> >> >> >> >> >> it optional so that it doesn't break existing code).
>> >> >> >> >> >> >>
>> >> >> >> >> >> >> Then call it three times in RS with a static value and
>> >> >> >> >> >> >> create
>> >> >> >> >> >> >> three
>> >> >> >> >> >> >> datasets.
>> >> >> >> >> >> >> For instance dataset1
>> >> >> >> >> >> >> yourproc 1
>> >> >> >> >> >> >>
>> >> >> >> >> >> >> Dataset2
>> >> >> >> >> >> >> yourproc 2
>> >> >> >> >> >> >>
>> >> >> >> >> >> >> etc.
>> >> >> >> >> >> >>
>> >> >> >> >> >> >> Then in your stored procedure return the appropriate
>> >> >> >> >> >> >> resultset
>> >> >> >> >> >> >> based
>> >> >> >> >> >> >> on
>> >> >> >> >> >> >> the
>> >> >> >> >> >> >> parameter.|||i'm sorry, bruce, possibly this is too burdensome for you. i'm just not
getting beyond this. i delete the fields, add the new ones, the thing runs
when i hit the run...but i hit refresh and the old fields come back, the new
ones i just added are gone. even if i save everything when they're
there...they just keep blowing out.
-- Lynn
"Bruce L-C [MVP]" wrote:
> Just because they are calculated in the stored procedure does not mean they
> are calculated when you manually add them to the field list. You put the
> name same as the name of the field being returned and mark them as database
> field. If you name them appropriately and say they are are database fields
> it will work.
> So, let's say you are in dataset2 which is called the stored procedure with
> a parameter value of 2. When you click the execute the data comes back. Plus
> you can see the name of the fields in the dataset (but not in the field
> list). Add then appropriate field names to the field list.
>
> --
> Bruce Loehle-Conger
> MVP SQL Server Reporting Services
> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> news:56F8F3F3-94C0-4E6F-9385-423CB80090EF@.microsoft.com...
> > Bruce, i apologize, this is going on and on. I attempt to add the fields
> > in...just as they are in dataset1, except with new values, and it fails
> > with
> > this:
> >
> > 'The properties for the currently selected item are not valid. Please
> > correct all errors before continuing.'
> >
> > Now, all of these values are calculated...Volume (sum of another value), #
> > of Trades (count of another value), etc...but the same thing applies to
> > dataset 1, and those fields are listed as database fields, not calculated
> > fields. please can you tell me what the right way to do this is?
> > -- Lynn
> >
> >
> > "Bruce L-C [MVP]" wrote:
> >
> >> Ok, what is happening is that it is detecting the first resultset. What
> >> you
> >> can do it is add the fields manually. In the field list add a new field
> >> and
> >> name it correctly for what will be coming back. (Right mouse click in the
> >> field list).
> >>
> >>
> >> --
> >> Bruce Loehle-Conger
> >> MVP SQL Server Reporting Services
> >>
> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> news:D5EEA5C8-DB3A-4DB3-ADE6-D8092373DC46@.microsoft.com...
> >> > Bruce, every time I refresh the fields, it pops the 1st three back in
> >> > the
> >> > list. They're the first three in the report, and i guess they're the
> >> > only
> >> > ones in that first resultset. So, I go into dataset 2, 3 and 4, all
> >> > the
> >> > same
> >> > 3 fields are listed. i remove them per dataset, hit refresh, and the
> >> > same
> >> > 3
> >> > come back.
> >> > -- Lynn
> >> >
> >> >
> >> > "Bruce L-C [MVP]" wrote:
> >> >
> >> >> For each of your datasets make sure there is a field list. Sometimes
> >> >> you
> >> >> have to click on the refresh fields button (to the right of the ...).
> >> >>
> >> >> --
> >> >> Bruce Loehle-Conger
> >> >> MVP SQL Server Reporting Services
> >> >>
> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> news:17C0ED6F-0E4A-4033-A1A2-A841AA7BBECF@.microsoft.com...
> >> >> > oh my goodness this is frustrating me....i did what you said,
> >> >> > bruce,
> >> >> > and
> >> >> > it
> >> >> > almost worked. the preview report shows me three values which
> >> >> > correspond,
> >> >> > i
> >> >> > believe, to the only three fields in my report. see, they're all
> >> >> > calculated
> >> >> > fields. the output of the rpt is this:
> >> >> >
> >> >> > Build complete -- 0 errors, 0 warnings
> >> >> > The data set 'DataSet3' contains a definition for the field
> >> >> > 'Futures_Volume'. This field is missing from the returned result set
> >> >> > from
> >> >> > the
> >> >> > data source.
> >> >> > The data set 'DataSet4' contains a definition for the field
> >> >> > 'Futures_Volume'. This field is missing from the returned result set
> >> >> > from
> >> >> > the
> >> >> > data source.
> >> >> > The data set 'DataSet2' contains a definition for the field
> >> >> > 'Futures_Volume'. This field is missing from the returned result set
> >> >> > from
> >> >> > the
> >> >> > data source.
> >> >> > Preview complete -- 0 errors, 3 warnings
> >> >> >
> >> >> > Now, I created the4 datasets, the parameter for each is simply 1, 2,
> >> >> > 3
> >> >> > and
> >> >> > 4. The report, or the query, is not auto-generating my other fields
> >> >> > as
> >> >> > it
> >> >> > did for three that I do see. The 'Futures_Volume' is one of the
> >> >> > fields
> >> >> > that
> >> >> > was auto-generated for me, and it is in the 1st dataset. Is it that
> >> >> > I
> >> >> > just
> >> >> > need to manually add in the other fields? Please do let me know
> >> >> > what
> >> >> > you
> >> >> > think.
> >> >> >
> >> >> > and thank you, bruce, for helping me through this. i truly do
> >> >> > appreciate
> >> >> > it. i know i am close...and i got the other reports for my server
> >> >> > jobs
> >> >> > and
> >> >> > one of the other company reports to work. it's just these
> >> >> > multi-resultset
> >> >> > reports are fighting me.
> >> >> > -- Lynn
> >> >> >
> >> >> >
> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >
> >> >> >> Query parameters and report parameters seem to be the same thing
> >> >> >> but
> >> >> >> they
> >> >> >> are not. RS automatically creates a report parameter for each query
> >> >> >> parameter but instead you can map the query parameter to a
> >> >> >> constant.
> >> >> >> Click
> >> >> >> on the ... for the dataset, go to the parameters tab. On the right
> >> >> >> you
> >> >> >> will
> >> >> >> see it mapping to the report parameter, click on that and select
> >> >> >> expression.
> >> >> >> In expression put = 1 (assuming it is an integert expression) for
> >> >> >> the
> >> >> >> first
> >> >> >> dataset, =2 etc. Then go to report layout, report menu-> report
> >> >> >> parameters
> >> >> >> and then delete the report parameters created for you.
> >> >> >>
> >> >> >> You are very very close to the solution.
> >> >> >>
> >> >> >> --
> >> >> >> Bruce Loehle-Conger
> >> >> >> MVP SQL Server Reporting Services
> >> >> >>
> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> news:61E1ED5C-B204-4024-9DC4-82635AEBD912@.microsoft.com...
> >> >> >> > last one for a while, bruce, i promise. i've got all 4 datasets
> >> >> >> > in
> >> >> >> > there,
> >> >> >> > each asks me for a parameter, i put 1,2,3 and 4 into each,
> >> >> >> > getting
> >> >> >> > my
> >> >> >> > 'whole
> >> >> >> > report' in four small subsets of data. how do i get this to
> >> >> >> > happen
> >> >> >> > on
> >> >> >> > the
> >> >> >> > report page automatically without needing user input?
> >> >> >> > -- Lynn
> >> >> >> >
> >> >> >> >
> >> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >> >
> >> >> >> >> Are you going against SQL Server?
> >> >> >> >>
> >> >> >> >> If so, then just select tored procedure for the command type and
> >> >> >> >> just
> >> >> >> >> put
> >> >> >> >> in
> >> >> >> >> the name of the stored procedure. Do not put exec in from of it
> >> >> >> >> or
> >> >> >> >> anything
> >> >> >> >> else. It should detect the parameter and prompt you for it. It
> >> >> >> >> should
> >> >> >> >> also
> >> >> >> >> create a report parameter as well for you.
> >> >> >> >>
> >> >> >> >> Try creating a new dataset and do this from the start. If you
> >> >> >> >> continue
> >> >> >> >> to
> >> >> >> >> have problems create a new stored procedure just for testing .
> >> >> >> >>
> >> >> >> >> create procedure dbo.testproc
> >> >> >> >> @.PARAM1 int
> >> >> >> >> as
> >> >> >> >> select 'Parameter passed in = ' + @.PARAM1 as Message
> >> >> >> >> return
> >> >> >> >>
> >> >> >> >> Get the above procedure to work for you so you know how to call
> >> >> >> >> a
> >> >> >> >> stored
> >> >> >> >> procedure they way I am telling you (do not use exec).
> >> >> >> >>
> >> >> >> >>
> >> >> >> >> --
> >> >> >> >> Bruce Loehle-Conger
> >> >> >> >> MVP SQL Server Reporting Services
> >> >> >> >> --
> >> >> >> >> Bruce Loehle-Conger
> >> >> >> >> MVP SQL Server Reporting Services
> >> >> >> >>
> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> >> news:9B089D7B-1F23-465B-B443-08BD09469A3E@.microsoft.com...
> >> >> >> >> > i'm sorry, bruce, but where do i define the parameters? rs is
> >> >> >> >> > not
> >> >> >> >> > detecting
> >> >> >> >> > them. in my 1st dataset i've got cmd type stored procedure
> >> >> >> >> > and
> >> >> >> >> > the
> >> >> >> >> > proc
> >> >> >> >> > name
> >> >> >> >> > is in the query string. i assumed i would put the 1st
> >> >> >> >> > parameter
> >> >> >> >> > in
> >> >> >> >> > on
> >> >> >> >> > the
> >> >> >> >> > parameters tab and then do the same for 2, 3 and 4 on 3 other
> >> >> >> >> > datasets,
> >> >> >> >> > so
> >> >> >> >> > i
> >> >> >> >> > gave it @.ch and the value of 1, but when i attempted to run
> >> >> >> >> > it,
> >> >> >> >> > it
> >> >> >> >> > threw
> >> >> >> >> > me a
> >> >> >> >> > 'define query parameters box asking me to put the '1' in it.
> >> >> >> >> > -- Lynn
> >> >> >> >> >
> >> >> >> >> >
> >> >> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >> >> >
> >> >> >> >> >> If you are going against SQL Server do not run your stored
> >> >> >> >> >> procedure
> >> >> >> >> >> this
> >> >> >> >> >> way. Pick command type of stored procedure. RS will detect
> >> >> >> >> >> the
> >> >> >> >> >> parameters.
> >> >> >> >> >> If going against ODBC or OLEDB driver (which uses ? format
> >> >> >> >> >> for
> >> >> >> >> >> parameters)
> >> >> >> >> >> then pick text as the command type and do this:
> >> >> >> >> >> myproc ?
> >> >> >> >> >>
> >> >> >> >> >> Create multiple datasets and for each one you should call the
> >> >> >> >> >> stored
> >> >> >> >> >> procedure for each one.
> >> >> >> >> >>
> >> >> >> >> >> Bruce Loehle-Conger
> >> >> >> >> >>
> >> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> >> >> news:79CA374D-729B-4181-8F45-5D61FCF30F28@.microsoft.com...
> >> >> >> >> >> > And, if I blow away the 2nd dataset and just give my 1st
> >> >> >> >> >> > one
> >> >> >> >> >> > parameters,
> >> >> >> >> >> > it
> >> >> >> >> >> > almost works. EXEC db.dbo.procname 1 for chunk one of
> >> >> >> >> >> > the
> >> >> >> >> >> > results,
> >> >> >> >> >> > works
> >> >> >> >> >> > just fine. if i change the parameter to 2, 3 or 4, when I
> >> >> >> >> >> > hit
> >> >> >> >> >> > RUN
> >> >> >> >> >> > in
> >> >> >> >> >> > Data
> >> >> >> >> >> > tab it returns an error: SQL Syntax Errors
> >> >> >> >> >> > Encountered...The
> >> >> >> >> >> > designer
> >> >> >> >> >> > does
> >> >> >> >> >> > not graphically support the EXEC SQL Construct' but, i
> >> >> >> >> >> > hit
> >> >> >> >> >> > 'OK'
> >> >> >> >> >> > and
> >> >> >> >> >> > my
> >> >> >> >> >> > results are still returned to me. On 'Preview' tab,
> >> >> >> >> >> > however,
> >> >> >> >> >> > I
> >> >> >> >> >> > get
> >> >> >> >> >> > no
> >> >> >> >> >> > data/results at all.
> >> >> >> >> >> > -- Lynn
> >> >> >> >> >> >
> >> >> >> >> >> >
> >> >> >> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >> >> >> >
> >> >> >> >> >> >> Yes, you are calling it three times. In RS you create|||i think i may be almost there, bruce. hopefully...
i've added all the fields from the diff datasets into the rpt, 4 diff
tables. now when i go to preview, it doesn't show me anything, but up top
left there is a parameter box asking me for a value. and on the far right
there's a 'view report' button.
what should i do?
-- Lynn
"Bruce L-C [MVP]" wrote:
> Just because they are calculated in the stored procedure does not mean they
> are calculated when you manually add them to the field list. You put the
> name same as the name of the field being returned and mark them as database
> field. If you name them appropriately and say they are are database fields
> it will work.
> So, let's say you are in dataset2 which is called the stored procedure with
> a parameter value of 2. When you click the execute the data comes back. Plus
> you can see the name of the fields in the dataset (but not in the field
> list). Add then appropriate field names to the field list.
>
> --
> Bruce Loehle-Conger
> MVP SQL Server Reporting Services
> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> news:56F8F3F3-94C0-4E6F-9385-423CB80090EF@.microsoft.com...
> > Bruce, i apologize, this is going on and on. I attempt to add the fields
> > in...just as they are in dataset1, except with new values, and it fails
> > with
> > this:
> >
> > 'The properties for the currently selected item are not valid. Please
> > correct all errors before continuing.'
> >
> > Now, all of these values are calculated...Volume (sum of another value), #
> > of Trades (count of another value), etc...but the same thing applies to
> > dataset 1, and those fields are listed as database fields, not calculated
> > fields. please can you tell me what the right way to do this is?
> > -- Lynn
> >
> >
> > "Bruce L-C [MVP]" wrote:
> >
> >> Ok, what is happening is that it is detecting the first resultset. What
> >> you
> >> can do it is add the fields manually. In the field list add a new field
> >> and
> >> name it correctly for what will be coming back. (Right mouse click in the
> >> field list).
> >>
> >>
> >> --
> >> Bruce Loehle-Conger
> >> MVP SQL Server Reporting Services
> >>
> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> news:D5EEA5C8-DB3A-4DB3-ADE6-D8092373DC46@.microsoft.com...
> >> > Bruce, every time I refresh the fields, it pops the 1st three back in
> >> > the
> >> > list. They're the first three in the report, and i guess they're the
> >> > only
> >> > ones in that first resultset. So, I go into dataset 2, 3 and 4, all
> >> > the
> >> > same
> >> > 3 fields are listed. i remove them per dataset, hit refresh, and the
> >> > same
> >> > 3
> >> > come back.
> >> > -- Lynn
> >> >
> >> >
> >> > "Bruce L-C [MVP]" wrote:
> >> >
> >> >> For each of your datasets make sure there is a field list. Sometimes
> >> >> you
> >> >> have to click on the refresh fields button (to the right of the ...).
> >> >>
> >> >> --
> >> >> Bruce Loehle-Conger
> >> >> MVP SQL Server Reporting Services
> >> >>
> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> news:17C0ED6F-0E4A-4033-A1A2-A841AA7BBECF@.microsoft.com...
> >> >> > oh my goodness this is frustrating me....i did what you said,
> >> >> > bruce,
> >> >> > and
> >> >> > it
> >> >> > almost worked. the preview report shows me three values which
> >> >> > correspond,
> >> >> > i
> >> >> > believe, to the only three fields in my report. see, they're all
> >> >> > calculated
> >> >> > fields. the output of the rpt is this:
> >> >> >
> >> >> > Build complete -- 0 errors, 0 warnings
> >> >> > The data set 'DataSet3' contains a definition for the field
> >> >> > 'Futures_Volume'. This field is missing from the returned result set
> >> >> > from
> >> >> > the
> >> >> > data source.
> >> >> > The data set 'DataSet4' contains a definition for the field
> >> >> > 'Futures_Volume'. This field is missing from the returned result set
> >> >> > from
> >> >> > the
> >> >> > data source.
> >> >> > The data set 'DataSet2' contains a definition for the field
> >> >> > 'Futures_Volume'. This field is missing from the returned result set
> >> >> > from
> >> >> > the
> >> >> > data source.
> >> >> > Preview complete -- 0 errors, 3 warnings
> >> >> >
> >> >> > Now, I created the4 datasets, the parameter for each is simply 1, 2,
> >> >> > 3
> >> >> > and
> >> >> > 4. The report, or the query, is not auto-generating my other fields
> >> >> > as
> >> >> > it
> >> >> > did for three that I do see. The 'Futures_Volume' is one of the
> >> >> > fields
> >> >> > that
> >> >> > was auto-generated for me, and it is in the 1st dataset. Is it that
> >> >> > I
> >> >> > just
> >> >> > need to manually add in the other fields? Please do let me know
> >> >> > what
> >> >> > you
> >> >> > think.
> >> >> >
> >> >> > and thank you, bruce, for helping me through this. i truly do
> >> >> > appreciate
> >> >> > it. i know i am close...and i got the other reports for my server
> >> >> > jobs
> >> >> > and
> >> >> > one of the other company reports to work. it's just these
> >> >> > multi-resultset
> >> >> > reports are fighting me.
> >> >> > -- Lynn
> >> >> >
> >> >> >
> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >
> >> >> >> Query parameters and report parameters seem to be the same thing
> >> >> >> but
> >> >> >> they
> >> >> >> are not. RS automatically creates a report parameter for each query
> >> >> >> parameter but instead you can map the query parameter to a
> >> >> >> constant.
> >> >> >> Click
> >> >> >> on the ... for the dataset, go to the parameters tab. On the right
> >> >> >> you
> >> >> >> will
> >> >> >> see it mapping to the report parameter, click on that and select
> >> >> >> expression.
> >> >> >> In expression put = 1 (assuming it is an integert expression) for
> >> >> >> the
> >> >> >> first
> >> >> >> dataset, =2 etc. Then go to report layout, report menu-> report
> >> >> >> parameters
> >> >> >> and then delete the report parameters created for you.
> >> >> >>
> >> >> >> You are very very close to the solution.
> >> >> >>
> >> >> >> --
> >> >> >> Bruce Loehle-Conger
> >> >> >> MVP SQL Server Reporting Services
> >> >> >>
> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> news:61E1ED5C-B204-4024-9DC4-82635AEBD912@.microsoft.com...
> >> >> >> > last one for a while, bruce, i promise. i've got all 4 datasets
> >> >> >> > in
> >> >> >> > there,
> >> >> >> > each asks me for a parameter, i put 1,2,3 and 4 into each,
> >> >> >> > getting
> >> >> >> > my
> >> >> >> > 'whole
> >> >> >> > report' in four small subsets of data. how do i get this to
> >> >> >> > happen
> >> >> >> > on
> >> >> >> > the
> >> >> >> > report page automatically without needing user input?
> >> >> >> > -- Lynn
> >> >> >> >
> >> >> >> >
> >> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >> >
> >> >> >> >> Are you going against SQL Server?
> >> >> >> >>
> >> >> >> >> If so, then just select tored procedure for the command type and
> >> >> >> >> just
> >> >> >> >> put
> >> >> >> >> in
> >> >> >> >> the name of the stored procedure. Do not put exec in from of it
> >> >> >> >> or
> >> >> >> >> anything
> >> >> >> >> else. It should detect the parameter and prompt you for it. It
> >> >> >> >> should
> >> >> >> >> also
> >> >> >> >> create a report parameter as well for you.
> >> >> >> >>
> >> >> >> >> Try creating a new dataset and do this from the start. If you
> >> >> >> >> continue
> >> >> >> >> to
> >> >> >> >> have problems create a new stored procedure just for testing .
> >> >> >> >>
> >> >> >> >> create procedure dbo.testproc
> >> >> >> >> @.PARAM1 int
> >> >> >> >> as
> >> >> >> >> select 'Parameter passed in = ' + @.PARAM1 as Message
> >> >> >> >> return
> >> >> >> >>
> >> >> >> >> Get the above procedure to work for you so you know how to call
> >> >> >> >> a
> >> >> >> >> stored
> >> >> >> >> procedure they way I am telling you (do not use exec).
> >> >> >> >>
> >> >> >> >>
> >> >> >> >> --
> >> >> >> >> Bruce Loehle-Conger
> >> >> >> >> MVP SQL Server Reporting Services
> >> >> >> >> --
> >> >> >> >> Bruce Loehle-Conger
> >> >> >> >> MVP SQL Server Reporting Services
> >> >> >> >>
> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> >> news:9B089D7B-1F23-465B-B443-08BD09469A3E@.microsoft.com...
> >> >> >> >> > i'm sorry, bruce, but where do i define the parameters? rs is
> >> >> >> >> > not
> >> >> >> >> > detecting
> >> >> >> >> > them. in my 1st dataset i've got cmd type stored procedure
> >> >> >> >> > and
> >> >> >> >> > the
> >> >> >> >> > proc
> >> >> >> >> > name
> >> >> >> >> > is in the query string. i assumed i would put the 1st
> >> >> >> >> > parameter
> >> >> >> >> > in
> >> >> >> >> > on
> >> >> >> >> > the
> >> >> >> >> > parameters tab and then do the same for 2, 3 and 4 on 3 other
> >> >> >> >> > datasets,
> >> >> >> >> > so
> >> >> >> >> > i
> >> >> >> >> > gave it @.ch and the value of 1, but when i attempted to run
> >> >> >> >> > it,
> >> >> >> >> > it
> >> >> >> >> > threw
> >> >> >> >> > me a
> >> >> >> >> > 'define query parameters box asking me to put the '1' in it.
> >> >> >> >> > -- Lynn
> >> >> >> >> >
> >> >> >> >> >
> >> >> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >> >> >
> >> >> >> >> >> If you are going against SQL Server do not run your stored
> >> >> >> >> >> procedure
> >> >> >> >> >> this
> >> >> >> >> >> way. Pick command type of stored procedure. RS will detect
> >> >> >> >> >> the
> >> >> >> >> >> parameters.
> >> >> >> >> >> If going against ODBC or OLEDB driver (which uses ? format
> >> >> >> >> >> for
> >> >> >> >> >> parameters)
> >> >> >> >> >> then pick text as the command type and do this:
> >> >> >> >> >> myproc ?
> >> >> >> >> >>
> >> >> >> >> >> Create multiple datasets and for each one you should call the
> >> >> >> >> >> stored
> >> >> >> >> >> procedure for each one.
> >> >> >> >> >>
> >> >> >> >> >> Bruce Loehle-Conger
> >> >> >> >> >>
> >> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> >> >> news:79CA374D-729B-4181-8F45-5D61FCF30F28@.microsoft.com...
> >> >> >> >> >> > And, if I blow away the 2nd dataset and just give my 1st
> >> >> >> >> >> > one
> >> >> >> >> >> > parameters,
> >> >> >> >> >> > it
> >> >> >> >> >> > almost works. EXEC db.dbo.procname 1 for chunk one of
> >> >> >> >> >> > the
> >> >> >> >> >> > results,
> >> >> >> >> >> > works
> >> >> >> >> >> > just fine. if i change the parameter to 2, 3 or 4, when I
> >> >> >> >> >> > hit
> >> >> >> >> >> > RUN
> >> >> >> >> >> > in
> >> >> >> >> >> > Data
> >> >> >> >> >> > tab it returns an error: SQL Syntax Errors
> >> >> >> >> >> > Encountered...The
> >> >> >> >> >> > designer
> >> >> >> >> >> > does
> >> >> >> >> >> > not graphically support the EXEC SQL Construct' but, i
> >> >> >> >> >> > hit
> >> >> >> >> >> > 'OK'
> >> >> >> >> >> > and
> >> >> >> >> >> > my
> >> >> >> >> >> > results are still returned to me. On 'Preview' tab,
> >> >> >> >> >> > however,
> >> >> >> >> >> > I
> >> >> >> >> >> > get
> >> >> >> >> >> > no
> >> >> >> >> >> > data/results at all.
> >> >> >> >> >> > -- Lynn
> >> >> >> >> >> >
> >> >> >> >> >> >
> >> >> >> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >> >> >> >
> >> >> >> >> >> >> Yes, you are calling it three times. In RS you create|||d:\...\...\blah report.rdl The data set name is missing in the data region
â'data set nameâ'.
d:\...\...\blah report.rdl The data set â'DataSet2â' contains a definition
for the field â'Futures_Volumeâ'. This field is missing from the returned
result set from the data source.
'Futures_Volume' was/is in the 1st dataset, i deleted from the other three,
adding all the correct fields manually. each rpt runs fine in Data tab when i
hit the run exclamation point. but if i try to preview, i get those two
erros, the second one i get three times for each dataset (2, 3 and 4).
-- Lynn
"Bruce L-C [MVP]" wrote:
> Just because they are calculated in the stored procedure does not mean they
> are calculated when you manually add them to the field list. You put the
> name same as the name of the field being returned and mark them as database
> field. If you name them appropriately and say they are are database fields
> it will work.
> So, let's say you are in dataset2 which is called the stored procedure with
> a parameter value of 2. When you click the execute the data comes back. Plus
> you can see the name of the fields in the dataset (but not in the field
> list). Add then appropriate field names to the field list.
>
> --
> Bruce Loehle-Conger
> MVP SQL Server Reporting Services
> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> news:56F8F3F3-94C0-4E6F-9385-423CB80090EF@.microsoft.com...
> > Bruce, i apologize, this is going on and on. I attempt to add the fields
> > in...just as they are in dataset1, except with new values, and it fails
> > with
> > this:
> >
> > 'The properties for the currently selected item are not valid. Please
> > correct all errors before continuing.'
> >
> > Now, all of these values are calculated...Volume (sum of another value), #
> > of Trades (count of another value), etc...but the same thing applies to
> > dataset 1, and those fields are listed as database fields, not calculated
> > fields. please can you tell me what the right way to do this is?
> > -- Lynn
> >
> >
> > "Bruce L-C [MVP]" wrote:
> >
> >> Ok, what is happening is that it is detecting the first resultset. What
> >> you
> >> can do it is add the fields manually. In the field list add a new field
> >> and
> >> name it correctly for what will be coming back. (Right mouse click in the
> >> field list).
> >>
> >>
> >> --
> >> Bruce Loehle-Conger
> >> MVP SQL Server Reporting Services
> >>
> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> news:D5EEA5C8-DB3A-4DB3-ADE6-D8092373DC46@.microsoft.com...
> >> > Bruce, every time I refresh the fields, it pops the 1st three back in
> >> > the
> >> > list. They're the first three in the report, and i guess they're the
> >> > only
> >> > ones in that first resultset. So, I go into dataset 2, 3 and 4, all
> >> > the
> >> > same
> >> > 3 fields are listed. i remove them per dataset, hit refresh, and the
> >> > same
> >> > 3
> >> > come back.
> >> > -- Lynn
> >> >
> >> >
> >> > "Bruce L-C [MVP]" wrote:
> >> >
> >> >> For each of your datasets make sure there is a field list. Sometimes
> >> >> you
> >> >> have to click on the refresh fields button (to the right of the ...).
> >> >>
> >> >> --
> >> >> Bruce Loehle-Conger
> >> >> MVP SQL Server Reporting Services
> >> >>
> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> news:17C0ED6F-0E4A-4033-A1A2-A841AA7BBECF@.microsoft.com...
> >> >> > oh my goodness this is frustrating me....i did what you said,
> >> >> > bruce,
> >> >> > and
> >> >> > it
> >> >> > almost worked. the preview report shows me three values which
> >> >> > correspond,
> >> >> > i
> >> >> > believe, to the only three fields in my report. see, they're all
> >> >> > calculated
> >> >> > fields. the output of the rpt is this:
> >> >> >
> >> >> > Build complete -- 0 errors, 0 warnings
> >> >> > The data set 'DataSet3' contains a definition for the field
> >> >> > 'Futures_Volume'. This field is missing from the returned result set
> >> >> > from
> >> >> > the
> >> >> > data source.
> >> >> > The data set 'DataSet4' contains a definition for the field
> >> >> > 'Futures_Volume'. This field is missing from the returned result set
> >> >> > from
> >> >> > the
> >> >> > data source.
> >> >> > The data set 'DataSet2' contains a definition for the field
> >> >> > 'Futures_Volume'. This field is missing from the returned result set
> >> >> > from
> >> >> > the
> >> >> > data source.
> >> >> > Preview complete -- 0 errors, 3 warnings
> >> >> >
> >> >> > Now, I created the4 datasets, the parameter for each is simply 1, 2,
> >> >> > 3
> >> >> > and
> >> >> > 4. The report, or the query, is not auto-generating my other fields
> >> >> > as
> >> >> > it
> >> >> > did for three that I do see. The 'Futures_Volume' is one of the
> >> >> > fields
> >> >> > that
> >> >> > was auto-generated for me, and it is in the 1st dataset. Is it that
> >> >> > I
> >> >> > just
> >> >> > need to manually add in the other fields? Please do let me know
> >> >> > what
> >> >> > you
> >> >> > think.
> >> >> >
> >> >> > and thank you, bruce, for helping me through this. i truly do
> >> >> > appreciate
> >> >> > it. i know i am close...and i got the other reports for my server
> >> >> > jobs
> >> >> > and
> >> >> > one of the other company reports to work. it's just these
> >> >> > multi-resultset
> >> >> > reports are fighting me.
> >> >> > -- Lynn
> >> >> >
> >> >> >
> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >
> >> >> >> Query parameters and report parameters seem to be the same thing
> >> >> >> but
> >> >> >> they
> >> >> >> are not. RS automatically creates a report parameter for each query
> >> >> >> parameter but instead you can map the query parameter to a
> >> >> >> constant.
> >> >> >> Click
> >> >> >> on the ... for the dataset, go to the parameters tab. On the right
> >> >> >> you
> >> >> >> will
> >> >> >> see it mapping to the report parameter, click on that and select
> >> >> >> expression.
> >> >> >> In expression put = 1 (assuming it is an integert expression) for
> >> >> >> the
> >> >> >> first
> >> >> >> dataset, =2 etc. Then go to report layout, report menu-> report
> >> >> >> parameters
> >> >> >> and then delete the report parameters created for you.
> >> >> >>
> >> >> >> You are very very close to the solution.
> >> >> >>
> >> >> >> --
> >> >> >> Bruce Loehle-Conger
> >> >> >> MVP SQL Server Reporting Services
> >> >> >>
> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> news:61E1ED5C-B204-4024-9DC4-82635AEBD912@.microsoft.com...
> >> >> >> > last one for a while, bruce, i promise. i've got all 4 datasets
> >> >> >> > in
> >> >> >> > there,
> >> >> >> > each asks me for a parameter, i put 1,2,3 and 4 into each,
> >> >> >> > getting
> >> >> >> > my
> >> >> >> > 'whole
> >> >> >> > report' in four small subsets of data. how do i get this to
> >> >> >> > happen
> >> >> >> > on
> >> >> >> > the
> >> >> >> > report page automatically without needing user input?
> >> >> >> > -- Lynn
> >> >> >> >
> >> >> >> >
> >> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >> >
> >> >> >> >> Are you going against SQL Server?
> >> >> >> >>
> >> >> >> >> If so, then just select tored procedure for the command type and
> >> >> >> >> just
> >> >> >> >> put
> >> >> >> >> in
> >> >> >> >> the name of the stored procedure. Do not put exec in from of it
> >> >> >> >> or
> >> >> >> >> anything
> >> >> >> >> else. It should detect the parameter and prompt you for it. It
> >> >> >> >> should
> >> >> >> >> also
> >> >> >> >> create a report parameter as well for you.
> >> >> >> >>
> >> >> >> >> Try creating a new dataset and do this from the start. If you
> >> >> >> >> continue
> >> >> >> >> to
> >> >> >> >> have problems create a new stored procedure just for testing .
> >> >> >> >>
> >> >> >> >> create procedure dbo.testproc
> >> >> >> >> @.PARAM1 int
> >> >> >> >> as
> >> >> >> >> select 'Parameter passed in = ' + @.PARAM1 as Message
> >> >> >> >> return
> >> >> >> >>
> >> >> >> >> Get the above procedure to work for you so you know how to call
> >> >> >> >> a
> >> >> >> >> stored
> >> >> >> >> procedure they way I am telling you (do not use exec).
> >> >> >> >>
> >> >> >> >>
> >> >> >> >> --
> >> >> >> >> Bruce Loehle-Conger
> >> >> >> >> MVP SQL Server Reporting Services
> >> >> >> >> --
> >> >> >> >> Bruce Loehle-Conger
> >> >> >> >> MVP SQL Server Reporting Services
> >> >> >> >>
> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> >> news:9B089D7B-1F23-465B-B443-08BD09469A3E@.microsoft.com...
> >> >> >> >> > i'm sorry, bruce, but where do i define the parameters? rs is
> >> >> >> >> > not
> >> >> >> >> > detecting
> >> >> >> >> > them. in my 1st dataset i've got cmd type stored procedure
> >> >> >> >> > and
> >> >> >> >> > the
> >> >> >> >> > proc
> >> >> >> >> > name
> >> >> >> >> > is in the query string. i assumed i would put the 1st
> >> >> >> >> > parameter
> >> >> >> >> > in
> >> >> >> >> > on
> >> >> >> >> > the
> >> >> >> >> > parameters tab and then do the same for 2, 3 and 4 on 3 other
> >> >> >> >> > datasets,
> >> >> >> >> > so
> >> >> >> >> > i
> >> >> >> >> > gave it @.ch and the value of 1, but when i attempted to run
> >> >> >> >> > it,
> >> >> >> >> > it
> >> >> >> >> > threw
> >> >> >> >> > me a
> >> >> >> >> > 'define query parameters box asking me to put the '1' in it.
> >> >> >> >> > -- Lynn
> >> >> >> >> >
> >> >> >> >> >
> >> >> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >> >> >
> >> >> >> >> >> If you are going against SQL Server do not run your stored
> >> >> >> >> >> procedure
> >> >> >> >> >> this
> >> >> >> >> >> way. Pick command type of stored procedure. RS will detect
> >> >> >> >> >> the
> >> >> >> >> >> parameters.
> >> >> >> >> >> If going against ODBC or OLEDB driver (which uses ? format
> >> >> >> >> >> for
> >> >> >> >> >> parameters)
> >> >> >> >> >> then pick text as the command type and do this:
> >> >> >> >> >> myproc ?
> >> >> >> >> >>
> >> >> >> >> >> Create multiple datasets and for each one you should call the
> >> >> >> >> >> stored
> >> >> >> >> >> procedure for each one.
> >> >> >> >> >>
> >> >> >> >> >> Bruce Loehle-Conger
> >> >> >> >> >>
> >> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> >> >> news:79CA374D-729B-4181-8F45-5D61FCF30F28@.microsoft.com...
> >> >> >> >> >> > And, if I blow away the 2nd dataset and just give my 1st
> >> >> >> >> >> > one
> >> >> >> >> >> > parameters,
> >> >> >> >> >> > it
> >> >> >> >> >> > almost works. EXEC db.dbo.procname 1 for chunk one of
> >> >> >> >> >> > the
> >> >> >> >> >> > results,
> >> >> >> >> >> > works
> >> >> >> >> >> > just fine. if i change the parameter to 2, 3 or 4, when I
> >> >> >> >> >> > hit
> >> >> >> >> >> > RUN
> >> >> >> >> >> > in
> >> >> >> >> >> > Data
> >> >> >> >> >> > tab it returns an error: SQL Syntax Errors
> >> >> >> >> >> > Encountered...The
> >> >> >> >> >> > designer
> >> >> >> >> >> > does
> >> >> >> >> >> > not graphically support the EXEC SQL Construct' but, i
> >> >> >> >> >> > hit
> >> >> >> >> >> > 'OK'
> >> >> >> >> >> > and
> >> >> >> >> >> > my
> >> >> >> >> >> > results are still returned to me. On 'Preview' tab,
> >> >> >> >> >> > however,
> >> >> >> >> >> > I
> >> >> >> >> >> > get
> >> >> >> >> >> > no
> >> >> >> >> >> > data/results at all.
> >> >> >> >> >> > -- Lynn
> >> >> >> >> >> >
> >> >> >> >> >> >
> >> >> >> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >> >> >> >
> >> >> >> >> >> >> Yes, you are calling it three times. In RS you create|||The datasets 2, 3 and 4 contain definition for futures volume...the field is
missing from the returned resultset from the data source.
possibly i'm looking at this wrong, and i should have four separate
datasets, each with different group of fields, and a single report in which
all fields (from all 4 datasets) are combined?
-- Lynn
"Bruce L-C [MVP]" wrote:
> Just because they are calculated in the stored procedure does not mean they
> are calculated when you manually add them to the field list. You put the
> name same as the name of the field being returned and mark them as database
> field. If you name them appropriately and say they are are database fields
> it will work.
> So, let's say you are in dataset2 which is called the stored procedure with
> a parameter value of 2. When you click the execute the data comes back. Plus
> you can see the name of the fields in the dataset (but not in the field
> list). Add then appropriate field names to the field list.
>
> --
> Bruce Loehle-Conger
> MVP SQL Server Reporting Services
> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> news:56F8F3F3-94C0-4E6F-9385-423CB80090EF@.microsoft.com...
> > Bruce, i apologize, this is going on and on. I attempt to add the fields
> > in...just as they are in dataset1, except with new values, and it fails
> > with
> > this:
> >
> > 'The properties for the currently selected item are not valid. Please
> > correct all errors before continuing.'
> >
> > Now, all of these values are calculated...Volume (sum of another value), #
> > of Trades (count of another value), etc...but the same thing applies to
> > dataset 1, and those fields are listed as database fields, not calculated
> > fields. please can you tell me what the right way to do this is?
> > -- Lynn
> >
> >
> > "Bruce L-C [MVP]" wrote:
> >
> >> Ok, what is happening is that it is detecting the first resultset. What
> >> you
> >> can do it is add the fields manually. In the field list add a new field
> >> and
> >> name it correctly for what will be coming back. (Right mouse click in the
> >> field list).
> >>
> >>
> >> --
> >> Bruce Loehle-Conger
> >> MVP SQL Server Reporting Services
> >>
> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> news:D5EEA5C8-DB3A-4DB3-ADE6-D8092373DC46@.microsoft.com...
> >> > Bruce, every time I refresh the fields, it pops the 1st three back in
> >> > the
> >> > list. They're the first three in the report, and i guess they're the
> >> > only
> >> > ones in that first resultset. So, I go into dataset 2, 3 and 4, all
> >> > the
> >> > same
> >> > 3 fields are listed. i remove them per dataset, hit refresh, and the
> >> > same
> >> > 3
> >> > come back.
> >> > -- Lynn
> >> >
> >> >
> >> > "Bruce L-C [MVP]" wrote:
> >> >
> >> >> For each of your datasets make sure there is a field list. Sometimes
> >> >> you
> >> >> have to click on the refresh fields button (to the right of the ...).
> >> >>
> >> >> --
> >> >> Bruce Loehle-Conger
> >> >> MVP SQL Server Reporting Services
> >> >>
> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> news:17C0ED6F-0E4A-4033-A1A2-A841AA7BBECF@.microsoft.com...
> >> >> > oh my goodness this is frustrating me....i did what you said,
> >> >> > bruce,
> >> >> > and
> >> >> > it
> >> >> > almost worked. the preview report shows me three values which
> >> >> > correspond,
> >> >> > i
> >> >> > believe, to the only three fields in my report. see, they're all
> >> >> > calculated
> >> >> > fields. the output of the rpt is this:
> >> >> >
> >> >> > Build complete -- 0 errors, 0 warnings
> >> >> > The data set 'DataSet3' contains a definition for the field
> >> >> > 'Futures_Volume'. This field is missing from the returned result set
> >> >> > from
> >> >> > the
> >> >> > data source.
> >> >> > The data set 'DataSet4' contains a definition for the field
> >> >> > 'Futures_Volume'. This field is missing from the returned result set
> >> >> > from
> >> >> > the
> >> >> > data source.
> >> >> > The data set 'DataSet2' contains a definition for the field
> >> >> > 'Futures_Volume'. This field is missing from the returned result set
> >> >> > from
> >> >> > the
> >> >> > data source.
> >> >> > Preview complete -- 0 errors, 3 warnings
> >> >> >
> >> >> > Now, I created the4 datasets, the parameter for each is simply 1, 2,
> >> >> > 3
> >> >> > and
> >> >> > 4. The report, or the query, is not auto-generating my other fields
> >> >> > as
> >> >> > it
> >> >> > did for three that I do see. The 'Futures_Volume' is one of the
> >> >> > fields
> >> >> > that
> >> >> > was auto-generated for me, and it is in the 1st dataset. Is it that
> >> >> > I
> >> >> > just
> >> >> > need to manually add in the other fields? Please do let me know
> >> >> > what
> >> >> > you
> >> >> > think.
> >> >> >
> >> >> > and thank you, bruce, for helping me through this. i truly do
> >> >> > appreciate
> >> >> > it. i know i am close...and i got the other reports for my server
> >> >> > jobs
> >> >> > and
> >> >> > one of the other company reports to work. it's just these
> >> >> > multi-resultset
> >> >> > reports are fighting me.
> >> >> > -- Lynn
> >> >> >
> >> >> >
> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >
> >> >> >> Query parameters and report parameters seem to be the same thing
> >> >> >> but
> >> >> >> they
> >> >> >> are not. RS automatically creates a report parameter for each query
> >> >> >> parameter but instead you can map the query parameter to a
> >> >> >> constant.
> >> >> >> Click
> >> >> >> on the ... for the dataset, go to the parameters tab. On the right
> >> >> >> you
> >> >> >> will
> >> >> >> see it mapping to the report parameter, click on that and select
> >> >> >> expression.
> >> >> >> In expression put = 1 (assuming it is an integert expression) for
> >> >> >> the
> >> >> >> first
> >> >> >> dataset, =2 etc. Then go to report layout, report menu-> report
> >> >> >> parameters
> >> >> >> and then delete the report parameters created for you.
> >> >> >>
> >> >> >> You are very very close to the solution.
> >> >> >>
> >> >> >> --
> >> >> >> Bruce Loehle-Conger
> >> >> >> MVP SQL Server Reporting Services
> >> >> >>
> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> news:61E1ED5C-B204-4024-9DC4-82635AEBD912@.microsoft.com...
> >> >> >> > last one for a while, bruce, i promise. i've got all 4 datasets
> >> >> >> > in
> >> >> >> > there,
> >> >> >> > each asks me for a parameter, i put 1,2,3 and 4 into each,
> >> >> >> > getting
> >> >> >> > my
> >> >> >> > 'whole
> >> >> >> > report' in four small subsets of data. how do i get this to
> >> >> >> > happen
> >> >> >> > on
> >> >> >> > the
> >> >> >> > report page automatically without needing user input?
> >> >> >> > -- Lynn
> >> >> >> >
> >> >> >> >
> >> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >> >
> >> >> >> >> Are you going against SQL Server?
> >> >> >> >>
> >> >> >> >> If so, then just select tored procedure for the command type and
> >> >> >> >> just
> >> >> >> >> put
> >> >> >> >> in
> >> >> >> >> the name of the stored procedure. Do not put exec in from of it
> >> >> >> >> or
> >> >> >> >> anything
> >> >> >> >> else. It should detect the parameter and prompt you for it. It
> >> >> >> >> should
> >> >> >> >> also
> >> >> >> >> create a report parameter as well for you.
> >> >> >> >>
> >> >> >> >> Try creating a new dataset and do this from the start. If you
> >> >> >> >> continue
> >> >> >> >> to
> >> >> >> >> have problems create a new stored procedure just for testing .
> >> >> >> >>
> >> >> >> >> create procedure dbo.testproc
> >> >> >> >> @.PARAM1 int
> >> >> >> >> as
> >> >> >> >> select 'Parameter passed in = ' + @.PARAM1 as Message
> >> >> >> >> return
> >> >> >> >>
> >> >> >> >> Get the above procedure to work for you so you know how to call
> >> >> >> >> a
> >> >> >> >> stored
> >> >> >> >> procedure they way I am telling you (do not use exec).
> >> >> >> >>
> >> >> >> >>
> >> >> >> >> --
> >> >> >> >> Bruce Loehle-Conger
> >> >> >> >> MVP SQL Server Reporting Services
> >> >> >> >> --
> >> >> >> >> Bruce Loehle-Conger
> >> >> >> >> MVP SQL Server Reporting Services
> >> >> >> >>
> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> >> news:9B089D7B-1F23-465B-B443-08BD09469A3E@.microsoft.com...
> >> >> >> >> > i'm sorry, bruce, but where do i define the parameters? rs is
> >> >> >> >> > not
> >> >> >> >> > detecting
> >> >> >> >> > them. in my 1st dataset i've got cmd type stored procedure
> >> >> >> >> > and
> >> >> >> >> > the
> >> >> >> >> > proc
> >> >> >> >> > name
> >> >> >> >> > is in the query string. i assumed i would put the 1st
> >> >> >> >> > parameter
> >> >> >> >> > in
> >> >> >> >> > on
> >> >> >> >> > the
> >> >> >> >> > parameters tab and then do the same for 2, 3 and 4 on 3 other
> >> >> >> >> > datasets,
> >> >> >> >> > so
> >> >> >> >> > i
> >> >> >> >> > gave it @.ch and the value of 1, but when i attempted to run
> >> >> >> >> > it,
> >> >> >> >> > it
> >> >> >> >> > threw
> >> >> >> >> > me a
> >> >> >> >> > 'define query parameters box asking me to put the '1' in it.
> >> >> >> >> > -- Lynn
> >> >> >> >> >
> >> >> >> >> >
> >> >> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >> >> >
> >> >> >> >> >> If you are going against SQL Server do not run your stored
> >> >> >> >> >> procedure
> >> >> >> >> >> this
> >> >> >> >> >> way. Pick command type of stored procedure. RS will detect
> >> >> >> >> >> the
> >> >> >> >> >> parameters.
> >> >> >> >> >> If going against ODBC or OLEDB driver (which uses ? format
> >> >> >> >> >> for
> >> >> >> >> >> parameters)
> >> >> >> >> >> then pick text as the command type and do this:
> >> >> >> >> >> myproc ?
> >> >> >> >> >>
> >> >> >> >> >> Create multiple datasets and for each one you should call the
> >> >> >> >> >> stored
> >> >> >> >> >> procedure for each one.
> >> >> >> >> >>
> >> >> >> >> >> Bruce Loehle-Conger
> >> >> >> >> >>
> >> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
> >> >> >> >> >> news:79CA374D-729B-4181-8F45-5D61FCF30F28@.microsoft.com...
> >> >> >> >> >> > And, if I blow away the 2nd dataset and just give my 1st
> >> >> >> >> >> > one
> >> >> >> >> >> > parameters,
> >> >> >> >> >> > it
> >> >> >> >> >> > almost works. EXEC db.dbo.procname 1 for chunk one of
> >> >> >> >> >> > the
> >> >> >> >> >> > results,
> >> >> >> >> >> > works
> >> >> >> >> >> > just fine. if i change the parameter to 2, 3 or 4, when I
> >> >> >> >> >> > hit
> >> >> >> >> >> > RUN
> >> >> >> >> >> > in
> >> >> >> >> >> > Data
> >> >> >> >> >> > tab it returns an error: SQL Syntax Errors
> >> >> >> >> >> > Encountered...The
> >> >> >> >> >> > designer
> >> >> >> >> >> > does
> >> >> >> >> >> > not graphically support the EXEC SQL Construct' but, i
> >> >> >> >> >> > hit
> >> >> >> >> >> > 'OK'
> >> >> >> >> >> > and
> >> >> >> >> >> > my
> >> >> >> >> >> > results are still returned to me. On 'Preview' tab,
> >> >> >> >> >> > however,
> >> >> >> >> >> > I
> >> >> >> >> >> > get
> >> >> >> >> >> > no
> >> >> >> >> >> > data/results at all.
> >> >> >> >> >> > -- Lynn
> >> >> >> >> >> >
> >> >> >> >> >> >
> >> >> >> >> >> > "Bruce L-C [MVP]" wrote:
> >> >> >> >> >> >
> >> >> >> >> >> >> Yes, you are calling it three times. In RS you create|||You are trying to learn many things all at once. You cannot combine datasets
together however you can use the First aggegate funtion (think of it like
Sum except it returns the first value which if the dataset has a single row
is the data you want.
Normally with multiple datasets you would have multiple table controls on
your form (or a list control).
Not sure if you solved the problem of it wiping out your field list. If so,
here is a work around. Make sure your stored procedure works. Then go to
layout view. Show the dataset/fieldlist from there and delete / add fields
to the field list from there.
Note, when wanting to essentially join data into a single dataset another
technique is to use subreports.
Bruce Loehle-Conger
MVP SQL Server Reporting Services
"Lynn" <Lynn@.discussions.microsoft.com> wrote in message
news:8781DA41-EE73-4E1D-8195-42A8355BF10E@.microsoft.com...
> The datasets 2, 3 and 4 contain definition for futures volume...the field
> is
> missing from the returned resultset from the data source.
> possibly i'm looking at this wrong, and i should have four separate
> datasets, each with different group of fields, and a single report in
> which
> all fields (from all 4 datasets) are combined?
> -- Lynn
>
> "Bruce L-C [MVP]" wrote:
>> Just because they are calculated in the stored procedure does not mean
>> they
>> are calculated when you manually add them to the field list. You put the
>> name same as the name of the field being returned and mark them as
>> database
>> field. If you name them appropriately and say they are are database
>> fields
>> it will work.
>> So, let's say you are in dataset2 which is called the stored procedure
>> with
>> a parameter value of 2. When you click the execute the data comes back.
>> Plus
>> you can see the name of the fields in the dataset (but not in the field
>> list). Add then appropriate field names to the field list.
>>
>> --
>> Bruce Loehle-Conger
>> MVP SQL Server Reporting Services
>> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> news:56F8F3F3-94C0-4E6F-9385-423CB80090EF@.microsoft.com...
>> > Bruce, i apologize, this is going on and on. I attempt to add the
>> > fields
>> > in...just as they are in dataset1, except with new values, and it fails
>> > with
>> > this:
>> >
>> > 'The properties for the currently selected item are not valid. Please
>> > correct all errors before continuing.'
>> >
>> > Now, all of these values are calculated...Volume (sum of another
>> > value), #
>> > of Trades (count of another value), etc...but the same thing applies
>> > to
>> > dataset 1, and those fields are listed as database fields, not
>> > calculated
>> > fields. please can you tell me what the right way to do this is?
>> > -- Lynn
>> >
>> >
>> > "Bruce L-C [MVP]" wrote:
>> >
>> >> Ok, what is happening is that it is detecting the first resultset.
>> >> What
>> >> you
>> >> can do it is add the fields manually. In the field list add a new
>> >> field
>> >> and
>> >> name it correctly for what will be coming back. (Right mouse click in
>> >> the
>> >> field list).
>> >>
>> >>
>> >> --
>> >> Bruce Loehle-Conger
>> >> MVP SQL Server Reporting Services
>> >>
>> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> >> news:D5EEA5C8-DB3A-4DB3-ADE6-D8092373DC46@.microsoft.com...
>> >> > Bruce, every time I refresh the fields, it pops the 1st three back
>> >> > in
>> >> > the
>> >> > list. They're the first three in the report, and i guess they're
>> >> > the
>> >> > only
>> >> > ones in that first resultset. So, I go into dataset 2, 3 and 4, all
>> >> > the
>> >> > same
>> >> > 3 fields are listed. i remove them per dataset, hit refresh, and
>> >> > the
>> >> > same
>> >> > 3
>> >> > come back.
>> >> > -- Lynn
>> >> >
>> >> >
>> >> > "Bruce L-C [MVP]" wrote:
>> >> >
>> >> >> For each of your datasets make sure there is a field list.
>> >> >> Sometimes
>> >> >> you
>> >> >> have to click on the refresh fields button (to the right of the
>> >> >> ...).
>> >> >>
>> >> >> --
>> >> >> Bruce Loehle-Conger
>> >> >> MVP SQL Server Reporting Services
>> >> >>
>> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> >> >> news:17C0ED6F-0E4A-4033-A1A2-A841AA7BBECF@.microsoft.com...
>> >> >> > oh my goodness this is frustrating me....i did what you said,
>> >> >> > bruce,
>> >> >> > and
>> >> >> > it
>> >> >> > almost worked. the preview report shows me three values which
>> >> >> > correspond,
>> >> >> > i
>> >> >> > believe, to the only three fields in my report. see, they're all
>> >> >> > calculated
>> >> >> > fields. the output of the rpt is this:
>> >> >> >
>> >> >> > Build complete -- 0 errors, 0 warnings
>> >> >> > The data set 'DataSet3' contains a definition for the field
>> >> >> > 'Futures_Volume'. This field is missing from the returned result
>> >> >> > set
>> >> >> > from
>> >> >> > the
>> >> >> > data source.
>> >> >> > The data set 'DataSet4' contains a definition for the field
>> >> >> > 'Futures_Volume'. This field is missing from the returned result
>> >> >> > set
>> >> >> > from
>> >> >> > the
>> >> >> > data source.
>> >> >> > The data set 'DataSet2' contains a definition for the field
>> >> >> > 'Futures_Volume'. This field is missing from the returned result
>> >> >> > set
>> >> >> > from
>> >> >> > the
>> >> >> > data source.
>> >> >> > Preview complete -- 0 errors, 3 warnings
>> >> >> >
>> >> >> > Now, I created the4 datasets, the parameter for each is simply 1,
>> >> >> > 2,
>> >> >> > 3
>> >> >> > and
>> >> >> > 4. The report, or the query, is not auto-generating my other
>> >> >> > fields
>> >> >> > as
>> >> >> > it
>> >> >> > did for three that I do see. The 'Futures_Volume' is one of the
>> >> >> > fields
>> >> >> > that
>> >> >> > was auto-generated for me, and it is in the 1st dataset. Is it
>> >> >> > that
>> >> >> > I
>> >> >> > just
>> >> >> > need to manually add in the other fields? Please do let me know
>> >> >> > what
>> >> >> > you
>> >> >> > think.
>> >> >> >
>> >> >> > and thank you, bruce, for helping me through this. i truly do
>> >> >> > appreciate
>> >> >> > it. i know i am close...and i got the other reports for my
>> >> >> > server
>> >> >> > jobs
>> >> >> > and
>> >> >> > one of the other company reports to work. it's just these
>> >> >> > multi-resultset
>> >> >> > reports are fighting me.
>> >> >> > -- Lynn
>> >> >> >
>> >> >> >
>> >> >> > "Bruce L-C [MVP]" wrote:
>> >> >> >
>> >> >> >> Query parameters and report parameters seem to be the same thing
>> >> >> >> but
>> >> >> >> they
>> >> >> >> are not. RS automatically creates a report parameter for each
>> >> >> >> query
>> >> >> >> parameter but instead you can map the query parameter to a
>> >> >> >> constant.
>> >> >> >> Click
>> >> >> >> on the ... for the dataset, go to the parameters tab. On the
>> >> >> >> right
>> >> >> >> you
>> >> >> >> will
>> >> >> >> see it mapping to the report parameter, click on that and select
>> >> >> >> expression.
>> >> >> >> In expression put = 1 (assuming it is an integert expression)
>> >> >> >> for
>> >> >> >> the
>> >> >> >> first
>> >> >> >> dataset, =2 etc. Then go to report layout, report menu-> report
>> >> >> >> parameters
>> >> >> >> and then delete the report parameters created for you.
>> >> >> >>
>> >> >> >> You are very very close to the solution.
>> >> >> >>
>> >> >> >> --
>> >> >> >> Bruce Loehle-Conger
>> >> >> >> MVP SQL Server Reporting Services
>> >> >> >>
>> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> >> >> >> news:61E1ED5C-B204-4024-9DC4-82635AEBD912@.microsoft.com...
>> >> >> >> > last one for a while, bruce, i promise. i've got all 4
>> >> >> >> > datasets
>> >> >> >> > in
>> >> >> >> > there,
>> >> >> >> > each asks me for a parameter, i put 1,2,3 and 4 into each,
>> >> >> >> > getting
>> >> >> >> > my
>> >> >> >> > 'whole
>> >> >> >> > report' in four small subsets of data. how do i get this to
>> >> >> >> > happen
>> >> >> >> > on
>> >> >> >> > the
>> >> >> >> > report page automatically without needing user input?
>> >> >> >> > -- Lynn
>> >> >> >> >
>> >> >> >> >
>> >> >> >> > "Bruce L-C [MVP]" wrote:
>> >> >> >> >
>> >> >> >> >> Are you going against SQL Server?
>> >> >> >> >>
>> >> >> >> >> If so, then just select tored procedure for the command type
>> >> >> >> >> and
>> >> >> >> >> just
>> >> >> >> >> put
>> >> >> >> >> in
>> >> >> >> >> the name of the stored procedure. Do not put exec in from of
>> >> >> >> >> it
>> >> >> >> >> or
>> >> >> >> >> anything
>> >> >> >> >> else. It should detect the parameter and prompt you for it.
>> >> >> >> >> It
>> >> >> >> >> should
>> >> >> >> >> also
>> >> >> >> >> create a report parameter as well for you.
>> >> >> >> >>
>> >> >> >> >> Try creating a new dataset and do this from the start. If you
>> >> >> >> >> continue
>> >> >> >> >> to
>> >> >> >> >> have problems create a new stored procedure just for testing
>> >> >> >> >> .
>> >> >> >> >>
>> >> >> >> >> create procedure dbo.testproc
>> >> >> >> >> @.PARAM1 int
>> >> >> >> >> as
>> >> >> >> >> select 'Parameter passed in = ' + @.PARAM1 as Message
>> >> >> >> >> return
>> >> >> >> >>
>> >> >> >> >> Get the above procedure to work for you so you know how to
>> >> >> >> >> call
>> >> >> >> >> a
>> >> >> >> >> stored
>> >> >> >> >> procedure they way I am telling you (do not use exec).
>> >> >> >> >>
>> >> >> >> >>
>> >> >> >> >> --
>> >> >> >> >> Bruce Loehle-Conger
>> >> >> >> >> MVP SQL Server Reporting Services
>> >> >> >> >> --
>> >> >> >> >> Bruce Loehle-Conger
>> >> >> >> >> MVP SQL Server Reporting Services
>> >> >> >> >>
>> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> >> >> >> >> news:9B089D7B-1F23-465B-B443-08BD09469A3E@.microsoft.com...
>> >> >> >> >> > i'm sorry, bruce, but where do i define the parameters? rs
>> >> >> >> >> > is
>> >> >> >> >> > not
>> >> >> >> >> > detecting
>> >> >> >> >> > them. in my 1st dataset i've got cmd type stored procedure
>> >> >> >> >> > and
>> >> >> >> >> > the
>> >> >> >> >> > proc
>> >> >> >> >> > name
>> >> >> >> >> > is in the query string. i assumed i would put the 1st
>> >> >> >> >> > parameter
>> >> >> >> >> > in
>> >> >> >> >> > on
>> >> >> >> >> > the
>> >> >> >> >> > parameters tab and then do the same for 2, 3 and 4 on 3
>> >> >> >> >> > other
>> >> >> >> >> > datasets,
>> >> >> >> >> > so
>> >> >> >> >> > i
>> >> >> >> >> > gave it @.ch and the value of 1, but when i attempted to run
>> >> >> >> >> > it,
>> >> >> >> >> > it
>> >> >> >> >> > threw
>> >> >> >> >> > me a
>> >> >> >> >> > 'define query parameters box asking me to put the '1' in
>> >> >> >> >> > it.
>> >> >> >> >> > -- Lynn
>> >> >> >> >> >
>> >> >> >> >> >
>> >> >> >> >> > "Bruce L-C [MVP]" wrote:
>> >> >> >> >> >
>> >> >> >> >> >> If you are going against SQL Server do not run your stored
>> >> >> >> >> >> procedure
>> >> >> >> >> >> this
>> >> >> >> >> >> way. Pick command type of stored procedure. RS will detect
>> >> >> >> >> >> the
>> >> >> >> >> >> parameters.
>> >> >> >> >> >> If going against ODBC or OLEDB driver (which uses ? format
>> >> >> >> >> >> for
>> >> >> >> >> >> parameters)
>> >> >> >> >> >> then pick text as the command type and do this:
>> >> >> >> >> >> myproc ?
>> >> >> >> >> >>
>> >> >> >> >> >> Create multiple datasets and for each one you should call
>> >> >> >> >> >> the
>> >> >> >> >> >> stored
>> >> >> >> >> >> procedure for each one.
>> >> >> >> >> >>
>> >> >> >> >> >> Bruce Loehle-Conger
>> >> >> >> >> >>
>> >> >> >> >> >> "Lynn" <Lynn@.discussions.microsoft.com> wrote in message
>> >> >> >> >> >> news:79CA374D-729B-4181-8F45-5D61FCF30F28@.microsoft.com...
>> >> >> >> >> >> > And, if I blow away the 2nd dataset and just give my 1st
>> >> >> >> >> >> > one
>> >> >> >> >> >> > parameters,
>> >> >> >> >> >> > it
>> >> >> >> >> >> > almost works. EXEC db.dbo.procname 1 for chunk one of
>> >> >> >> >> >> > the
>> >> >> >> >> >> > results,
>> >> >> >> >> >> > works
>> >> >> >> >> >> > just fine. if i change the parameter to 2, 3 or 4, when
>> >> >> >> >> >> > I
>> >> >> >> >> >> > hit
>> >> >> >> >> >> > RUN
>> >> >> >> >> >> > in
>> >> >> >> >> >> > Data
>> >> >> >> >> >> > tab it returns an error: SQL Syntax Errors
>> >> >> >> >> >> > Encountered...The
>> >> >> >> >> >> > designer
>> >> >> >> >> >> > does
>> >> >> >> >> >> > not graphically support the EXEC SQL Construct' but,
>> >> >> >> >> >> > i
>> >> >> >> >> >> > hit
>> >> >> >> >> >> > 'OK'
>> >> >> >> >> >> > and
>> >> >> >> >> >> > my
>> >> >> >> >> >> > results are still returned to me. On 'Preview' tab,
>> >> >> >> >> >> > however,
>> >> >> >> >> >> > I
>> >> >> >> >> >> > get
>> >> >> >> >> >> > no
>> >> >> >> >> >> > data/results at all.
>> >> >> >> >> >> > -- Lynn
>> >> >> >> >> >> >
>> >> >> >> >> >> >
>> >> >> >> >> >> > "Bruce L-C [MVP]" wrote:
>> >> >> >> >> >> >
>> >> >> >> >> >> >> Yes, you are calling it three times. In RS you create