Check this:
SELECT GROUP_CONCAT(id)
FROM table_level
WHERE parent_id = 4
GROUP BY parent_id;
More Related Contents:
- Recreating a query using INNER JOIN? [duplicate]
- MySQL – UPDATE query based on SELECT Query
- quick selection of a random row from a large table in mysql
- MySQL: is a SELECT statement case sensitive?
- Create a temporary table in a SELECT statement without a separate CREATE TABLE
- MySQL SELECT WHERE datetime matches day (and not necessarily time)
- MySQL Query – Records between Today and Last 30 Days
- Ordering by specific field value first
- SELECT / GROUP BY – segments of time (10 seconds, 30 seconds, etc)
- INSERT INTO…SELECT for all MySQL columns
- Combine Multiple child rows into one row MYSQL
- #1139 – Got error ‘repetition-operator operand invalid’ from regexp
- MySQL select statement with CASE or IF ELSEIF? Not sure how to get the result
- How to get an age from a D.O.B field in MySQL?
- Checking multiple columns for one value
- MySQL difference between two rows of a SELECT Statement
- MySQL – How to search for exact word match using LIKE?
- MySQL – How to select data by string length
- MySQL How do you INSERT INTO a table with a SELECT subquery returning multiple rows?
- How do I get the first day of the week of a date in mysql?
- MySQL error 1241: Operand should contain 1 column(s)
- quick selection of a random row from a large table in mysql
- Converting SELECT DISTINCT ON queries from Postgresql to MySQL
- mysql select sum group by date
- SELECT query return 1 row from each group
- MySQL Select Query – Get only first 10 characters of a value
- SELECT INTO Variable in MySQL DECLARE causes syntax error?
- MySQL Error: #1142 – SELECT command denied to user
- MySQL Select Multiple VALUES
- mySQL returns all rows when field=0