I’m trying to come up two formulas that can extract characters from the middle of a string of text of varying lengths. Here is an example-
A1: 1234 309 Embankment Cu. Yds. 217
B1: 4567 587 12" Conduit, Type B, As Per Plan Lin. Ft. 14
C1: 4321 5432 Pull Box Adjusted to Grade - Contingency Ea. 1
D1: 7654 Spec. Power Distribution Cabinet, Complete (Item 4894) Lump Sum 1
My goal:
[TABLE="class: grid, width: 600, align: left"]
<tbody>[TR]
[TD="align: center"]ID[/TD]
[TD="align: center"]ITEM[/TD]
[TD="align: center"]DESCRIPTION[/TD]
[TD="align: center"]UNIT[/TD]
[TD="align: center"]QTY[/TD]
[/TR]
[TR]
[TD]1234[/TD]
[TD]309[/TD]
[TD]Embankment[/TD]
[TD]Cu. Yds.[/TD]
[TD]217[/TD]
[/TR]
[TR]
[TD]4567[/TD]
[TD]589[/TD]
[TD]12” Conduit, Type B, As Per Plan[/TD]
[TD]Lin. Ft.[/TD]
[TD]14[/TD]
[/TR]
[TR]
[TD]4321[/TD]
[TD]5432[/TD]
[TD]Pull Box Adjusted to Grade – Contingency[/TD]
[TD]Ea.[/TD]
[TD]1[/TD]
[/TR]
[TR]
[TD]7654[/TD]
[TD]Spec.[/TD]
[TD]Power Distribution Cabinet, Complete (Item 4894)[/TD]
[TD]Lump Sum[/TD]
[TD]1[/TD]
[/TR]
</tbody>[/TABLE]
I would like to formulate the Description and Unit columns. I’ve already have formulas set up for ID, ITEM, and QTY using =LEFT, =MID, and =TRIM/RIGHT/SUBSTITUTE/REPT formulas respectively.
Here is what I’ve noticed with the dataset:
ID is consistently four digits
ITEM varies in length but always has one set of characters surrounded by a space on each side
DESCRIPTION varies in length and in character usage
UNIT while different these are consistent in use
QTY numbers vary in length but always have one set of characters surrounded by a space on each side
Is this possible without VBA? Thank you in advance.
A1: 1234 309 Embankment Cu. Yds. 217
B1: 4567 587 12" Conduit, Type B, As Per Plan Lin. Ft. 14
C1: 4321 5432 Pull Box Adjusted to Grade - Contingency Ea. 1
D1: 7654 Spec. Power Distribution Cabinet, Complete (Item 4894) Lump Sum 1
My goal:
[TABLE="class: grid, width: 600, align: left"]
<tbody>[TR]
[TD="align: center"]ID[/TD]
[TD="align: center"]ITEM[/TD]
[TD="align: center"]DESCRIPTION[/TD]
[TD="align: center"]UNIT[/TD]
[TD="align: center"]QTY[/TD]
[/TR]
[TR]
[TD]1234[/TD]
[TD]309[/TD]
[TD]Embankment[/TD]
[TD]Cu. Yds.[/TD]
[TD]217[/TD]
[/TR]
[TR]
[TD]4567[/TD]
[TD]589[/TD]
[TD]12” Conduit, Type B, As Per Plan[/TD]
[TD]Lin. Ft.[/TD]
[TD]14[/TD]
[/TR]
[TR]
[TD]4321[/TD]
[TD]5432[/TD]
[TD]Pull Box Adjusted to Grade – Contingency[/TD]
[TD]Ea.[/TD]
[TD]1[/TD]
[/TR]
[TR]
[TD]7654[/TD]
[TD]Spec.[/TD]
[TD]Power Distribution Cabinet, Complete (Item 4894)[/TD]
[TD]Lump Sum[/TD]
[TD]1[/TD]
[/TR]
</tbody>[/TABLE]
I would like to formulate the Description and Unit columns. I’ve already have formulas set up for ID, ITEM, and QTY using =LEFT, =MID, and =TRIM/RIGHT/SUBSTITUTE/REPT formulas respectively.
Here is what I’ve noticed with the dataset:
ID is consistently four digits
ITEM varies in length but always has one set of characters surrounded by a space on each side
DESCRIPTION varies in length and in character usage
UNIT while different these are consistent in use
QTY numbers vary in length but always have one set of characters surrounded by a space on each side
Is this possible without VBA? Thank you in advance.