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 bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Table relationships not working..

Status
Not open for further replies.

paul123456

Technical User
Apr 29, 2002
518
US
I have having a hard time getting this to work..Heres what i have

Table1 = Calllogs
Billto
Extension Number
Date
Duration
Cost
Calltype

Table2 = Calltypes
Name
ID

Table3 = Departments
Site
Name
Department Name
Billto

I am trying to pull up infor based on the Department name..
Basically i was trying to group by department To the callrecords by joining Billto together. (this is the extension number)

Department.Billto = Calllogs.Billto

But then i need to know what call type it is so i did
Calllogs.Calltype = Calltypes.ID (these have the same data but different names)

I can't seem to display any data correctly..can somone help me out?


Thanks, PAUL

 
You didnt mention what version of Crystal you are using. Secondly what kind of database are you using?

This link should show you how the basic table linking works (CR 8.5 and below):


You can also download some sample reports from this link:


If this is not what you are looking for then please provide more information and I am sure you will find your answer here.

Kchaudhry
 
What happens if you change both joins to left joins, as in:

dept---left join-->calllogs---left join-->calltypes

...using the same fields for linking as you did for the equal joins?

-LB
 
I am using crystal 9..linked to an access database..

the department table has a field called Billto (extension)
in the same table (departments) it has an additional field called "name" this is what I have it grouped by..but right now when i click on one of the groups it displays all of the data in my calllogs (all the billto/extensions) My goal is to be able to click on one of the groups and have only the extenstion in the department show up.. departments and calllogs are linked together by Billto (which is extensions)

Thanks for the replies..i will try to left join them. and post in a bit.

Thanks, PAUL

 
What will be affected if i use a subreport for my call logs
what i want is a invoice like layout..but on the bottom a list of all call logs for that department name??

how else can i get my call logs to display as a list?

Thanks, PAUL

 
Ok heres what i have so far.. The inner join left looked like it worked..now i have them grouped by name in the deparment..and the records show up perfect..but only when displaying one page at a time and only one record at a time. Picture this...an invoice with the persons business name at the top..down below..it has all the call records. I works perfect if i put my records in the same details section as the invoice..but if i create a sub report so that the callrecords display row after row..it displays all records..can i get a section to display as a list without making a subreport??

Thanks, PAUL

 
I'm having trouble following your description. Could you please provide a sample of your report as it currently looks and then show what it should look like? It would help if you identified rows by sections, also, e.g.,:

GH1 {Dept.DeptName}
D {CallLog.Billto}
GF1

So far I can't identify what the issue is here.

-LB
 
Ok i'll try my best..first the table relationships

there are 2 tables im working with

Calllogs (holds all the call log data, phone #,time,billto,duration.

Departments (holds customer information)

Ok so departments is connected to Calllogs by a left outer join connecting by field Billto (billto is the equivelent to Extension Number)

I have a report that is grouped by "name" which is a field in department.

on my report if i insert some call records into the details section it will display them only 1 at a time.

so i figured ok so i need to create a subreport with in my report..so i can have my report with all clients information and then on the bottom followed by pages of information of all the details of the calllogs (just like a phone bill would have). but when i created the subreport and when i clicked on one of the groups (groups = department name. It did not display the information under that department name, it displayed all of the data in the calllogs.

what i am trying to do is group by department name and display all records under that department. (the would be linked by the billto field)

GH1 = Department.Name
Details = all customer info.

If i create detailsb section with some calllog records all records under my department name show up correctly but it only displays 1 record for each page.

I need to display all calllogs as a list under the department name..like a phone bill would do.


Thanks, PAUL

 
Make sure you haven't got NewPageAfter selected for any of the sections of your report.

Gary Parker
Systems Support Analyst
Manchester, England
 
Also make sure you do not have the details section formatted to "Print at bottom of the page"--this will cause only one detail to be printed per page.

Otherwise, I still had difficulty following what you were saying. Details by their nature should be printing like a list, one after the other. If you are still having trouble please provide a visual of your report format as I suggested earlier--showing what it looks like now and then what you would like it to look like.

I'm also unclear whether you are trying to report by customer or by department, or by customer within department--in the latter case, you would to group by department and then by customer.

-LB
 
Ok sry..ok ok..My details pain is not just 1 row..it is displayed and spread out to 2 pages. It looks like 2 pages of a phone bill. I tried to put 2 pages of the bill on the page header but it will only fit as 1. Now..having 2 pages or details with fields all over the place..i need to create another details pane...or sub report with a list of call logs for that person i am viewing on the report. When i created the sub report it was displaying all calllog records for all groups..i need the subreport to only display the records on the current report i am looking at.

Thanks, PAUL

 
Paul

You are miking this very hard for people to understand your problem, please provide details as sked for by lb

If you are still having trouble please provide a visual of your report format as I suggested earlier--showing what it looks like now and then what you would like it to look like.

This would probably clarify things a little

Gary Parker
Systems Support Analyst
Manchester, England
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top