Print Page | Close Window

Filtering strings on the ends

Printed From: Crystal Reports Book
Category: Crystal Reports 9 through 2020
Forum Name: Report Design
Forum Discription: The best way to design a report and problems you have encountered
URL: http://www.crystalreportsbook.com/forum/forum_posts.asp?TID=15381
Printed Date: 30 Apr 2024 at 7:50am


Topic: Filtering strings on the ends
Posted By: acidraine
Subject: Filtering strings on the ends
Date Posted: 16 Jan 2012 at 7:07am
New to the forum, so go easy on me for this question; as I've tried looking around to the best of my ability.
 
In my report I have an invoice number field that is in string format. I'm looking to filter out all of these invoice numbers that do not end in 0. The logic I found below I used got rid of most of them, but there are some that are still showing up and I have no clue why:
 
if {INVOICE_NUM}[len({INVOICE_NUM})-1] = "0" then {INVOICE_NUM}
 
I would appreciate any help coming my way.



Replies:
Posted By: FrnhtGLI
Date Posted: 16 Jan 2012 at 9:18am
You could put this into Report>Selection Formulas>Record:

right({inovice_num},1)='0'


-------------
|< /\ '][' ( )


Posted By: acidraine
Date Posted: 16 Jan 2012 at 9:38am
Works perfectly. Thanks so much for the assistance!



Print Page | Close Window