Doing those 2 checks is guaranteed to give out the expected result.
The .OK parameter is generated when you call .FromJSON, it expects a particular format of a response. For example, by default, OK = false
B4X:
'convert the json
Sub FromJSON As BANanoMySQLE
OK = False
If json.StartsWith("{") Or json.Startswith("[") Then
Dim m As Map = BANano.FromJson(json)
response = m.Get("response")
error = m.Get("error")
result = m.Get("result")
affectedRows = m.Get("affectedRows")
If response = "Success" Then
OK = True
End If
Else
response = json
error = json
result = NewList
affectedRows = -1
End If
Return Me
End Sub
So in your case, what is returned does not start with { or [ I wouldn't know why that is though. Perhaps if you log dbsql.json after you retrieve it might provide you with what is happening.
So in your case, what is returned does not start with { or [ I wouldn't know why that is though. Perhaps if you log dbsql.json after you retrieve it might provide you with what is happening.
If the result is 0, it means nothing was changed due to affected records being 0. Perhaps PM me your project I will check what could be happening.
Q(uestion). Are you running this from an external server or from your development server.
A(sumption). If you are running from an external webserver, did you update the BANano.PHPHost in AppStart to point to your external web server IP/Domain Name?
If the result is 0, it means nothing was changed due to affected records being 0. Perhaps PM me your project I will check what could be happening.
Q(uestion). Are you running this from an external server or from your development server.
A(sumption). If you are running from an external webserver, did you update the BANano.PHPHost in AppStart to point to your external web server IP/Domain Name?