Good all the time of the day gentlemen
There is a sign from which I want to group the data by the number field:
$zapros = mysql_query("SELECT * FROM `table` GROUP BY `number`,$db); // работает
Is it possible to make the same grouping by number, but not by the whole number, but from 2nd to 5th character (3 characters)? Ie: from 8388608, 8387608, 8388609 - must find 2 records
ps in my example it turns out they look through 3 records (there are actually several thousand of them), and they have from 2nd to 5th character: 886, 876, 886. then group them together, we get 886, 876. would hear once, something like:
$zapros = mysql_query("SELECT * FROM `table` GROUP BY `substr(number,2,3)`,$db);