USE [SISTEST]
GO

/****** Object:  View [dbo].[vv_ProductSelect]    Script Date: 05/18/2012 09:20:03 ******/
SET ANSI_NULLS ON
GO

SET QUOTED_IDENTIFIER ON
GO



CREATE view [dbo].[vv_ProductSelect]
as
select Oid=case when t2.Oid IS null then t1.Oid else t2.Oid end, 
       Products=t1.Oid,
       StorageComputed=t2.oid
from Products t1 left join StorageComputed t2 on
t1.Oid=t2.Products
where t1.GCRecord is null and t2.GCRecord is null


GO

