Home > php教程 > php手册 > fetchAll()与mysql_fetch_array()的区别详解

fetchAll()与mysql_fetch_array()的区别详解

WBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWB
Release: 2016-06-13 11:51:27
Original
1090 people have browsed it

同一个查询语句:
fetchAll():

复制代码 代码如下:


array(1) {       
   [0]=>  array(6) {             
     ["id"]=>    string(2) "15"          
                   [0]=>    string(2) "15"        
            ["lot_sellid"]=>    string(20) "00000000000000003877"    
     [1]=>    string(20) "00000000000000003877"              
      ["lotteryid"]=>    string(2) "D8"               
            [2]=>    string(2) "D8"                 
        }  
}


mysql_fetch_array():

复制代码 代码如下:


array(6) {
                      [0]=> string(2) "15"
                      ["id"]=> string(2) "15"
                      [1]=> string(20) "00000000000000003877"
                      ["lot_sellid"]=> string(20) "00000000000000003877"
                      [2]=> string(2) "D8"
                      ["lotteryid"]=> string(2) "D8" 
}


Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Latest Issues
PHP fetchall usage
From 1970-01-01 08:00:00
0
0
0
PDO query data error
From 1970-01-01 08:00:00
0
0
0
Form not fetched via POST
From 1970-01-01 08:00:00
0
0
0
Popular Recommendations
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template