Column with value of *, how to specify as criteria in query?

  • Thread starter Thread starter glen_esq
  • Start date Start date
G

glen_esq

Hello everyone.

Is there some way to search for the value of '*' in a column?

I have a sql server table linked in my access database which has a column
containing values of '*' and '?' , and 'C' And 'P'..

I need to create an access query that searches for the values of '*' and
a 2nd query that searches for value '?' in this column.

The problem I'm having is that * and ? are wildcard characters in access.
If I specify '*' in the search criteria in the query, all rows are
returned in the table - all values for the column including the values of
'C' and 'P'.... where all I want are the rows with a value of '*' for that
column.

Any help is appreciated.

Glen
 
Try placing the asterisk in square brackets.

--
Allen Browne - Microsoft MVP. Perth, Western Australia.

Reply to group, rather than allenbrowne at mvps dot org.


Hello everyone.

Is there some way to search for the value of '*' in a column?

I have a sql server table linked in my access database which has a column
containing values of '*' and '?' , and 'C' And 'P'..

I need to create an access query that searches for the values of '*' and a
2nd query that searches for value '?' in this column.

The problem I'm having is that * and ? are wildcard characters in access. If
I specify '*' in the search criteria in the query, all rows are returned in
the table - all values for the column including the values of 'C' and
'P'.... where all I want are the rows with a value of '*' for that column.

Any help is appreciated.

Glen
 
Make sure that you put an equal sign (=) in front of your criteria:

="*"

Otherwise it assumes LIKE

--
Lynn Trapp
MS Access MVP
www.ltcomputerdesigns.com
Access Security: www.ltcomputerdesigns.com/Security.htm




Hello everyone.

Is there some way to search for the value of '*' in a column?

I have a sql server table linked in my access database which has a column containing values of '*' and '?' , and 'C' And 'P'..

I need to create an access query that searches for the values of '*' and a 2nd query that searches for value '?' in this column.

The problem I'm having is that * and ? are wildcard characters in access. If I specify '*' in the search criteria in the query, all rows are returned in the table - all values for the column including the values of 'C' and 'P'.... where all I want are the rows with a value of '*' for that column.

Any help is appreciated.

Glen
 
Back
Top