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

loop in Crystal 7

Status
Not open for further replies.

mwhalen

Programmer
Oct 31, 2000
217
CA
is there such a thing? I have multiple addresses in table A for each customer number. I need to go through all addresses for one customer and where address.field equals "flag" then pass the value.
 
You wouldn't use a loop for this. You would use a formula. something along the lines of :
If {address.field} = "flag" then value.



To answer your original question: Looping isn't available with Version 7. Mike

 
Thanks - I can't just say if address.field = flag then pass the value because it will only give me the first one it comes across. I have the potential of having multiple addresses in my address table for one customer id.
 
How is the relationship set up in your table?

One data record:
ID address1 address2
AAA 123 234
BBB abc cde

or as multiple records:
ID address
AAA 123
AAA 234
BBB abc
BBB cde

In either case you would have to use a formula to pass your value.
If it's all one data record:
if ({address1}= "test" or {address2}="test") then value

If it's multiple records, my first post applies.


Mike

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top