Do you have a question? Post it now! No Registration Necessary. Now with pictures!
- Posted on
- mysql question
- Bob Bedford
March 9, 2006, 1:31 pm
rate this thread
I know this isn't a mysql NG, but I've no access to any good mysql
newsgroup, and since most php coders also know mysql, I ask here.
I've a table in wich I store pictures of articles. I've a field where I
store the priority (let's say is the order the pictures are shown).
So I've those fields in the database: articleID, imagepath, priority.
So for article 455 I've this record:
Now some articles have missing numbers priority.
example article 24 has those records:
I've up to 5 pictures per article. How to retrieve with a query all
articlesID where I've priority 2 but not priority1 with mysql ?
Thanks for helping
Re: mysql question
SELECT articleID FROM ArticleTable GROUP BY articleID HAVING
Is that what you meant?
Andy Jeffries MBCS CITP ZCE | gPHPEdit Lead Developer
http://www.gphpedit.org | PHP editor for Gnome 2
http://www.andyjeffries.co.uk | Personal site and photos