Hi Micro why you create a separate table for each group?
usaly the groups are all in a singel table I think is a veter aproact one table for users other for groups and a third table for the realtion betwen users and groups, you can view all the groups that a user beyons to with a select * FROM GroupUsers where userId='user' Users userId; name; Groups groupId; name; GroupUsers userId; groupId; On 11/18/06, Micro Mega Dust <[EMAIL PROTECTED]> wrote:
Hi, I'm a novice using databases, and I have a doubt about the working of SQL language: I have a system of user group, where each group is a table in sqlite_master, (each table of a group contains the UIDs of the members). But I don't know how to get the groups of a user, in a single query. I tried this: SELECT name FROM sqlite_master WHERE 'foo' IN name /* foo is a UID */; But don't work, "name" is used like a literal value. Is possible? Thanks! P.D.: I using SQLite version "2.8.17". ----------------------------------------------------------------------------- To unsubscribe, send email to [EMAIL PROTECTED] -----------------------------------------------------------------------------
-- play tetris http://pepone.on-rez.com/tetris run gentoo http://gentoo-notes.blogspot.com/ ----------------------------------------------------------------------------- To unsubscribe, send email to [EMAIL PROTECTED] -----------------------------------------------------------------------------