Pregunta

I want to return all columns, and anywhere there's a NULL to say 'hey' instead.

But this doesn't work

SELECT IFNULL(*, 'hey') FROM $table
¿Fue útil?

Solución

You have to do this one column at a time.

Functions do not generally take * as an argument.

select ifnull(col1, 'hey'), . . .
Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow
scroll top