3
I have a table with the following names:
João Goldy Alfredo, Gaby, João Antônio, Rodrigo, Maria Aparecida, Mario
How can I get only their first name, and those who don’t have a last name, should show it anyway.
what I tried to:
SELECT SUBSTR(NOMEJOGADOR, 0, INSTR(NOMEJOGADOR, ' ', -3))
FROM JOGADOR;
but with this I only managed to get the first name of those who have surname, already Gaby, Rodrigo and Mario do not appear in the select. Is there any way to return the first name of the surname and show those who have no surname?
It worked perfectly! Thanks for the help
– lfmaker