Hi.
I have this table (A)

IDJOB ¦ IDKIT

  4     ¦  19   
  4     ¦  19 
  2     ¦  19 
  2     ¦  5

I need to extract IDKIT with IDJOB<>2 if and only if IDKIT <> IDKIT when
IDJOB=2
In this case my query should return null
With a subquery I can do this and it works

SELECT idkit from A where A.id_job<>2 and A.id_kit not in  (select
A.id_kit from A where A.id_job=2)

Anyone could suggest how I could do this in mysql without subquery?

Thanks in advance

Matteo

---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Reply via email to