Software Venture Consulting

FileMaker Pro downloads & Resources
FileMaker Custom Functions
FileMaker Web Viewer Examples
FileMaker Pro & Lasso Consulting
Training
FileMaker Books
FileMaker Articles
FileMaker Error Reference

Free Web Tools
Free FileMaker Tools

Personal Pages
Videos
Adventures
Links

Shopping Cart
Shopping Cart

Search:

Free Newsletter
Signup


Contact


Privacy Policy



FileMaker is a registered trademark of FileMaker, Inc. in the U.S. and other countries.

 

 FileMaker Pro Custom Functions

List  |  Show Random  |  Upload  |  Add This to Your Site

FilterPartialValues ( values ; string )

Rate this function:  

RatingRatingRatingRatingRating
  Average rating: 4.1  (21 votes)
  Discuss this Custom Function

Richard Dyce, Dyce & Sons
http://dyce.com

Exclude values that contain string.

Sample Input:
FilterPartialValues ( "Item List¶item_scripting¶User List¶user_scripting¶Prefs" ; "_scripting" )
Sample Output:
item_scripting
user_scripting


 Then copy & paste into FileMaker Advanced's Edit Custom Function window.

Click here to copy To Clip Manager if you have myFMbutler's Clip Manager installed

Description:

This is simply convenience function, used to search for 'scripting' layouts.
Updated to avoid adding a trailing return

Note: these functions are not guaranteed or supported by BrianDunning.com. Please contact the individual developer with any questions or problems.

This is my Custom Function and I want to edit it

Discuss:

5 most recent comments | Show all 7 comments

Agnès, where exactly are you adding Upper for case-insensitive? Or is that an exercise for the student? ;-)

Richard, Zuchwil
April 26, 2016 7:35am

Agnès, ahem, sorry, but I'm not sure that the non-recursive works for all the same cases:

Assuming your version is implemented (and I haven't screwed up the implementation):

// FilterPartialValues_NR ( values ; string )

// FilterPartialValues_NR ( values ; string )

Let (
[
R = "#" & Substitute ( values ; [ ¶ ; "¶#" ] ; [ string ; string & ¶ & string ] ) ;
Fb = Substitute (
R ;
[ ¶ ; "#¶"] ;
[ string & "#" ; string ]
) & "#"
];

Substitute (
FilterValues ( R ; Fb ) & "[end]" ;
[ "#¶" ; "" ] ;
[ "¶[end]" ; "" ] ;
[ "#" ; "" ] ;
[ string & "¶" & string ; string ]
)
)


Then,

FilterPartial_NR ( "Item List¶item_scripting¶User List¶user_scripting¶Prefs" ; "script" )

returns:

"item_script¶user_script"

Whereas, the original version:

FilterPartialValues ( "Item List¶item_scripting¶User List¶user_scripting¶Prefs" ; "script" )

returns:

"item_scripting¶user_scripting"

:-(

Richard, Zuchwil
April 26, 2016 8:05am

Oh sorry, I'ts an old calc, and I removed that line, I do not know why she was there...
D = FilterValues ( R ; Substitute ( R ; "#" ; "" ) ) without checking calc !

donc :

Let ([

L = "Item List¶Item_scripting¶User List¶user_scripting¶Prefs" ;
Keep = "_scr" ;

R = "#" & Substitute ( L ; [ ¶ ; "¶#" ] ; [ Keep ; Keep & ¶ & Keep ] ) ;
Fb = Substitute ( R ; [ ¶ ; "#¶"] ; [ Keep & "#" ; Keep ] ) & "#" ;
D = FilterValues ( R ; Substitute ( R ; "#" ; "" ) )
];
Substitute ( FilterValues ( R ; Fb & ¶ & D ) & "[NoValue]" ; [ "#¶" ; "" ] ; [ "¶[NoValue]" ; "" ] ; [ "#" ; "" ] ; [ Keep & "¶" & Keep ; Keep ] /* ; [ "[NoValue]" ; "" ] */ )

it's ok

Agnès, France
April 26, 2016 8:45am

For Case no sensitive :

Let ([

L = "Item List¶Item_scripting¶User List¶user_scripting¶Prefs" ;
Keep = Upper ( "_Scr" ) ;

R = "#" & Substitute ( Upper ( L ) ; [ ¶ ; "¶#" ] ; [ Keep ; Keep & ¶ & Keep ] ) ;
Fb = Substitute ( R ; [ ¶ ; "#¶"] ; [ Keep & "#" ; Keep ] ) & "#" ;
D = FilterValues ( R ; Substitute ( R ; "#" ; "" ) ) ;
Result = Substitute ( FilterValues ( R ; Fb & ¶ & D ) ; [ "#¶" ; "" ] ; [ "#" ; "" ] ; [ Keep & "¶" & Keep ; Keep ] )

];
Substitute ( FilterValues ( L ; Result ) & "[NoValue]" ; [ "¶[NoValue]" ; "" ] )
)

but the calc is less pretty ;)

Agnès, France
April 26, 2016 9:02am

CF Description says "Exclude values that contain string."
Would a description such as "Search only values containing string" not be more appropriate ?

Eric, France
April 29, 2016 6:30am

Make a comment about this Custom Function (please try to keep it brief & to the point). Anyone can post:

Your Name:
City/Location:
Comment:
characters left. If you paste in more than 1500 characters, it will be truncated. Discuss the function - advertisements and other useless posts will be deleted.
Answer 6 + 7 =
Search for Custom Functions:

Custom Functions Widget
Download the Custom Function Dashboard Widget for OS X
Keep all the latest Custom Functions right at your fingertips!

Newest Custom Functions:

1. decFromHex ( hexValue )
  (Mon, Oct 16, 12:34pm)
2. MonthYearList ( startmonth ; startyear ; numbermonth ; short )
  (Mon, Oct 16, 3:38am)
3. ErrorDescription ( errorNumber )
  (Wed, Sep 27, 2:51am)
4. decodeEntities (text)
  (Wed, Sep 27, 1:22am)
5. HexidecimalToNumber ( HexidecimalValue ; counter )
  (Mon, Sep 25, 12:39pm)
6. FixedFieldConverter ( Fieldname ; f1 ; f2 ; f3 ; f4 ; f5 ; f6 ; f7 ; f8 ; f9 ; f10 ; f11 ; f12 ; f13 ; f14 ; f15 ; f16 ; f17 ; f18 ; f1
  (Fri, Sep 15, 12:34pm)
7. ShannonEntropy ( text )
  (Thu, Sep 07, 5:59am)
8. LetterCount ( text ; summary )
  (Thu, Sep 07, 5:53am)

RSS Feed of Custom Functions