Setting PURCHSTAT for DROPSHIP items.

An easy way to fix this is with the POST stored procedure associated with taSopHdrIvcInsert.  This would be the taSopHdrIvcInsertPost.sql file.  Remember that each eConnect function is executed by a stored procedure with the same name and that each of these stored procedures has a PRE and POST that is executed before and after, respectively.

 

The Pre and Post stored procedures have a section for custom business logic, which is where we want to put the code, as follows:

/* Create Custom Business Logic */
 
UPDATE SOP10200
    SET PURCHSTAT = 2
    WHERE   SOPTYPE = @I_vSOPTYPE
        AND SOPNUMBE = @I_vSOPNUMBE
        AND DROPSHIP = 1
        AND PURCHSTAT <> 2
 
/* End Create Custom Business Logic */

 

 

Remember to check before modifying any existing code within that section!

 


RealWorldCode gives developers practical, real‑world solutions with clean, working code — no fluff, no theory, just answers.
Links
Home
Knowledge Areas
Sitemap
Contact
Et cetera
Privacy Policy
Terms and Conditions
Cookie Preferences