Ask for help (maybe) in query.value(0).
Solved
General and Desktop
-
Here is the code:
QString s = QString("SELECT Numone, Numtwo FROM number");
query.exec(s);
while(query.next()){
QString name1 = query.value(0).toString();
QString name2 = query.value(1).toString(); <--it,'s wrong T^T
qDebug()<<name1; / /Numone
qDebug()<<name2; / /Numtwo
}I want it to output the data of both Numone and Numtwo, however, it just showed me Numone.
How can I get the data of both Numone and Numtwo?
Thanks every viewer. -
Hi,
did u check wat value ur getting from dB, and
is value present in dB for Numtwo?.Thanks,
-
@Pradeep-Kumar Thanks for your respond!
I have solved it after your suggestion. -