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

Crystal Report + Data Recurssion 1

Status
Not open for further replies.

HomeAway

Programmer
Jun 6, 2003
36
AE
Hi Experts,

Ill get straight to the point, i have a database structure that manages a tree like structure in a VB tree control.
Example:
StructureID ParentID Descrption
7 -3 (root) Bridge Scheme
12 7 Bridge 108
15 12 North Support
16 12 South Support
8 -3 (root) Dam Scheme
21 8 Dam Wall
22 21 Dam Wall Top

What this equates to is the following.
- Bridge Scheme
|-- Bridge 108
|-- North Support
|-- South Support
- Dam Scheme
|-- Dam Wall
|-- Dam Wall Top


I need some way of displaying this in crystal reports 8.5
i thought of a main report grouping all structure where parentid = -3 (thus only showing the root structures) and displaying the strucure ID.

---------------------------------------------------
Parent ID Structure ID
eg: -3 7 -- Bridge Scheme
{Sub report}
8 -- Damn Scheme
{Sub report}
--------------------------------------------------

Then having a sub report showing all sub items where the structure ID = structure ID (group) from the main report.

---------------------------------------------------
Parent ID Structure ID
eg: -3 7 -- Bridge Scheme
Structure ID ParentID
12 -- Bridge 108
15 -- North ...
8 -- Damn Scheme
etc.
---------------------------------------------------

Any ideas on how to do this would be soooo appreciated, even a few ideas on what to use, namely, running totals or shared variables.
 
Check out the "Heirarchical Grouping" option and see if this helps.

Ken Hamady, On-site Custom Crystal Reports Training & Consulting
Public classes and individual training.
Expert's Guide to Formulas / Guide to Crystal in VB
- tek@kenhamady.com
 
Kenhamady,

Thanks for the help. surprisingly with a few formulas and tweaks it looked even better than i thought.

Is there anyway to add increment margines through formulas ?


 
Not sure what you mean.

Ken Hamady, On-site Custom Crystal Reports Training & Consulting
Public classes and individual training.
Expert's Guide to Formulas / Guide to Crystal in VB
- tek@kenhamady.com
 
sorry, its friday afternoon and the brain is hardly working. lol.
i would like the increase the increment on a section based on the value it writes.
ie. if while writing my records and the previous groups values was say "X" then dont increment however, if the value was "Y" then do.

a sort of
whileprintingrecords;
if "VALUE" = 'X' then True else false .. and have this formulae in the new page before section.
 
HomeAway

Would you start a new question for this? I am not sure what you are trying to increment, but maybe someone else will be able to help.

Ken Hamady, On-site Custom Crystal Reports Training & Consulting
Public classes and individual training.
Expert's Guide to Formulas / Guide to Crystal in VB
- tek@kenhamady.com
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top