Extracting parts of a fraction into separate columns

Hello,

I have the following data in a spreadsheet:

A B C
1 fraction Part A Part B
2 1/64 1 64
3 5/64 5 64
4 7/64 7 64
5 1/8 8
6 11/64 1 64
7 13/64 1 64
8 1/4 4
9 17/64 1 64

formula in col B: =LEFT(A2,LEN(A2)-(SEARCH("/",A2))-1) etc.

formula in col C: =RIGHT(A2,LEN(A2)-SEARCH("/",A2)) etc.

As you can see the formula works properly on the data in the cols B2-B4.

It does not work properly in the cols B5-B9.

The formula in column C work fine from start to end.

I have no explanation why this is working this way.

Does anyone know the reason>

Any help is much appreciated.

Using Libreoffice 6.4.7.2 on Linux Mint

=LEFT(A2; (SEARCH("/";A2)-1))
1 Like

Please note that although the other answers do work, they do not answer why your formulas for left didn’t work, except for the one from @sokol92 - your formula only counted characters to the right of the separator, and used one less number of characters for the left part, regardless of what was actually there.

1 Like

Try regex
fraction-parts (1).ods (13.9 KB)

Снимок экрана от 2022-07-24 21-46-12

Снимок экрана от 2022-07-24 21-49-35

Fantastic, it works.
Nice solution
Thanks

Hallo

=LEFT(A2;FIND("/";A2)-1)
=MID(A2;FIND("/";A2)+1;99)

Nice solution, Thanks