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

Excluding invoices that begin with certain characters

Status
Not open for further replies.
Dec 27, 2002
167
US
I have invoices that begin with 'RI-' that I wish to exclude from the report.

I go into Record Section Formula Editor and enter
{Invoice_ID} <> ??????

What do I enter so it exludes these??
 
hi
click on the select expert and choose your field {Invoice_ID} and from the selection drop list select not one of &quot;RI&quot;

cheers

pgtek
 
I solved it...

It was
not ({INVOICE_ID} like &quot;RI-*&quot;)
 
That's very inefficient.

Try:

Create a SQL Expression.

// %First3chars
substring((SQL SERVER) ,1,3)

Now in your record selection:

{%First3chars} <> &quot;RI-&quot;

Likes are very inefficient, and should be avoided. The above offloads all of the work to the database.

Consider posting version information in the future, as in Crystal and database.

-k
 
Thats very good feedback on the use of the Like clause.
Handy to know.

Cheers
Fred
 
Synapsevampire, is it more efficient to define the truncated value as an SQL expression rather than a formual field? Or are these just two methods of getting the same result?

Madawc Williams
East Anglia, Great Britain
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top