ASP.NET: Insert and Update Server Actions fail

OS info

  • Operating System : Windows 10.0.17134
  • Wappler Version : 1.7.1

Both Insert and Update Server Actions fail

Steps to reproduce

  1. Create very simple Insert Server Action
    2 Create Insert Form using Boostrap Form Generator.
  2. Save file
  3. File loads correctly but upon entering data and submitting form using SAVE button ( the insert process)
    the task fails due to “Cannot access child value on Newtonsoft.Json.Linq.JValue.”
    5.Stack Trace String makes references to various dmx files with paths beginning with d:\develop\DMXServerConnect… SecondInsert.aspx.zip (9.1 KB)

report_2018-11-28_16-48-14.zip (135.2 KB)

This has occurred repeatedly with similar failures to find the “child value”. I have used different data tables and all have the same problem.

Any help in this matter will be greatly appreciated

Hi @wld,
The bug report function in Wappler is for problems related to the program, i.e. bugs in the UI, panels, etc.

If you are experiencing issues with your pages not functioning properly, no need to use this option - just create a topic, explaining the issue.

So in your case the insert and update actions are not working, is that right?
Can you please paste the exact error message you see in your browser as described here:

Debugging Problems

Hi Teodor:

Attached are fiver screen shots of the error page. The first is of a simple insert action. The debugging message reads “Cannot access child value on NewtonSoft.json.Linq.JValue.” This is followed by the table description with null values and a SQL statement and then a series of “post “ values with no values. The file is 2018-12-29-10-39-20insert.png. The error message appears on 2018-12-29-10-17-21.png. and unfortunately, the lengthy bit about the files used in putting together the SQL is cut off on the right as it does not line wrap. As you can see in the Firefox developer the error message is returned as a Server Error 500.

I am assuming that the values entered in the form are not being captured. The data base has an identity column that automatically increments every time an insert is made.

The remaining attachments are the error messages when the an update is attempted. The error message is long and is broken into three segments : update A, update and update. These are similar to the insert error message and I am guessing it refers to the fact that the data elements are missing.

Other than this I do not know what to do.

Many thanks for any help.

Bill Duschatko

It seems to me you are mixing the database fields types ie storing strings in numeric fields…

So check those

I wish that was the case, and had previously looked at possible conflicts. The attachments are screen shots of the error message and the Insert Query Setup. The target table consists of an identity column ( int) and the two columns Town and Category are varchar(50). MSSQL Server. No problems in past with this design.

Just to make sure I made a new database with one table. The table consists of two columns, name and state. Both are varchar(50) columns. The entries are less then 10 letters. The result is still the same. Refer to Error Report DEC30.

Out of desperation I reloaded a Dreamweaver 2017 program and tired the same things using it. Same failure, same errors. I have uninstalled and reinstalled Wappler, but it seems that something is not being cleaned up through this process.

Something is wrong somewhere and I have no idea where to look for it.

(Attachment Error Report Dec 30.txt is missing)

Could make sure those fields have the “required” validation in the server connect action and that the submitting form has the method set to “post”

Inspect the submitted data in devtools to see if the right data is posted.

Seems fields are missing values or wrongly posted/ named

Added “required” data validation to the two fields. The same error has been returned. Yes, there is no data in the fields, and that is the root of the error as best as I can determine, but no data is generated. Form method is set to “post” and

The simple page can be found at http://wldgroup.com/september/Dec30.html

The attached file is the error page from chrome dev tools.

Thanks,

Bill

(Attachment ErrorMessageLate Dec30.txt is missing)

ErrorMessageLate Dec30.zip (9.8 KB)
Hi George:
I do not know if you received the earlier attachment so I am re sending it . Clearly without the ability to Insert or Update I can not accomplish any work using databases. I am willing to unistall/reinstall any components that can make Wappler work for me. The only thing that I can imagine at this point is that some how one of the files that gets called has been corrupted. But I have gotten to the point where my knowledge and ability is insufficient to make any progress.

Thanks for your assistance in solving these problems.

I loaded the newest version of JNode and got still am unable to either accomplish a simple INSERT or UPDATE of data. However, after the update in JNode, the error message indicates the data is being written. See Error MessageJanuary5 and compare it to ErrorMessage Dec 30. The simple insert still fails because the child values are not being picked up … "Cannot access child value on Newtonsoft.Json.Linq.JValue.",

I aam still at a loss of how to go forward and fix this problem, Can you offer any assistance ?

Missing attachments from Last MessageNewZip.zip (3.7 KB)

Hi @wld,

did you solve the problem?

I get the same error message on ASP.NET.

Yes the problem is naming of the fields in form and database. They have to have same case and that is why keeping them lowercase is best

Hi @George,

I renamed all fields in lowercase but still get the problem. I made a new form with the generator to make sure I don’t miss anything.

https://intranet.vewa.de:10444/anmeldung/register.aspx

Can you please lookup the link if you find anything else which could cause the problem?

Thanks a lot for your help in advance.

This might be a duplicate reply, because I cannot see that my earlier reply is posted anywhere. It seems like you and I might be the only people using Wappler with ASP.Net. We get the same failures when trying to post ( INSERT) data, and I presume you will get the same error if you attempt to UPDATE a record. The error that I get is is " unable to access child value on NewtonSoft.JSON.Linq.JValue" and your page fails in the same manner. This error message is return for both INSERT and UPDATE server actions and makes the program unusable. I have requested help on this many times and each time I bring up the error message the conversation ends. About two months ago, I reported a possible bug in the UPDATE server action using ASP.net. It was recognized and corrected in another release.

I hope for our sake that this can be resolved.

I think that I found the problem and I’m working on a solution. Is this error only with the insert/update or is the select also giving an error?

Hi @patrick

I get this error only with insert/update. Select works fine. What about you @wld?

My problem is limited to insert/update actions, although I have noticed that from time to time the set value function does not seem to be recognized, as this can be worked around it was not a series problem compared to insert/update failure.

This should be now solved in Wappler 1.8.0

1 Like