Skip to content

SEPARATOR

SELECT GROUP_CONCAT(name SEPARATOR '; ')
FROM users;
John Doe; Jane Doe; Richard Roe; John Stiles

In the provided example, the GROUP_CONCAT function is used to concatenate all the values from the name column of the users table. The SEPARATOR clause within the GROUP_CONCAT function is used to define the delimiter that separates the values, in this case, a semicolon ’;’ followed by a space. Therefore, the result is a string of all name column values separated by a semicolon and a space.