Hello,
I'm very new to php - MySQL. I've just learnt how to fetch a specific row from a db using the WHERE clause.
example: "SELECT * FROM articles WHERE id=2"
Now, let's say I want to display multiple specific rows, selected by their id's, like rows number 2, 10 and 14 and place them in in different cells of a unique html table... how do I do that?
Any help will be appreciated,
Thanks
Eduardo
fetching multiple rows in the same page
Moderator: General Moderators
Re: fetching multiple rows in the same page
Code: Select all
SELECT * FROM articles WHERE id IN (2,10,4)