Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm running ArcMap 10.1.

I have a point feature class joined to a table and am trying to query a field.

If I do [field] = 'TEST', it selects all the fields.

But if I do [field] LIKE 'TES%', it doesn't work.

Any idea why the LIKE command isn't working?

share|improve this question
Double quotes are for field names and single quotes are for field values, as far as I know. Maybe that's the issue? – Martin Jun 10 '13 at 14:06
Sorry, it is only single quotes. – ianbroad Jun 10 '13 at 14:14
up vote 5 down vote accepted

The wildcard to use with LIKE depends on the data source.

You are using square brackets as field name delimiters. So I suppose you are using a Personal Geodatabase.

The wildcards you have to use to query a personal geodatabases are asterisk (*) for any number of characters and question mark (?) for one character.

If you use SDE or file based geodatabase you have to use percent symbol (%) and underscore (_).

share|improve this answer
You are awesome! Thanks. For some reason I never knew you had to use an asterisk for personal geodatabases. – ianbroad Jun 10 '13 at 14:27
With a personal geodatabase you have to use the same syntax as Microsoft Access (* and ?). – Jens Jun 10 '13 at 14:29
here's a little tip - on the Select By Attributes dialog, at the lower left, there is a button which changes to show the relevant wildcard character for each dataset. It shows * or % depending on the chosen layer type. – Stephen Lead Jun 11 '13 at 8:41

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.