G
Guest
I'm working with an Access database and one of the fields contain codes like
this:
A03AA01
A03AB01
and so on
I would like to make a query where I select all records that contain A03A
So I write:
Like "A03A*"
But I get no records despite the fact that there are several records which
fits this template.
If I write:
Like "A03*"
I get the ones listed above
Also if I write
Like "A03AA*"
will I get the first ones.
The rule seems to be that if using * as a wildcard it only works if:
1. * represents a number after a letter (A03AA* = A03AA01)
2. * represents a letter after a number (A03* = A03AA01)
Now to the extra weird part:
Some of the entries work just fine with wildcard.
And it gets weirder:
If I take an original list of all the different possible values of this
field and link to the aforementioned field Access links all posts and has no
problems recognizing that A03AA01 in one table is equal to A03AA01 in another
table.
Now for the superweird part.
Wildcards works fine if I use it in the original list.
So this means that A03AA01 can't be identified in one table by A03A*
But in another table, which contains elements that (according to Access) are
EQUAL to A03AA01, A03AA01 can easily be identified by the wildcard A03A*.
I can of course solve the problem simply by linking the original list to the
field and make the query on the field in the original list instead of on the
field that behaves strangely. But it would be nice to understand the problem.
Both the original list and the problematic table have been exported to Excel
and later reimported into Access. I assume that some problems have arisen
there but I can't find anything that seperates those two fields that
apparently are equal but behaves differently to wildcards.
Any suggestions are welcome
this:
A03AA01
A03AB01
and so on
I would like to make a query where I select all records that contain A03A
So I write:
Like "A03A*"
But I get no records despite the fact that there are several records which
fits this template.
If I write:
Like "A03*"
I get the ones listed above
Also if I write
Like "A03AA*"
will I get the first ones.
The rule seems to be that if using * as a wildcard it only works if:
1. * represents a number after a letter (A03AA* = A03AA01)
2. * represents a letter after a number (A03* = A03AA01)
Now to the extra weird part:
Some of the entries work just fine with wildcard.
And it gets weirder:
If I take an original list of all the different possible values of this
field and link to the aforementioned field Access links all posts and has no
problems recognizing that A03AA01 in one table is equal to A03AA01 in another
table.
Now for the superweird part.
Wildcards works fine if I use it in the original list.
So this means that A03AA01 can't be identified in one table by A03A*
But in another table, which contains elements that (according to Access) are
EQUAL to A03AA01, A03AA01 can easily be identified by the wildcard A03A*.
I can of course solve the problem simply by linking the original list to the
field and make the query on the field in the original list instead of on the
field that behaves strangely. But it would be nice to understand the problem.
Both the original list and the problematic table have been exported to Excel
and later reimported into Access. I assume that some problems have arisen
there but I can't find anything that seperates those two fields that
apparently are equal but behaves differently to wildcards.
Any suggestions are welcome