A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Running & Setting Up Queries
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Filtering for fields with character



 
 
Thread Tools Display Modes
  #1  
Old May 15th, 2010, 03:00 PM posted to microsoft.public.access.queries
Louis[_8_]
external usenet poster
 
Posts: 1
Default Filtering for fields with character

How can I filter for results that contain the charcter "(" ?

For example if my fields a

A(2001)
B(2004)
C
D(2055)
E(2006)

I would like to display results that contain parentheses brackets.

I try filtering using the wildcard *(* but it does not work.
  #2  
Old May 15th, 2010, 06:28 PM posted to microsoft.public.access.queries
John W. Vinson
external usenet poster
 
Posts: 18,261
Default Filtering for fields with character

On Sat, 15 May 2010 07:00:28 -0700 (PDT), Louis
wrote:

How can I filter for results that contain the charcter "(" ?

For example if my fields a

A(2001)
B(2004)
C
D(2055)
E(2006)

I would like to display results that contain parentheses brackets.

I try filtering using the wildcard *(* but it does not work.


Try

LIKE "*(*"

Wildcards only work with the LIKE operator; if you just put

*(*

on the criteria line it will search for that exact sequence of three
characters.

If you want to search *for a wildcard character* without having it treated as
a wildcard, enclose it in square brackets:

LIKE "*[#]*"

will search for the # character, rather than treating it as a numeric digit
wildcard.
--

John W. Vinson [MVP]
 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 08:47 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.