• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1122
  • Last Modified:

LIKE operator in Crystal Reports

Hello,
Quick question: I am trying to use LIKE operator in my Operation field.
Operation - number value
So I want to Supress if Operation has value '9' in it.
I am using inside Format Editor --> Supress --> X2 box for Formula

thank you
0
Palmer_Admin
Asked:
Palmer_Admin
  • 2
  • 2
1 Solution
 
mlmccCommented:
You could try

{YourField} LIKE "*9*"

ANother way would be

InStr({YourField},"9") > 0

mlmcc
0
 
Palmer_AdminAuthor Commented:
Hello MLMCC,
I get this error when I use:
{YourField} LIKE "*9*" - a string is required here

if I use the other command I get this error:
Not enough arguments have been give

thanks

0
 
JayConverseCommented:
Sounds like you have a numeric field.  In that case,

ToText({yourfield}) like "*9*"

should do the trick
0
 
Palmer_AdminAuthor Commented:
JayConverse, is there a way to add exlude Operation "999"? the user came up to me and said that they want Operation "999"

thank you
0
 
mlmccCommented:
ToText({yourfield}) like "*9*"
AND
ToText({yourfield}) <> "999"

mlmcc

0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Cloud Class® Course: CompTIA Cloud+

The CompTIA Cloud+ Basic training course will teach you about cloud concepts and models, data storage, networking, and network infrastructure.

  • 2
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now