Brian Dunning's FileMaker Custom Functions

IsUUID ( text )

Checks if a text string is in UUID format, e.g. generated by Get(UUID).

  Average rating: 4.3 (31 votes) Log in to vote

John Hanson   John Hanson
Pulp Studio
http://www.pulpstudio.com

Share on Facebook Share on Twitter

  Sample input:
IsUUID ( "random text" )
IsUUID ( "37EEAC77-E584-8642-A026-5BA61C66DDB1" )
IsUUID ( "" )
  Sample output:
0
1
0

  Function definition: (Copy & paste into FileMaker's Edit Custom Function window)

Returns a Boolean result of True if the text string matches a UUID generated by Get(UUID). Useful for validating UUID-based ID fields with direct data entry, e.g. with drop-down lists for type-ahead lookups.

Credit to Daryl Eisner for additional hex filtering.

 

Comments

Daryl Eisner   Daryl Eisner, San Diego
Oct 15, 2014
Very nice and simple. Like it.
Maybe add this to the end of the function:

"and Length ( filter ( Lower ( text ) ; "abcdef0123456789-" ) ) = 36"
 

Log in to post comments.

 

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

Under construction. Email me your wish list for improvements.