Page 1 of 1

Separate last word?

PostPosted: Thu Jan 10, 2019 6:36 pm
by dawidek990
Hello, I have a question, is it possible to do something that when broken into columns will separate only last word? from last space?
or some formula for this?
Example: APENINO ANTRACYT LAPPATO 29.7X59.7
separates only 29,7X59,7

greetings ;]

Re: Separate last word?

PostPosted: Thu Jan 10, 2019 7:11 pm
by Lupp
Text to Columns can only do that if the last separator is unique.
Assuming your
Code: Select all   Expand viewCollapse view
APENINO ANTRACYT LAPPATO 29.7X59.7
is placed in A1, the formula
Code: Select all   Expand viewCollapse view
=MID(A1; SEARCH("[^ ]*$"; A1);65535)
should return what you want if the option to use regular expressions with the respecive functions is enabled. Regard the space behind the circonflex in "[^ ]*$".

By the way: You will never get happy with these compounds. Split them once and for all.
Currently you are working with "data" that are none in a strict sense, at leas not in a sense workable with spreadsheets, and alo not the database way.
The items, let me call them products, obviously have a property concerning an impression of the surface we might call color. In most cases this property is represented by a name in the second position - but sometimes there is another word of unclear role (and the coloris shifted to the right). Is it an apposition to the primary name? Is it placed for a property not always applicable? What is it? Then there are a few products not qualified by any name but having the color in the first place. Then ... It's simply a mess. Calc has limited abilities to process data. To process a mess with a computer you need "Artificial Intelligence" if such a thing exists and is superior to natural intelligence. Conceding that someone must have messed up things that way, however, we cannot feel sure that natural intelligence exists.

Re: Separate last word?

PostPosted: Sat Jan 12, 2019 11:46 pm
by dawidek990
is working.... but what can I do to separate one or two initial words?