Showing posts with label exception. Show all posts
Showing posts with label exception. Show all posts

Thursday, March 29, 2012

Error exporting to Excel with expression in footer

I can export to all other formats from the report viewer with no issues, but when I try to render to Excel, I get an exception:

[Exception: Object reference not set to an instance of an object.]

[Exception: An error occurred during rendering of the report.]

[Exception: An error occurred during rendering of the report.]
Microsoft.Reporting.WebForms.ServerReport.ServerUrlRequest(Boolean isAbortable, String url, Stream outputStream, String& mimeType, String& fileNameExtension) +553
Microsoft.Reporting.WebForms.ServerReport.InternalRender(Boolean isAbortable, String format, String deviceInfo, NameValueCollection urlAccessParameters, Stream reportStream, String& mimeType, String& fileNameExtension) +941
Microsoft.Reporting.WebForms.ServerReport.Render(String format, String deviceInfo, NameValueCollection urlAccessParameters, String& mimeType, String& fileNameExtension) +97
Microsoft.Reporting.WebForms.ServerReportControlSource.RenderReport(String format, String deviceInfo, NameValueCollection additionalParams, String& mimeType, String& fileExtension) +126
Microsoft.Reporting.WebForms.ExportOperation.PerformOperation(NameValueCollection urlQuery, HttpResponse response) +153
Microsoft.Reporting.WebForms.HttpHandler.ProcessRequest(HttpContext context) +202
System.Web.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +154
System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +64

I've pinned it down to a footer cell that uses an expression to determine the TextAlign property. If I do something as simple as ="Right", I get the error. Of course, if I just use Right, there is no problem. So are expressions not supported in footer cell properties or is there possibly some fix for this?

Thanks.

The only solution would be to keep the textbox in the report body than the footer.

Shyam

|||

How can I get text to act like a page footer in the report body?

In case any MS folks are reading and want to reproduce this problem, here's a simple report that exhibits the behavior:

Code Snippet

<?xml version="1.0" encoding="utf-8"?>

<Report xmlns="http://schemas.microsoft.com/sqlserver/reporting/2005/01/reportdefinition" xmlns:rd="http://schemas.microsoft.com/SQLServer/reporting/reportdesigner">

<BottomMargin>1in</BottomMargin>

<RightMargin>1in</RightMargin>

<rd:DrawGrid>true</rd:DrawGrid>

<InteractiveWidth>8.5in</InteractiveWidth>

<rd:SnapToGrid>true</rd:SnapToGrid>

<Body>

<Height>0.79in</Height>

</Body>

<rd:ReportID>503a3ed2-a87d-4315-8de8-77c3ff0e807f</rd:ReportID>

<LeftMargin>1in</LeftMargin>

<Width>5in</Width>

<InteractiveHeight>11in</InteractiveHeight>

<Language>en-US</Language>

<PageFooter>

<ReportItems>

<Textbox Name="textbox3">

<Top>0.125in</Top>

<rd:DefaultName>textbox3</rd:DefaultName>

<Style>

<TextAlign>=IIf(Globals!PageNumber Mod 2 = 0, "Left", "Right")</TextAlign>

<PaddingLeft>2pt</PaddingLeft>

<PaddingBottom>2pt</PaddingBottom>

<PaddingRight>2pt</PaddingRight>

<PaddingTop>2pt</PaddingTop>

</Style>

<CanGrow>true</CanGrow>

<Value>Test</Value>

</Textbox>

</ReportItems>

<Height>0.375in</Height>

<PrintOnLastPage>true</PrintOnLastPage>

<PrintOnFirstPage>true</PrintOnFirstPage>

</PageFooter>

<TopMargin>1in</TopMargin>

</Report>

|||

Try to handle in the value property of the textbox. For example:

IIf(Globals!PageNumber Mod 2 = 0, CStr(Globals!PageNumber) & Space(15), Space(15) & CStr(Globals!PageNumber))

Shyam

Error exporting to Excel

SSRS 2005...report exports to all formats, but when I try to go to excel i get an error.

Unhandled exception was caught:

Microsoft.Reporting.WebForms.ReportServerException: An error occurred during rendering of the report. (rrRenderingError)

Microsoft.Reporting.WebForms.ReportServerException: Stack empty

Excel has limitations that other rendering extensions do not have. Two of these limitations are from Excel - Max of 256 columns per sheet and ~65000 rows per sheet.|||

Actually that wasn't the issue...the report had about 10 columns and 3000 rows of data.

I solved it. The issue is that one of the formulas was trying to divide by zero in the denominator. The buggy behavior was that in HTML or PDF this simply renders as #Error in the textbox. But when you go to export to Excel, you don't even get that luxury. You get a nasty and ambiguous "Stack Empty" rendering error.

Actually if the resultset IS more than 65k rows it would be nice to provide an enduser with a message to that effect anyway...

sql

Tuesday, March 27, 2012

Error executing extended stored procedure: Invalid Parameter

When I try to connect to sql server instance I received this error:
TITLE: Microsoft SQL Server Management Studio
--
An exception occurred while executing a Transact-SQL statement or batch.
(Microsoft.SqlServer.ConnectionInfo)
--
ADDITIONAL INFORMATION:
Error executing extended stored procedure: Invalid Parameter
Error executing extended stored procedure: Invalid Parameter (Microsoft SQL
Server, Error: 22001)
when i click refresh button i am able to see my schema, but i can't see the
properties of my base and any table properties. I receive error:
TITLE: Microsoft SQL Server Management Studio
--
Cannot show requested dialog.
--
ADDITIONAL INFORMATION:
Cannot show requested dialog. (SqlMgmt)
--
An exception occurred while executing a Transact-SQL statement or batch.
(Microsoft.SqlServer.ConnectionInfo)
--
Error executing extended stored procedure: Invalid Parameter
Error executing extended stored procedure: Invalid Parameter (Microsoft SQL
Server, Error: 22001)
--
BUTTONS:
OK
--
also the registry key
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft SQL Server\Instance Names is
locked and can not be opened.
After a reboot the key is now readable and the 2005 instance can be
connected to without these messages.
But after a while it does it again.
does anyone have any idea what is going wrong?Hi
My guess is that you have some group policy or Anti-virus/ISD system that is
locking down this registry key.
John
"nikolakg" wrote:
> When I try to connect to sql server instance I received this error:
> TITLE: Microsoft SQL Server Management Studio
> --
> An exception occurred while executing a Transact-SQL statement or batch.
> (Microsoft.SqlServer.ConnectionInfo)
> --
> ADDITIONAL INFORMATION:
> Error executing extended stored procedure: Invalid Parameter
> Error executing extended stored procedure: Invalid Parameter (Microsoft SQL
> Server, Error: 22001)
>
> when i click refresh button i am able to see my schema, but i can't see the
> properties of my base and any table properties. I receive error:
> TITLE: Microsoft SQL Server Management Studio
> --
> Cannot show requested dialog.
> --
> ADDITIONAL INFORMATION:
> Cannot show requested dialog. (SqlMgmt)
> --
> An exception occurred while executing a Transact-SQL statement or batch.
> (Microsoft.SqlServer.ConnectionInfo)
> --
> Error executing extended stored procedure: Invalid Parameter
> Error executing extended stored procedure: Invalid Parameter (Microsoft SQL
> Server, Error: 22001)
>
> --
> BUTTONS:
> OK
> --
>
> also the registry key
> HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft SQL Server\Instance Names is
> locked and can not be opened.
> After a reboot the key is now readable and the 2005 instance can be
> connected to without these messages.
> But after a while it does it again.
> does anyone have any idea what is going wrong?

error enabling AWE to access >2GB of memory

hi,

I am having a problem enabling this, I am getting the error message:

Alter failed. (Microsoft.SqlServer.Smo)

Aditional information:

An exception occurred while executing a Transact-SQl Statement or batch
(Microsoft.SqlServer.ConnectionInfo)

Address Windowing Extensions (AWE) requires the 'lock pages in memory' privilege which is not currently present in the access token of the process.

Configuration option 'show advanced options' changed from 1 to 0. Run the RECONFIGURE statement to install (Microsoft SQL Server, Error: 5845)

-- end of error.

Prior to this, I opened up gpedit.msc, and associated the Administrator on the "lock pages in memory" policy.

I rebooted the server thinking that this might require it, but it didn't. I still cannot access memory .2Gb.

Any ideas?

cheers.hi,

anyone who can help?

thanks

Wednesday, March 21, 2012

Error de Aplication

SQL dump exception Handler: Process 58 Generated fatal exception C0000005. Exception acces violation. SQL server is terminating this process.
I don=B4t undesrstand please help me !!!
please send email anaula@.maint.com.ecThese types of errors are bugs in SQL Server. Search Knowledgebase for info and make sure you are
current on service packs. If that doesn't help, open a case with Microsoft Support.
--
Tibor Karaszi, SQL Server MVP
Archive at: http://groups.google.com/groups?oi=djq&as ugroup=microsoft.public.sqlserver
"Ana Naula" <anaula@.maint.com.ec> wrote in message news:0c5c01c391ea$f8fb4f20$a101280a@.phx.gbl...
SQL dump exception Handler: Process 58 Generated fatal
exception C0000005. Exception acces violation. SQL server
is terminating this process.
I don´t undesrstand please help me !!!
please send email anaula@.maint.com.ec

error creating publication

When I am in my publications folder and I attempt to add
a new publication, I get... 'Error 5: [SQL-DMO]Code
Execution exception: EXCEPTION_ACCESS_VIOLATION' after I
click next for the first time. If I click OK in the
error box, there are no publication databases listed.
HELP!!!!
Some times EM gets confused with all the caching it does.
Can you try to create the publication using the stored procedures?
Hilary Cotter
Looking for a book on SQL Server replication?
http://www.nwsu.com/0974973602.html
"larry" <anonymous@.discussions.microsoft.com> wrote in message
news:0af901c48b82$7daf3420$a501280a@.phx.gbl...
> When I am in my publications folder and I attempt to add
> a new publication, I get... 'Error 5: [SQL-DMO]Code
> Execution exception: EXCEPTION_ACCESS_VIOLATION' after I
> click next for the first time. If I click OK in the
> error box, there are no publication databases listed.
> HELP!!!!
>
sql

Sunday, March 11, 2012

Error converting data type varchar to datetime.

Hi,

It is not exactly what I stated in the subject - It's an outcome - exception thrown while executing non-query command.

I get this exception when I try to execute my stored procedure that takes datetime as one of its parameters.

I am using dataset designer to create table adapters and build queries. Then I simply use objectdatasource component that uses one of the table adapters and bind it to for example a detailsview control.

When I run this in debug mode and trace the objects everything looks perfect including these datetime parameters. It is sql server that throws the exception. I ran the sql profiler to see what exactly is going on, and I captured the command that is sent by ADO - it's broken into several lines right in the middle of my datetime parameters... this is the source of the problem. Everything is working fine when I take this command and execute it as a single line in the sql management studio.

Is there anything about ADO that I do not know?

Is the error only with that particular SQL statement or anyother query with date? What datatype you are passing to the stored procedure? DateTime or varchar?

Thanks

|||

Are you passing date as string ? Are you sure that you date format is the same as default date format on SQL server?

If your date is not in valid format for SQL you can have this kind of problems.

Thanks

Friday, February 24, 2012

Error Code = 0x8007000E, External Code = 0x00000000: Exception when deploying the SSAS

Hi
I am getting this error when deploying the Analysis Services Project.

Error Code = 0x8007000E, External Code = 0x00000000:

Can anyone Point me the reason for the same?

Thankyou
Vidya
Test your connection, if it's OK, delete your AS database and deploy it again.

Error Code = 0x8007000E, External Code = 0x00000000: Exception when deploying the SSAS

Hi
I am getting this error when deploying the Analysis Services Project.

Error Code = 0x8007000E, External Code = 0x00000000:

Can anyone Point me the reason for the same?

Thankyou
Vidya
Test your connection, if it's OK, delete your AS database and deploy it again.

Sunday, February 19, 2012

Error automating SQL DTS Pkg from VB6 to VB.Net

I am trying to convert a VB6 SQL 2000 created code into VB.NET. Everything
complies fine but then I get this error message:
An unhandled exception of type 'System.InvalidCastException' occurred in
Project1.exe
Additional information: QueryInterface for interface DTS.CustomTask failed.
This is the portion of the code that it is breaking on:
I found 2 ways to do this but both ways are giving me the same error message
Way #1:
Public Sub Task_Sub1(ByVal goPackage As DTS.Package2)
Dim oTask As DTS.Task
Dim oLookup As DTS.Lookup
Dim oCustomTask1 As DTS.DataPumpTask2
oTask = CType(goPackage, DTS.Package2).Tasks.New("DTSDataPumpTask")
oTask = goPackage.Tasks.New("DTSDataPumpTask")
oCustomTask1 = oTask.CustomTask
Way #2:
Public Sub Task_Sub1(ByVal goPackage As Object)
Dim oTask As DTS.Task
Dim oLookup As DTS.Lookup
Dim oCustomTask1 As DTS.DataPumpTask2
oTask = CType(goPackage, DTS.Package2).Tasks.New("DTSDataPumpTask")
oCustomTask1 = oTask.CustomTask
If anyone has an idea on what I need to change in the code I would greatly
appreciate it.
Thanks in advanceJohn,
Try with this excellent article from Gert Drapers:
http://www.sqldev.net/dts/DotNETCookBook.htm.
Dejan Sarka, SQL Server MVP
Mentor
www.SolidQualityLearning.com
"John" <John@.discussions.microsoft.com> wrote in message
news:B830B251-9289-4510-9ED8-6165AB2A0B92@.microsoft.com...
>I am trying to convert a VB6 SQL 2000 created code into VB.NET. Everything
> complies fine but then I get this error message:
> An unhandled exception of type 'System.InvalidCastException' occurred in
> Project1.exe
> Additional information: QueryInterface for interface DTS.CustomTask
> failed.
> This is the portion of the code that it is breaking on:
> I found 2 ways to do this but both ways are giving me the same error
> message
> Way #1:
> Public Sub Task_Sub1(ByVal goPackage As DTS.Package2)
> Dim oTask As DTS.Task
> Dim oLookup As DTS.Lookup
> Dim oCustomTask1 As DTS.DataPumpTask2
> oTask = CType(goPackage, DTS.Package2).Tasks.New("DTSDataPumpTask")
> oTask = goPackage.Tasks.New("DTSDataPumpTask")
> oCustomTask1 = oTask.CustomTask
> Way #2:
> Public Sub Task_Sub1(ByVal goPackage As Object)
> Dim oTask As DTS.Task
> Dim oLookup As DTS.Lookup
> Dim oCustomTask1 As DTS.DataPumpTask2
> oTask = CType(goPackage, DTS.Package2).Tasks.New("DTSDataPumpTask")
> oCustomTask1 = oTask.CustomTask
> If anyone has an idea on what I need to change in the code I would greatly
> appreciate it.
> Thanks in advance
>

Friday, February 17, 2012

error attaching adventureworks database and SSIS training database

Hi there,

I got this error when i tried to attach the adventureworks database and SSIS training database.

an exception occurred while executing a transact-sql statement or batch
(microsoft.sqlserver.connectioninfo)

could not find row in sysindexes for database ID 17, object ID 1, index ID 1. Run DBCC
checktable on sysindexes.

I join join a network domain for my computer. Previously it doesnt have this problem.

Hello,

It appears that you are trying to attach a SQL Server 2005 database to an instance of SQL Server 2000 or earlier. Please try to attach the AV database to a SQL Server 2005 instance.

Derrick VanArnam - MSFT

Error at deployment time (SSAS 2005)

Hello all,

May be somebody know what does this error mean:


"Error 1 Exception of type 'System.OutOfMemoryException' was thrown. 0 0"

I get it during deployment of cube after small changes I made in cube role.

When I deleted the role to return project to prviouse condition which was working, I still get the same error.

If anybody has any idea - it would be very appreciated.

Thanks

Inna

Hard to say on what is going on. Not clear which component produced an error.

Try connecting to Analysis Server from SQL Profiler and see if you will get the same error from the server.

Can you try and make changes to the role from SQL Managment studio and see if you are getting the same error?

Edward.
--
This posting is provided "AS IS" with no warranties, and confers no rights

|||

Hello Inna

Could it be possible that Your workstation has not enough memory for the Business Intelligence Studio ? You could also have some trouble in he Control Panel/System/Performance. I recommend a contact with Your System Support.

regards

Matti

|||

Hi Edward,

Thank you for your answer.

From SQL Profiler I didn't see my deployment process - when task failed it doesn't reach server and doesn't apply any changes there.

I tried and made changes to the role from SQL Management studio as you advised and it worked without any errors.

At the same time project stood not up to date and I don't know how to export the changes I made directly on the server to VS to continue development:

I can open Analysis Database in V Studio and make changes directly on the server.

After all I reopened the project, deleted role at all and got the same error.

Every time after reboot - it let me to make and to deploy changes for only one time.

Do you have any idea what could be a problem?

Thanks a lot

Inna

|||

Hello Matti,

Thank you for your reply.

Unfortunately now I have to work directly on the server (Windows Server 2003 Standard x64 edition - 6 GB memory and 1 CPU). BI studio installed there. When I get this error during deployment time – memory doesn’t grow out of 2 GB. So I thought enough is still available.

May be I need to configure BI Studio the way it can raise the memory it needs? - I have no idea if it makes sense.

I didn't notice any degradation in performance on the server at the time I got memory error.

All additional ideas would be much appreciated.

Regards

Inna

|||

Hi Inna again

You seem to have lots of memory.

I have met same error and same behaviour ones with my own Java application in Windows Xp.

In that case I could make the correction by changing in the registry the limit for the space of memory the operating system allocates to that type of applications.

Sorry, but I am not an expert in Windows Server 2003. I expect that there somewhere is a limit for the size of memory the operating system allocates to one task.

This is only a quess, but I hope it would be helpfull.

regards

Matti