Now let's take a look at the Mysql_fetch_field () function, which is to read the MySQL data table's example name, the field name. Let's take a look at its syntax.
Mysql_fetch_field (Data,field_offset)
The Mysql_fetch_field () function pairs like a recordset that returns a. mysql_query () function and returns success on an object, or false or failed
He has two parameters. Data and Field_offset
Data: Required if, the specified pointer is used. The data pointer is due to the mysql_query () function
Field_offset: Optional, from which record to start reading, do not write is code starting from 0.
Now let's look at a Mysql_fetch_field instance.
$sql = "SELECT * from a";
$result = mysql_query ($sql, $con);
while ($property = Mysql_fetch_field ($result)) {echo "Field name:". $property->name. "
";}
The result of the output is the name of all the fields in your data table.
http://www.bkjia.com/PHPjc/630897.html www.bkjia.com true http://www.bkjia.com/PHPjc/630897.html techarticle now let's take a look at the Mysql_fetch_field () function, the function is to read the MySQL data table example name, field name. Let's look at its syntax. Mysql_fetch_field (data,field_o ...