Saturday, November 17, Bruce Ferrell wrote:

BF> SELECT position, title FROM WHERE position1 IN (1...200) OR position2 IN
BF> (1...200);


no, i wasn't clear enough, let's try it again.

the table book contains :

|-- title -----|--position1--|--position2--|--lots of other fields---
| bravenewworld|          0  |             |
| foundation   |          1  |             |
| shortstories |          2  |          3  |
| neuromancer  |          4  |          7  |
| hyperion     |          8  |          6  |
| salem        |          5  |             |
| lovedeath    |         11  |          9  |

the table could grow further than 200 elements

i want to design a sql request than returns :

|--position--|--- title -----|
|         0  | bravenewworl  |
|         1  | foundation    |
|         2  | shortstories  |
|         3  | shortstories  |
|         4  | neuromancer   |
|         5  | salem         |
|         6  | hyperion      |
|         7  | neuromancer   |
|         8  | hyperion      |
|         9  | lovedeath     |
|         11 | lovedeath     |


---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Reply via email to