Solved

Conditional values on Import Scenarios

  • 11 May 2022
  • 7 replies
  • 140 views

Userlevel 1
Badge

I’m working on an Import Scenario that will update a sales order’s user-defined attribute.

The simplified process will go as followed:

  1. Identify the order by Type and Number
  2. Open or Re-Open the order (QT requires the Re-Open)
  3. Set the attribute
  4. Return the order it starting state

Steps 3 and 4 need to be conditional and I haven’t found any documentation on how to do that. For instance, step 3 would need something like:

 IIf(=[Document.OrderType] = ‘QT’, <Action: Open Order> (OpenOrder), <Action: Re-Open Order> (ReopenOrder)


As a work-a-round I am thinking about using Target Restrictions to limit the data to a single condition, i.e., QT and Completed or QT and Canceled. That way I can set the Mapping fields and change them each time to match the current conditon. I’m really trying to avoid this since it will be fairly manual. 

icon

Best answer by IhorPatko 4 August 2022, 13:27

View original

7 replies

Userlevel 3
Badge +1

My initial thought is to use workflow or a small customization to keep the attribute field open on every order status so that your import scenario just updates the attribute without having to worry about status.  

I can’t think of a way to do that through a single import scenario.

-Kurt

Userlevel 1
Badge

I was really hoping there was something out of the box to support this. Especially since opening/re-opening is only the first part. As I noted in step 4, I have to return the order back to their start state (closed, confirmed, cancelled, etc.).

Looks like it might be time to reach out to our VAR and see if they can run a script on the SQL database. 

@KurtBauer thanks for commenting, and I’m definitely going to have to keep playing with workflows to see what else I can do.   

Userlevel 7
Badge +8

Hi @abrunner78 

As you mentioned, using target restriction is the only out of the box option one can use with import scenario. You may have more than one scenario with same provider with different target restriction. That should not consume more time since you would use same DB provider. 

Is this an on going import and also automated? If so, creating more than one import scenario using same provider and different target restriction should work. 

Hope this helps,

Regards,

Userlevel 1
Badge

@vkumar This would be a 1 off run to update older records.

While the target restrictions might be the best and, probably, only option, I would end up needing a handful of import scenarios to make this work. However, if that is what it is going to take I’ll do it. 

To my other point, having our VAR update the SQL database with a script, is there any fault in that? We are just trying to populate a user-defined field value on sales orders. Since these fields aren’t tied to any of Acumatica’s logic or core processes, I assumed we could update the field without disturbing (changing) anything else? 

Userlevel 7
Badge

Hi @abrunner78 - were you ever able to find a solution for this issue? Thank you!

Userlevel 1
Badge

@Chris Hackett Asking here, looking online, and talking with our VAR, it doesn’t seem that there is a solution for this issue.

@abrunner78,

Please try conditional workflow actions described below.

It helped me to put SO on hold if the current status is not on hold and Hold flag in my data provider.

 

Reply


About Acumatica ERP system
Acumatica Cloud ERP provides the best business management solution for transforming your company to thrive in the new digital economy. Built on a future-proof platform with open architecture for rapid integrations, scalability, and ease of use, Acumatica delivers unparalleled value to small and midmarket organizations. Connected Business. Delivered.
© 2008 — 2022  Acumatica, Inc. All rights reserved