Anda cukup IFNULL
kolom yang bisa NULL
;
SELECT userId, GROUP_CONCAT(CONCAT(questionId, '=',
IFNULL(selectionId, 'NULL')))
FROM selection
GROUP BY userId;
Demo di sini .
Anda cukup IFNULL
kolom yang bisa NULL
;
SELECT userId, GROUP_CONCAT(CONCAT(questionId, '=',
IFNULL(selectionId, 'NULL')))
FROM selection
GROUP BY userId;
Demo di sini .