You can also DISTINCT command instead.
UNIQUE command isnot supported by mySQL (at least at MySQL 3.23.41- I am
using)

Hope this helps,
M.Mamedov


----- Original Message ----- 
From: "Justin Patrin" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, December 11, 2003 9:52 AM
Subject: [PHP-DB] Re: Very complex query


> Mike U. Petrov wrote:
>
> > Hi every1!
> > Excuse me for maybe offtopic but I need help on mysql database.
> > I have 4 tables, and here are some important extractions from 'em:
> > objects{
> > object_id;
> > name;
> > }
> > users{
> > user_id;
> > nick;
> > date;
> > }
> > notes{
> > user_id;
> > object_id;
> > }
> > object_properties{
> > object_id;
> > property_name;
> > property_value;
> > }
> > I need to get EACH object_id from notes with ONLY ONE of corresponding
> > user_id's. Also for each object I need it's name from objects and
property
> > from object_properties where property_name = 'foo'. And for each of
obtained
> > user_id I need it's nick and it's date.
> > Does anyone know how to do it just by one mysql query?
> >
> > Thanx...
> > Mike U. Petrov
>
> Use unique(user_id). And please don't reply to a previous post when
> posting a new thread....it screws up threading.
>
> -- 
> paperCrane <Justin Patrin>
>
> -- 
> PHP Database Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>


---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.545 / Virus Database: 339 - Release Date: 27.11.2003

-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to