I have designed a form that reads data from a SQL table, then, if the table contains a DocID, I use SwapDOMwithDocument qRules command. I'm not saving the data back to a form library, I just want to store the data in DBXL, then I have the data mapped to the same SQL table. My intent is to allow DBXL to take care of any changes, thus removing security issues between the user, SQL Server, and the form. I also have a trigger on the SQL table that deletes the old entry, then DBXL inserts the new one. Thanks Hilary for this method.
This is working just fine when entries are replaced with new DBXL entries. However, if I'm simply updating data, I'm getting the error "InfoPath cannot submit the form. An error occurred while the form was being submitted." in preview mode, and in the browser I get "An error occurred while trying to connect to a Web service.", with a log id of 5567. Here is the error log entry I retrieved from the server:
06/20/2014 14:12:36.38 SPUCWorkerProcess.exe (0x1340) 0x2F30 InfoPath Forms Services Runtime - Data Connections eq8m Warning Form submission failed. (User: , Form Name: PersonalInfoSheet, IP: , Request: , Form ID: urn:schemas-microsoft-com:office:infopath:PersonalInfoSheet:-myXSD-2013-02-04T19-12-58, Type: DataAdapterException, Exception Message: The remote server returned an error: (400) Bad Request. The remote server returned an error: (400) Bad Request.) 86d5e6ba-7545-4d26-8a8c-1c182988d768
Do I need a separate connection for updates?