Genius123
asked on
Access 97 / 2010 query
Hello,
I have an Access 2010 query that grabs the value of 5 from this string: *22200108B5B99B1*. See the query in the attached file.
grabs-value-in-the-middle.accdb
I have two issues:
1- I need to have it grab the 99 value instead.
2- This doesn't work in Access 97.
Thanks,
Joel
I have an Access 2010 query that grabs the value of 5 from this string: *22200108B5B99B1*. See the query in the attached file.
grabs-value-in-the-middle.accdb
I have two issues:
1- I need to have it grab the 99 value instead.
2- This doesn't work in Access 97.
Thanks,
Joel
ASKER
In Access 97, I get the error "Undefined function 'InStrRev' in expression".
check in your references for "MISSING"
ASKER
Thank you. Also, sometimes the value might not be just two characters like 99. If it's 12345, it only grabs 45. Is there a way to grab 12345?
test this
grabs-value-in-the-middle.accdb
grabs-value-in-the-middle.accdb
The InStrRev() function was added AFTER A97 and so cannot be used in an .mdb indented to run under A97. If you need to run the app using A97, you will need to write your own custom user function to find the string you are looking for by searching from the right.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
That worked perfectly! Thank you very much!
You are welcome!
/gustav
/gustav
<2- This doesn't work in Access 97.>
try creating an .mdb file and create a local table , it should work
grabs-value-in-the-middle.accdb