first, you'd better post some of the something you tried here.
In mysql 8.0
you can use row_number() over (partition by B, C order by A)
to slove this question.
CREATE TABLE Table1
(`A` int, `B` int, `C` int)
;
INSERT INTO Table1
(`A`, `B`, `C`)
VALUES
(1, 2, 3),
(2, 2, 3),
(2, 5, 6),
(3, 5, 6)
;
select `A`, `B`, `C` from (
select *,row_number() over (partition by `B`, `C` order by `A`) rnk from Table1
) T
where rnk = 1;
A | B | C
-: | -: | -:
1 | 2 | 3
2 | 5 | 6
db<>fiddle here
if mysql < 8.0
you can follow this answer ROW_NUMBER() in MySQL
Update :
if like @forpas says : taking the first occurrence of A for that pair of B, C is not solved by order by A.
You have to sort the rownum first :
CREATE TABLE Table1
(`A` int, `B` int, `C` int)
;
INSERT INTO Table1
(`A`, `B`, `C`)
VALUES
(2, 2, 3),
(1, 2, 3),
(2, 5, 6),
(3, 5, 6)
;
SET @rownum:=0;
select `A`, `B`, `C` from (
select *,row_number() over (partition by `B`, `C` order by rownum) rnk from (
select *,@rownum:=@rownum+1 AS rownum from Table1
) T
) T
where rnk = 1;
✓
A | B | C
-: | -: | -:
2 | 2 | 3
2 | 5 | 6
db<>fiddle here