各位大神,请问select count(*)from student_info与select *from student_info有什么区别?

2025-04-17 09:03:22
推荐回答(1个)
回答1:

你加一个统计条目数的count()函数。两条语句就不是一个意思,区别大拉。

第一个是统计你所查询的条目数,student_info这个表实际有多少条数据运行select count(*)from student_info 这个语句就可以得到。
而select *from student_info 是查询student_info表中实际数据。