SoftTree Technologies SoftTree Technologies
Technical Support Forums
RegisterSearchFAQMemberlistUsergroupsLog in
sql join query

 
Reply to topic    SoftTree Technologies Forum Index » SQL Assistant View previous topic
View next topic
sql join query
Author Message
user71408



Joined: 17 Mar 2008
Posts: 1
Country: India

Post sql join query Reply with quote
Hi I have 3 tables.
Code:


Table                   columns
--------------------------------------------------------
1. Buy                     buyer,sellername
2. IM                      product,hdate,UOM,dept,sec,subsec
3. stud                    dept,sec,subsec



[code]
Required O/P with columns as :
--------------------------------------------

--------------------------------------------------
buyer product dept sec subsec
---------------------------------------------------
[code]

I wrote the query as follows

[code]
select b.buyer,iem.product,iem.dept,iem.class,iem.subsec
from buyer b,im iem,stud st
where iem.class=st.class and b.buyer in
(select buyer from buyer)


Error :
--------
I got for the same item i am getting different buyers..
So please resolve this issue.
I am not able to join BUYER table. Hope i am getting the error
at (select buyer from buyer)
so can you please help me in this issue.


Thank you.
Mon Mar 17, 2008 5:51 am View user's profile Send private message
SysOp
Site Admin


Joined: 26 Nov 2006
Posts: 7833

Post Reply with quote
It looks like you got bad data in your database or your SQL query is not correct

Sorry, I am not really clear what this all has to do with SQL Assistant software?
Mon Mar 17, 2008 10:40 am View user's profile Send private message
Display posts from previous:    
Reply to topic    SoftTree Technologies Forum Index » SQL Assistant All times are GMT - 4 Hours
Page 1 of 1

 
Jump to: 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


 

 

Powered by phpBB © 2001, 2005 phpBB Group
Design by Freestyle XL / Flowers Online.