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 THROUGH ALL OCCURANCES IN FIELD

Status
Not open for further replies.

SusanStoHelit

Technical User
Jan 26, 2006
15
US
We are using crystal XI on an Oracle database. We have a certain 14-digit number that can show up anywhere from 0-20 times in a field, always after the words "Order Number: ".

I need a way to loop through all occurences of "Order Number: " to pull those numbers out.

Thanks!
 
stringvar array x := split({table.string}, "Order Number: ");
numbervar i;
numbervar j := ubound(x);
stringvar y;

for i := 2 to j do(
y := y + left(x,14)+ ", "
);
y

-LB
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top