select abbreviateName,CustomerPONo,DelNotifyNo,PlanShipDate,PartSpec,NotifyQty,forwarderName,EnteredDate,Remark,round(isnull(dbo.Get_PartTotalStock(site,partNo),0),2) stock from (
select abbreviateName,CustomerPONo,DelNotifyNo,PlanShipDate,PartSpec,NotifyQty,forwarderName,EnteredDate,Remark,site,partNo from view_KANBAN_CODelNotify_new
select abbreviateName,CustomerPONo,DelNotifyNo,PlanShipDate,PartSpec,NotifyQty,forwarderName,EnteredDate,Remark,round(isnull(dbo.Get_PartTotalStock(site,partNo),0),2) stock ,finishedFlag from (
select abbreviateName,CustomerPONo,DelNotifyNo,PlanShipDate,PartSpec,NotifyQty,forwarderName,EnteredDate,Remark,site,partNo,finishedFlag from view_KANBAN_CODelNotify_new