Its working just fine, but, Im having problem with datetime fields. The data its inserted ok, but when I tryed to see in SQL Browser or SQLite Admin, gives wrong dates.
MY DATE FORMAT:
11/11/1973 12:00:00 AM
D/M/YYYY HH:MIN:SEC AM/PM
FORMAT IN ASP.NET:
11/11/1973 12:00:00 AM
M/D/YYYY HH:MIN:SEC AM/PM
PARSED DATE :
\/Date(121831200000)\/
DATE IN DB(SQLite Administrator):
30/12/1899 12:18:31
I solved sending the dates as Text, replacing the original sample with this:
B4X:
Dim d As New Dictionary(Of String, Object)(rdr.FieldCount)
For i As Integer = 0 To rdr.FieldCount - 1
If rdr.GetFieldType(i) Is GetType(Date) Then
If rdr.IsDBNull(i) = True Then
d(rdr.GetName(i)) = rdr.GetValue(i)
Else
d(rdr.GetName(i)) = rdr.GetDateTime(i).ToString("yyyy-MM-dd HH:mm:ss")
End If
Else
d(rdr.GetName(i)) = rdr.GetValue(i)
End If
Next
If there is anyway better please share. If not, you can update the Tutorial sample to this.