Intro to innert select in sql

Before

select OrderID,ProductID

from [Order Details] od 

A select statement with one column as inner select

select OrderID,ProductID,
(select p.CategoryID from Products p where p.ProductID=od.ProductID) categoryId

from [Order Details] od 

Help us improve, Edit this page on GitHub
or email us at info@fireflymigration.com