Advertisement
rstx2

mes mes mes

Dec 2nd, 2024
65
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
SQL 0.49 KB | None | 0 0
  1.  SELECT  DISTINCT
  2.                 A.Dept_ID Dept_ID,
  3.                 C.Style_No Model_No,
  4.                 C.Style_Name Model_Name,
  5.                 C.Color_No Article,
  6.                 A.Work_Date Work_Date,
  7.                 A.MO_No
  8.             FROM [TSH-MSSQL1].[TSHMES].[dbo].[MES_Yield_Log] AS A
  9.                 LEFT JOIN [TSH-MSSQL1].[TSHMES].[dbo].[MES_Dept] B ON A.Dept_ID = B.Dept_ID
  10.                 LEFT JOIN [TSH-MSSQL1].[TSHMES].[dbo].[MES_MO] C ON A.MO_No = C.MO_No AND A.Seq = C.MO_Seq
  11.             WHERE A.Work_Date = CAST(getdate() AS DATE) AND A.Time_Bucket IS NOT NULL AND C.Style_No IS NULL
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement