Initial commit: JDE Scoping Tool migration project
Set up repository with legacy .NET Framework 4.8 source (OLD/), new .NET 10 Blazor solution (NEW/), OpenSpec specifications, documentation, and project configuration.
This commit is contained in:
@@ -0,0 +1,47 @@
|
||||
-- Migration: 028_CreateWorkOrderStepView
|
||||
-- Source: OLD/Database/Views/WorkOrderStep.sql
|
||||
-- Union view with FunctionCode join for description
|
||||
|
||||
CREATE OR ALTER VIEW [dbo].[WorkOrderStep] AS
|
||||
SELECT wos.WorkOrderNumber,
|
||||
wos.WorkCenterCode,
|
||||
wos.StepNumber,
|
||||
wos.StepTypeCode,
|
||||
wos.BranchCode,
|
||||
wos.StepDescription,
|
||||
wos.StartDT,
|
||||
wos.EndDT,
|
||||
wos.FunctionCode,
|
||||
fc.[Description] AS FunctionOperationDescription,
|
||||
wos.ScrappedQuantity,
|
||||
wos.LastUpdateDT
|
||||
FROM
|
||||
(
|
||||
SELECT hist.WorkOrderNumber,
|
||||
hist.WorkCenterCode,
|
||||
hist.StepNumber,
|
||||
hist.StepTypeCode,
|
||||
hist.BranchCode,
|
||||
hist.StepDescription,
|
||||
hist.StartDT,
|
||||
hist.EndDT,
|
||||
hist.FunctionCode,
|
||||
hist.ScrappedQuantity,
|
||||
hist.LastUpdateDT
|
||||
FROM dbo.WorkOrderStep_Hist hist
|
||||
UNION ALL
|
||||
SELECT curr.WorkOrderNumber,
|
||||
curr.WorkCenterCode,
|
||||
curr.StepNumber,
|
||||
curr.StepTypeCode,
|
||||
curr.BranchCode,
|
||||
curr.StepDescription,
|
||||
curr.StartDT,
|
||||
curr.EndDT,
|
||||
curr.FunctionCode,
|
||||
curr.ScrappedQuantity,
|
||||
curr.LastUpdateDT
|
||||
FROM dbo.WorkOrderStep_Curr curr
|
||||
) wos
|
||||
LEFT OUTER JOIN dbo.FunctionCode fc ON (wos.FunctionCode = fc.Code);
|
||||
GO
|
||||
Reference in New Issue
Block a user