Tuesday, March 20, 2012
Custom Security works but i get this error sometimes...
srs2000 for a little over a year with custom security.
I used the 2005 Custom Security project and installed it on a dev box.
Everything seems to work (i get login screen when i try to access report
manager) but when i try to access report server I get a wacky error:
c:\Program Files\Microsoft SQL Server\MSSQL.3\Reporting
Services\reportserver\Logon.aspx(28): error CS0012: The type
'System.Drawing.Color' is defined in an assembly that is not referenced. You
must add a reference to assembly 'System.Drawing, Version=2.0.0.0,
Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'.
----
The strange thing about this is that I am referencing this module in my
project both within the "References" and in code using the "using" statement.
I can't figure out what I'm missing...
Has anyone else encountered this issue? Any help would be greatly appreciated.
Thanks,
NunoBy the way, I'm referencing this post to SRS 2005.
Nuno
"Nuno" wrote:
> I installed custom security the same way I did on SRS 2000. I've been running
> srs2000 for a little over a year with custom security.
> I used the 2005 Custom Security project and installed it on a dev box.
> Everything seems to work (i get login screen when i try to access report
> manager) but when i try to access report server I get a wacky error:
> c:\Program Files\Microsoft SQL Server\MSSQL.3\Reporting
> Services\reportserver\Logon.aspx(28): error CS0012: The type
> 'System.Drawing.Color' is defined in an assembly that is not referenced. You
> must add a reference to assembly 'System.Drawing, Version=2.0.0.0,
> Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'.
> ----
> The strange thing about this is that I am referencing this module in my
> project both within the "References" and in code using the "using" statement.
> I can't figure out what I'm missing...
> Has anyone else encountered this issue? Any help would be greatly appreciated.
> Thanks,
> Nuno
>|||I figured out why this happens... I added ForeColor="Red" to the one of the
labels called lblMessage in the Logon.aspx page. I changed it to
Style="Color:Red;" and it now works fine. I have no clue as to why this would
cause an error in the Custom Security Sample solution but I suspect it has
something to do with its connection to a resource(.resx) file.
Nuno
"Nuno" wrote:
> By the way, I'm referencing this post to SRS 2005.
> Nuno
> "Nuno" wrote:
> > I installed custom security the same way I did on SRS 2000. I've been running
> > srs2000 for a little over a year with custom security.
> >
> > I used the 2005 Custom Security project and installed it on a dev box.
> > Everything seems to work (i get login screen when i try to access report
> > manager) but when i try to access report server I get a wacky error:
> >
> > c:\Program Files\Microsoft SQL Server\MSSQL.3\Reporting
> > Services\reportserver\Logon.aspx(28): error CS0012: The type
> > 'System.Drawing.Color' is defined in an assembly that is not referenced. You
> > must add a reference to assembly 'System.Drawing, Version=2.0.0.0,
> > Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'.
> >
> > ----
> >
> > The strange thing about this is that I am referencing this module in my
> > project both within the "References" and in code using the "using" statement.
> > I can't figure out what I'm missing...
> >
> > Has anyone else encountered this issue? Any help would be greatly appreciated.
> >
> > Thanks,
> >
> > Nuno
> >
Thursday, March 8, 2012
Custom Errors
Hi,
I am showing my report in the web application using Report Viewer control.In the report i have start date and End date parameters.While running the report if i give startdate as '45/66/20007' it is displaying a message which is not user friendly.Is there is any way we can handle this type of errors and display our own custom error messages.
Thanks in advance
Hello Mahima,
I was facing the same problem but I solved it through strored procedures. I passed my custom message in the RaiseError exception after the validation.
Example : This is not a solution for your problem, but I think you change the validation accordingly
IF (DATEDIFF(MM,@.StartReceivedDate,@.EndReceivedDate) > 12)
BEGIN
SET @.DateErrMsg = 'The Date Range should fall with in an year, Please correct the range.'
RAISERROR (@.DateErrMsg,18,1)
END
Hope this helps.
|||
Hi,
I try to implement that when the condition occured, it is displaying like in this way:
Query execution failed for DataSet1.
An error occured during local report processing
under this our raise error message is displaying.
Is there any way only to display our message which in raise error other than first 2 lines.
Thanks in advance
|||I am using the (ReportErrorEventArgs e) from Microsoft.Reporting.WinForms namespace.
The way I have displayed our Raise Error exception is through the Message box.
Example:
MessageBox.Show(e.Exception.GetBaseException().Message, "Some message",MessageBoxButtons.OK, MessageBoxIcon.Error);
Then
I am hiding the " Query execution failed for DataSet1.
An error occured during local report processing
our raise error message is displaying."
with this expression : ReportErrorEventArgs.Handled = True.
In our requirement we need a messagebox to display ,but I am sure we can find a way to hide the first two lines and dispay only Raise Error execption message.
Hope this helps.....
|||Hi,
Can you please tell me in which event you are handling this.
Can you please give me the detailed example or any other link which speciefied this event handling.
Thanks in advance
|||It is the ReportError event for the ReportViewer.
private Microsoft.Reporting.WinForms.ReportViewer rptvSelReport;
Example:
private void rptvSelReport_ReportError(object sender, ReportErrorEventArgs e)
{
MessageBox.Show(e.Exception.GetBaseException().Message, DIALOG_FORM_CAPTION,MessageBoxButtons.OK, MessageBoxIcon.Error);
e.Handled = true;
Cursor.Current = Cursors.Arrow;
}
We have used this in our dev. environment and its working fine.
Let me know if you need any help....
|||Hi,
Thanks for the information.I will try this and i will ask you when i have problem with this,
Thanks
|||
Custom Errors
Hi,
I am showing my report in the web application using Report Viewer control.In the report i have start date and End date parameters.While running the report if i give startdate as '45/66/20007' it is displaying a message which is not user friendly.Is there is any way we can handle this type of errors and display our own custom error messages.
Thanks in advance
Hello Mahima,
I was facing the same problem but I solved it through strored procedures. I passed my custom message in the RaiseError exception after the validation.
Example : This is not a solution for your problem, but I think you change the validation accordingly
IF(DATEDIFF(MM,@.StartReceivedDate,@.EndReceivedDate)> 12)
BEGIN
SET @.DateErrMsg ='The Date Range should fall with in an year, Please correct the range.'
RAISERROR(@.DateErrMsg,18,1)
END
Hope this helps.
|||
Hi,
I try to implement that when the condition occured, it is displaying like in this way:
Query execution failed for DataSet1.
An error occured during local report processing
under this our raise error message is displaying.
Is there any way only to display our message which in raise error other than first 2 lines.
Thanks in advance
|||I am using the (ReportErrorEventArgs e) from Microsoft.Reporting.WinForms namespace.
The way I have displayed our Raise Error exception is through the Message box.
Example:
MessageBox.Show(e.Exception.GetBaseException().Message, "Some message",MessageBoxButtons.OK, MessageBoxIcon.Error);
Then
I am hiding the " Query execution failed for DataSet1.
An error occured during local report processing
our raise error message is displaying."
with this expression : ReportErrorEventArgs.Handled = True.
In our requirement we need a messagebox to display ,but I am sure we can find a way to hide the first two lines and dispay only Raise Error execption message.
Hope this helps.....
|||Hi,
Can you please tell me in which event you are handling this.
Can you please give me the detailed example or any other link which speciefied this event handling.
Thanks in advance
|||It is the ReportError event for the ReportViewer.
private Microsoft.Reporting.WinForms.ReportViewer rptvSelReport;
Example:
private void rptvSelReport_ReportError(object sender, ReportErrorEventArgs e)
{
MessageBox.Show(e.Exception.GetBaseException().Message, DIALOG_FORM_CAPTION,MessageBoxButtons.OK, MessageBoxIcon.Error);
e.Handled = true;
Cursor.Current = Cursors.Arrow;
}
We have used this in our dev. environment and its working fine.
Let me know if you need any help....
|||Hi,
Thanks for the information.I will try this and i will ask you when i have problem with this,
Thanks
|||
Saturday, February 25, 2012
Custom Data Extension problems
I'm trying to develop a custom data extension for a proprietary database we
use, and I'm running into problems. I've built a test harness for it and it
works fine; however when I try to use it with RS I get the following error
just after having entered my query and pressed Next in the New Report wizard:
"An error occurred while the query design method was being saved. Object
reference not set to an instance of an object"
When I step through my code, I can see that everything goes well until the
designer tries to call the Parameters property on the Command object. Because
my database doesn't support parameters I'm returning null here, something
I've seen in several code examples. As soon as I've exited the property I get
the error, with the debugger saying it originates from
Microsoft.ReportDesigner.Design.Query.HasParameters.
Other background information (in no particular order):
- Before I get to the Parameters property, I see that the GetName and
GetFieldType properties on my DataReader are called the same number of times
as there are columns in my resultset, and then the Dispose method is called
on the DataReader.
- My queries are in XML, and here's the sample I'm using for testing:
<DVAutoXMLFetch Database="C:\Program Files\IMS Health\DATA\DBPINT01.PRM">
<TimePeriods Count="4">
<TimePeriod>QTR/3/02</TimePeriod>
</TimePeriods>
<Variables Count="3">
<Variable>UN</Variable>
</Variables>
<Dimensions Count="16">
<Dimension Name="CTY" IsGroup="False" BaseDim="">
<Member>AUSTRIA</Member>
</Dimension>
</Dimensions>
<FetchDefinition>
<NumberPrecision ValColNumPrec="1000" ValColRndPrec="1" CalcColRndPrec="3"
/>
<AcrossMeasures Count="2">
<AcrossMeasure Index="1" DimName="TimePeriods" />
<AcrossMeasure Index="2" DimName="Variables" />
<Columns Count="1" Rank="0" CalcRank="0" />
</AcrossMeasures>
<DownMeasures Count="1">
<DownMeasure Index="1" DimName="CTY" />
</DownMeasures>
</FetchDefinition>
</DVAutoXMLFetch>
- I'm running RS SP1 on Windows 2000.
- I can post the source code if anyone wants...
Thanks in advance for any hints!
ChrisChris,
Don't return null. Instead, instantiate your ParameterCollection and return
it back although it will be emply.
--
Hope this helps.
----
Teo Lachev, MCSD, MCT
Author: "Microsoft Reporting Services in Action"
Publisher website: http://www.manning.com/lachev
Buy it from Amazon.com: http://shrinkster.com/eq
Home page and blog: http://www.prologika.com/
----
"Chris Webb" <OnlyForPostingToNewsgroups@.hotmail.com> wrote in message
news:7373D28A-BDDA-450B-B1DC-53605BF8C821@.microsoft.com...
> Hi all,
> I'm trying to develop a custom data extension for a proprietary database
we
> use, and I'm running into problems. I've built a test harness for it and
it
> works fine; however when I try to use it with RS I get the following error
> just after having entered my query and pressed Next in the New Report
wizard:
> "An error occurred while the query design method was being saved. Object
> reference not set to an instance of an object"
> When I step through my code, I can see that everything goes well until the
> designer tries to call the Parameters property on the Command object.
Because
> my database doesn't support parameters I'm returning null here, something
> I've seen in several code examples. As soon as I've exited the property I
get
> the error, with the debugger saying it originates from
> Microsoft.ReportDesigner.Design.Query.HasParameters.
> Other background information (in no particular order):
> - Before I get to the Parameters property, I see that the GetName and
> GetFieldType properties on my DataReader are called the same number of
times
> as there are columns in my resultset, and then the Dispose method is
called
> on the DataReader.
> - My queries are in XML, and here's the sample I'm using for testing:
> <DVAutoXMLFetch Database="C:\Program Files\IMS Health\DATA\DBPINT01.PRM">
> <TimePeriods Count="4">
> <TimePeriod>QTR/3/02</TimePeriod>
> </TimePeriods>
> <Variables Count="3">
> <Variable>UN</Variable>
> </Variables>
> <Dimensions Count="16">
> <Dimension Name="CTY" IsGroup="False" BaseDim="">
> <Member>AUSTRIA</Member>
> </Dimension>
> </Dimensions>
> <FetchDefinition>
> <NumberPrecision ValColNumPrec="1000" ValColRndPrec="1"
CalcColRndPrec="3"
> />
> <AcrossMeasures Count="2">
> <AcrossMeasure Index="1" DimName="TimePeriods" />
> <AcrossMeasure Index="2" DimName="Variables" />
> <Columns Count="1" Rank="0" CalcRank="0" />
> </AcrossMeasures>
> <DownMeasures Count="1">
> <DownMeasure Index="1" DimName="CTY" />
> </DownMeasures>
> </FetchDefinition>
> </DVAutoXMLFetch>
> - I'm running RS SP1 on Windows 2000.
> - I can post the source code if anyone wants...
> Thanks in advance for any hints!
> Chris
>|||Hi Teo,
Thanks, that solved that problem. I've seen several code examples which
returned null for Parameters, which presumably must have worked at some
point; has the behaviour changed since beta 1?
Anyway, I have a new problem now - the report wizard almost, but I get a COM
Interop exception when I click Finish. The error originates from
Microsoft.DataWarehouse.VsIntegration.Designer.Serialization.DataWarehouseContainerManager.CreateDocumentObjectDictionary.
Once again the error is raised from outside my code. Any more ideas?
Thanks again,
Chris
"Teo Lachev" wrote:
> Chris,
> Don't return null. Instead, instantiate your ParameterCollection and return
> it back although it will be emply.
> --
> Hope this helps.
> ----
> Teo Lachev, MCSD, MCT
> Author: "Microsoft Reporting Services in Action"
> Publisher website: http://www.manning.com/lachev
> Buy it from Amazon.com: http://shrinkster.com/eq
> Home page and blog: http://www.prologika.com/
> ----
> "Chris Webb" <OnlyForPostingToNewsgroups@.hotmail.com> wrote in message
> news:7373D28A-BDDA-450B-B1DC-53605BF8C821@.microsoft.com...
> > Hi all,
> >
> > I'm trying to develop a custom data extension for a proprietary database
> we
> > use, and I'm running into problems. I've built a test harness for it and
> it
> > works fine; however when I try to use it with RS I get the following error
> > just after having entered my query and pressed Next in the New Report
> wizard:
> > "An error occurred while the query design method was being saved. Object
> > reference not set to an instance of an object"
> >
> > When I step through my code, I can see that everything goes well until the
> > designer tries to call the Parameters property on the Command object.
> Because
> > my database doesn't support parameters I'm returning null here, something
> > I've seen in several code examples. As soon as I've exited the property I
> get
> > the error, with the debugger saying it originates from
> > Microsoft.ReportDesigner.Design.Query.HasParameters.
> >
> > Other background information (in no particular order):
> > - Before I get to the Parameters property, I see that the GetName and
> > GetFieldType properties on my DataReader are called the same number of
> times
> > as there are columns in my resultset, and then the Dispose method is
> called
> > on the DataReader.
> > - My queries are in XML, and here's the sample I'm using for testing:
> > <DVAutoXMLFetch Database="C:\Program Files\IMS Health\DATA\DBPINT01.PRM">
> > <TimePeriods Count="4">
> > <TimePeriod>QTR/3/02</TimePeriod>
> > </TimePeriods>
> > <Variables Count="3">
> > <Variable>UN</Variable>
> > </Variables>
> > <Dimensions Count="16">
> > <Dimension Name="CTY" IsGroup="False" BaseDim="">
> > <Member>AUSTRIA</Member>
> > </Dimension>
> > </Dimensions>
> > <FetchDefinition>
> > <NumberPrecision ValColNumPrec="1000" ValColRndPrec="1"
> CalcColRndPrec="3"
> > />
> > <AcrossMeasures Count="2">
> > <AcrossMeasure Index="1" DimName="TimePeriods" />
> > <AcrossMeasure Index="2" DimName="Variables" />
> > <Columns Count="1" Rank="0" CalcRank="0" />
> > </AcrossMeasures>
> > <DownMeasures Count="1">
> > <DownMeasure Index="1" DimName="CTY" />
> > </DownMeasures>
> > </FetchDefinition>
> > </DVAutoXMLFetch>
> > - I'm running RS SP1 on Windows 2000.
> > - I can post the source code if anyone wants...
> >
> > Thanks in advance for any hints!
> >
> > Chris
> >
>
>|||Chris,
Not from the top of my head. Could you put breakpoints in all public methods
and see after which call the exception is thrown. There must be something
quirky in the data extension itself.
--
Hope this helps.
----
Teo Lachev, MCSD, MCT
Author: "Microsoft Reporting Services in Action"
Publisher website: http://www.manning.com/lachev
Buy it from Amazon.com: http://shrinkster.com/eq
Home page and blog: http://www.prologika.com/
----
"Chris Webb" <OnlyForPostingToNewsgroups@.hotmail.com> wrote in message
news:987083A9-8CE5-4A99-A887-A32247FB8776@.microsoft.com...
> Hi Teo,
> Thanks, that solved that problem. I've seen several code examples which
> returned null for Parameters, which presumably must have worked at some
> point; has the behaviour changed since beta 1?
> Anyway, I have a new problem now - the report wizard almost, but I get a
COM
> Interop exception when I click Finish. The error originates from
>
Microsoft.DataWarehouse.VsIntegration.Designer.Serialization.DataWarehouseCo
ntainerManager.CreateDocumentObjectDictionary.
> Once again the error is raised from outside my code. Any more ideas?
> Thanks again,
> Chris
> "Teo Lachev" wrote:
> > Chris,
> >
> > Don't return null. Instead, instantiate your ParameterCollection and
return
> > it back although it will be emply.
> >
> > --
> > Hope this helps.
> >
> > ----
> > Teo Lachev, MCSD, MCT
> > Author: "Microsoft Reporting Services in Action"
> > Publisher website: http://www.manning.com/lachev
> > Buy it from Amazon.com: http://shrinkster.com/eq
> > Home page and blog: http://www.prologika.com/
> > ----
> >
> > "Chris Webb" <OnlyForPostingToNewsgroups@.hotmail.com> wrote in message
> > news:7373D28A-BDDA-450B-B1DC-53605BF8C821@.microsoft.com...
> > > Hi all,
> > >
> > > I'm trying to develop a custom data extension for a proprietary
database
> > we
> > > use, and I'm running into problems. I've built a test harness for it
and
> > it
> > > works fine; however when I try to use it with RS I get the following
error
> > > just after having entered my query and pressed Next in the New Report
> > wizard:
> > > "An error occurred while the query design method was being saved.
Object
> > > reference not set to an instance of an object"
> > >
> > > When I step through my code, I can see that everything goes well until
the
> > > designer tries to call the Parameters property on the Command object.
> > Because
> > > my database doesn't support parameters I'm returning null here,
something
> > > I've seen in several code examples. As soon as I've exited the
property I
> > get
> > > the error, with the debugger saying it originates from
> > > Microsoft.ReportDesigner.Design.Query.HasParameters.
> > >
> > > Other background information (in no particular order):
> > > - Before I get to the Parameters property, I see that the GetName and
> > > GetFieldType properties on my DataReader are called the same number of
> > times
> > > as there are columns in my resultset, and then the Dispose method is
> > called
> > > on the DataReader.
> > > - My queries are in XML, and here's the sample I'm using for testing:
> > > <DVAutoXMLFetch Database="C:\Program Files\IMS
Health\DATA\DBPINT01.PRM">
> > > <TimePeriods Count="4">
> > > <TimePeriod>QTR/3/02</TimePeriod>
> > > </TimePeriods>
> > > <Variables Count="3">
> > > <Variable>UN</Variable>
> > > </Variables>
> > > <Dimensions Count="16">
> > > <Dimension Name="CTY" IsGroup="False" BaseDim="">
> > > <Member>AUSTRIA</Member>
> > > </Dimension>
> > > </Dimensions>
> > > <FetchDefinition>
> > > <NumberPrecision ValColNumPrec="1000" ValColRndPrec="1"
> > CalcColRndPrec="3"
> > > />
> > > <AcrossMeasures Count="2">
> > > <AcrossMeasure Index="1" DimName="TimePeriods" />
> > > <AcrossMeasure Index="2" DimName="Variables" />
> > > <Columns Count="1" Rank="0" CalcRank="0" />
> > > </AcrossMeasures>
> > > <DownMeasures Count="1">
> > > <DownMeasure Index="1" DimName="CTY" />
> > > </DownMeasures>
> > > </FetchDefinition>
> > > </DVAutoXMLFetch>
> > > - I'm running RS SP1 on Windows 2000.
> > > - I can post the source code if anyone wants...
> > >
> > > Thanks in advance for any hints!
> > >
> > > Chris
> > >
> >
> >
> >|||Teo,
I did that and still had no luck - and then saw the bug by accident and
fixed it. Everything now seems to run fine, but it did make me wonder - I was
debugging the devenv.exe process, but when you run a report in preview
(rather than build it) does it spawn a new process? That might explain my
problems debugging it, no?
Thanks for all your help,
Chris
"Teo Lachev" wrote:
> Chris,
> Not from the top of my head. Could you put breakpoints in all public methods
> and see after which call the exception is thrown. There must be something
> quirky in the data extension itself.
> --
> Hope this helps.
> ----
> Teo Lachev, MCSD, MCT
> Author: "Microsoft Reporting Services in Action"
> Publisher website: http://www.manning.com/lachev
> Buy it from Amazon.com: http://shrinkster.com/eq
> Home page and blog: http://www.prologika.com/
> ----
> "Chris Webb" <OnlyForPostingToNewsgroups@.hotmail.com> wrote in message
> news:987083A9-8CE5-4A99-A887-A32247FB8776@.microsoft.com...
> > Hi Teo,
> >
> > Thanks, that solved that problem. I've seen several code examples which
> > returned null for Parameters, which presumably must have worked at some
> > point; has the behaviour changed since beta 1?
> >
> > Anyway, I have a new problem now - the report wizard almost, but I get a
> COM
> > Interop exception when I click Finish. The error originates from
> >
> Microsoft.DataWarehouse.VsIntegration.Designer.Serialization.DataWarehouseCo
> ntainerManager.CreateDocumentObjectDictionary.
> > Once again the error is raised from outside my code. Any more ideas?
> >
> > Thanks again,
> >
> > Chris
> >
> > "Teo Lachev" wrote:
> >
> > > Chris,
> > >
> > > Don't return null. Instead, instantiate your ParameterCollection and
> return
> > > it back although it will be emply.
> > >
> > > --
> > > Hope this helps.
> > >
> > > ----
> > > Teo Lachev, MCSD, MCT
> > > Author: "Microsoft Reporting Services in Action"
> > > Publisher website: http://www.manning.com/lachev
> > > Buy it from Amazon.com: http://shrinkster.com/eq
> > > Home page and blog: http://www.prologika.com/
> > > ----
> > >
> > > "Chris Webb" <OnlyForPostingToNewsgroups@.hotmail.com> wrote in message
> > > news:7373D28A-BDDA-450B-B1DC-53605BF8C821@.microsoft.com...
> > > > Hi all,
> > > >
> > > > I'm trying to develop a custom data extension for a proprietary
> database
> > > we
> > > > use, and I'm running into problems. I've built a test harness for it
> and
> > > it
> > > > works fine; however when I try to use it with RS I get the following
> error
> > > > just after having entered my query and pressed Next in the New Report
> > > wizard:
> > > > "An error occurred while the query design method was being saved.
> Object
> > > > reference not set to an instance of an object"
> > > >
> > > > When I step through my code, I can see that everything goes well until
> the
> > > > designer tries to call the Parameters property on the Command object.
> > > Because
> > > > my database doesn't support parameters I'm returning null here,
> something
> > > > I've seen in several code examples. As soon as I've exited the
> property I
> > > get
> > > > the error, with the debugger saying it originates from
> > > > Microsoft.ReportDesigner.Design.Query.HasParameters.
> > > >
> > > > Other background information (in no particular order):
> > > > - Before I get to the Parameters property, I see that the GetName and
> > > > GetFieldType properties on my DataReader are called the same number of
> > > times
> > > > as there are columns in my resultset, and then the Dispose method is
> > > called
> > > > on the DataReader.
> > > > - My queries are in XML, and here's the sample I'm using for testing:
> > > > <DVAutoXMLFetch Database="C:\Program Files\IMS
> Health\DATA\DBPINT01.PRM">
> > > > <TimePeriods Count="4">
> > > > <TimePeriod>QTR/3/02</TimePeriod>
> > > > </TimePeriods>
> > > > <Variables Count="3">
> > > > <Variable>UN</Variable>
> > > > </Variables>
> > > > <Dimensions Count="16">
> > > > <Dimension Name="CTY" IsGroup="False" BaseDim="">
> > > > <Member>AUSTRIA</Member>
> > > > </Dimension>
> > > > </Dimensions>
> > > > <FetchDefinition>
> > > > <NumberPrecision ValColNumPrec="1000" ValColRndPrec="1"
> > > CalcColRndPrec="3"
> > > > />
> > > > <AcrossMeasures Count="2">
> > > > <AcrossMeasure Index="1" DimName="TimePeriods" />
> > > > <AcrossMeasure Index="2" DimName="Variables" />
> > > > <Columns Count="1" Rank="0" CalcRank="0" />
> > > > </AcrossMeasures>
> > > > <DownMeasures Count="1">
> > > > <DownMeasure Index="1" DimName="CTY" />
> > > > </DownMeasures>
> > > > </FetchDefinition>
> > > > </DVAutoXMLFetch>
> > > > - I'm running RS SP1 on Windows 2000.
> > > > - I can post the source code if anyone wants...
> > > >
> > > > Thanks in advance for any hints!
> > > >
> > > > Chris
> > > >
> > >
> > >
> > >
>
>|||It may be if the issue was security related. The idea behind the ReportHost
(F5), is to allow the report author to simulate the Report Server
(production) environment by applying the security settings from the
rspreviewpolicy.config.
--
Hope this helps.
----
Teo Lachev, MCSD, MCT
Author: "Microsoft Reporting Services in Action"
Publisher website: http://www.manning.com/lachev
Buy it from Amazon.com: http://shrinkster.com/eq
Home page and blog: http://www.prologika.com/
----
"Chris Webb" <OnlyForPostingToNewsgroups@.hotmail.com> wrote in message
news:44823615-9F6C-4477-A3DD-ECDCF43BE81A@.microsoft.com...
> Teo,
> I did that and still had no luck - and then saw the bug by accident and
> fixed it. Everything now seems to run fine, but it did make me wonder - I
was
> debugging the devenv.exe process, but when you run a report in preview
> (rather than build it) does it spawn a new process? That might explain my
> problems debugging it, no?
> Thanks for all your help,
> Chris
> "Teo Lachev" wrote:
> > Chris,
> >
> > Not from the top of my head. Could you put breakpoints in all public
methods
> > and see after which call the exception is thrown. There must be
something
> > quirky in the data extension itself.
> >
> > --
> > Hope this helps.
> >
> > ----
> > Teo Lachev, MCSD, MCT
> > Author: "Microsoft Reporting Services in Action"
> > Publisher website: http://www.manning.com/lachev
> > Buy it from Amazon.com: http://shrinkster.com/eq
> > Home page and blog: http://www.prologika.com/
> > ----
> >
> > "Chris Webb" <OnlyForPostingToNewsgroups@.hotmail.com> wrote in message
> > news:987083A9-8CE5-4A99-A887-A32247FB8776@.microsoft.com...
> > > Hi Teo,
> > >
> > > Thanks, that solved that problem. I've seen several code examples
which
> > > returned null for Parameters, which presumably must have worked at
some
> > > point; has the behaviour changed since beta 1?
> > >
> > > Anyway, I have a new problem now - the report wizard almost, but I get
a
> > COM
> > > Interop exception when I click Finish. The error originates from
> > >
> >
Microsoft.DataWarehouse.VsIntegration.Designer.Serialization.DataWarehouseCo
> > ntainerManager.CreateDocumentObjectDictionary.
> > > Once again the error is raised from outside my code. Any more ideas?
> > >
> > > Thanks again,
> > >
> > > Chris
> > >
> > > "Teo Lachev" wrote:
> > >
> > > > Chris,
> > > >
> > > > Don't return null. Instead, instantiate your ParameterCollection and
> > return
> > > > it back although it will be emply.
> > > >
> > > > --
> > > > Hope this helps.
> > > >
> > > > ----
> > > > Teo Lachev, MCSD, MCT
> > > > Author: "Microsoft Reporting Services in Action"
> > > > Publisher website: http://www.manning.com/lachev
> > > > Buy it from Amazon.com: http://shrinkster.com/eq
> > > > Home page and blog: http://www.prologika.com/
> > > > ----
> > > >
> > > > "Chris Webb" <OnlyForPostingToNewsgroups@.hotmail.com> wrote in
message
> > > > news:7373D28A-BDDA-450B-B1DC-53605BF8C821@.microsoft.com...
> > > > > Hi all,
> > > > >
> > > > > I'm trying to develop a custom data extension for a proprietary
> > database
> > > > we
> > > > > use, and I'm running into problems. I've built a test harness for
it
> > and
> > > > it
> > > > > works fine; however when I try to use it with RS I get the
following
> > error
> > > > > just after having entered my query and pressed Next in the New
Report
> > > > wizard:
> > > > > "An error occurred while the query design method was being saved.
> > Object
> > > > > reference not set to an instance of an object"
> > > > >
> > > > > When I step through my code, I can see that everything goes well
until
> > the
> > > > > designer tries to call the Parameters property on the Command
object.
> > > > Because
> > > > > my database doesn't support parameters I'm returning null here,
> > something
> > > > > I've seen in several code examples. As soon as I've exited the
> > property I
> > > > get
> > > > > the error, with the debugger saying it originates from
> > > > > Microsoft.ReportDesigner.Design.Query.HasParameters.
> > > > >
> > > > > Other background information (in no particular order):
> > > > > - Before I get to the Parameters property, I see that the GetName
and
> > > > > GetFieldType properties on my DataReader are called the same
number of
> > > > times
> > > > > as there are columns in my resultset, and then the Dispose method
is
> > > > called
> > > > > on the DataReader.
> > > > > - My queries are in XML, and here's the sample I'm using for
testing:
> > > > > <DVAutoXMLFetch Database="C:\Program Files\IMS
> > Health\DATA\DBPINT01.PRM">
> > > > > <TimePeriods Count="4">
> > > > > <TimePeriod>QTR/3/02</TimePeriod>
> > > > > </TimePeriods>
> > > > > <Variables Count="3">
> > > > > <Variable>UN</Variable>
> > > > > </Variables>
> > > > > <Dimensions Count="16">
> > > > > <Dimension Name="CTY" IsGroup="False" BaseDim="">
> > > > > <Member>AUSTRIA</Member>
> > > > > </Dimension>
> > > > > </Dimensions>
> > > > > <FetchDefinition>
> > > > > <NumberPrecision ValColNumPrec="1000" ValColRndPrec="1"
> > > > CalcColRndPrec="3"
> > > > > />
> > > > > <AcrossMeasures Count="2">
> > > > > <AcrossMeasure Index="1" DimName="TimePeriods" />
> > > > > <AcrossMeasure Index="2" DimName="Variables" />
> > > > > <Columns Count="1" Rank="0" CalcRank="0" />
> > > > > </AcrossMeasures>
> > > > > <DownMeasures Count="1">
> > > > > <DownMeasure Index="1" DimName="CTY" />
> > > > > </DownMeasures>
> > > > > </FetchDefinition>
> > > > > </DVAutoXMLFetch>
> > > > > - I'm running RS SP1 on Windows 2000.
> > > > > - I can post the source code if anyone wants...
> > > > >
> > > > > Thanks in advance for any hints!
> > > > >
> > > > > Chris
> > > > >
> > > >
> > > >
> > > >
> >
> >
> >|||Using Custom data Extensions , i am able to pass a dataset to my report. All goes fine as long as i dont need a parameter to pass to my stored procedure which i execute from my CDE. But i now need to pass a parameter to it for it to return a dataset.Please help.I have spend lots of time over this but have not yet goy the soluion
From http://www.developmentnow.com/g/115_2004_9_0_0_450456/Custom-Data-Extension-problems.ht
Posted via DevelopmentNow.com Group
http://www.developmentnow.com
Friday, February 17, 2012
Custom Assembly deserialization issue
server, even though things are running fine in design mode on their local
machines. I know that you need to copy all assemblies referenced to
/80/Tools/Report Designer/ and /MSSQL/Reporting Services/ReportServe/bin/ as
well as update rspreviewpolicy.config and rssrvpolicy.config files with
something resembling the following:
<CodeGroup
class="UnionCodeGroup"
version="1"
PermissionSetName="FullTrust"
Name="Custom_Code_Group"
Description="Allows for custom code execution in Reporting Services">
<IMembershipCondition class="UrlMembershipCondition"
version="1"
Url="C:/Program Files/Microsoft SQL Server/80/Tools/Report Designer/*"/>
</CodeGroup>
However, when I try to run the report in the preview utility or on the
server, I am presented with:
<i>Request for the permission of type
System.Security.Permissions.StrongNameIdentityPermission, mscorlib,
Version=1.0.5000.0, Culture=neutral, PublicKeyToken=[PublicKeyToken]
failed.</i>
In the preview tab in the designer, the referenced assemblies are properly
deserializing my serialized object being returned by the query but since
there's this security issue when running the report elsewhere, I am having no
such luck. What am I doing wrong?It is also worth mentioning that the other error I get sporadically without
rhyme or reason is:
The value expression for the textbox â'textboxâ' contains an error: Cannot
find the assembly AssemblyName, Version=1.0.2120.25649, Culture=neutral,
PublicKeyToken=null.
This appears and disappears as I close and reopen Visual Studio as well as
rebuild my reporting project.|||Hi Keenan,
As you are doing the mermership of the assembly through the url and not the
strong name of the assembly maybe this is your case... in your server, the
assemblies are located exacly at: C:/Program Files/Microsoft SQL
Server/80/Tools/Report Designer/ ? or maybe it's in a different drive? if
they are not located in the same place you would have to change the url or
try with a membership with the strong name of the assembly
"Keenan Chadwick" <KeenanChadwick@.discussions.microsoft.com> wrote in
message news:D9C0CF29-9C02-45E9-AC79-5CBE3505173D@.microsoft.com...
> I see a lot of people are having the same issue when deploying to the
report
> server, even though things are running fine in design mode on their local
> machines. I know that you need to copy all assemblies referenced to
> /80/Tools/Report Designer/ and /MSSQL/Reporting Services/ReportServe/bin/
as
> well as update rspreviewpolicy.config and rssrvpolicy.config files with
> something resembling the following:
> <CodeGroup
> class="UnionCodeGroup"
> version="1"
> PermissionSetName="FullTrust"
> Name="Custom_Code_Group"
> Description="Allows for custom code execution in Reporting Services">
> <IMembershipCondition class="UrlMembershipCondition"
> version="1"
> Url="C:/Program Files/Microsoft SQL Server/80/Tools/Report Designer/*"/>
> </CodeGroup>
> However, when I try to run the report in the preview utility or on the
> server, I am presented with:
> <i>Request for the permission of type
> System.Security.Permissions.StrongNameIdentityPermission, mscorlib,
> Version=1.0.5000.0, Culture=neutral, PublicKeyToken=[PublicKeyToken]
> failed.</i>
> In the preview tab in the designer, the referenced assemblies are properly
> deserializing my serialized object being returned by the query but since
> there's this security issue when running the report elsewhere, I am having
no
> such luck. What am I doing wrong?|||According to Microsoft, there is no need to have a strong-named assembly when
doing custom code. The URL references the exact spot on the server (from the
server's point of view, of course) where the assemblies reside. Nothing
works. I've tried strong-naming my assemblies and that caused a huge error
even in the design preview, so I have no idea at this point.
I am pretty sure there is some way to get my assemblies to run, since they
work in the design preview mode which runs everything with full permission.
Microsoft's support suggestion to me was really a question asking me to wait
for the 2005 suite of everything.
Tuesday, February 14, 2012
cursors CPU usage
i started trace and found some procedures running in background
1) sp_cursorope
2) sp_cursorfetch and sp_cursorclose.
wot are these system procedures and it runs after every 2-3 mins and taking too much cpu.
any help would be appreciated
SanjayGenerally, those are SP's used by the MDAC client when a cursor is opened to
retrieve data by an application. Have a look at what application is being
used at the time. Maybe that application needs tuning.
Those 3 are Extended SP's that are shipped with SQL as standard and can not
be changed.
Cheers
--
Mike Epprecht, Microsoft SQL Server MVP
Epprecht Consulting (PTY) LTD
Johannesburg, South Africa
Mobile: +27-82-552-0268
IM: mike@.NOSPAMepprecht.net
Specialist SQL Server Solutions and Consulting
"sanjay" <anonymous@.discussions.microsoft.com> wrote in message
news:59A038C1-4F19-4AD0-8FD2-440ECEDF008E@.microsoft.com...
> hi
> i started trace and found some procedures running in background.
> 1) sp_cursoropen
> 2) sp_cursorfetch and sp_cursorclose..
> wot are these system procedures and it runs after every 2-3 mins and
taking too much cpu..
> any help would be appreciated.
> Sanjay|||hi mike,
i checked the application..but this sp's run continously after every 2-3 mins and there are no background processes running on..
do they utilise cpu..as site is working too slow..
can we avoid them'
regards
sanjay|||These stored procedures are being called on the behalf of
the application. For instance, if your application
executes a query "select field1, field2,... from table1",
the ADO drivers are converting this to the three cursor
stored procedure calls. Essentially what is happening is
that the first one, sp_cursoropen executes the query
storing the results in a server side cursor (sort of a
temp table), and the sequence of sp_cursorfetch's return
the rows to the application on the client side.
sp_cursorclose closes the server side cursor.
This is usually the result of an application written to
use the defaults when populating an ADO recordset. It
becomes very inefficient if you have a large number of
rows to return, since the default is to return one row to
the client for each execution of the sp_cursorfetch
stored proc. If the third parameter for sp_cursorfetch
is 1 (one), then you are seeing this default behavior.
To fix this you would have to recode the application to
use non-default ADO property settings for properties like
cachesize or cursorlocation.
I hope that this helps.
Matthew Bando
BandoM@.CSCTGI(RemoveThis).com
>--Original Message--
>hi mike,
> i checked the application..but this sp's run
continously after every 2-3 mins and there are no
background processes running on..
>do they utilise cpu..as site is working too slow..
>can we avoid them'
>regards
>sanjay
>.
>