Skip to main content
Solved

Close Previous Line - Migration Job

  • September 30, 2021
  • 2 replies
  • 125 views

robert_g
Sidekick (Customer)
Forum|alt.badge.img+7

Hi all,

 

I have an excel migration for Supplier for Purchase Part. This allows price lists to be created by users and inserted to the price list tab. However, if a price list is active - this prevents the tool from working. Is there a way to close an active price list automatically before the new price list is inserted?

Best answer by pwlm

Hi @robert_g,

The CONNJOB isn’t an available rule for Excel Migration jobs.

This can be achieved by adding a row to the start of the Source Mapping which calls a custom function that performs the following steps:

  1. Check if date of new entry will overlap with existing entries.
  2. If overlap then call autonomous procedure to amend VALID_UNTIL date on existing entries.
  3. the DM job will then execute with no errors.

Cheers,

Pete

View original
Did this topic help you find an answer to your question?
This topic has been closed for comments

2 replies

Forum|alt.badge.img+10
  • Hero (Customer)
  • 82 replies
  • October 4, 2021

S4PP price lists have effectivity dates (date from/date to)

I presume you are getting an ‘interval already exists or overlaps and existing interval’ error message?

So, you need to have two migration jobs.

  1. Close any Price Lists for any Supplier/partcode combinations you are about to update by setting the ‘To date’ to today -1
  2. Add the new Price list entries with a ‘From Date’ set to today

You can chain DataMig jobs together by calling the first from the 2nd using a CONNJOB parameter which allows for some degree of error checking before processing.

 


pwlm
Hero (Partner)
Forum|alt.badge.img+11
  • Hero (Partner)
  • 70 replies
  • Answer
  • October 8, 2021

Hi @robert_g,

The CONNJOB isn’t an available rule for Excel Migration jobs.

This can be achieved by adding a row to the start of the Source Mapping which calls a custom function that performs the following steps:

  1. Check if date of new entry will overlap with existing entries.
  2. If overlap then call autonomous procedure to amend VALID_UNTIL date on existing entries.
  3. the DM job will then execute with no errors.

Cheers,

Pete


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings