MySQL Query
Today I wanted to select the names of all attendees for the upcoming TYPO3 Developer Days 2007. I knew, I've done this once before - but didn't remember how I did it. Now I found my "old" soluttion that worked out last year.
SELECT name, tx_ptconference_firstname FROM `fe_users` WHERE
(`usergroup` LIKE '%,7,%') OR (`usergroup` LIKE '7,%')
OR (`usergroup` LIKE '%,7') OR (`usergroup` LIKE '7');
For the next time, I know I've blogged it so I won't have to do such a long search...



Donnerstag, 29-03-07 20:07
SELECT name
FROM fe_users
WHERE CONCAT(',',usergroup,',') LIKE '%,7,%'
;)