Results 1 to 2 of 2
  1. #1
    Join Date
    Jul 2009
    Posts
    58

    Unanswered: Help with Select statement

    Hi Guys,

    I have two tables.

    Code:
    Table A
    Empid  DepCode
       1       1
       1       2
       2       1
       2        2
       2       3
    
    Table B
    Depid
    1
    2
    Now i should get only those empid which has every depid from the Table B. In the above example, i should get only Empid 1. And i should not get empid 2 as it has one more Depcode as 3.


    Can somebody help me with this...

    Thanks for your help in advance.

    Cheers!!!

  2. #2
    Join Date
    Jun 2003
    Location
    West Palm Beach, FL
    Posts
    2,713

    Cool

    Homework?
    Show us what you have coded so far?
    The person who says it can't be done should not interrupt the person doing it. -- Chinese proverb

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •