Create Scripted Field using substring before "."

Hi Aaron,

thanks a lot for your quick reply.

I get this error "Unable to write index pattern! Refresh the page to get the most up to date changes for this index pattern." and the Create Field object keeps spinning.

I have also found theses articles that seems similar:

But I couldn't make it work. Any help would be greatly appreciated!