Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

How to merge two reports using ttx file as datasource.

Posted on 2004-08-24
11
Medium Priority
?
703 Views
Last Modified: 2011-10-03
I'm trying to merge two reports using a ttx data file with a disconnected recordset as the data source. However I cannot get the second report to show any data.  

When I use MS Access as the data source, I can merge two reports by placing the second report as a subreport in the first report footer, linking on a similar parameter. So its like the first report will cycle through all its records.  Then at the report footer, the second report knows to cycle through all its records before being displayed -in effect giving me two merged reports.

However when I use a ttx file with a disconnected recordset as the data source.  The first report dispalys all the records.  But in the report footer no records are displayed for the second report. This scenario is actually what I expect, why will data appear in the second report with MS Access but not with a disconnected recordset?

I know I may not have been completely clear so any help on this would be appreciated.

0
Comment
Question by:TommyTupa
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 5
  • 3
  • 2
  • +1
11 Comments
 
LVL 10

Accepted Solution

by:
ebolek earned 1000 total points
ID: 11882296
is the ttx file inserted to the main report as the sub report too. If it is, it should work . what version of crystal are using
0
 
LVL 13

Author Comment

by:TommyTupa
ID: 11882379
Yes.  I'm using crystal 9.0 developer.  I've donwloaded all the latest service packs/hot fixes.
0
 
LVL 10

Expert Comment

by:ebolek
ID: 11882394
why are you using ttx file as the datasource of the sub report. Are the link sto the sub report right
0
Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 
LVL 13

Author Comment

by:TommyTupa
ID: 11882544
I kinda thought I had to use the ttx file as the data source of the subreport.  And I believe my links are correct because I  accomplished my goal first in MS Access for testing.  And now I'm trying to get it to work with ttx files.
0
 
LVL 42

Assisted Solution

by:frodoman
frodoman earned 500 total points
ID: 11882689
Sounds like there's no data available to the second report.  You didn't create the dataset with a forward-only cursor that may be preventing the second report from reading?

0
 
LVL 101

Assisted Solution

by:mlmcc
mlmcc earned 500 total points
ID: 11883141
Is there a need to link the subreport?  When you do that it will filter the data for the second report to match to linking value.

mlmcc
0
 
LVL 13

Author Comment

by:TommyTupa
ID: 11884027
I didn't create a forward-only cursor.  And I need to pass parameter values to the subreport.  Thats why I'm linking.  
0
 
LVL 13

Author Comment

by:TommyTupa
ID: 11884083
And I can take away the links to the second report and it still shows no data.
0
 
LVL 13

Author Comment

by:TommyTupa
ID: 11887271
Turns out the problem was with my code (...sigh) and not Crystal. I didn't mention this portion in the original question because I just knew the problem couldn't be my doing!!!   The DataSource method is new to RAS and lists some things as optional which turn out not to be optional at all.  Adding all the optional items finally got it to work:
Session("oClientDoc").SubReportController.setDataSource  "Report2.rpt", rstTableData,  Session("oClientDoc").SubReportController.GetSubreportDatabase("Report2.rpt").Tables.Item(0).Alias, "ADORecordset"

Thank you everyone for your input. I'll distribute the points evenly.
0
 
LVL 10

Expert Comment

by:ebolek
ID: 11887826
Glad to help

Regards
Emre
0
 
LVL 101

Expert Comment

by:mlmcc
ID: 11887969
Glad i could help

mlmcc
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I hate sub reports and always consider them the last resort in any reporting solution.  The negative effect on performance and maintainability is just not worth the easy ride they give the report writer.  Nine times out of ten reporting requirements…
Hot fix for .Net Crystal Reports 10.2.3600.0 to fix problems with sub reports running on 64 bit operating systems ISSUE: Reports which contain subreports fail with error "Missing Parameter Value" DEPLOYMENT SERVER OS: Windows 2008 with 64 bi…
In this video, Percona Solution Engineer Dimitri Vanoverbeke discusses why you want to use at least three nodes in a database cluster. To discuss how Percona Consulting can help with your design and architecture needs for your database and infras…
In this video, Percona Solutions Engineer Barrett Chambers discusses some of the basic syntax differences between MySQL and MongoDB. To learn more check out our webinar on MongoDB administration for MySQL DBA: https://www.percona.com/resources/we…

664 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question