Skip to main content

Notifications

Microsoft Dynamics GP (Archived)

How do I properly close/cancel POs using SQL?

Posted on by 95

I'm trying to mass-close old POs that have not been closed or cancelled using SQL.

Can I just do the following?

    UPDATE POP10100 SET POSTATUS = 5 WHERE PONUMBER in ('PO1', 'PO2','PO3'...)

This only changes the header level status, but not line-level status. I'm not sure if I will be able to remove them to history afterwards.

Or do I need to change the line-level status too?  If so, would I be changing to 5 (closed) or 6(cancelled)?

Does this interfere with GP's normal process?

Any input would be appreaciated.  Thank you.

 

·     

*This post is locked for comments

  • Re: How do I properly close/cancel POs using SQL?

    We do not recommend to update information on the backend unless you have to. With that being said please make sure you have backups:

    UPDATE POP10100 set STATGRP = 2, POSTATUS = 5 where DEX_ROW_ID = 240843

    The above script would be an example

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Community AMA December 12th

Join us as we continue to demystify the Dynamics 365 Contact Center

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,253 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,188 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans