querybuilder icon indicating copy to clipboard operation
querybuilder copied to clipboard

The member p3 of type SqlKata.InsertClause cannot be used as a parameter value

Open higgs2 opened this issue 4 years ago • 0 comments

Perhaps I'm maybe just looking over it... but I'm getting this System.NotSupportedException exception for some reason when doing an insert. I don't do anything very exciting, it's just a simple table insert:

            var workflowActionsInfo = new List<object[]>();
            var workflowActionColumns = new[] {"Status", "Action", "CreationDate", "ActionId"};

            foreach (var workflowAction in workflowActions)
            {
                workflowActionsInfo.Add(new object[]
                {
                    "Pending", JsonConvert.SerializeObject(workflowAction), DateTime.Now.ToLongDateString(), workflowAction.ActionId
                });
            }

            this._database.Query("actions").Insert(workflowActionColumns, workflowActionsInfo);

It works with other tables, so I'm not entirely sure what the issue is here... I'll gladly give context if needed.

higgs2 avatar Apr 23 '20 15:04 higgs2