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!

does CR have a "like" or "in" function like SQL does?

Status
Not open for further replies.

darwin101

Programmer
Mar 7, 2001
156
US
i am looking for a method to compare the numeric value of a column to a list of known numbers. Does CR have something similar to oracle's sql (the "IN" or "LIKE")
such as

If (column) in ('1234','2345','3456') then
"bob's your uncle"
elseif (column) in ('9876','8765','7845') then
"bob's your aunt"
else
nothing

Thanks :)
 
Hello

Yes, you can use either the like or the in operators in Crysal reports. Look up In Array Operator, In Range Operator, and in String Operator. for the like, use the search to locate the Like operator. Crystal Help on these two are quite good.

Hope this helps.
E. McEvoy
Crystal Reports Consultant
 
I have found that you can use the IN statement with Crystal reports. The trick is that you need to enclose the qualifiers in square brackets. I.E.
{PO_Custom_TextSmall1.potxt_Small02} IN ['Closed','Active']
 
Hi Darwin,
you may also find little used functions called:- "lookslike" and "soundslike" in the additional functions!
 
Thanks All! i have never seen lookslike or soundslike.. now i know.. ver 6.0 has soundex but not soundslike. i think we are upgrading this summer :)
3 months ago i knew next to nothing about CR, yesterday i completed a report with 80+ needed formulas.. but still have a great deal to learn...
Thanks again... B-)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top