Skip to content


Unable to create restriction asked 9 years ago
I am importing from Excel into GP ReceivablesTransaction, and need to restrict amounts that are negative. This is what I have put in the Restrictions:

if _INVAMT > 0 then
return true
else return false
end if

When I run the map, I get errors on the negative amounts, so it doesn't appear that the restriction is working.
Can someone please let me know how i can get the restriction to work?


dfeenstra replied 9 years ago

If you are trying to put a restriction on the "Create Transaction" node, you will get an error since SC is trying to initiate a transaction but a required node is being restricted out. 
Try redoing your datasource to use an ODBC connection and then set your query to be something like "SELECT * FROM [YourSheetName$] where INVAMT>0". 


Dave Feenstra replied 9 years ago

Thank you for the reply Dave. I understand what you're saying, and I can use ODBC and add my filter there.

But can you please tell me what are the Restrictions intended for, if not to filter the data source?

Best Answer
Chris answered 9 years ago
The restrictions only apply on the node they are placed, so if you want to restrict an entire transaction it is better to do it at the data source level.

The restrictions due cut out source data, but they are best used for line item nodes or even further down. An exmaple is a transaction that has analytical accounting info in it, but not on all the lines. You would map the AA node and put a restriction in so it only runs if the AA Code field was populated. 

If the entire transaction needs to be blocked then the data source is the best spot otherwise you end up sneding in lines without a header, or sending entirely blank eConnect calls across when running the map.


If you would like to submit an answer or comment, please sign in to the eOne portal.