Skip to main content
Announcements
Global Transformation Awards! Applications are now open. Submit Entry
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

LIKE operator

Hi


I am trying to use the LIKE operator in an IF() statement to match up two Field values:

=if(ImageName LIKE PhotoLookup&'*',ImageName,'')


However; on several occasions there is more than one value LIKE another.

PhotoLookup value: DA BLOFIELD


ImageName value(s):

                                   DA BLOFIELD.JPG

                                   DA BLOFIELD 3456.JPG


Is there a way to automatically pick the first value?



Thanks

Oli


5 Replies
jonathandienst
Partner - Champion III
Partner - Champion III

Hi

I think you need:

=if(ImageName LIKE '$(=PhotoLookup)*', ImageName, '')

HTH

Jonathan

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
Not applicable
Author

Hi Jonathan

Thank you for your reply.

I may not have made myself very clear?  What I have works to produce matching values.  Unfortunately, the majority of results result more than one value in the ImageName field.

I would like to just return the first of the multiple matches...?

Is that possible and if so how?

Thanks

Oli

Not applicable
Author

Hi,

Try using wildmatch.

Regards,

Nitesh

Not applicable
Author

Hi,

LIKE function can works like this.

=if([FirstField] LIKE PhotoLookup &'*',[SecondField],'')

there are replace the any conditional string from FirstField instead of '*' .

rubenmarin

Hi Oli, you can use the MinString function to retrieve the first alphabetically sorted value:

=if(ImageName LIKE PhotoLookup&'*',MinString(ImageName),'')