You are here: SQL question « All PHP « IT news, forums, messages
SQL question

Posted by lallous on 10/12/55 11:38

Hello list,

I have three tables:

mailinglist(listid, name)
subscribers(userid, listid)
users(userid, username)

A given user can belong to multiple mailing lists and his membership is
defined by an entry in subscribers table.

How can I write a 3.23 compatible MySQL statement to list all mailing lists
names and a field that designates whether a user with a given ID is
subscribed to it or not?

Currently, I am doing two queries then glueing them through a PHP script.

Regards,
Elias

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация