today i learned how to send a query to select between values

for example, i have 50 user_id and i want to select only between 25 and 30 so to do that, i can send this query:

$sql = "SELECT user_id FROM mytable WHERE user_id BETWEEN 25 AND 30";