on 12-09-2013 5:52 AM
Hi,
In production order, for example there are 4 items, enduser can not add or delete row items in that particular production order. Once raise the production order, if any one can add or delete any row that screen can not be updated. is there any restrictions to using stored procedure to block that production order or disable that update button.
Kindly provide the query for me.
Regards,
VRK
Hi VRK,
We can block the production order update when child item missing or different from bill of material.
Regards,
Ganesh
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi VRK,
You can use Sp_TransactionNotification stored procedure to block the updation of "Released" production order. Please use following sp
GO
/****** Object: StoredProcedure [dbo].[SBO_SP_TransactionNotification] Script Date: 12/09/2013 11:52:49 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
ALTER proc [dbo].[SBO_SP_TransactionNotification]
@object_type nvarchar(20), -- SBO Object Type
@transaction_type nchar(1), -- [A]dd, [U]pdate, [D]elete, [C]ancel, C[L]ose
@num_of_cols_in_key int,
@list_of_key_cols_tab_del nvarchar(255),
@list_of_cols_val_tab_del nvarchar(255)
AS
begin
-- Return values
declare @error int -- Result (0 for no error)
declare @error_message nvarchar (200) -- Error string to be displayed
select @error = 0
select @error_message = N'Ok'
--------------------------------------------------------------------------------------------------------------------------------
-- ADD YOUR CODE HERE
--------------------------------------------------------------------------------------------------------------------------------
if(@object_type=202 And @transaction_type in ('A','U'))
begin
if exists (select * from AWOR T0 where T0.DocEntry =@list_of_cols_val_tab_del and T0.Status ='R' )
begin
select @error =1
select @error_message ='You can not update prodution order'
end
end
-- Select the return values
select @error, @error_message
end
Please go through the following link
Hope this will help to resolve your issue.
Regards
Manoj
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
91 | |
7 | |
7 | |
4 | |
3 | |
3 | |
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.