[PHP-DB] Making Join

2003-02-28 Thread Daniel Harik
> > Hello, > > > > I have 2 tables users table, that stores user info, and photos table, > > i want to select all users with one photo form photos table, but i don't > > want it to be photos * users = result. > > > > Is there way to do it? > > Assuming you mean, you have a table called user_info a

Re: [PHP-DB] Making Join

2003-03-01 Thread Daniel Harik
Mark wrote: > > --- Daniel Harik <[EMAIL PROTECTED]> wrote: >> > > Hello, >> > > >> > > I have 2 tables users table, that stores user info, and photos >> table, >> > > i want to select all users with one photo form photos

Re: [PHP-DB] Making Join

2003-03-01 Thread Daniel Harik
Paul Burney wrote: > on 2/28/03 3:15 PM, Daniel Harik at [EMAIL PROTECTED] appended the > following bits to my mbox: > >> Thank You for your reply, but the problem is that users may have many >> photos, and i need to get only one, i use folllowing sql: >> SELECT users

[PHP-DB] group by get last record

2003-03-15 Thread Daniel Harik
Hello, Guys i try to join to tables slides: id userid file moment users id username As there few slids per user and i want to get only last one, i use following sql query, but it fetches me first slide. How can i make it fetch last one please? SELECT slides.file, slides.moment, users.id, us

[PHP-DB] Re: Making tree menu

2003-03-20 Thread Daniel Harik
Hello, thanks for all replies guyes :) i di this before reading them Bookmarks Bookmarks\n\n"; tree(0);

[PHP-DB] Making tree menu

2003-03-19 Thread Daniel Harik
Hello guys I make following query: mysql> SELECT b.type, a.link AS parent_link, b.link AS child_link FROM bookmarks AS a, bookmarks AS b WHERE a.id = b.parentid order by parent_link; and here is result ++-++ | type | parent_link | child_link