I have a simple array $ids e.g. (2,9,4,10,18). And also I've got a mysql table $table1 with the same IDs as primary keys. My question is: how to select the elements in my table in THE SAME ORDER as the IDs go in my array using just 1 query (I don't what to call the query by every ID number of an array, because the table is supposed to have a lot of entries).
Still, if you can give me another way to do it, I would like to know it.