Page 1 of 1

BigCommerce Insert Issue

Posted: Sat 18 Aug 2018 14:46
by StonewareSoftware
We receive an error when trying to execute the following SQL in OAUTH. It works fine in Basic Authentication.

insert into optionsetsoptions (optionid, optionsetid, displayname, sortorder, isrequired) values(2116,1395,'COLOR',0,true)

It does trigger an exception, however the exception message is blank.

exception {""} Devart.Data.Bigcommerce.BigcommerceException
Source "Devart.Data.SqlShim"
Stack Trace Devart.Data.SqlShimCommand.InternalExecute(CommandBehavior behavior, IDisposable stmt, Int32 startRecord, Int32 maxRecords)" & vbCrLf & " at Devart.Common.DbCommandBase.InternalExecute(CommandBehavior behavior, IDisposable stmt, Int32 startRecord, Int32 maxRecords, Boolean nonQuery)" & vbCrLf & " at Devart.Common.DbCommandBase.ExecuteDbDataReader(CommandBehavior behavior, Boolean nonQuery)" & vbCrLf & " at Devart.Common.DbCommandBase.ExecuteDbDataReader(CommandBehavior behavior)" & vbCrLf & " at Devart.Common.DbCommandBase.ExecuteScalar()" & vbCrLf & " at BigCommerceLibrary.BCConnect.InsertedData(String Query) in BigCommerceLibrary\BigCommerceLibrary\BCConnect.vb:line 398"

We have also tried this with SkyVia and the OAUTH doesn't work however the basic authentication does there as well.
We can insert into other tables as expected with both OAUTH and Basic with our code and on Skyvia.

Can you give me some advice on how to correct this error?, This keeps us from being able to add new product that have SKU's since we cant add the options values.

Re: BigCommerce Insert Issue

Posted: Mon 20 Aug 2018 21:10
by StonewareSoftware
This appears to be an issue with the http error code returned. Error 422 is returned. The driver (Devart.BigCommerce) is not trapping this error or it's subsequent message.

Using a normal HTTP Post, we can see the error 422 and reading the stream, we can see the details as to why.

May I suggest an update to the BigCommerce Connector to trap error 422 and subsequently the response stream in order to show the returned message from BigCommerce.

Thanks

Re: BigCommerce Insert Issue

Posted: Thu 23 Aug 2018 12:52
by Pinturiccio
We have reproduced the issue. We will investigate it and post here about the results as soon as possible.

Re: BigCommerce Insert Issue

Posted: Wed 19 Sep 2018 14:07
by Pinturiccio
We have fixed the bug with not inserting data to the BigCommerce OptionSetsOptions object via an OAuth connection. We will post here when the corresponding build of dotConnect for BigCommerce is available for download.

Re: BigCommerce Insert Issue

Posted: Thu 20 Sep 2018 12:36
by Pinturiccio
New build of dotConnect for BigCommerce 1.7.744 is available for download now!
It can be downloaded from https://www.devart.com/dotconnect/bigco ... nload.html (trial version) or from Customer Portal (for users with valid subscription only).
For more information, please refer to viewtopic.php?t=37709