Parse data in table using query with space as delimiter.

T

TerryD

I have created Kanban cards with the part number and card number in the
barcode. I need to break down the data without going to excel and reloading
back to access. I used a space in the format to accomplish this. Problem is
the part numbers are alpha numeric and different lenghts which don't allow me
to break down the beginning, mid, and ending. I need to be able to break down
like excel does in text to columns.
 
D

Duane Hookom

It might have helped if you had posted some sample values as well as field
names. However, you can use the Instr() function to find the first occurance
of a space. Combine this with Left() and Mid() to parse the two values.

Left([SomeField],Instr([SomeField]," ")-1)
Mid([SomeField],Instr([SomeField]," ")+1)
 
T

TerryD

Thanks very much!!!!

Duane Hookom said:
It might have helped if you had posted some sample values as well as field
names. However, you can use the Instr() function to find the first occurance
of a space. Combine this with Left() and Mid() to parse the two values.

Left([SomeField],Instr([SomeField]," ")-1)
Mid([SomeField],Instr([SomeField]," ")+1)


--
Duane Hookom
MS Access MVP

TerryD said:
I have created Kanban cards with the part number and card number in the
barcode. I need to break down the data without going to excel and
reloading
back to access. I used a space in the format to accomplish this. Problem
is
the part numbers are alpha numeric and different lenghts which don't allow
me
to break down the beginning, mid, and ending. I need to be able to break
down
like excel does in text to columns.
 
T

TerryD

Thanks very much!! This was helpful to get my project completed. It's hard to
read or get the right data strings when you don't program and the help
question asked points in so many directions.

Duane Hookom said:
It might have helped if you had posted some sample values as well as field
names. However, you can use the Instr() function to find the first occurance
of a space. Combine this with Left() and Mid() to parse the two values.

Left([SomeField],Instr([SomeField]," ")-1)
Mid([SomeField],Instr([SomeField]," ")+1)


--
Duane Hookom
MS Access MVP

TerryD said:
I have created Kanban cards with the part number and card number in the
barcode. I need to break down the data without going to excel and
reloading
back to access. I used a space in the format to accomplish this. Problem
is
the part numbers are alpha numeric and different lenghts which don't allow
me
to break down the beginning, mid, and ending. I need to be able to break
down
like excel does in text to columns.
 

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