corsasport.co.uk
 

Corsa Sport » Message Board » Off Day » Geek Day » Friday Night MySQL Party » Post Reply

Post Reply
Who Can Post? All users can post new topics and all users can reply.
Icon:
Formatting Mode:
Normal
Advanced
Help

Insert Bold text Insert Italicized text Insert Underlined text Insert Centered text Insert a Hyperlink Insert Email Hyperlink Insert an Image Insert Code Formatted text Insert Quoted text
Message:
HTML is Off
Smilies are On
BB Code is On
[img] Code is On
Post Options: Disable smileys?
Turn BBCode off?
Receive email notification of new replies?

Baskey

posted on 12th Oct 12 at 21:52

You wouldn't be updating it but you could use a case statement to display 'queued' instead of wait in the results


ed

posted on 12th Oct 12 at 21:08

Two queries it is then - thanks :)


Ian

posted on 12th Oct 12 at 21:07

No, update and select are separate.

Although the where clause will be the same to select the same records you want to affect.


ed

posted on 12th Oct 12 at 21:05

Right, got a simple query which selects the first five records from a database like so:

SELECT Public_ID,User_ID,Full_URL,Description FROM jbs_images WHERE Accepted=1 && YT_ID='wait' ORDER BY Last_Update LIMIT 0,5

Is it possible to update a value while doing a select? I'd like to set YT_ID to 'queued' somehow, could do a second query I suppose.