Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

subreport and "Perform grouping on server" option

Status
Not open for further replies.

chioma

IS-IT--Management
Aug 10, 2001
34
IT
I realized some reports (CR 7.0) that contain subreports.
The Subreport doesn't "Perform grouping on server" so the performance decrease dramatically (the "group by" clause disappear in "sql query").
I'm sure that the problem is in "subreport links" infact if I delete the where conditions in subreport the "group By" clause appeare in "sql query" (I have seen it in menu "database" -- "Show sql query"
This is the where condition that link main report with subreport:

"{Dati_Vendite.Desc_serie} = {?Pm-Dati_Vendite.Desc_serie} and
{Dati_Vendite.Desc_linea} = {?Pm-Dati_Vendite.Desc_linea}"


Is there someone that can help me?
 
First, edit the subreport and make sure it also has "perform grouping on server" checked.

Having said that, perform grouping on server has no effect if you display the details section in any way, or place a detail field on the group, page or report headers or footers.

Are you doing any of the above? Software Sales, Training and Support for Macola, Crystal Reports and Goldmine
dgilsdorf@mchsi.com
 
I'm doing all of the above but the problem is still alive.

Do you have any others suggestions? Is that option supported by CR 7? (With the 8.5 the report works well, but I can't use this release)
 
Are you sure you want to link as:

"{Dati_Vendite.Desc_serie} = {?Pm-Dati_Vendite.Desc_serie} and
{Dati_Vendite.Desc_linea} = {?Pm-Dati_Vendite.Desc_linea}"

If you don't actually have a parameter called {?Pm-Dati_etc_etc} then consider right clicking the subreport, selecting Change Subreport Links, and using the tiny scrollbar to link to the actual database field instead of the fields that start with {?Pm...}

Naith
 
O.K. Naith in my report I have linked the main report with the subreport using the "Change Subreport Links" function and Crystal have automatically created the parameters :
{?Pm-Dati_Vendite.Desc_serie}
{?Pm-Dati_Vendite.Desc_linea}

and the selection formula :

"{Dati_Vendite.Desc_serie} = {?Pm-Dati_Vendite.Desc_serie} and
{Dati_Vendite.Desc_linea} = {?Pm-Dati_Vendite.Desc_linea}"

but these conditions delete the "group by " clause on sql_query so the group by is performed by Crystal and not by the Db servere (sql-server).

Do you know why?

Thanks




 
It's the automatic links I'm querying, as this is what's probably forcing your subreport to drop the grouping on server.

What I was asking was whether or not you could verify that the automatic links assumed by Crystal to {?Pm_yada_yada_yada} is correct. I suspect that you will have to scroll down in the link field box using the very small scroll bar and choose the field name [bold]without[/bold] the ?Pm prefix.

This should allow the subreport to utilise the main report grouping, which will then be able to legitimately pass it's grouping on to the server.

Naith
 
Sorry but probably I don't understand what you wrote.
I should try to explain the problem better:
When I set-up "Change Subreport Links" I fix the value in this way:
1) Windows "Field(s) to link to:" I choose the "report Field" of the main report that I would pass to subreport (In example "{Dati_Vendite.Desc_serie}":that is a field of DB)

2)Windows "Subreport parameters field to use" Crystal force the name of the subreport's parameter that it automatically created, I can't choose another because in this combo-box thare are only Parameters and I can't choose the blank value because CR don't accept that value

3)I checked "select data in subreport based on field:" and then I selected "{Dati_Vendite.Desc_serie}" in the combo-box belove.(this is the right report field in subreport)

So I don't Understand when you write
"I suspect that you will have to scroll down in the link field box using the very small scroll bar and choose the field name [bold]without[/bold] the ?Pm prefix."
Please try to explain me in different way.

Thanks very much
 
I apologise about this, but I didn't pay close enough attention to your field. You will only see the fields I described if you are linking from a parameter field. But when I look back at dgillz's post, you say that you are doing all the things that he mentions in his 2nd paragraph.

Doing any of these things negates the affect of performing the grouping on the server.

Naith
 
I apologise too, but "I'm doing all of the above" means that I checked all the things that dgzillz wrote and any of these things aren't true.
Do you have any others suggestions?

Thanks in advance.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top