×
INTELLIGENT WORK FORUMS
FOR COMPUTER PROFESSIONALS

Contact US

Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

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

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

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

(OP)
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

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

see the answer in the general forum.

Ken Hamady
http://www.kenhamady.com/
Crystal Reports Training/Consulting and a
Quick Reference Guide to VB/Crystal (including ADO)

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

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
www.pacificridgesolutions.com

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

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']

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

Hi Darwin,
you may also find little used functions called:- "lookslike" and "soundslike" in the additional functions!

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

(OP)
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...  

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members! Already a Member? Login

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close