Update Sales Transactions Distributions From Item

Microsoft Dynamics GPThis is a script I’ve had a few months now and, like the one I posted yesterday, thought it might be useful to others.

This script was created for a client who changed some of their account codes on some Item Classes and had rolled them down to the Items themselves but there were many Sales Transactions already on the system which had the old code on and needed to be updated to the new one.

A relatively simple SQL script later and I had a method which would update all Quotes and Orders at a status of Work in Sales Order Processing with the new codes from the Item where the Item Class was within a required range;

   ['Sales Transactions Amounts Work']
   INVINDX = ['Item Master'].IVIVINDX -- Inventory
   ,CSLSINDX = ['Item Master'].IVCOGSIX -- Cost of Goods Sold
   ,SLSINDX = ['Item Master'].IVSLSIDX -- Sales
   SOP10200 AS ['Sales Transactions Amounts Work']
   IV00101 AS ['Item Master']
      ON ['Item Master'].ITEMNMBR = ['Sales Transactions Amounts Work'].ITEMNMBR
   ['Sales Transactions Amounts Work'].SOPTYPE IN (1, 2)

If Invoices, Returns or Fulfillment Orders also need to be updated then another script which updates Sales Transaction Distributions Work (SOP10102) would be needed in addition to the above.

If you use this script then, as always when running a script, please make sure you have a good backup of your company database (I define a good backup as one you have restored to ensure it backed up correctly) and know what you are doing in Management Studio with SQL Statements.

Can ISC Software Solutions help?

ISC Software Solutions are UK and Ireland based experts on Microsoft Dynamics GP. If you’d like to speak to someone about support, consultancy, upgrades, implementation, development, GP Elementz add-ons or portals, or anything else Dynamics GP related, you can use the form below.

Your Name (required):
Your Email (required):
Enquiry message:

What should we write about next?

Your Name (required) –
Your Email (required) –

2 thoughts on “Update Sales Transactions Distributions From Item

  1. Pingback: Comment
  2. Pingback: Comment

Leave a Reply

Your email address will not be published. Required fields are marked *