Jump to content
Sign in to follow this  
Manj

SQL Query - Conditions

Recommended Posts

Hi, 

I am not sure how to write a query for the below case, Pls help me out.

 ID          description          values             
M1 ab1 23        
M1 ab2 54        
M1 ab3 23        
M2 ab1 67        
M2 ab2 56        
M2 ab3 91        
M3 ab1 41        
M3 ab2 53        
M3 ab3 27        
M3 ab4 41        

Conditions: I need to pick the row when values are same for different description under similar ID, 

Example: Under ID (M1) , I have the description (ab1 and ab3) have same values (23), 

                  Similarly ID (M3) have same values 41 for descripttion ab1 and ab4. hence the result must be only Red texted in the table. 

 

Thanks In advance.

 

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
Sign in to follow this  

×
×
  • Create New...