Technical Questions
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Technical Questions
Message Icon Topic: summary help Post Reply Post New Topic
Page  of 2 Next >>
Author Message
dykstsam
Newbie
Newbie


Joined: 16 Jun 2009
Location: United States
Online Status: Offline
Posts: 11
Quote dykstsam Replybullet Topic: summary help
     Posted: 10 Aug 2009 at 8:29am
Hello
OK My problem is when i create a report my summary fields are double or more what they should be?

I use a lot of census data, in my reports and am trying to build a report out with two files my problem is when I insert a summary to say get the total population the summary is double or quadruple of what the number should be I hope someone can help me with this.
Thanks
Sam
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 10 Aug 2009 at 8:31am
Are you joining tables? IF so are you getting multiple rows from those joins? Chances are that is what is causing the increase in the NUmbers
IP IP Logged
dykstsam
Newbie
Newbie


Joined: 16 Jun 2009
Location: United States
Online Status: Offline
Posts: 11
Quote dykstsam Replybullet Posted: 10 Aug 2009 at 8:51am
I think that might be it.  Is there a way to remove the join between the tables

Edited by dykstsam - 10 Aug 2009 at 8:54am
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 10 Aug 2009 at 8:54am
Probably not.
You can use Running Totals (or variable formuals) to count or Sum items without using the dupe records.
If you need help with those post some sample data and what you need it to do and we can assist with those.
IP IP Logged
dykstsam
Newbie
Newbie


Joined: 16 Jun 2009
Location: United States
Online Status: Offline
Posts: 11
Quote dykstsam Replybullet Posted: 10 Aug 2009 at 9:31am
My problem is  I am working with population data so some there might be some duplicate records. If you can picture it I am using two different geographical area's so the to tables don't relate to each other

Here is a example of what crystal reports give me. (There are other fields like geography ID and others.)
Unique ID Total(from first Table), Population(from first table), Total Children(from Second Table)
1                                                     150                                        73            
1                                                     150                                        54
1                                                     150                                        42
2                                                     121                                        73
2                                                     121                                        54
2                                                     121                                        42

What I want is just
1                                                     150                                        0
2                                                     121                                        0
                                                           0                                        73
                                                           0                                        54
                                                           0                                        42
  Hope this helps and thanks for all the support you have provided
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 10 Aug 2009 at 9:52am
In your sample data there seems to be something wrong on your join with the total children (second table). It looks as if there is no join at all. What do you have that set up as in the DB Expert?
If you can clean that up I think you can get what you need.
IP IP Logged
dykstsam
Newbie
Newbie


Joined: 16 Jun 2009
Location: United States
Online Status: Offline
Posts: 11
Quote dykstsam Replybullet Posted: 10 Aug 2009 at 10:53am
I pretty new to crystal reports so I don't know if this is possible. Can I get it so I have no link between the to tables at all so its like two different reports in one. 
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 10 Aug 2009 at 11:10am

No - it will go completely wonky if you try that.

You can do a subreport with the second table.
However, let's evaluate it a bit more...
Can you explain why in your sample you want the "children values" (73, 54 and 42) to only appear as if they are a not attached to any value from table 1.
And what is UniqueID (column 1) representing...maybe a country? SHouldn't there be "children values" for each of these?


Edited by DBlank - 10 Aug 2009 at 11:11am
IP IP Logged
dykstsam
Newbie
Newbie


Joined: 16 Jun 2009
Location: United States
Online Status: Offline
Posts: 11
Quote dykstsam Replybullet Posted: 10 Aug 2009 at 11:39am
I really apprecate all the help and would love to slove this problem so thanks for all the help so far and in the future.

OK the Unique ID is a number that in each table starts at 1 and goes for each row there is so there is no connection between the tables on that number. For the Children value its not exactly that but a more detailed on poverty numbers and there housing situation i thought I would make it a bit easier to understand so I'm sorry if that made it worse.
I will try and explain it that most of my data is really detailed in that I can get it by the block level(like a city Block) while other data I can only get in a less geographically detailed it goes by  Block Group(A grouping of Blocks). So if you can picture say I only need the data on only 3 blocks but 2 of those blocks are in one block group made up of 7 blocks and the other block is in a second block group made up of 4 blocks. So I want the most detailed and accurate data I can get, but some data I can only get on the block group so I have to take the extra area for those data sets.

Hope this helps clear it up it might not I know what I am doing and I thought my explanation was confusing so thanks again
Sam
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 10 Aug 2009 at 12:06pm
OK. My head is spinning a bit...I got the ID as a PK counter and is useless for joins but the rest I need to visualize better.
Do you only have 2 tables you are dealing with? How are these "Blocks" defined in the data... Are they all in one table or does each group level have a different table?...If the are in different tables how are you joing them.
Sory , but I just can't seem to "see" the data structure and need that to give you some direction.
IP IP Logged
Page  of 2 Next >>
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum