文章詳情頁
php代碼運行報錯
瀏覽:203日期:2022-06-03 09:36:01
問題描述
Warning: mysqli_query() expects at least 2 parameters, 1 given in D:phpstudy_proWWWallusers.php on line 31Warning: mysqli_num_rows() expects parameter 1 to be mysqli_result, null given in D:phpstudy_proWWWallusers.php on line 33
下面是代碼
//查詢數(shù)據(jù)表中的所有數(shù)據(jù)
$result=mysqli_query("SELECT * FROM users BY id DESC");
//獲取數(shù)據(jù)表的數(shù)據(jù)條數(shù)
$dataCount=mysqli_num_rows($result);
//echo $dataCount;
//打印輸出所有數(shù)據(jù)
問題解答
回答1:mysqli_query()接收兩個參數(shù),第一個參數(shù)是MySQL 連接
上一條:中文phpword文檔下一條:您的function文件哪里有啊。
相關(guān)文章:
1. 關(guān)docker hub上有些鏡像的tag被標(biāo)記““This image has vulnerabilities””2. boot2docker無法啟動3. docker-compose中volumes的問題4. java - SSH框架中寫分頁時service層中不能注入分頁類5. docker安裝后出現(xiàn)Cannot connect to the Docker daemon.6. nignx - docker內(nèi)nginx 80端口被占用7. dockerfile - 為什么docker容器啟動不了?8. docker images顯示的鏡像過多,狗眼被亮瞎了,怎么辦?9. docker容器呢SSH為什么連不通呢?10. 關(guān)于docker下的nginx壓力測試
排行榜

熱門標(biāo)簽
網(wǎng)公網(wǎng)安備