Record Selection

D

Dmario

I am working with a part number that is 10-11 alpha numeric characters. I
need to focus on the 8th character which represents the color of the item and
make a selection as to the color.

I started looking at the "Like" function, but couldn't figure out how to
have it look at the 8th character only.

I am using Access 2000.

Any help would be appreciated.
 
F

fredg

I am working with a part number that is 10-11 alpha numeric characters. I
need to focus on the 8th character which represents the color of the item and
make a selection as to the color.

I started looking at the "Like" function, but couldn't figure out how to
have it look at the 8th character only.

I am using Access 2000.

Any help would be appreciated.

ColorChar:InStr([PartNumber],8)

will return the 8th character.
 
J

John W. Vinson

I am working with a part number that is 10-11 alpha numeric characters. I
need to focus on the 8th character which represents the color of the item and
make a selection as to the color.

I started looking at the "Like" function, but couldn't figure out how to
have it look at the 8th character only.

I am using Access 2000.

Any help would be appreciated.


A couple of ways.

Mid([partnumber], 8, 1)

will return the 8th character from the string; or you can in fact use Like:

LIKE "???????" & [Enter color code:] & "*"

will prompt for a one-character color and find records containing that value
as the 8th byte.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top