Error while inserting a Boolean value from data table to MYSQL DB using the Database INSERT option


#1

Error while inserting NULL from data table to MYSQL DB using the Database INSERT option into a datatype BOOLEAN. The same values worked if we are using the INSERT command on the DB.

Error prompts the value which we have in datatable is STRING type and it should be a BOOLEAN Value. Have seen other posts and they suggest to use a every row insert option. Would like to know if the database INSERT option will work the same way.


#2

Hi @Ashok_Chowdary,
Actually the Insert Activity inserts a compatible DataTable variable in an existing Table.
It returns the number of rows affected.
If the constraints on the table aren’t met, the activity will fail and all the written rows will be saved.

So if you are doing something else than this then they may not work. If you want to add row wise to the database then, you can use the “Add Data Row” Activity.

Let us know further.
Regards,
Jiban


#3

Thanks, instead of creating a data table and from there INSERT data into database we directly did a DB Query to INSERT these variables for each iteration. It worked.