本文介绍了选择count(*)语句的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
在计算来自mySql数据库的记录数时出现问题:
Having a problem counting number of record from mySql database:
adpter = New MySqlDataAdapter("select count(*) from bookings where busNumber = '" & txtBusNumber.Text & "' and departTime = '" & cmbDepartTime.Text & "' and departDay = '" & cmbDay.Text & "'", con)
Dim myDataSet = New DataSet
adpter.Fill(myDataSet, "bookings")
txtCount.Text = myDataSet.Tables("bookings").Rows(0).Item(0)
我得到0 ...
请帮助
I get 0...
please Help
推荐答案
这篇关于选择count(*)语句的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!