i am trying to sort mysql data with alphabeticaly like
A | B | C | D
when i click on B this query runs
select name from user order by \
If you want to restrict the rows that are returned by a query, you need to use a WHERE clause, rather than an ORDER BY clause. Try
WHERE
ORDER BY
select name from user where name like 'b%'