JerichoDummyLearner
Member
Hi! its me again... the thing is, I want to have my query result as string and assign it to a variable.
My Sql query is this
sql.validate=SELECT `UserID` FROM `tbl_userinfo` WHERE `Username` = ? AND `Password`= ?
so basically, I wanted to take the data from UserID from the results of the query, i've been stuck in here, I tried j.getstring, etc.. but I don't really know what to do.
B4X:
Dim req As DBRequestManager = CreateRequest
Dim cmd As DBCommand = CreateCommand("validate", Array(uName.text,pWord.text))
Wait For (req.ExecuteQuery(cmd, 0, Null)) JobDone(j As HttpJob)
If j.Success Then
req.HandleJobAsync(j, "req")
Wait For (req) req_Result(res As DBResult)
'work with result
req.PrintTable(res)
My Sql query is this
sql.validate=SELECT `UserID` FROM `tbl_userinfo` WHERE `Username` = ? AND `Password`= ?
so basically, I wanted to take the data from UserID from the results of the query, i've been stuck in here, I tried j.getstring, etc.. but I don't really know what to do.