Search This Blog

2023/06/21

get salary greater than value along with their id

 create table emp(

id int auto_increment primary key,
salary float
)

insert into emp(salary) values(1000),(2000),(3000),(4000),(5000),(6000)


select * from emp;

select count(*),group_concat(id) from emp
where salary > 2000

No comments:

Post a Comment