我有以下查询:Transfering右连接到子查询
select
name, description
from tblproducts
right join tblproductssales
on tblproducts.ID = tblproductssales.Product_ID
我怎样才能使用子查询相同retreived数据?
我有以下查询:Transfering右连接到子查询
select
name, description
from tblproducts
right join tblproductssales
on tblproducts.ID = tblproductssales.Product_ID
我怎样才能使用子查询相同retreived数据?
SELECT
(SELECT name FROM tblproducts WHERE ID = A.ProductID) AS name,
(SELECT description FROM tblproducts WHERE ID = A.ProductID) AS description
FROM tblproductssales A
非常感谢你http://stackoverflow.com/users/2254931/nguy%e1%bb%85n-h%e1%ba%a3i-tri%e1%bb%81u)它工作,谢谢你的反馈 –
哦,没问题:) –
如果需要任何帮助,我可以谈谈您的电子邮件或任何联系信息。 –
使用JOINS有什么问题? –
你想在这里实现什么? –
'select name,description from tblproducts where ID In(select tblproductssales中的Product_ID)' –