cancel
Showing results for 
Search instead for 
Did you mean: 

SP _validation for Outgoing Vender paymnet Project should be same

former_member188586
Active Contributor
0 Kudos

hi

MY Requirement is

OVPM project=Row level Project be same other wise raise erron

header Project = Headoffice

Row level Project =Head office

if both are not match get raise on e error

--Ramudu

Accepted Solutions (0)

Answers (2)

Answers (2)

ganeshram_v
Explorer
0 Kudos

Hi,

Create separate SP for all the transactions just changing the OPCH table to respective table.

Ganesh

ganeshram_v
Explorer
0 Kudos

Hi,

Check this.

If @object_type='46' and @transaction_type in (N'A',N'U')

Begin If exists (SELECT DISTINCT 'ERROR' FROM OVPM A INNER JOIN VPM2 B ON A.DocEntry = B.DocNum INNER JOIN OPCH C ON C.DocEntry = B.DocEntry WHERE A.PrjCode <> C.Project AND A.DocEntry = @list_of_cols_val_tab_del)

Begin set @error ='02'

Set @error_message=N'Testing!'

end

end

Ganesh

former_member188586
Active Contributor
0 Kudos

Hi ganesh ram ..thanks for Quick replay .for invoice ok ,what about journal entry and Down paymentt advice's

after selecting the vendor name , what ever the dispalys it should it be ovpm has to match