Showing posts with label searched. Show all posts
Showing posts with label searched. Show all posts

Wednesday, March 7, 2012

Charts slow report rendering to a crawl

I've searched the forums on this issue, haven't really found the answer.

I have several nifty little sales reports which crunch a ton of data quite efficiently and render in just a few seconds in Report Manager. I've pushed as much of the data processing back to the server as possible, use a stored procedure (with parameters) in a shared datasource, don't return unneccessary data, all that. It works great.

When I first developed the reports, I continued generating my charts (which use the same data as the reports, just grouped differently) in Excel and pasting them in as images. Now I want to stop that nonsense and use the SSRS charts. I fooled around with the charting function and got a reasonable facimile of my Excel charts, two per report, which use their own separate stored procedures and the same shared datasource.

Now, reports that used to render in 5-8 seconds may take 1-5 MINUTES. Help! It's definitely the charts--taking them back out fixes the problem.

I have complete control over the datasources--would it make more sense to use non-shared sources, or to create totally separate shared sources? I saw a post that recommended "making data calls non-synchronous," but I have no idea how to do that.

Thanks for any suggestions.

On further investigation, it appears that deleting EITHER ONE of the charts brings the rendering time down almost to the same time as no chart at all. It's apparent that having MULTIPLE charts on a page multiplies the rendering time exponentially (I'm gonna tell Edward Tufte!)

This happens whether I put the charts side-by-side (preferred) or one above the other on the page--they just take FOREVER to render.

Anybody...?

|||

I know this post is a bit old but im having exactly the same problem.

I have a report that has around 150 charts on it once expanded and it is taking around 3 seconds to load each chart.

Is there a resolution for this?

Regards

Will

Charts slow report rendering to a crawl

I've searched the forums on this issue, haven't really found the answer.

I have several nifty little sales reports which crunch a ton of data quite efficiently and render in just a few seconds in Report Manager. I've pushed as much of the data processing back to the server as possible, use a stored procedure (with parameters) in a shared datasource, don't return unneccessary data, all that. It works great.

When I first developed the reports, I continued generating my charts (which use the same data as the reports, just grouped differently) in Excel and pasting them in as images. Now I want to stop that nonsense and use the SSRS charts. I fooled around with the charting function and got a reasonable facimile of my Excel charts, two per report, which use their own separate stored procedures and the same shared datasource.

Now, reports that used to render in 5-8 seconds may take 1-5 MINUTES. Help! It's definitely the charts--taking them back out fixes the problem.

I have complete control over the datasources--would it make more sense to use non-shared sources, or to create totally separate shared sources? I saw a post that recommended "making data calls non-synchronous," but I have no idea how to do that.

Thanks for any suggestions.

On further investigation, it appears that deleting EITHER ONE of the charts brings the rendering time down almost to the same time as no chart at all. It's apparent that having MULTIPLE charts on a page multiplies the rendering time exponentially (I'm gonna tell Edward Tufte!)

This happens whether I put the charts side-by-side (preferred) or one above the other on the page--they just take FOREVER to render.

Anybody...?

Friday, February 24, 2012

chart slows report render to crawl in Report Manager

I've searched the forums on this issue, haven't really found the answer.
I have several nifty little sales reports which crunch a ton of data quite
efficiently and render in just a few seconds in Report Manager. I've pushed
as much of the data processing back to the server as possible, use a stored
procedure (with parameters) in a shared datasource, don't return unneccessary
data, all that. It works great.
When I first developed the reports, I continued generating my charts (which
use the same data as the reports, just grouped differently) in Excel and
pasting them in as images. Now I want to stop that nonsense and use the SSRS
charts. I fooled around with the charting function and got a reasonable
facimile of my Excel charts, two per report, which use their own separate
stored procedures and the same shared datasource.
Now, reports that used to render in 5-8 seconds may take 1-5 MINUTES. Help!
It's definitely the charts--taking them back out fixes the problem.
I have complete control over the datasources--would it make more sense to
use non-shared sources, or to create totally separate shared sources? I saw
a post that recommended "making data calls non-synchronous," but I have no
idea how to do that.
Thanks for any suggestions.On further investigation, it appears that deleting EITHER ONE of the charts
brings the rendering time down almost to the same time as no chart at all.
It's apparent that having MULTIPLE charts on a page multiplies the rendering
time exponentially (I'm gonna tell Edward Tufte!)
This happens whether I put the charts side-by-side (preferred) or one above
the other on the page--they just take FOREVER to render.
Anybody...?|||RS 2005
I'm not sure how you mean your question about grouping. The charts each
have one grouping level, the table below them has three. Each component
(table, each chart separately) renders in roughly 5 seconds by itself. When
I put all three of them in the same report, the rendering time goes up to
well over one minute. Weird.
"Bruce L-C [MVP]" wrote:
> Hmmm, I don't know, I have a report with 3 charts and I don't see this
> issue. Do you have any grouping, anything special? Also, RS 2000 or RS 2005?
>
> --
> Bruce Loehle-Conger
> MVP SQL Server Reporting Services
> "elinde" <elinde@.discussions.microsoft.com> wrote in message
> news:301D52EC-E38F-423D-9A01-B4386A282B36@.microsoft.com...
> > On further investigation, it appears that deleting EITHER ONE of the
> > charts
> > brings the rendering time down almost to the same time as no chart at all.
> > It's apparent that having MULTIPLE charts on a page multiplies the
> > rendering
> > time exponentially (I'm gonna tell Edward Tufte!)
> >
> > This happens whether I put the charts side-by-side (preferred) or one
> > above
> > the other on the page--they just take FOREVER to render.
> >
> > Anybody...?
> >
>
>|||Is this deployed or in the IDE? If in the development environment try
deploying and see if that makes a difference in performance.
Bruce Loehle-Conger
MVP SQL Server Reporting Services
"elinde" <elinde@.discussions.microsoft.com> wrote in message
news:54603F35-85B8-405F-B979-DC03DD43AB16@.microsoft.com...
> RS 2005
> I'm not sure how you mean your question about grouping. The charts each
> have one grouping level, the table below them has three. Each component
> (table, each chart separately) renders in roughly 5 seconds by itself.
> When
> I put all three of them in the same report, the rendering time goes up to
> well over one minute. Weird.
> "Bruce L-C [MVP]" wrote:
>> Hmmm, I don't know, I have a report with 3 charts and I don't see this
>> issue. Do you have any grouping, anything special? Also, RS 2000 or RS
>> 2005?
>>
>> --
>> Bruce Loehle-Conger
>> MVP SQL Server Reporting Services
>> "elinde" <elinde@.discussions.microsoft.com> wrote in message
>> news:301D52EC-E38F-423D-9A01-B4386A282B36@.microsoft.com...
>> > On further investigation, it appears that deleting EITHER ONE of the
>> > charts
>> > brings the rendering time down almost to the same time as no chart at
>> > all.
>> > It's apparent that having MULTIPLE charts on a page multiplies the
>> > rendering
>> > time exponentially (I'm gonna tell Edward Tufte!)
>> >
>> > This happens whether I put the charts side-by-side (preferred) or one
>> > above
>> > the other on the page--they just take FOREVER to render.
>> >
>> > Anybody...?
>> >
>>|||This is happening in deployment, unfortunately. The server is big, new &
fast--it's not that.
"Bruce L-C [MVP]" wrote:
> Is this deployed or in the IDE? If in the development environment try
> deploying and see if that makes a difference in performance.
>
> --
> Bruce Loehle-Conger
> MVP SQL Server Reporting Services
> "elinde" <elinde@.discussions.microsoft.com> wrote in message
> news:54603F35-85B8-405F-B979-DC03DD43AB16@.microsoft.com...
> > RS 2005
> >
> > I'm not sure how you mean your question about grouping. The charts each
> > have one grouping level, the table below them has three. Each component
> > (table, each chart separately) renders in roughly 5 seconds by itself.
> > When
> > I put all three of them in the same report, the rendering time goes up to
> > well over one minute. Weird.
> >
> > "Bruce L-C [MVP]" wrote:
> >
> >> Hmmm, I don't know, I have a report with 3 charts and I don't see this
> >> issue. Do you have any grouping, anything special? Also, RS 2000 or RS
> >> 2005?
> >>
> >>
> >> --
> >> Bruce Loehle-Conger
> >> MVP SQL Server Reporting Services
> >>
> >> "elinde" <elinde@.discussions.microsoft.com> wrote in message
> >> news:301D52EC-E38F-423D-9A01-B4386A282B36@.microsoft.com...
> >> > On further investigation, it appears that deleting EITHER ONE of the
> >> > charts
> >> > brings the rendering time down almost to the same time as no chart at
> >> > all.
> >> > It's apparent that having MULTIPLE charts on a page multiplies the
> >> > rendering
> >> > time exponentially (I'm gonna tell Edward Tufte!)
> >> >
> >> > This happens whether I put the charts side-by-side (preferred) or one
> >> > above
> >> > the other on the page--they just take FOREVER to render.
> >> >
> >> > Anybody...?
> >> >
> >>
> >>
> >>
>
>|||Hmmm, I don't know, I have a report with 3 charts and I don't see this
issue. Do you have any grouping, anything special? Also, RS 2000 or RS 2005?
Bruce Loehle-Conger
MVP SQL Server Reporting Services
"elinde" <elinde@.discussions.microsoft.com> wrote in message
news:301D52EC-E38F-423D-9A01-B4386A282B36@.microsoft.com...
> On further investigation, it appears that deleting EITHER ONE of the
> charts
> brings the rendering time down almost to the same time as no chart at all.
> It's apparent that having MULTIPLE charts on a page multiplies the
> rendering
> time exponentially (I'm gonna tell Edward Tufte!)
> This happens whether I put the charts side-by-side (preferred) or one
> above
> the other on the page--they just take FOREVER to render.
> Anybody...?
>

Thursday, February 16, 2012

CHARINDEX

I find that CHARINDEX does not seem to return the position of a matching
phrase when the token being searched contains punctuation after the phrase.
In other words CHARINDEX('Birthday', 'Hope you have a happy Birthday!', 0)
does NOT return the position of Birthday in the phrase!!
Please can anyone advise me on this.
Thanks
Bryan
I get 23 from both SQL 2000 SP4, and SQL 2005 SP2.
Mohit K. Gupta
B.Sc. CS, Minor Japanese
MCTS: SQL Server 2005

Tuesday, February 14, 2012

Character greater than 'z'

I've searched and have not found any good answers to this. Maybe there
isn't one...
I need to have a string that when sorted with an ORDER BY, it comes after
the letter 'z'.
The database is created with the collation SQL_Latin1_General_CP1_CI_AS.
I know it is best to not rely on this and use some sort of surrogate field
to order the rows, but I cannot do that in this case - the data is being
used by SharePoint (MOSS) in a Business Data Catalog (BDC) column.
SharePoint will sort one of it's lists by the BDC column value, but it sorts
only by the values in that column.
In ASCII, I could use the tilde (~), but SQL is putting the tilde first in
the results.
Is there any character I could put at the beginning of the string so it
would fall out last in the query results?
(Remember, it is SharePoint generating the query, so I cannot change the SQL
it uses. I only control the values in the column.)
I assume the column is char or varchar? If so, you can use the value
CHAR(208), for example,
Set NoCount ON
Create Table #FooBar(Foo varchar(10))
Insert #FooBar (Foo) Values ('A')
Insert #FooBar (Foo) Values (Char(208))
Insert #FooBar (Foo) Values ('z')
Select Foo, Ascii(Foo)
From #FooBar
Order By Foo
go
Drop Table #FooBar
You can find all the characters which will sort after 'z' with the following
code
Set NoCount ON
Create Table #FooBar(Foo varchar(10))
Insert #FooBar (Foo) Values ('A')
Insert #FooBar (Foo) Values ('z')
Declare @.i int
Set @.i = 1
While @.i < 256
Begin
Insert #FooBar (Foo) Values (Char(@.i))
Set @.i = @.i + 1
End
Select Foo, Ascii(Foo)
From #FooBar
Where Foo > 'z'
Order By Foo
go
Drop Table #FooBar
Tom
"JD" <yazoo@.newsgroup.nospam> wrote in message
news:%23uiqZB3nIHA.3556@.TK2MSFTNGP04.phx.gbl...
> I've searched and have not found any good answers to this. Maybe there
> isn't one...
> I need to have a string that when sorted with an ORDER BY, it comes after
> the letter 'z'.
> The database is created with the collation SQL_Latin1_General_CP1_CI_AS.
> I know it is best to not rely on this and use some sort of surrogate field
> to order the rows, but I cannot do that in this case - the data is being
> used by SharePoint (MOSS) in a Business Data Catalog (BDC) column.
> SharePoint will sort one of it's lists by the BDC column value, but it
> sorts only by the values in that column.
> In ASCII, I could use the tilde (~), but SQL is putting the tilde first in
> the results.
> Is there any character I could put at the beginning of the string so it
> would fall out last in the query results?
> (Remember, it is SharePoint generating the query, so I cannot change the
> SQL it uses. I only control the values in the column.)
>
|||JD
select * from #FooBar order by case when foo ='z' then 1 else 2 end
"JD" <yazoo@.newsgroup.nospam> wrote in message
news:%23uiqZB3nIHA.3556@.TK2MSFTNGP04.phx.gbl...
> I've searched and have not found any good answers to this. Maybe there
> isn't one...
> I need to have a string that when sorted with an ORDER BY, it comes after
> the letter 'z'.
> The database is created with the collation SQL_Latin1_General_CP1_CI_AS.
> I know it is best to not rely on this and use some sort of surrogate field
> to order the rows, but I cannot do that in this case - the data is being
> used by SharePoint (MOSS) in a Business Data Catalog (BDC) column.
> SharePoint will sort one of it's lists by the BDC column value, but it
> sorts only by the values in that column.
> In ASCII, I could use the tilde (~), but SQL is putting the tilde first in
> the results.
> Is there any character I could put at the beginning of the string so it
> would fall out last in the query results?
> (Remember, it is SharePoint generating the query, so I cannot change the
> SQL it uses. I only control the values in the column.)
>
|||As I said, I cannot change the query, since Sharepoint is doing the query.
I can only affect the data in the column.
"Uri Dimant" <urid@.iscar.co.il> wrote in message
news:uVGG%2305nIHA.4328@.TK2MSFTNGP03.phx.gbl...
> JD
> select * from #FooBar order by case when foo ='z' then 1 else 2 end
>
> "JD" <yazoo@.newsgroup.nospam> wrote in message
> news:%23uiqZB3nIHA.3556@.TK2MSFTNGP04.phx.gbl...
>
|||Thanks - it is nvarchar, so I made a few changes to your example and found a
series of Unicode characters that sort after 'z':
set nocount on
create table #FooBar(Foo nvarchar(10))
insert #FooBar (Foo) values ('A')
declare @.i int
set @.i = 900
while (@.i < 1200)
begin
insert #FooBar (Foo) values (nchar(@.i))
set @.i = @.i + 1
end
insert #FooBar (Foo) values ('z')
select Foo, unicode(Foo)
from #FooBar
where Foo > 'z'
order by Foo
drop table #FooBar
"Tom Cooper" <tomcooper@.comcast.no.spam.please.net> wrote in message
news:O6sC0c3nIHA.4832@.TK2MSFTNGP06.phx.gbl...
>I assume the column is char or varchar? If so, you can use the value
>CHAR(208), for example,
> Set NoCount ON
> Create Table #FooBar(Foo varchar(10))
> Insert #FooBar (Foo) Values ('A')
> Insert #FooBar (Foo) Values (Char(208))
> Insert #FooBar (Foo) Values ('z')
> Select Foo, Ascii(Foo)
> From #FooBar
> Order By Foo
> go
> Drop Table #FooBar
> You can find all the characters which will sort after 'z' with the
> following code
> Set NoCount ON
> Create Table #FooBar(Foo varchar(10))
> Insert #FooBar (Foo) Values ('A')
> Insert #FooBar (Foo) Values ('z')
> Declare @.i int
> Set @.i = 1
> While @.i < 256
> Begin
> Insert #FooBar (Foo) Values (Char(@.i))
> Set @.i = @.i + 1
> End
> Select Foo, Ascii(Foo)
> From #FooBar
> Where Foo > 'z'
> Order By Foo
> go
> Drop Table #FooBar
> Tom
> "JD" <yazoo@.newsgroup.nospam> wrote in message
> news:%23uiqZB3nIHA.3556@.TK2MSFTNGP04.phx.gbl...
>

Character greater than 'z'

I've searched and have not found any good answers to this. Maybe there
isn't one...
I need to have a string that when sorted with an ORDER BY, it comes after
the letter 'z'.
The database is created with the collation SQL_Latin1_General_CP1_CI_AS.
I know it is best to not rely on this and use some sort of surrogate field
to order the rows, but I cannot do that in this case - the data is being
used by SharePoint (MOSS) in a Business Data Catalog (BDC) column.
SharePoint will sort one of it's lists by the BDC column value, but it sorts
only by the values in that column.
In ASCII, I could use the tilde (~), but SQL is putting the tilde first in
the results.
Is there any character I could put at the beginning of the string so it
would fall out last in the query results?
(Remember, it is SharePoint generating the query, so I cannot change the SQL
it uses. I only control the values in the column.)I assume the column is char or varchar? If so, you can use the value
CHAR(208), for example,
Set NoCount ON
Create Table #FooBar(Foo varchar(10))
Insert #FooBar (Foo) Values ('A')
Insert #FooBar (Foo) Values (Char(208))
Insert #FooBar (Foo) Values ('z')
Select Foo, Ascii(Foo)
From #FooBar
Order By Foo
go
Drop Table #FooBar
You can find all the characters which will sort after 'z' with the following
code
Set NoCount ON
Create Table #FooBar(Foo varchar(10))
Insert #FooBar (Foo) Values ('A')
Insert #FooBar (Foo) Values ('z')
Declare @.i int
Set @.i = 1
While @.i < 256
Begin
Insert #FooBar (Foo) Values (Char(@.i))
Set @.i = @.i + 1
End
Select Foo, Ascii(Foo)
From #FooBar
Where Foo > 'z'
Order By Foo
go
Drop Table #FooBar
Tom
"JD" <yazoo@.newsgroup.nospam> wrote in message
news:%23uiqZB3nIHA.3556@.TK2MSFTNGP04.phx.gbl...
> I've searched and have not found any good answers to this. Maybe there
> isn't one...
> I need to have a string that when sorted with an ORDER BY, it comes after
> the letter 'z'.
> The database is created with the collation SQL_Latin1_General_CP1_CI_AS.
> I know it is best to not rely on this and use some sort of surrogate field
> to order the rows, but I cannot do that in this case - the data is being
> used by SharePoint (MOSS) in a Business Data Catalog (BDC) column.
> SharePoint will sort one of it's lists by the BDC column value, but it
> sorts only by the values in that column.
> In ASCII, I could use the tilde (~), but SQL is putting the tilde first in
> the results.
> Is there any character I could put at the beginning of the string so it
> would fall out last in the query results?
> (Remember, it is SharePoint generating the query, so I cannot change the
> SQL it uses. I only control the values in the column.)
>|||JD
select * from #FooBar order by case when foo ='z' then 1 else 2 end
"JD" <yazoo@.newsgroup.nospam> wrote in message
news:%23uiqZB3nIHA.3556@.TK2MSFTNGP04.phx.gbl...
> I've searched and have not found any good answers to this. Maybe there
> isn't one...
> I need to have a string that when sorted with an ORDER BY, it comes after
> the letter 'z'.
> The database is created with the collation SQL_Latin1_General_CP1_CI_AS.
> I know it is best to not rely on this and use some sort of surrogate field
> to order the rows, but I cannot do that in this case - the data is being
> used by SharePoint (MOSS) in a Business Data Catalog (BDC) column.
> SharePoint will sort one of it's lists by the BDC column value, but it
> sorts only by the values in that column.
> In ASCII, I could use the tilde (~), but SQL is putting the tilde first in
> the results.
> Is there any character I could put at the beginning of the string so it
> would fall out last in the query results?
> (Remember, it is SharePoint generating the query, so I cannot change the
> SQL it uses. I only control the values in the column.)
>|||As I said, I cannot change the query, since Sharepoint is doing the query.
I can only affect the data in the column.
"Uri Dimant" <urid@.iscar.co.il> wrote in message
news:uVGG%2305nIHA.4328@.TK2MSFTNGP03.phx.gbl...
> JD
> select * from #FooBar order by case when foo ='z' then 1 else 2 end
>
> "JD" <yazoo@.newsgroup.nospam> wrote in message
> news:%23uiqZB3nIHA.3556@.TK2MSFTNGP04.phx.gbl...
>> I've searched and have not found any good answers to this. Maybe there
>> isn't one...
>> I need to have a string that when sorted with an ORDER BY, it comes after
>> the letter 'z'.
>> The database is created with the collation SQL_Latin1_General_CP1_CI_AS.
>> I know it is best to not rely on this and use some sort of surrogate
>> field to order the rows, but I cannot do that in this case - the data is
>> being used by SharePoint (MOSS) in a Business Data Catalog (BDC) column.
>> SharePoint will sort one of it's lists by the BDC column value, but it
>> sorts only by the values in that column.
>> In ASCII, I could use the tilde (~), but SQL is putting the tilde first
>> in the results.
>> Is there any character I could put at the beginning of the string so it
>> would fall out last in the query results?
>> (Remember, it is SharePoint generating the query, so I cannot change the
>> SQL it uses. I only control the values in the column.)
>>
>|||Thanks - it is nvarchar, so I made a few changes to your example and found a
series of Unicode characters that sort after 'z':
set nocount on
create table #FooBar(Foo nvarchar(10))
insert #FooBar (Foo) values ('A')
declare @.i int
set @.i = 900
while (@.i < 1200)
begin
insert #FooBar (Foo) values (nchar(@.i))
set @.i = @.i + 1
end
insert #FooBar (Foo) values ('z')
select Foo, unicode(Foo)
from #FooBar
where Foo > 'z'
order by Foo
drop table #FooBar
"Tom Cooper" <tomcooper@.comcast.no.spam.please.net> wrote in message
news:O6sC0c3nIHA.4832@.TK2MSFTNGP06.phx.gbl...
>I assume the column is char or varchar? If so, you can use the value
>CHAR(208), for example,
> Set NoCount ON
> Create Table #FooBar(Foo varchar(10))
> Insert #FooBar (Foo) Values ('A')
> Insert #FooBar (Foo) Values (Char(208))
> Insert #FooBar (Foo) Values ('z')
> Select Foo, Ascii(Foo)
> From #FooBar
> Order By Foo
> go
> Drop Table #FooBar
> You can find all the characters which will sort after 'z' with the
> following code
> Set NoCount ON
> Create Table #FooBar(Foo varchar(10))
> Insert #FooBar (Foo) Values ('A')
> Insert #FooBar (Foo) Values ('z')
> Declare @.i int
> Set @.i = 1
> While @.i < 256
> Begin
> Insert #FooBar (Foo) Values (Char(@.i))
> Set @.i = @.i + 1
> End
> Select Foo, Ascii(Foo)
> From #FooBar
> Where Foo > 'z'
> Order By Foo
> go
> Drop Table #FooBar
> Tom
> "JD" <yazoo@.newsgroup.nospam> wrote in message
> news:%23uiqZB3nIHA.3556@.TK2MSFTNGP04.phx.gbl...
>> I've searched and have not found any good answers to this. Maybe there
>> isn't one...
>> I need to have a string that when sorted with an ORDER BY, it comes after
>> the letter 'z'.
>> The database is created with the collation SQL_Latin1_General_CP1_CI_AS.
>> I know it is best to not rely on this and use some sort of surrogate
>> field to order the rows, but I cannot do that in this case - the data is
>> being used by SharePoint (MOSS) in a Business Data Catalog (BDC) column.
>> SharePoint will sort one of it's lists by the BDC column value, but it
>> sorts only by the values in that column.
>> In ASCII, I could use the tilde (~), but SQL is putting the tilde first
>> in the results.
>> Is there any character I could put at the beginning of the string so it
>> would fall out last in the query results?
>> (Remember, it is SharePoint generating the query, so I cannot change the
>> SQL it uses. I only control the values in the column.)
>>
>