Quantcast
Channel: SCN: Message List
Viewing all articles
Browse latest Browse all 8491

SP to block Credit Limit change

$
0
0

Help Me to modify below SP

 

IF @OBJECT_TYPE='2' AND @TRANSACTION_TYPE IN (N'A', N'U')

     BEGIN

if exists (Select T0.CreditLine from OCRD T0

INNER JOIN DBO.OUSR T2 ON T0.UserSign=T2.USERID

            where  T0.[usersign] not in ('1','5') AND  T0.CreditLine>=@list_of_cols_val_tab_del and

            T0.CreditLine<=@list_of_cols_val_tab_del  )

Begin

set @error = 30

set @error_message=N'You are not authorized to change payment terms'

End

END


Viewing all articles
Browse latest Browse all 8491

Trending Articles