If you have data like this in [Projects Sched]
04730611X;0486q61;0535b51;0537c61;
you should be able to extract and test the first "subfield" using
something like this. The (0) specifies the first item from the array
returned by Split():
... OR (Split(Sheet1.[Projects Sched], ";")(0)
LIKE "*06#*[-a-zA-Z][1-6]1")
which will be true if the first subfield begins with any character, then
three digits beginning with 06, then any other character, then a letter
or hyphen, then a number from 1 to 6 and finally the number 1.
Problem is when I added the split function to our where for the query,
query
said split is unknown.
Following it the first part of the where of the docmd.openreport ...
"(((Sheet1.[Alternate Street]) Is Null)And ((Sheet1.[MEM#]) < 700)And
((Sheet1.[projects sched]) Is Null Or Not ((Sheet1.[projects sched]) Like
"*06#*[-a-zA-Z][1-6]1;*"Or (Sheet1.[proj" ...
What we did was change the 'Sheet1.[projects sched]' to
'split(Sheet1.[projects sched],';',-1)'
and that produced the split not found or something like that
Spent a lot of time trying lots of things but no banana :-(. Any help
would
be appreciated. TIA
John Nurick said:
See help for the Split function.
Ok thanks I spent a lot of time looking for that info. Now I have a problem:
We have this text line: 04730611X;0486q61;0535b51;0537c61;
All of the fields are ended with a ; Therefore there are 4 fields
above.
Our 'like' criteria is: *06#*[a-z]#1;*
Unfortunately that criteria spans the first 2 fields :-(.
We would like to end @ the first ; not end @ the second ; Got any
ideas?
Try Looking up Wildcard in the online help.
* = any number of characters (including zero characters)
?= any single character
# = any number character
! = Not and is used in conjuction with the square brackets [] "A[!a-e]*"
would be Starts with A and second character not in the range A to e, and
followed by zero or more characters.
Have been trying to find what characters mean in a 'like' query.
See
that
[0-9] means numeric characters 0 thru 9. So what does *, # ...
mean. I
have been unable to find those definitions anywhere in access help :-(.
Where are they defined? TIA