I am having one requirement
ie.
while adding purchase request..
header level date should be validate.
ie. required date should not be greater than Mr date
i used below one but i not able to get the result..
Any information plz update me.
IF @OBJECT_TYPE = '1470000113' AND (@TRANSACTION_TYPE = 'A' or @TRANSACTION_TYPE = 'U')
BEGIN
declare @date INT
set @date =(select DATEDIFF(DD, T0.TAXDATE, T0.REQDATE) from OPRQ T0 where T0.DocEntry = @list_of_cols_val_tab_del)
IF EXISTS (SELECT @DATE > 1)
Begin
SET @error = 10
SET @error_message = 'U Can not Update the doucemnt plz check it'
End
End