I have a table os which contains below data
id name
-- ----
1 windows server 2012 R2
2 windows 2016 SQL
3 Oracle linux 7.5
I need to update os table to something like below
id name
-- ----
1 windows server
2 windows
3 Oracle linux
Basically I need to extract the text from name starting from to before the number.
I am not getting an idea about how to do this. How can I do this in a Postgresql query?