How to overwrite target values based on certain source value conditions

Hey!

Ok, so I have an ERP to Website connection (Prophet21 to Magento). I'm wanting to show whether products are in stock or out of stock online.

 

I've attached a screenshot of my map so far.

 

I'm querying P21

Fetching Product and Stock Status tables from Magento (stock status table being the child)

Then, for Each Child see if row as a Quantity greater than 0

If greater than 0, then it's in stock

If it's in stock, then overwrite Magento is_in_stock field with 1 (1 means In Stock in Magento)

Etc

 

But I don't think I've built my Update Block correctly - see screenshot of Field Linking tab.

 

I've just entered the number to be entered in the is_in_stock field, but I have a feeling that's too simple (needs to be a formula or something).

 

To clarify: There is no exact correlation between the source, and the target Magento field I'm wanting to overwrite. Meaning, the P21 source field must have a quantity greater than zero, in order to write in "1" into the Magento target field.

 

Hope that makes sense.

 

Please help, thanks!

 

 

(7) Answers

Login