CONCAT function returns NULL if there is NULL in concatination. CONCAT_WS just skips the NULL, it return concatenate with separator SYNTAX: CONCAT_WS(separator,str1,str2,...) e.g. select concat("1-","2-",NULL,"3-"); OUTPUT is: (NULL) select concat_ws("-","1","2",NULL,"3"); OUTPUT is: 1-2-3
|
My Blog Title
|