I work for a software company that makes business information systems for a large enterprise. We do systems for invoicing, payment, planning, etc. The enterprise uses SAP for their core system, and our systems use SQL Server with PHP as the application layer.
So far we've always used XML files to communicate between SQL Server and SAP, if SQL wants to send data to SAP, it would write an XML file to a certain folder, which SAP will consume on a daily schedule, and write an XML file response back to another folder, which SQL will consume on a schedule as well. This scheme has been rather error prone, and generating the XML file is extremely slow using cursor operations, and it often causes timeout errors which needs manual correction.
Is there a better way to communicate? The SAP system is from a different software vendor but we can ask them to make modifications if necessary.