on 08-25-2015 8:41 PM
Dear Experts,
In Production order Transaction,
Cost center mandatory
IF @transaction_type='A' AND @Object_type = '202'
BEGIN
IF EXISTS (SELECT T0.DocEntry FROM dbo.WOR1 T0
WHERE ((T0.[OcrCode]='' OR T0.[OcrCode] IS NULL) and (T0.[OcrCode2]='' OR T0.[OcrCode2] IS NULL) and (T0.[OcrCode3]='' OR T0.[OcrCode3] IS NULL) and
(T0.[OcrCode4]='' OR T0.[OcrCode4] IS NULL) and (T0.[OcrCode5]='' OR T0.[OcrCode5] IS NULL)) AND T0.DocEntry = @list_of_cols_val_tab_del)
Begin
SET @Error = 1111
SET @error_message = 'At least one cost center is mandatory!'
End
End
My Requirement Dimension 3 mandatory in production order.
try this
IF @transaction_type = 'A'
AND @Object_type = '202'
BEGIN
IF EXISTS (
SELECT T0.DocEntry
FROM dbo.WOR1 T0
WHERE
ISNULL(T0.[OcrCode],'') = ''
AND ISNULL(T0.[OcrCode2],'') = ''
AND isnull(T0.[OcrCode3],'') = ''
AND isnull(T0.[OcrCode4],'') = ''
AND isnull(T0.[OcrCode5],'') = ''
AND T0.DocEntry = @list_of_cols_val_tab_del
)
BEGIN
SET @Error = 1111
SET @error_message = 'At least one cost center is mandatory!'
END
END
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Dear Experts,
Its urgent. Any updates.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
108 | |
12 | |
11 | |
6 | |
5 | |
4 | |
3 | |
3 | |
3 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.