You are here: sql code left outer join « PHP SQL « IT news, forums, messages
sql code left outer join

Posted by Raj on 10/04/90 11:32

Hi, I'm trying to left outer join two tables onto one. For some reason the
table is losing some of the left table data (vw_standard_costing_items).
Please can you tell me why, and a fix please?



I'm left outer joining

vw_standard_costing_budgeted_amount

and

vw_standard_costing_purchase_price

onto

vw_standard_costing_items




Thanks,

Raj (Newbie)



SELECT dbo.vw_standard_costing_items.No_,
dbo.vw_standard_costing_items.[Safety Stock Quantity],

dbo.vw_standard_costing_items.[Gen_ Prod_ Posting
Group], dbo.vw_standard_costing_items.Form,
dbo.vw_standard_costing_items.Description,

dbo.vw_standard_costing_items.[Description 2],
dbo.vw_standard_costing_items.[Vendor No_],
dbo.vw_standard_costing_budgeted_amount.Name,

dbo.vw_standard_costing_budgeted_amount.[Budgeted
Amount], dbo.vw_standard_costing_items.[Minimum Order Quantity],

dbo.vw_standard_costing_purchase_price.[Currency Code],
dbo.vw_standard_costing_purchase_price.[Direct Unit Cost],

dbo.vw_standard_costing_purchase_price.[Starting Date],
dbo.vw_standard_costing_purchase_price.[Ending Date],

dbo.vw_standard_costing_purchase_price.[Unit of Measure
Code]

FROM dbo.vw_standard_costing_items LEFT OUTER JOIN

dbo.vw_standard_costing_budgeted_amount ON

dbo.vw_standard_costing_items.[Vendor No_] =
dbo.vw_standard_costing_budgeted_amount.No_ LEFT OUTER JOIN

dbo.vw_standard_costing_purchase_price ON

dbo.vw_standard_costing_items.[Vendor No_] =
dbo.vw_standard_costing_purchase_price.[Vendor No_] AND

dbo.vw_standard_costing_items.No_ =
dbo.vw_standard_costing_purchase_price.[Item No_]

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация