Michael wrote:Are there are any implications with inserting orders placed online from our site directly into the database as opposed to using XML files with the Jiwa file watcher?
Hi Michael,
Yes, there are some considerations and potential problems.
When you use the XML import, it uses our business logic for the appropriate document (in your case, the sales order business logic) and as such the logic associated with both the sales order and the system in general are enforced. This basically means that the nuances of how to create an order are abstracted away and insulated from you. Things like FIFO stock allocation are complex and not something you'd want to do with direct table inserts / updates.
If the orders you place don't involve the complex aspects of sales order entry - such as stock allocation, payments, et cetera - then direct inserts aren't that difficult, but there are still many rules you must adhere to in order to maintain data integrity. We don't document how to do those direct inserts to the database, but we can help with that if you feel it's the best solution for you.
As you have posted in the Jiwa 6 forum, I'm going to assume you're interested in integrating with version 6 of Jiwa and not Version 7 (if you are using Version 7 or going to be moving to that version soon, then there are also web services options for order entry which may be of interest to you). In both versions I would recommend order entry from an online store to not be done using direct table inserts.
We have a low-priority project (meaning when we have the time!) in progress to build an integration with the
Magento e-commerce solution with Jiwa 7. This is using web services and the Jiwa 7 plugin framework. We're only part way into that project but it may be worth keeping in mind if you are developing an e-commerce front end to Jiwa.
In summary - we don't recommend direct database inserts for integrations, but it is possible - it all depends on the scope of the integration.
I hope that helps - if you have any further questions please don't hesitate to ask.
Mike