On Monday 14 August 2006 07:08 am, Michael DePhillips wrote:
> select ID from T1 where ID = 1235 and ID<1235 and ID >1235 LIMIT 3
> (obviously this doesn't work)  I would want to return....
>
> 1234
> 1235
> 1236

mysql> select int_value, (int_value + 1) as value2, (int_value - 1) as value3 
FROM data_values;
+-----------+--------+--------+
| int_value | value2 | value3 |
+-----------+--------+--------+
|        11 |     12 |     10 |
+-----------+--------+--------+
1 row in set (0.00 sec)

You can do like that.

-- 
Chris White
PHP Programmer/DBrother
Interfuel

-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to