diff --git a/svc/queries/orderproduction_items.go b/svc/queries/orderproduction_items.go index d6bcf34..b6e7181 100644 --- a/svc/queries/orderproduction_items.go +++ b/svc/queries/orderproduction_items.go @@ -967,13 +967,14 @@ FROM missing m CROSS JOIN ( SELECT ISNULL(MAX( - CASE - WHEN ISNUMERIC(Barcode)=1 - THEN CAST(Barcode AS BIGINT) - ELSE NULL - END -),0) MaxBarcode -FROM dbo.prItemBarcode + CASE + WHEN ISNUMERIC(Barcode)=1 + THEN CAST(Barcode AS BIGINT) + ELSE NULL + END + ),0) AS MaxBarcode + FROM dbo.prItemBarcode +) seed `, strings.Join(values, ","), orderHeaderParam, usernameParam, usernameParam) chunkStart := time.Now()